Use remote control commands from the command line
You can install tools that you can use to start a remote control session from the command line. You can also use the tools to run a command on a target and see the output of the command on your computer.
The cli tools can be useful if you want to connect to a target without using the BigFix® Remote Control Server interface. You can also use them as part of a script to run multiple commands. For more information about installing the cli tools, see the BigFix® Remote Control Installation Guide.
COMMAND session mode in server session policy must be enabled to use the CLI tools.
There are two command line tools available
- wrc - to start a remote control session.
- wrcmdpcr - to run a command on a target and see the output from the command on your computer.
Before you use the command line tools, the following configuration actions must be carried out.
- The server URL defined in the trc.properties file on the server must be the same as the URL that is defined in the ServerURL property in the target properties.
- The remote control port that is defined during the installation of the command line tools must be the same on both the computer that the commands are being run from and in the target settings.
- If FIPS compliance is required, you must enable FIPS on the computer that you use to run the
command from and also on the target. For more information about enabling FIPS compliance, see the
BigFix® Remote Control Installation
Guide. Note: The computer that is starting the controller software requires a JavaHome registry key entry. JavaHome must contain the path to the FIPS-compliant IBM® JRE that is installed with the controller software. If you are starting the controller on a remote computer, you must create a registry key entry on the remote computer too.
- Windows® systems
-
C:\Program Files\BigFix\Remote Control\Controller\jre
- Linux® systems
- Edit the trc_target.properties file and update the value of the JavaHome property.
- An INFO level log,
cli_trace_[suffix].log is created on the computer that you
run the cli tools from. Where [suffix] is determined by the value of the
LOGROTATION property. For example, cli_trace_Mon.log. To create a DEBUG level
log, change the LOGLEVEL property value to 4.
- Windows system
- Edit the target registry and go to HKEY_LOCAL_MACHINE\SOFTWARE\BigFix\Remote
Control\TargetNote: On a 64-bit system, all the 32-bit registry keys are under the WOW6432Node key. For example: HKEY_LOCAL_MACHINE\SOFTWARE\WOW6432Node\BigFix\Remote Control\Target
- Right-click LogLevel and select Modify
- Set the value to 4 and click OK.
- Edit the target registry and go to HKEY_LOCAL_MACHINE\SOFTWARE\BigFix\Remote
Control\Target
- Linux system
- Edit the /etc/trc_target.properties file and set LogLevel=4 and save the file.