Welcome, Guest. Please login or register.

Author Topic: Crontab copy running-config startup-config  (Read 362 times)

Saguu

  • Newbie
  • *
  • Posts: 12
    • View Profile
Crontab copy running-config startup-config
« on: March 15, 2019, 10:31:37 AM »
Hello,

We have been using NeDi for many months with great satisfaction. Currently, all configurations of our network equipment are saved in NeDi. I would also like every night, the running-config is written in the startup-config. I did not find how to do it in the documentation. Could you help me on this?

Thank you

rickli

  • Administrator
  • Hero Member
  • *****
  • Posts: 2701
    • View Profile
    • NeDi
Re: Crontab copy running-config startup-config
« Reply #1 on: March 20, 2019, 12:39:56 PM »
You can create a command file in System-Files:
- Click green+ next to "CLI Send>"
- replace cmd-new with cmd-savrun
- Enter "wr mem" (or so) in the textarea below
- Click Write

Then schedule a crontjob:

0 0    * * *   /var/nedi/nedi.pl -ti -Aall -SAFGgadobewitjumpvs -c cmd_savrun > /var/log/nedi/nedi-00.savrun 2>&1

You can review the action in System-Files "Discover Log" or "CLI Send" selectbox...

About arguments:
-ti will prevent updating devices in DB
-S... skips over all OIDs
-c... executes the command
Please consider Other-Invoices on your NeDi installation for an annual contribution, tx!
-Remo

Saguu

  • Newbie
  • *
  • Posts: 12
    • View Profile
Re: Crontab copy running-config startup-config
« Reply #2 on: March 22, 2019, 09:16:26 AM »
Works fine !

Thank you very much Rickli :)