How to set LoadRunner Agent as a service or process after installation

The LoadRunner Agent can be run both as a process and a service:

1. When running LoadRunner Agent as a process, it runs the ‘magentproc.exe’ from the <LoadRunner>\launch_service\bin folder. User needs to login to the machine in order to start this Agent.

2. When running LoadRunner Agent as a service, the service ‘magentservice’ runs automatically even if the user does not log in to the system. User can login to the machine and go to Administrative Tools -> Services -> ‘LoadRunner Agent’ to verify or change the authentication information.

After installing LoadRunner, user can switch the agent to be service / process anytime they want.

Solution

Agent options during Installation:
While installing LoadRunner, the following two options are provided for User Login settings:
1. When installed with option "Manual log into the Load Generator machine", LoadRunner agent is installed as process.
2. When we install with option "Allow Virtual Users to run on this machine without user login", the LoadRunner agent is installed as service"

Switching after installation:
After installing LoadRunner, you can switch the agent to be service / process anytime you want. You do not need to uninstall LoadRunner to switch the LoadRunner Agent install. Here are the steps:

1. For the first time, login to the host machine.
2. Launch the command prompt.
3. Go to <LoadRunner>\launch_service\bin

To install LoadRunner agent as a service
1. Remove the LoadRunner Agent Process shortcut from the Start -> Program Files -> Startup group.
2. Type in
magentservice.exe -install<enter>
Note: If you want to set a different account, then type in :
magentservice.exe -install <user_domain>\<user_name> <password>
3. If the install is successful, you will receive the following messages:
LoadRunner Agent Service installed
LoadRunner Agent Service started.
LoadRunner Agent service will be started automatically as well.
4. Go to the Window’s Services and change its properties to start it as "Automatic."
5. If you wish to modify the login details after installation of agent service, do the following
Go to Start -> Control Panel -> Administrative Tools -> Services and look for the LoadRunner Agent Service.
Right-click and select Properties->Log On and change the information from there

To install LoadRunner agent as a process
1. Uninstall LoadRunner agent service by typing in
magentservice.exe -remove<enter>
2. If the uninstall is sucessful, you will receive the following messages:
Stopping LoadRunner Agent Service.
LoadRunner Agent Service stopped.
LoadRunner Agent Service removed.
3. Start the agent process by running magentproc.exe from <LoadRunner>\launch_service\bin
4. Add the LoadRunner Agent Process shortcut back into the Startup group.

Note: It is recommended to reboot the machine after the installation

Advertisements

5 thoughts on “How to set LoadRunner Agent as a service or process after installation

  1. Andy L

    I wish the machines I use (Win Server 2012 VMs) would conform – I can’t see how on earth the LR Agent Process gets started at login!

    Reply
  2. Andy L

    Loadrunner Agent Standalone was the answer – it installed as a service on Windows 2012 R2 VM. Use the setup.exe which appears after the first step (unpacking) – that offers a choice of “Agent for Performance Centre = service” or “Agent for Loadrunner = as a Process”. Agent as a process is fine if the relevant login account is never auto-logged off.

    Reply

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s