# DCAP Central4.1

### Sonarremote Service

Remote files can be copied directly to the DCAP Central server through a service named sonarremote. The sonarremote service processes remote files so that DCAP Central does not need to directly copy the files from the remote server or move them on the remote server from incoming to archive folders.

The sonarremote service is triggered by a timer mechanism named sonarremote.timer. To configure the sonarremote service for such operations, add the remote host (server), and remote directory path in /etc/sonar/sonarremote.conf. Additionally, specify a list of copy patterns. Files matching these patterns will be copied over; files that do not match will be ignored.

Edit the following sections in /etc/sonar/sonarremote.conf:

#
# REMOTE_HOST: Specify remote host. Ensure that sonargd user can run ssh <remote-host>. If you
# need to specify a user name, you can use <user>@<host> format.
#
# Mandatory, no default value
#
REMOTE_HOST=<remote-hostname>

# REMOTE_DIR: directory on the remote server, to copy files from. Can be relative to the home
# directory of the user used for ssh to the remote server,
# or an absolute path, starting with a forward slash.
#
# Mandatory, no default value
#
REMOTE_DIR=<remote-dir-path>

# PATTERNS: Specify a list of patterns to copy on match.
# Files that do not match the patterns, will be ignored.
#
# You can use the following escaped wild cards.
# '\?' - any single character.
# '\*' - zero or more characters.
# Note: wrap each pattern with single quotes.
#
# Example:
#
# PATTERNS=(
#     '\*.rwf'