Device identity, capability and behavior are controlled by runtime parameters stored in the device PIB. To change device identity, capability or behavior you must alter a template PIB file, download it to the device and flash it into NVRAM. A template PIB can come from several sources but an excellent souce is the device, itself. Configuration changes then become a simple read, modify and write back operation.
Example 5.12. Read a PIB File
# int6k -i eth2 -p old.pib local eth2 00:B0:52:00:00:01 Read Parameters from Device eth2 00:B0:52:00:00:BE Read.
This example reads the PIB from the local device and writes it to a file. The toolkit has a growing number of programs designed to inspect and change pibfiles in various ways. Program modpib is one program that can be used for this purpose.
Example 5.13. Modify a PIB File
# modpib old.pib -M 00:B0:52:00:BA:BE \ -N 00:11:22:33:44:55:66:77:88:99:AA:BB:CC:DD:EE:FF \ -D FF:EE:DD:CC:BB:AA:99:88:77:66:55:44:33:22:11:00 \ -S "Intergalactic Death Rays, Inc." \ -T "Global Spy Network" \ -U "Bedroom"
The example above edits identity parameters in PIB file, old.pib
, recomputes the internal checksum and re-writes the file. The network identity parameters are MAC (-M
), NMK (-N
) and DAK (-D
). The user identity parameters are MFG_HFID (-S
), NET_HFID (-T
) and USR_HFID (-U
). The PIB file is ready for download and flash.
Program modpib is a safe way to edit a PIB file because it only change selected parameters. Use program setpib to edit other parameters if required.
Example 5.14. Save a PIB File
# int6k -i eth2 -P old.pib -C pib eth2 00:B0:52:00:00:01 Write Parameters to Device eth2 00:B0:52:00:00:BE Written.
This example writes the modified PIB file, old.pib
, to the local device and commits it to NVRAM. Option -P
writes the PIB file to the device instead of reading it from the device. Option -C
with argument pib
commits only the PIB, and not firmware, to NVRAM.