Friday, August 9, 2019

PSA: Found solution to POAP deleting system image

I just wanted to post this solution here in case there is some other poor soul out there trying to get POAP to work on a cisco nexus switch and finding that the switch keeps deleting it's own nxos .bin file.

A while back I posted here asking if anyone else had encountered this, nobody had, which is not surprising since I don't think POAP gets used that much, and cisco even now recommends not using it for security reasons. Nonetheless, here is the solution:

If you are using this poap script from github look at lines 393 - 396 under the function init_globals().

 # confirm image deletion del_system_image = True # confirm image deletion del_kickstart_image = True 

This is causing the deletion.

When POAP starts, it looks for a switch configuration file on the server specified in the DHCP lease. If it does not find the configuration file, POAP fails and loops again. When it fails, it runs some cleanup and in this process deletes its own system image.

Solution: set these values to False

We ran into this issue while setting up a workflow to allow our engineers to rack and stack switches, turn them on, and then later push config. The problem is, until the switch config exists, POAP fails, loops, then deletes its own system image unless you alter this bit of code in the poap.py script.

Hope this saves someone else some headache if they're also playing around with POAP



No comments:

Post a Comment