06-28-2016 10:51 PM
I am trying to track a bug which causes certain CLIs to disappear from the running-config after we reload the router.
Those CLIs were saved in startup-config before reloading the router.
Is there a EEM to compare running-config with startup-config line-by-line after reloading the router and syslog the lines which are missing from the running-config ?
Solved! Go to Solution.
06-29-2016 07:53 AM
You could do something simple like:
event manager applet compare-config
event timer cron cron-entry "@reboot"
action 1.0 cli command "enable"
action 2.0 cli command "show archive config diff nvram:startup-config system:running-config"
action 3.0 mail to "user@company.com" from "user@company.com" server "10.1.1.1" subject "Config diffs" body "$_cli_result"
06-29-2016 07:53 AM
You could do something simple like:
event manager applet compare-config
event timer cron cron-entry "@reboot"
action 1.0 cli command "enable"
action 2.0 cli command "show archive config diff nvram:startup-config system:running-config"
action 3.0 mail to "user@company.com" from "user@company.com" server "10.1.1.1" subject "Config diffs" body "$_cli_result"
06-29-2016 08:57 AM
Thank you Joe.
What does this command do ?
event timer cron cron-entry "@reboot"
and how does it accomplish the task after reboot ?
06-29-2016 08:59 AM
This schedules the EEM policy to run after each reboot.
Discover and save your favorite ideas. Come back to expert answers, step-by-step guides, recent topics, and more.
New here? Get started with these tips. How to use Community New member guide