I had added a feature to my ASA which now meant the flash was changing on a daily basis. This was spamming me that there was a version change even though it was just the flash contents changing but not any actual configuration.

This is an example of the output:

RANCID remove config

Obviously quite annoying.


Here’s what I did to rectify the problem.

  1. Determine the command that was actually outputting the information on my ASA. In this case it was the commands ‘show flash‘ and the ‘dir variants’
  2. SSH on to the RANCID server and find the following executable file: /var/lib/rancid/bin/rancid (Your path may be different depending on install OS e.g. /usr/local/rancid/bin/rancid)
  3. Open the file in a text editor as root ‘nano /var/lib/rancid/bin/rancid
  4. Find the section near the bottom, and modify the file like so:

{‘admin show version’ => ‘ShowVersion’},
{‘show version’ => ‘ShowVersion’},
{‘show redundancy secondary’ => ‘ShowRedundancy’},
{‘show idprom backplane’, => ‘ShowIDprom’},
{‘show install active’ => ‘ShowInstallActive’},
{‘admin show env all’ => ‘ShowEnv’},
{‘show env all’ => ‘ShowEnv’},
{‘show rsp chassis-info’, => ‘ShowRSP’},
{‘show gsr chassis’ => ‘ShowGSR’},
{‘show diag chassis-info’ => ‘ShowGSR’},
{‘show boot’ => ‘ShowBoot’},
{‘show bootvar’ => ‘ShowBoot’},
{‘admin show variables boot’ => ‘ShowBoot’},
{‘show variables boot’ => ‘ShowBoot’},
# {‘show flash’ => ‘ShowFlash’},
# {‘dir /all nvram:’ => ‘DirSlotN’},
# {‘dir /all bootflash:’ => ‘DirSlotN’},
# {‘dir /all slot0:’ => ‘DirSlotN’},
# {‘dir /all disk0:’ => ‘DirSlotN’},
# {‘dir /all slot1:’ => ‘DirSlotN’},
# {‘dir /all disk1:’ => ‘DirSlotN’},
# {‘dir /all slot2:’ => ‘DirSlotN’},
# {‘dir /all disk2:’ => ‘DirSlotN’},
# {‘dir /all harddisk:’ => ‘DirSlotN’},
# {‘dir /all harddiska:’ => ‘DirSlotN’},
# {‘dir /all harddiskb:’ => ‘DirSlotN’},
# {‘dir /all sup-bootflash:’ => ‘DirSlotN’}, # cat 6500-ios
# {‘dir /all sup-microcode:’ => ‘DirSlotN’}, # cat 6500-ios
# {‘dir /all slavenvram:’ => ‘DirSlotN’},
# {‘dir /all slavebootflash:’ => ‘DirSlotN’},
# {‘dir /all slaveslot0:’ => ‘DirSlotN’},
# {‘dir /all slavedisk0:’ => ‘DirSlotN’},
# {‘dir /all slaveslot1:’ => ‘DirSlotN’},
# {‘dir /all slavedisk1:’ => ‘DirSlotN’},
# {‘dir /all slaveslot2:’ => ‘DirSlotN’},
# {‘dir /all slavedisk2:’ => ‘DirSlotN’},
# {‘dir /all slavesup-bootflash:’ => ‘DirSlotN’}, # cat 7609
# {‘dir /all sec-nvram:’ => ‘DirSlotN’},
# {‘dir /all sec-bootflash:’ => ‘DirSlotN’},
# {‘dir /all sec-slot0:’ => ‘DirSlotN’},
# {‘dir /all sec-disk0:’ => ‘DirSlotN’},
# {‘dir /all sec-slot1:’ => ‘DirSlotN’},
# {‘dir /all sec-disk1:’ => ‘DirSlotN’},
# {‘dir /all sec-slot2:’ => ‘DirSlotN’},
# {‘dir /all sec-disk2:’ => ‘DirSlotN’},
{‘show controllers’ => ‘ShowContAll’},
{‘show controllers cbus’ => ‘ShowContCbus’},

So all I added was a comment to block the running of the ‘show flash‘ command and any commands which would list directory contents.

Job done, now the daily cron job doesn’t display the unneeded info. This would work the same way for any other command you want to exclude from diffs or any other type of device but would require modification of the relevant file for your device.

This would obviously effect all Cisco devices so there would never be any output for the directory contents.



RANCID 2.3.x Suppress Output From Diffs
Tagged on:

Leave a Reply

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

This site uses Akismet to reduce spam. Learn how your comment data is processed.