Knowledge Base

Showing results for 
Search instead for 
Did you mean: 

How do I add startup parameters to the Machine Agent?

How can Linux or Windows users pass startup parameters to their Machine Agents?

This article contains instructions for passing startup parameters, such as proxy details, to Machine Agents in Linux, or in Windows.


Table of Contents


Passing startup parameters to a Machine Agent in Linux

Linux users who wish to pass startup parameters such as proxy details to their Machine Agent have two options: during Machine Agent startup, or in the run time file.

Passing during Machine Agent startup

  1. Stop the Machine Agent.

  2. Depending on how you are starting Machine Agent, these JVM parameters can be added in startup command. For instance:
    1. When starting the Machine Agent from bin folder, JVM arguments will be passed as:
      ./machine-agent -Dappdynamics.http.proxyHost=XXX -Dappdynamics.http.proxyPort=80​


    2. When starting machineagent with machineagent.jar file, JVM arguments will be passed as:
      java -jar machineagent.jar -Dappdynamics.http.proxyHost=XXX -Dappdynamics.http.proxyPort=80​

Back to Table of Contents


Passing in the run-time file

  1. Stop the Machine Agent.

  2. Navigate to the <Machine Agent -Dir>\bin directory.

  3. Do a VI of filemachine-agent.

  4. In the VI editor, search for this line:
    JAVA_OPTS="$JAVA_OPTS -Xmx256m"​

    You should see that the -Xmx JVM argument is passed. After you pass the proxy settings, it will look like this: 

    JAVA_OPTS="$JAVA_OPTS -Xmx256m -Dappdynamics.http.proxyHost=XXX -Dappdynamics.http.proxyPort=80"


  5. Save the file.

  6. RestartMachine-Agent.

Back to Table of Contents


Passing startup parameters to a Machine Agent in Windows

Windows users who wish to pass startup parameters (such as proxy details) to their Machine Agent should follow these steps:


  1. Stop the Machine Agent service.

  2. Navigate to the <Machine Agent -Dir>\bin directory.

  3. Create a new empty file called MachineAgentService.vmoptions.

  4. Navigate to the <MachineAgent Home>/InstallService.vbs file and add the following lines of code before vmOptionsFile.WriteLine:

    For example:
    Set vmOptionsFile = fsObject.OpenTextFile(scriptDir & "\bin\MachineAgentService.vmoptions", OVERWRITE, True)

    NOTE: Do not create "MiniDump on crash". If the option is not supported by the JRE, the executable will ignore it.


  5. Save the changes.

  6. Restart the service. 

Back to Table of Contents


Version history
Revision #:
5 of 5
Last update:
‎06-24-2021 01:21 PM
Updated by:
Labels (1)

Found this article helpful? Click the Thumbs Up button.
Have an additional comment? Post it below.
0 Kudos

Require your help on the following queries/issues:


  1.  I am not able to find <MachineAgent Home>/InstallService.vbs in the  Non-JRE windows install (i.e. within or even in the latest install

    How do I run this Non-JRE bundled Agent as a Windows service?

  2. If I download the Windows machine agent with JRE bundled (i.e. machineagent-bundle-64bit-windows-, I cannot find out how to specify so that the windows service takes the JRE which is already installed in the host machine. 

    If I delete the <MachineAgent Home>/jre from the bundled after unzipping will it (
    MachineAgentService.exe ) pickup %JAVA_HOME% from the System environments parameter? 

  3.  How/Where to get the list of parameters accepted by MachineAgentService.exe ? Is this exe has a dependency on .NET Framework?

Hi Pranabesh,

 It is required to install Machine agent with the bundled JRE , then only we can able to pass the parameters to machine agent service.

  If you would like to points to JRE located on your host , need to change the Java home parameter & path accordingly.