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\IBM\tivoli\Remote Control\Controller\jre
- Linux® systems
- Edit the ibmtrct.conf 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\IBM\Tivoli\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\IBM\Tivoli\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\IBM\Tivoli\Remote
Control\Target
- Linux system
- Edit the /etc/ibmtrct.conf file and set LogLevel=4 and save the file.
Note: The wrc and wrcmdpcr commands do not work if you start
the remote controller or the commands on computers where you need to establish the connection
through BigFix® Remote
Control
gateways.