Generating Intellitrace log file for Azure Service Fabric On Premise - visual-studio

We have services (stateful/stateless) running on premise with 5 nodes cluster. In production environment, I would like to log diagnostic events/trace event into log file for further analyze in VS 2019 Enterprise edition.
How do I achieve that, as I can't find collection method such as
{
Start-IntelliTraceCollection "FabrikamFiber.Extranet.Web" c:\IntelliTrace\collection_plan.ASP.NET.trace.xml c:\LogFileLocation
}

The command "Start-IntelliTraceCollection" is in the IntelliTrace standalone package
https://learn.microsoft.com/en-us/visualstudio/debugger/using-the-intellitrace-stand-alone-collector?view=vs-2019.
That means
1. Upload the standalone package to your nodes.
2. Import the powershell module Import-Module "C:\IntelliTraceCollector\Microsoft.VisualStudio.IntelliTrace.PowerShell.dll"
3. Then you can use the command you post.
Be aware that the powershell module works for web application and sharepoint application.
For other types of application, you can use IntelliTraceCollectorIntelliTraceSC.exe
You should find more details from the above link.

Related

MMASetup Command Line Parameters for SCOM

I'm installing the latest MMASetup-AMD64.exe and want to hook up to Log Analytics AND SCOM. But, I'm having trouble finding the command line parameters for SCOM. Does anybody know them? The Log Analytics ones are well documented and are here:
ADD_OPINSIGHTS_WORKSPACE=1
OPINSIGHTS_WORKSPACE_ID="1234"
OPINSIGHTS_WORKSPACE_KEY="5678"
I need the equivalent parameters for management group name and management server. Effectively completing these boxes but via the command line.
Thanks in advance.
I believe parameters for management group, secure port, etc. are not available with MMASetup-AMD64.exe. Here are the supported command line options with it. So may be, if its feasible in your environment and setup, try to use MOMAgent.msi to install agent manually or to deploy System Center Operations Manager agents from the command line or by using the Setup Wizard. The parameters like MANAGEMENT_GROUP, SECURE_PORT, etc. are all explained along with examples in this document. For more information, please refer it.
Other references related to OM agents and OM groups:
Process manual agent installations
Configuring Windows agents
Operations Manager agents
Creating and managing groups
Connecting management groups in Operations Manager
Planning a Management Group Design

How do I restart a failed JSR-352 job running in Liberty through Eclipse / WDT?

While running the Java EE Batch job through eclipse, it is creating a new instance of it.
I wanted to re-run the failed instance so that it can use checkpoint information to resume from the failed point.
Step 1: Deploy Application into Liberty server.
Step 2: Run the batchManger.bat file from cmd, which can find under bin folder of your local server
.\batchManager.bat restart --batchManager=localhost:9443 --user=admin --password=P#ssw0rd --applicationName=your-app-Name --jobXMLName=XXXX.xml --wait --trustSslCertificates
Another (GUI) approach is to use the Admin Center Java Batch tool, which allows you to restart jobs submitted by other methods. You can reuse, and/or modify the original job execution parameters.
This also provides a rich set of search and filtering capabilities, plus lets you view job logs, and so complements the job submission capability in the Eclipse Java EE Batch tooling.
Start here for complete instructions on using Admin Center. In particular you need to make sure the adminCenter-1.0 feature is installed then configure a userid to be authorized as the administrator.
Then, as the Java Batch tool instructions say, configure your server.xml with features:
adminCenter-1.0
batchManagement-1.0

Trying to convert existing WCF service to Web Role can't deploy without errors

I've converted existing WCF application to web role by adding it with "Add web role project in solution". Convert menu doesn't offer me option to convert. Our application requires .NET 4.6.1
Application runs fine on full emulator. However deployment fails with two scenarios:
osFamily attribute set to "5" in Serviceconfiguration(no .NET 4.6.1 installation script required):
19:15:16 - Instance 0 of role Severa.API is restarting
Details: [11/28T17:15Z]Failed to load role entrypoint. System.Reflection.ReflectionTypeLoadException: Unable to load one or more of the requested types. Retrieve the LoaderExceptions property for more information.
at System.Reflection.RuntimeModule.GetTypes(RuntimeModule module)
at System.Reflection.Assembly.GetTypes()
at Microsoft.WindowsAzure.ServiceRuntime.RoleEnvironment.GetRoleEntryPoint(Assembly entryPointAssembly)
--- End of inner exception stack trace ---
at Microsoft.WindowsAzure.ServiceRuntime.RoleEnvironment.GetRoleEntryPoint(Assembly entryPointAssembly)
at Microsoft.WindowsAzure.ServiceRuntime.RoleEnvironment.CreateRoleEntryPoint(RoleType roleTypeEnum)
at Microsoft.WindowsAzure.ServiceRuntime.RoleEnvironment.InitializeRoleInternal(RoleType roleTypeEnum) Last exit time: [2016/11/28, 17:15:06.916]. Last exit code: 0.
osFamily attribute set to "4" in Serviceconfiguration with .NET 4.6.1 installation:
The feature named NetFx451 that is required by the uploaded package is not available in the OS * chosen for the deployment.
I've used the .NET installation script in other projects with success. Also I have added WebRole.CS class to the project.
Is the issue here that the webrole is not WCF type meaning some setting etc. is missing?
We've managed to identify and fix the issue.
I've enabled Fusion logging and immediately got the missing information.
What would have saved a lot of time and point us to right direction would have been to understand that web role in CS consists of two processes: WAIISHost which runs RoleEntryPoint code in startup and good old W3WP for the Web application itself.
WAIIShost can't read Web.config and requires an empty Web.config file named after name of the project and redeployed successfully. I followed instructions from this article:
Post about the issue

How to view log file on service startup?

Is it possible to view the log files when starting alfresco services on windows (prompt), like the tail -f on linux.
Actually, there is two approaches to achieve that:
Start Alfresco tomcat as a service, and have a 3rd party software like mtail* and tail the <alfresco-path>\alfresco.log
Stop tomcat service from msc.exe, tweak setenv.bat inside <path-to-alfresco-dir>\tomcat\bin\setenv.bat to give sufficient memory to the JVM, and then run <path-to-alfresco-dir>\tomcat\bin\startup.bat inside a cmd console
* Here is a list of alternative tools / methods.

How do i take Logs for windows application?

I am working on an application in Windows 7 environment and the application is not stable yet I wanted to see the crash logs , Please help me to get log files.
Reporting Services writes event messages to the Windows application
log. You can use the message information written to the application
log to find out about events that are generated by the report server
applications running on the local system.
Reporting Services provides three event sources:
Report Server (Report Server Windows service)
Report Manager
Scheduling and Delivery Processor
Source
You can use Log4Net to log errors or alternatively just write your errors to a text file.
Here is a link on how to use log4net Link

Resources