protected override void Collect() { string tabName = "Software Information"; AddDataPair(tabName, "Default browser", OSCollectorHelper.GetDefaultBrowser()); // Internet Explorer AddDataPair(tabName, "Internet Explorer version", OSCollectorHelper.GetIEVersion()); AddDataPair(tabName, "Internet Explorer Extensions" , Html.AddLinkToHiddenContent(DetectOtherSoftware.GetIEExtensions())); // Google Chrome AddDataPair(tabName, "Is Google Chrome installed?", DetectOtherSoftware.GetGoogleChromeInfo()); // Mozilla Firefox AddDataPair(tabName, "Is Mozilla Firefox installed?", DetectOtherSoftware.GetFirefoxInfo()); AddDataPair(tabName, "Is anti-virus software detected?", DetectSecuritySoftware.GetAntiVirusProgramsInstalled()); AddDataPair(tabName, "Is firewall software detected?", DetectSecuritySoftware.GetFirewallProgramsInstalled()); // Add the list of Windows Add/Remove Programs only if the menu is selected if (FormArguments.menuInstalledPrograms || FormArguments.details >= 3) { var listOfPrograms = InstalledProgramsHelper.ToList(); int count = InstalledProgramsHelper.installedProgramsList.Count; AddDataPair("Windows Add/Remove Programs", "Installed programs", count + " products found " + listOfPrograms); } if (FormArguments.menuWindowsUpdates || FormArguments.details >= 3) { AddDataPair("Windows Add/Remove Programs", "Installed Windows updates", InstalledProgramsHelper.GetWindowsUpdatesInfo()); } }
protected override void Collect() { string title = "Correlation"; AddDataPair(title, "Rules support", ProductDetection.Vugen.correlationRulesSupport); //check for ignored content only on versions > 11.50 if (ProductDetection.Vugen.isNew) { AddDataPair(title, "Ignored content types", ProductDetection.Vugen.correlationIgnoredContent); } AddDataPair(title, "Rules", CorrelationRules.GetListOfRulesText()); AddDataPair(title, CorrelationRules.settingsFileName + " content", Html.AddLinkToHiddenContent(CorrelationRules.GetRawContent())); //BBHOOK vesrion title = "Files"; AddDataPair(title, "Bbhook version", ProductDetection.Vugen.bbhookVersion); //AddStringsToDictionary("Miscellaneous registry settings", "Registry keys", importantRegKeys.ToString()); var iniContent = IniParser.ToHtml(Path.Combine(ProductDetection.Vugen.ConfigFolder, "vugen.ini")); AddDataPair(title, "vugen.ini content", Html.AddLinkToHiddenContent(iniContent)); title = "Log Files"; AddDataPair(title, "Registration failures", Html.AddLinkToHiddenContent(Helper.GetRegistraionFailuresContent())); if (ProductDetection.Vugen.isNew) { //TODO see how fast we parse 10MB log file int lines = 50; string vugenLogContent = Helper.GetLastLinesFromFile(2048 * 1024, System.IO.Path.GetTempPath() + "HP.LR.VuGen.log", lines); AddDataPair(title, "Last " + lines + " lines of HP.LR.VuGen.Log", Html.AddLinkToHiddenContent(vugenLogContent)); } }
public static string GetFlexRoInfo() { try { StringBuilder output = new StringBuilder(); output.Append(Html.B("Flex > RTMP") + Html.br); output.Append(Html.CheckBox(ini.GetBoolSetting("RTMP_RO", "GenerateReceiveStream", true)) + "Generate single step for RTMP/T stream handling" + Html.br); output.Append(Html.B("Flex > Configuration") + Html.br); bool useExternalVm = ini.GetBoolSetting("FLEX_RO", "UseExternalVm", false); output.Append(Html.CheckBox(useExternalVm) + "Use external JVM" + Html.br); int indentLevel = 8; if (useExternalVm) { output.Append(Html.IndentWithSpaces(indentLevel) + "External JVM path: " + ini.GetSetting("FLEX_RO", "ExternalVmPath", "") + Html.br); } output.Append(Html.CheckBox(ini.GetBoolSetting("FLEX_RO", "ExternalDsParser", false)) + "Use GraniteDS configuration" + Html.br); output.Append(Html.IndentWithSpaces(indentLevel) + "Maximum formatted Request/Response size to print (in characters): " + ini.GetSetting("FLEX_RO", "MaxReqResSizeToWriteForLog") + Html.br); output.Append(Html.B("Flex > Externalizable objects") + Html.br); bool EncodeExternalizableObject = ini.GetBoolSetting("FLEX_RO", "EncodeExternalizableObject", false); output.Append(Html.CheckBox(!EncodeExternalizableObject) + "Do not serialize externalizable objects" + Html.br); if (EncodeExternalizableObject == true) { output.Append(Html.CheckBox(true) + "Serialize objects using:" + Html.br); bool UseServerParserToParseAmf3 = ini.GetBoolSetting("FLEX_RO", "UseServerParserToParseAmf3", false); bool isCheckBoxDisabled = false; output.Append(Html.CheckBox(!UseServerParserToParseAmf3, isCheckBoxDisabled, indentLevel) + "LoadRunner AMF serializer" + Html.br); isCheckBoxDisabled = UseServerParserToParseAmf3 ? false : true; output.Append(Html.CheckBox(UseServerParserToParseAmf3, isCheckBoxDisabled, indentLevel) + "Custom Java classes" + Html.br); indentLevel = 12; output.Append(Html.CheckBox(ini.GetBoolSetting("FLEX_RO", "UseFlexGlobalJars", false), isCheckBoxDisabled, indentLevel) + "Use Flex LCDS/BlazeDS jars" + Html.br); bool UseAdditionalJars = ini.GetBoolSetting("FLEX_RO", "UseAdditionalJars", false); string additionalJarsList = ""; if (UseAdditionalJars) { additionalJarsList = Html.AddLinkToHiddenContent(GetFlexAdditionalJarFilesInfo(isCheckBoxDisabled)); } output.Append(Html.CheckBox(UseAdditionalJars, isCheckBoxDisabled, indentLevel) + "Use additional jars " + additionalJarsList + Html.br); } output.Append(Html.br + ini.GetSetting("FLEX_RO", "FlexJvmParams") + Html.br); return(output.ToString()); } catch (Exception ex) { Logger.Error(ex.ToString()); return(Html.Error(ex.Message) + Html.br); } }
public static string ToList() { installedProgramsList.Sort(); List <string> temp = installedProgramsList.ConvertAll(obj => obj.ToString()); String output = String.Join(Html.br, temp.ToArray()); return(Html.AddLinkToHiddenContent(output)); }
protected override void Collect() { var filePath = Path.Combine(ProductDetection.FullLR.ConfigFolder, "wlrun7.ini"); AddDataPair("Configuration files", "wlrun7.ini file content", Html.AddLinkToHiddenContent(IniParser.ToHtml(filePath))); AddDataPair("Connections", "Connected load generators", ControllerSettingsCollectorHelper.GetConnectedLGs()); //filePath = Path.Combine(ProductDetection.FullLR.WebControllerFolder, @"webapp\server\lib\config\configuration.json"); //AddDataPair("Web Controller", "Settings", Html.AddLinkToHiddenContent(ControllerSettingsCollectorHelper.WebControllerPorts())); }
protected override void RenderHtml() { HtmlTable t = new HtmlTable(cells); t.id = "processes"; t.tableClass = "alternateColors"; t.AddTableHead(new List <String> { "Process Name", "Memory Usage", "Process ID" }, true); buffer.Append(Html.AddLinkToHiddenContent(t.ToString())); }
protected override void RenderHtml() { HtmlTable htmlTable = new HtmlTable(cells); htmlTable.id = "dlls"; htmlTable.tableClass = "alternateColors"; htmlTable.AddTableHead(new List <String> { "DLL name", "File Version", "Last Modified" }); buffer.Append(Html.AddLinkToHiddenContent(htmlTable.ToString())); }
internal static string GetJavaIniOption(string option) { try { var setting = ini.GetSetting(tabName, option); return(setting.Length < 100 ? setting : Html.AddLinkToHiddenContent(setting.Replace(";", Html.br))); } catch (Exception ex) { Logger.Error(ex.ToString()); return(Html.ErrorMsg() + " " + option + " option"); } }
protected override void Collect() { var dh = new DataHolder("Hardware Information"); dh.dataPairs.Add("CPU", OSCollectorHelper.GetProcessorNameString()); dh.dataPairs.Add("Processor Count", Environment.ProcessorCount.ToString()); dh.dataPairs.Add("Total Memory", OSCollectorHelper.GetMemoryInfo()); dh.dataPairs.Add("Hard Drives", OSCollectorHelper.GetHardDrivesInformation()); dh.dataPairs.Add("Monitor information", OSCollectorHelper.GetMonitorsInfo()); //IPCONFIG /ALL if (FormArguments.network || FormArguments.details >= 3) { dh.dataPairs.Add("Network cards & IPs", OSCollectorHelper.GetNetworkCardsInfo()); dh.dataPairs.Add("Output of 'ipconfig /all' command", Html.AddLinkToHiddenContent(Html.Pre(OSCollectorHelper.IpConfig()))); } dataHolders.Add(dh); }
public static string GetNetworkCardsInfo() { StringBuilder output = new StringBuilder(128); // split the output by \r\n string[] rows = OSCollectorHelper.SystemInfo.Split(new Char[] { '\r', '\n', '\t' }, StringSplitOptions.RemoveEmptyEntries); int startingRow = 0; int i = 0; foreach (string row in rows) { if (row.Contains("Network Card")) { startingRow = i + 1; output.Append(row.Replace("Network Card(s): ", "") + " "); break; } i++; } StringBuilder updates = new StringBuilder(); if (startingRow != 0) { for (i = startingRow; i < rows.Length; i++) { if (rows[i].Replace(" ", "").StartsWith("[")) { updates.Append(Html.B(rows[i]) + Html.br); } else { updates.Append(" " + rows[i] + Html.br); } } output.Append(Html.AddLinkToHiddenContent(updates.ToString())); } return(output.ToString()); }
protected override void Collect() { var dh = new DataHolder("Operating System"); dh.dataPairs.Add("Machine name", System.Environment.MachineName); dh.dataPairs.Add("Full name", OSCollectorHelper.GetOSFullNameFormatted()); dh.dataPairs.Add("Root directory", OSCollectorHelper.GetOSRootDir()); // If VuGen is not installed product version will be 0.0 //if (ProductDetection.Vugen.version >= new Version(11, 04) && ProductDetection.Vugen.version <= new Version(12, 01)) // dh.dataPairs.Add("Is OS supported?", OSCollectorHelper.IsOSSupportedInfo()); dh.dataPairs.Add("Language", OSCollectorHelper.language); dh.dataPairs.Add("Locale", OSCollectorHelper.GetOSLocaleInfo()); dh.dataPairs.Add("Is OS Virtualized?", OSCollectorHelper.IsOSVirtualizedInfo()); dh.dataPairs.Add("Is 3GB switch enabled?", OSCollectorHelper.Is3GBSwitchEnabled()); dh.dataPairs.Add("Data Execution Prevention", OSCollectorHelper.DepInfo()); dh.dataPairs.Add("User Account Control", OSCollectorHelper.UACInfo()); dh.dataPairs.Add("Is user Admin?", Html.BoolToYesNo(OSCollectorHelper.IsUserInAdminGroup())); dh.dataPairs.Add("Is user connected remotely?", Html.BoolToYesNo(SystemInformation.TerminalServerSession)); dh.dataPairs.Add("Is Windows firewall enabled?", OSCollectorHelper.IsWindowsFirewallEnabled()); dh.dataPairs.Add("Is secondary logon enabled?", OSCollectorHelper.IsSecondaryLogonEnabledInfo()); dataHolders.Add(dh); dh = new DataHolder("Environment information"); dh.dataPairs.Add("System environment variables", Html.AddLinkToHiddenContent(OSCollectorHelper.GetEnvVariables())); dh.dataPairs.Add("User environment variables", Html.AddLinkToHiddenContent(OSCollectorHelper.GetUsrEnvVariables())); dh.dataPairs.Add("Kerberos configuration", OSCollectorHelper.GetKerberosConfiguration()); var lsp = Html.B(OSCollectorHelper.GetNumberOfInstalledLSPs() + " entries found ") + Html.AddLinkToHiddenContent(OSCollectorHelper.GetInstalledLSPs()); dh.dataPairs.Add("Layered Service Providers", lsp); dh.dataPairs.Add("AppInit_DLLs registry value", OSCollectorHelper.GetAppInitDLLsInfo()); //LoadAppInit_DLLs registry is only availbale in Windows 7 and later if (Environment.OSVersion.Version >= new Version(6, 1)) { dh.dataPairs.Add("LoadAppInit_DLLs registry value", OSCollectorHelper.GetLoadAppInitDLLsInfo()); } dataHolders.Add(dh); }
public static string GetKerberosConfiguration() { StringBuilder krb5Content = new StringBuilder(); // Get the KRB5_CONFIG environment variable string krb5File = OSCollectorHelper.GetEnvVariable("KRB5_CONFIG"); // If KRB5_CONFIG is not set if (krb5File.Contains("Not set")) { // Sometimes KRB5_CONFIG is not set because the krb5.ini is placed in C:\Windows Logger.Info("No KRB5_CONFIG eng. variable found. Searching for the file in C:\\Windows"); if (File.Exists(@"C:\Windows\krb5.ini")) { krb5File = @"C:\Windows\krb5.ini"; } else { return("Not detected"); } } else { krb5Content.Append(Html.B("KRB5_CONFIG = ") + krb5File + Html.br); } // Check if KRB5_TRACE exists and if it does add it's value var krb5trace = OSCollectorHelper.GetEnvVariable("KRB5_TRACE"); if (!krb5trace.Contains("Not set")) { krb5Content.Append(Html.B("KRB5_TRACE = ") + krb5trace + Html.br + Html.br); } // Get the content of krb5.ini Logger.Info("Getting the content from " + krb5File); krb5Content.Append("krb5.ini " + Html.AddLinkToHiddenContent(IniParser.ToHtml(krb5File))); return(krb5Content.ToString()); }
public override string ToString() { return(Html.CheckBox(enabled) + name + " " + Html.AddLinkToHiddenContent(RulesToHtml()) + Html.br); }
public override string ToString() { string tns = tnsContent != "" ? TNSNAMESORA + " " + Html.AddLinkToHiddenContent(tnsContent) : "No " + TNSNAMESORA + " found!"; return(String.Format("{0} x{1} client found in {2}{3} {4}", Html.B(name), bits, home, Html.br, tns)); }
protected override void Collect() { var ro = new DetectRecordingOptions(); base.OnRaiseProgressUpdate(); var title = "WEB (HTTP/HTML)"; AddDataPair(title, "Last used recording options", "User " + Html.B(Environment.UserName) + " " + Html.AddLinkToHiddenContent(ro.ToString(), true)); if (ProductDetection.Vugen.isNew) { title = "TruClient IE"; AddDataPair(title, "Is enabled?", VugenProtocolsCollectorHelper.TruClientIE.IsEnabled()); AddDataPair(title, "RRE version", VugenProtocolsCollectorHelper.TruClientIE.GetTCIEVersion()); AddDataPair(title, "General > Browser settings", Html.AddLinkToHiddenContent(VugenProtocolsCollectorHelper.TruClientIE.GetGeneralBrowserSettings())); AddDataPair(title, "General > Interactive options", Html.AddLinkToHiddenContent(VugenProtocolsCollectorHelper.TruClientIE.GetInteractiveOptions())); } if (ProductDetection.Vugen.version > new Version("11.00")) { title = "TruClient Firefox"; AddDataPair(title, "Firefox version", VugenProtocolsCollectorHelper.TruClientFF.GetFirefoxVersion()); AddDataPair(title, "General > Browser settings", Html.AddLinkToHiddenContent(VugenProtocolsCollectorHelper.TruClientFF.GetBrowserSettings())); AddDataPair(title, "General > Interactive options", Html.AddLinkToHiddenContent(VugenProtocolsCollectorHelper.TruClientFF.GetInteractiveOptions())); if (ProductDetection.Vugen.version >= new Version("11.50")) { AddDataPair(title, "Lists DACLs", Html.AddLinkToHiddenContent(VugenProtocolsCollectorHelper.TruClientFF.GetUrlAclInfo())); } } //TODO test on 11 title = "Java protocols"; AddDataPair(title, "Classpath", VugenProtocolsCollectorHelper.Java.GetJavaIniOption("Java_Env_ClassPath")); AddDataPair(title, "VM Params", VugenProtocolsCollectorHelper.Java.GetJavaIniOption("Java_VM_Params")); AddDataPair(title, "Use VM params during replay?", VugenProtocolsCollectorHelper.Java.GetJavaIniBoolOption("Java_SaveParams")); AddDataPair(title, "Use classic Java", VugenProtocolsCollectorHelper.Java.GetJavaIniBoolOption("Java_Classic")); AddDataPair(title, "Prepend classpath to -Xbootclasspath", VugenProtocolsCollectorHelper.Java.GetJavaIniBoolOption("Java_Prepend_Classpath")); title = "Citrix"; var ctrxClient = new CitrixHelper.Client(); AddDataPair(title, "Is Citrix client installed?", ctrxClient.GetCitrixClientInfo()); //if (citrixClient.isInstalled) // AddDataPair(title, "Is client version supported?", citrixClient.GetClientVersionSupportedInfo()); AddDataPair(title, "Is Citrix registry patch installed?", ctrxClient.GetCitrixRegistryPatchInfo()); AddDataPair(title, "Recording options", Html.AddLinkToHiddenContent(VugenProtocolsCollectorHelper.Citrix.GetCitrixRecOptions())); AddDataPair(title, "Citrix_XenApp correlation rules enabled?", CorrelationRules.IsGroupEnabledText("Citrix_XenApp")); title = "Dot Net"; AddDataPair(title, "Recording options", Html.AddLinkToHiddenContent(VugenProtocolsCollectorHelper.DotNet.GetDotNetRecOptions())); AddDataPair(title, "Filters", Html.AddLinkToHiddenContent(VugenProtocolsCollectorHelper.DotNet.GetDotNetFilters())); title = "RDP"; AddDataPair(title, "RDP client version", DetectOtherSoftware.GetRDPClientVersion()); AddDataPair(title, "RDP recording options", Html.AddLinkToHiddenContent(VugenProtocolsCollectorHelper.Rdp.GetRdpRecOptions())); title = "FLEX, AMF"; AddDataPair(title, "Recording options", Html.AddLinkToHiddenContent(VugenProtocolsCollectorHelper.FlexAmf.GetFlexRoInfo())); AddDataPair(title, "Other settings", VugenProtocolsCollectorHelper.FlexAmf.GetFlexInfo()); AddDataPair(title, "Flex correlation rules enabled?", CorrelationRules.IsGroupEnabledText("Flex")); title = "Siebel Web"; AddDataPair(title, "Is Siebel correlation library used?", VugenProtocolsCollectorHelper.SiebelWeb.GetSiebelDllVersionInfo()); AddDataPair(title, "Correlation rules", VugenProtocolsCollectorHelper.SiebelWeb.GetIsSiebelCorrelationEnabledInfo()); }
public static string GetOSLocaleInfo() { try { var culture = Thread.CurrentThread.CurrentUICulture; NumberFormatInfo nfi = culture.NumberFormat; return(String.Format("{0}, decimal separator is \"{1}\" group separator is \"{2}\", list separator is \"{3}\" {4}", culture.Name, nfi.NumberDecimalSeparator, nfi.NumberGroupSeparator, culture.TextInfo.ListSeparator, Html.AddLinkToHiddenContent(GetOSLocaleDetails()))); } catch (Exception ex) { Logger.Error(ex.ToString()); return(ex.Message); } }
protected override void Collect() { var title = "HP Citrix Agent Information"; var ctrxAgent = new CitrixHelper.Agent(); AddDataPair(title, "Citrix Agent", ctrxAgent.ToString()); if (ctrxAgent.isInstalled) { AddDataPair(title, "Agent configuration", Html.AddLinkToHiddenContent(ctrxAgent.GetIniContentInfo())); AddDataPair(title, "Citrix registry keys", ctrxAgent.GetImptKeyContent()); AddDataPair(title, "Is text trapping driver installed?", Html.BoolToYesNo(ctrxAgent.isTextTrappingDriverInstalled) + ctrxAgent.textTrappingDriverVersion); if (ctrxAgent.isTextTrappingDriverInstalled) { AddDataPair(title, "Is text trapping driver signed?", ctrxAgent.driverSignedInfo); AddDataPair(title, "Text trapping driver state", ctrxAgent.textTrappingDriverState); } } //################ //RDP Role Detection //################ title = "HP RDP Agent Information"; //AddDataPair(title, "Is RDP access allowed?", DetectOtherSoftware.IsRDPAccessAllowedInfo()); AddDataPair(title, "Is RDP Role installed?", DetectOtherSoftware.IsRDPRollInstalledInfo()); AddDataPair(title, "HP RDP Agent", DetectOtherSoftware.RDPAgentInfo()); //############# //VTS DETECTION //############# Logger.Info("Collecting VTS information"); var vts = new VirtualTableServer(); title = "HP Virtual Table Server"; if (vts.IsInstalled) { AddDataPair(title, "Is VTS installed?", vts.GetProductNameVersionDateFormatted()); AddDataPair(title, "Details", vts.GetExecutableFilesInfo()); AddDataPair(title, "Service status", vts.GetVTSServiceInfo()); } else { var vts2 = InstalledProgramsHelper.GetInstalledProgramByName(new Regex("[L|l]oad[R|r]unner - VTS")); var info = (vts2 != null) ? vts2.ToString() : "No"; AddDataPair(title, "Is VTS installed?", info); } //############# //LoadRunner Eclipse Add-in for Developers DETECTION //############# Logger.Info("Collecting LoadRunner Eclipse information"); title = "LoadRunner Eclipse Add-in for Developers"; var eclipsePlugin = InstalledProgramsHelper.GetInstalledProgramByName(new System.Text.RegularExpressions.Regex("LoadRunner Eclipse.*Developers")); if (eclipsePlugin != null) { AddDataPair(title, "Is Eclipse Add-in installed?", "Yes " + eclipsePlugin.DisplayName); AddDataPair(title, "Version", eclipsePlugin.DisplayVersion); AddDataPair(title, "Eclipse path", VuGenProperties.GetAttributeValue("Java.EclipseIdePath", "value", "Not found!")); } else { AddDataPair(title, "Is Add-in installed?", "No"); } //############# //LoadRunner Visual Studio 2012 Add-in for Developers DETECTION //############# Logger.Info("Collecting LoadRunner Eclipse information"); title = "LoadRunner Visual Studio Add-in for Developers"; var vsPlugin = InstalledProgramsHelper.GetInstalledProgramByName(new System.Text.RegularExpressions.Regex("LoadRunner Visual Studio 20[0-9]{2} Add")); string installed = vsPlugin != null ? Html.Yes + " " + vsPlugin.DisplayName + " version " + vsPlugin.DisplayVersion : Html.No; AddDataPair(title, "Is Add-in installed?", installed); //############# //BPM DETECTION //############# Logger.Info("Detecting BPM"); title = "HP Business Process Monitor"; var bpm = new BusinessProcessMonitorInfo(); //Logger.Info("BPM installation " + Html.Bool2Text(bpm.IsInstalled)); var bpmInstallInfo = (bpm.IsInstalled == true) ? bpm.GetProductNameVersionDateFormatted() : BusinessProcessMonitorInfo.GetBPMInstallationInfoFromUninstaller(); AddDataPair(title, "Is BPM installed?", bpmInstallInfo); if (bpm.IsInstalled == true || !bpmInstallInfo.Contains("No")) { AddDataPair(title, "Service status", BusinessProcessMonitorInfo.GetBPMServiceInfo()); AddDataPair(title, "BPM processes", Html.AddLinkToHiddenContent(BusinessProcessMonitorInfo.GetBPMProcessesInfo())); } //############# //ALM Platform Loader //############# if (FormArguments.details >= 2) { Logger.Info("Detecting ALM PL information"); AddDataPair("ALM Platform Loader", "Is ALM Platform Loader installed?", DetectOtherSoftware.GetALMPlatformLoaderInfo()); } //############# //QTP DETECTION //############# Logger.Info("Detecting UFT"); AddDataPair("HP Unified Functional Testing", "Is QTP/UFT installed?", DetectOtherSoftware.GetUFTInstallationInfo()); //############# //SITESCOPE DETECTION //############# if (FormArguments.details >= 2) { Logger.Info("Collecting SiteScope information"); AddDataPair("HP SiteScope", "Is SiteScope installed?", DetectOtherSoftware.GetSiteScopeInfo()); } }
/// <summary> /// PC LG 12.02 installed as a service saves 2 logs: /// C:\Program Files (x86)\HP\Load Generator\Temp\LoadRunner_agent_service.log /// C:\Program Files (x86)\HP\Load Generator\Temp\RemoteManagement_agent_service.log /// /// LR LG 12.02 installed as a process saves log in /// %Temp%\LoadRunner_agent_startup.log /// </summary> /// <returns></returns> public string GetLastLinesFromAgentLog() { try { string pathToAgentStartUpLog = Path.GetTempPath(); string nameOfAgentFile = "LoadRunner"; // if we have a load generator product installed which means PC Host and LoadRunner as well if (ProductDetection.Loadgen.IsInstalled) { if (ProductDetection.Loadgen.ProductName.Contains("Performance")) { nameOfAgentFile = "Performance Center"; } if (ProductDetection.Loadgen.ProductName.Contains("LoadRunner") || ProductDetection.Loadgen.ProductName.Contains("Generator")) { pathToAgentStartUpLog += nameOfAgentFile + "_agent_startup.log"; Logger.Info("Searching for Magent log file in: " + pathToAgentStartUpLog); } if (ProductDetection.Loadgen.ProductName.Contains("Performance")) { //if the agent is installed as a service, usually for 11.04 and below version the log goes to C:\tmp else it goes to %lg_path%\Temp if (isAgentInstalledAsService) { if (ProductDetection.Loadgen.isNew) { pathToAgentStartUpLog = ProductDetection.Loadgen.InstallLocation + @"Temp\" + nameOfAgentFile + "_agent_service.log"; Logger.Info("Searching for Magent log file in: " + pathToAgentStartUpLog); } else { pathToAgentStartUpLog = @"C:\tmp\" + nameOfAgentFile + "_agent_service.log"; Logger.Info("Searching for Magent log file in: " + ProductDetection.Loadgen.InstallLocation + pathToAgentStartUpLog); } } else if (isAgentInstalledAsProcess) { pathToAgentStartUpLog += nameOfAgentFile + "_agent_startup.log"; } else { pathToAgentStartUpLog += nameOfAgentFile + "_agent_startup.log"; } } } else { pathToAgentStartUpLog += nameOfAgentFile + "_agent_startup.log"; } StringBuilder output = new StringBuilder(); output.Append(Html.AddLinkToHiddenContent( Helper.GetLastLinesFromFile(1024 * 1024, pathToAgentStartUpLog, 10))); return(output.ToString()); } catch (Exception ex) { Logger.Error(ex.ToString()); return(ex.Message); } }
protected override void Collect() { var filePath = Path.Combine(ProductDetection.Analysis.ConfigFolder, "LRAnalysis80.ini"); AddDataPair("Analysis configuration files", "LRAnalysis80.ini file content", Html.AddLinkToHiddenContent(IniParser.ToHtml(filePath))); }
protected override void Collect() { //################ //DOTNET Detection //################ AddDataPair(".NET", ".NET versions installed", DetectOtherSoftware.GetGetDotNetVersionFromRegistry()); //################ //Java Detection //################ Logger.Info("Collecting JAVA Information"); var title = "JAVA"; AddDataPair(title, "Classpath", DetectJava.GetClassPath()); AddDataPair(title, "Other java environment variables", DetectJava.GetJavaEnvs()); AddDataPair(title, "JDKs isntalled", ClientsCollectorHelper.GetJavaProducts("JDK")); AddDataPair(title, "JREs isntalled", ClientsCollectorHelper.GetJavaProducts("JRE")); AddDataPair(title, "Details", Html.AddLinkToHiddenContent(ClientsCollectorHelper.GetJavaDetails())); //DetectJava dj = new DetectJava(); //AddDataPair("JAVA", "JDK/JRE versions installed", dj.ToString()); if (ProductDetection.Vugen.IsInstalled) { AddDataPair("JAVA", "VuGen JRE version", ClientsCollectorHelper.GetVugenJREVersion()); } //################ //CITRIX Detection //################ title = "Citrix"; //If any of LR/VuGen/PC Host is not installed if (!ProductDetection.Vugen.IsInstalled) { // Use it only if Vugen is not installed, otherwise the info would be under Vugen Protocols Logger.Info("Collecting Citrix Information"); var ctrxClient = new CitrixHelper.Client(); AddDataPair(title, "Citrix client version", ctrxClient.GetCitrixClientInfo()); } //################ //CITRIX Server Detection //################ var ctrxServer = new CitrixHelper.Server(); AddDataPair(title, "Citrix Server", ctrxServer.ToString()); if (ctrxServer.isInstalled) { AddDataPair(title, "End disconnected session", ctrxServer.GetIcaMaxDisconnectionTime()); AddDataPair(title, "Active session limit", ctrxServer.GetMaxConnectionTime()); } //If any of LR/VuGen/PC Host is not installed if (!ProductDetection.Vugen.IsInstalled) { //################ //RDP Detection //################ Logger.Info("Collecting RDP Information"); AddDataPair("RDP", "RDP client version", DetectOtherSoftware.GetRDPClientVersion()); } //################ //Oracle Detection //################ Logger.Info("Collecting Oracle client information"); AddDataPair("Oracle", "Oracle DB client information", DetectOtherSoftware.GetOracleClientInfo()); //################ //SAPGUI Detection //################ Logger.Info("Collecting SAPGUI information"); AddDataPair("SAPGUI", "Is SAPGUI installed?", DetectOtherSoftware.GetSapGuiClientInfo()); //################ //JENKINS Detection //################ Logger.Info("Collecting Jenkins information"); AddDataPair("Jenkins", "Is Jenkins installed?", DetectOtherSoftware.GetJenkinsInfo()); AddDataPair("Jenkins", "Is HP AAT plugin installed?", DetectOtherSoftware.GetJenkinsPluginInfo()); }