Lessons · Network switches · the running config
The configuration is a document you can read
show running-config prints the switch's current settings as the commands that would recreate them.
Hone is a place to practise programming. This is one of its lessons, written out in full and free to read without an account.
What it is for
It is the single most useful screen on the device. Every question of the form 'is this actually configured' is answered by reading it, and it is the file you hand to whoever comes after you.
How to think about it
Read it top to bottom once: global settings first, then one block per interface, then the management address at the end. What is missing matters as much as what is there.
Worked example
enableThe # prompt; running-config is not visible from user mode.
configure terminalInto configuration mode.
hostname EDGE7One change, so there is something to see.
endBack to EDGE7#.
show running-configThe hostname line is there now. Nothing was written to a file: this is the live configuration rendered back as commands.
Your turn
Print the configuration the switch is running right now.
show
Console into a switch
The trap
Reading running-config and thinking it is saved. It is what the switch is doing, not what it will do after a power cut. Those are two different files.