Submit a ticketCall us

Quickly Address Software Vulnerabilities
Patch Manager is an intuitive patch management software which extends the capabilities of WSUS and SCCM to not only patch Windows® servers and workstations, and Microsoft® applications, but also other 3rd-party applications which are commonly exploited by hackers. Learn more about our patch management solution.

 

Home > Success Center > Network Configuration Manager (NCM) > Execute scripts in NCM with the same command and not overwrite the file

Execute scripts in NCM with the same command and not overwrite the file

Table of contents

Updated March 22, 2017

Overview

When using NCM or any other means of issuing commands on a device that will create a file, locally or to an external file storage, if the name of the file is repetitive and is sent to the same location, it will either overwrite the file or fail to save. This  article shows a quick example of how to use NCM and common variables to save with a unique name for each device each time.

Environment

All NCM versions 

Detail

For example, a script is used to back up the binary UCS file to the SCP server.

This is executed on several F5s at the same time to ensure the files would not have the same name.

Note: This is only an example and may not be accurate.

tmsh save /sys /var/local/NCM.ucs

scp /var/local/NCM.ucs NSEuser@10.8.34.1:${SysName}_${Date}.ucs

SCPSERVERPASSWORD PLAIN TEXT

 

The name of the file will be unique for that day.

If multiple files per day are needed, the ${DateTime} can be used to make it unique to the specific time it was downloaded.

 

 

Last modified
00:42, 30 Mar 2017

Tags

Classifications

Public