Follow the steps given below to transfer files from NCM server to devices via SCP client using configlets:
Go to Settings >> Configlets >> Add Configlet.
In the UI that opens, provide a name, description and details about the new configlet.
Select the mode in which you wish to upload the configuration to the device. You can either choose script execution mode or advanced script execution mode for this operation.
The "<NCM-SERVER-HOME>/tftp_files" directory serves as the home directory by default. Both absolute and relative paths of the files to the tftp_files directory can be used. To copy files using the absolute path in script execution mode, use the syntax of the following example:
scp_transfer "<NCM-SERVER-HOME>/tftp_files/c2600-i-mz.122-28.bin" "/home/test/c2600-i-mz.122-28.bin".
To copy files from tftp_files using their relative path in script execution mode, use the syntax of the following example:
scp_transfer "./c2600-i-mz.122-28.bin" "/home/test/c2600-i-mz.122-28.bin"
To use relative path to copy a file outside the default tftp_files directory, use the syntax of the following example in the script execution mode:
scp_transfer "../c2600-i-mz.122-28.bin" "/home/test/c2600-i-mz.122-28.bin"
To copy a file outside the tftp_files directory in the advanced script execution mode you can use the syntax of the following example:
<command>show version</command>
<command>scp_transfer "../c2600-i-mz.122-28.bin" "/home/test/c2600-i-mz.122-28.bin"</command>