View Source

R1Soft designed the Linux Backup Agent CLI tools for use in shell scripts for users who prefer to use a command line interface over a Web interface. The following Linux Backup Agent CLI tools allow you to perform a variety of operations:
* {{cdp-agent}} is designed to start, restart, stop and view status of the Backup Agent
* {{serverbackup-setup}} is designed to manage the Keys of Backup Managers that the Backup Agent is aware of. The {{serverbackup-setup}} command line utility is used to manage the RSA Public Keys without having to cut and paste.

These tools allow you to perform the following actions on the server where the Backup Agent resides:
* [view the current Backup Agent status|View the Linux Backup Agent status] or [version|View the Linux Backup Agent version]
* [start, stop, and restart the Backup Agent service|ServerBackup:Start, stop, or restart the Linux Backup Agent]
* [set the TCP connection|Set the Linux Backup Agent TCP port] or [bind IP address|Set the Linux Backup Agent bind address] for listening
* [test your connection|Test your Backup Agent server connection]
* [display configuration|View the Linux Backup Agent version]
* [build, download, and install the kernel module|ServerBackup:Build the Linux Backup Agent kernel module]
* [install and delete manager keys|Manage authentication keys using the Linux Backup Agent CLI]
* [retrieve beta drivers|Get a beta driver using the Linux Backup Agent CLI]

*To use the Linux Backup Agent CLI tools*:
# Establish an SSH connection to the Linux server where the Backup Agent resides. R1Soft recommends using PuTTY as the SSH client because it allows you to paste text from the Windows clipboard by clicking the right mouse button. For more information about PuTTY or to download, see [http://www.chiark.greenend.org.uk/~sgtatham/putty/download.html|http://www.chiark.greenend.org.uk/~sgtatham/putty/download.html]. 
# Open a GUI terminal window, such as Konsole in KDE or a Gnome Terminal in Gnome, or log in to the text Linux console.
# Log in to the system using the root account. If you do not already have a root account, request root permissions after you log in using the {{su}} or {{sudo}} command.

h3. Use the cdp-agent command

The {{cdp-agent}} command is designed to start, stop, restart, and view the status of the Backup Agent using the following commands:
* {{start}}. The {{start}} command starts the Backup Agent. For more information about starting the Backup Agent, see [Start, stop, or restart the Linux Backup Agent].
* {{restart}}. *{_}If the Backup Agent (_{*}{{{}{*}{_}cdp-agent{_}{*}{}}}{*}_) is running{_}*, the {{restart}} command stops and starts the Backup Agent. *{_}If{_}* {{{*}{_}cdp-agent{_}{*}}} *{_}is not running{_}*, the {{restart}} command starts the Backup Agent. For more information about restarting the Backup Agent, see [Start, stop, or restart the Linux Backup Agent].{{stop}}.
* {{stop}}. The {{stop}} command stops the Backup Agent. For more information about stopping the Backup Agent, see [Start, stop, or restart the Linux Backup Agent].
* {{status}}. The {{status}} command displays the status of the Backup Agent, such as {{started}}. For more information about view the Backup Agent status, see [ServerBackup:View the Linux Backup Agent status].
* {{?}} or {{help}}. The {{?}} or {{help}} command displays the list of options and their descriptions.

Use the following command to view a list of all of the options supported by {{cdp-agent}}:

{code} /etc/init.d/cdp-agent help{code}

h3. Use the serverbackup-setup command

The {{serverbackup-setup}} command is designed to manage the RSA public keys in Backup Manager using the following commands: 
* {{\-v}} or {{\--version}}. The {{\-v}} or {{\--version}} command displays the Backup Agent version number. For more information about displaying the Backup Agent version, see [View the Linux Backup Agent version].
* {{\-?}} or {{\--help}}. The {{\-?}} or {{\--help}} command displays the list of options and their descriptions.
* {{\--get-module}}. The {{\--get-module}} command retrieves a kernel module. For more information about building a kernel module, see [ServerBackup:Build the Linux Backup Agent kernel module].
* {{\--no-scripts}}. The {{\--no-scripts}} command prevents internal scripts from running when retrieving the kernel module.
* {{\--tarball-only <file>}}. The&nbsp;{{\--tarball-only}} command combined with a file name creates a .tar file (tarball) of your kernel, but does not send the tarball to the custom kernel installer (CKI) servers. For more information about building a kernel module, see [ServerBackup:Build the Linux Backup Agent kernel module].
* {{\--custom-version major.minor.build-release}}. The {{\--custom-version}} command combined with version numbers downloads a custom version of the kernel module, such as {{\--custom-version 4.1.1-12345}}.
* {{\--experimental}}. *{_}No longer in use{_}*.
* {{\--module-type \[hcp\|backupdriver\]}}. The&nbsp;{{\--module-type}} command combined with hcp driver information specifies which 2.x or 3.x kernel module you want to use. If you do not specify a driver, the default is the 3.x hcp driver.
* {{\--dest <destination>}}. The&nbsp;{{\--dest}} command combined with a location displays the destination where you want to store the kernel module. For more information about building a kernel module, see [ServerBackup:Build the Linux Backup Agent kernel module].
* {{\--kernel-dir <source>}}. The&nbsp;{{\--kernel-dir}} command combined with a source path specifies the kernel directory at the specified location. For more information about building a kernel module, see [ServerBackup:Build the Linux Backup Agent kernel module].
* {{\--test-connection}}. The&nbsp;{{\--test-connection}} command tests the connection between the servers. For more information about testing the connection between your servers,&nbsp;see [ServerBackup:Test your Backup Agent server connection].
* {{\--no-binary}}. The&nbsp;{{\--no-binary}} command builds a kernel module without using a pre-built binary module. For more information about building a kernel module, see [ServerBackup:Build the Linux Backup Agent kernel module].
* {{\--binary-only}}. *{_}No longer in use{_}*.
* {{\--silent}}. The&nbsp;{{\--silent}} command runs the Backup Agent without producing any output.
* {{\--agent-port}}. The&nbsp;{{\--agent-port}} command sets the port on which the Backup Agent listens. For more information about setting the Backup Agent port, see [ServerBackup:Set the Linux Backup Agent TCP port].
* {{\--agent-bind-addr}}. The&nbsp;{{\--agent-bind-addr}} command sets the bind address for the Backup Agent. For more information about setting the Backup Agent bind address, see [ServerBackup:Set the Linux Backup Agent bind address].
* {{\--get-agent-bind-addr}}. The&nbsp;{{\--get-agent-bind-addr}} command retrieves the bind address for the Backup Agent. For more information about getting the Backup Agent bind address, see [ServerBackup:Set the Linux Backup Agent bind address].
* {{\--beta}}. The&nbsp;{{\--beta}} command retrieves any existing beta driver. For more information about retrieving the available beta driver, see [ServerBackup:Get a beta driver using the Linux Backup Agent CLI].
* {{\--get-key <url>}}. The&nbsp;{{\--get-key}} command combined with a URL retrieves a key from the Backup Manager. The Backup Manager must be running and accessible from the Backup Agent via the network. For more information about adding a key to the Linux Backup Agent, see [Add key to Linux Backup Agent].
* {{\--remove-key <name>}}. The&nbsp;{{\--remove-key}} command combined with the IP address or URL of the Backup Manager location removes the specified key, where the key is the IP&nbsp;address or URL. For more information about removing a key from the Linux Backup Agent, see [Uninstall the key from Linux Backup Agent].
* {{\--list-keys}}. The&nbsp;{{\--list-keys}} command displays a list of all of the installed keys. For more information about listing all of your installed keys, see [View keys added to Linux Backup Agent].
* {{\--stdin-key}}. The&nbsp;{{\--stdin-key}} command reads the manager key from standard input.
* {{\--key-filename <name>}}. The&nbsp;{{\--key-filename}} command combined with the name of the key file reads the manager key from the specified file.

Use the following command to view a list of all of the options supported by {{serverbackup-setup}}:

{code}serverbackup-setup{code}

or{code}serverbackup-setup \--help{code}\\
{anchor:cli_htm}

{excerpt:hidden=true}Provides&nbsp;information about the&nbsp;{{cdp-agent}} and&nbsp;{{serverbackup-setup}} Linux Backup Agent CLI commands and&nbsp;their options.
{excerpt}