scp the-config.cfg manager@theprocurveswitch:/cfg/startup-config

If you start dipping your toe into the waters of network automation with hp procurve switches and want to push the generated config via scp (or tftp) you have to make sure you have the correct “magic” in the first config line. You are fine if it matches the beginning of a show running-config output.


someone@somewhere:~/ANSIBLE/CFGS$ head -n3 sw-edv-0-12-sw1.txt
; J4899B Configuration Editor; Created on release #H.10.115

hostname "sw-edv-0-12-sw1"
someone@somewhere:~/ANSIBLE/CFGS$

This fact is discussed in a forum thread at hp.

The magic line is also there when one creates a backup of the running-config. Thankfully, you can push a startup-config to the switch that looks like a command file you would run after an erase startup-config.

Leave a Reply

Your email address will not be published. Required fields are marked *