vineri, 3 noiembrie 2017

'write' vs 'copy run start'

'Write' or 'write memory' vs 'copy running-config startup-config' or 'copy run start' for short, which one to use ?


Basicaly both commands perform the same thing, that is writting the current configuration which is running in the RAM memory, thus the name ‘running-config’, in the NVRAM (non volatile RAM) memory section of the router as the file which will be used to load the configuration on the next reboot (startup-config).


A closer look at these commands though, reveals that the things are not so simple. It all starts with the arguments available with any of these two commands. If we do a ‘write ?’ and a ‘copy ?’, we will quickly understand why Cisco is not recomending the usage of the ‘write’ command and considers it to be legacy.




Besides the limited arguments number presented by the ‘write’ command, it also comes with an argument which is prone to disaster or many hours of a headache if used by mistake. Yes, i’m talking here about the powerful ‘write erase’ which is the opposite of the ‘write’ or ‘write memory’. ‘Write’ followed by the ‘erase’ argument will delete all of the router's NVRAM content forcing it to use the default configuration file on the next reboot.


The ‘copy’ command also comes with an option to delete things, but it is implemented in a more granular way, allowing us much more options. Also, the ‘copy /erase’ by itself does nothing and it requires to be followed by an argument. Besides that, Cisco implemented the separate ‘erase’ command, which has the purpose of doing exactly what it says, to delete things.


In production, it comes down to personal choice and habit, but it's good to know the posibilities which each of these two commands present to the Network Admin and why Cisco is recommending the use of ‘copy run start’ when we want to write the running-config to NVRAM.


Personally, i get their point, i think it makes sense and i got accustomed to using the ‘copy run start’. I hope this article brought a little light to those who were wondering about the diffrence between the two commands. Cheers!






Niciun comentariu :

Trimiteți un comentariu