Backing up Cisco IOS Router image

As a network administrator, you should always have a backup for worse conditions. One of the common worse condition that can occur is IOS image of a device deleted.This condition gets more worse if there is no backup of IOS image present.

So to ignore conditions like these, backup should be must and here we will take a Cisco IOS image backup on TFTP server.

Trivial File Transfer Protocol (TFTP) –
TFTP is a simple file transfer protocol which is either used to put or get a file from a remote host. It uses UDP port number 69.
But TFTP is used where no authentication and control is required. Also, it takes less overhead. While on the other hand, it is less interactive than FTP. Therefore, according to the need, FTP or TFTP is used.

Configuration –

Here is a simple topology in which there is a router (for which we will take IOS backup) and a TFTP server. Router has IP address and TFTP server has IP address

Note –
Before taking IOS backup, make sure Tftp server and router is able to ping each other.

As shown in the figure, we see a IOS image file in flash (.bin file) by command:

router#show flash

Now, we will copy this file to our Tftp server by command:

router#copy flash: tftp:
Source filename[]? c1841-advipservicesk9-mz.124-15.T1.bin
Address or name of remote host []?
Destination filename [c1841-advipservicesk9-mz.124-15.T1.bin]? routerios 

Now, as we can see in the above image it is asking for source filename, Address of remote host and destination filename.

As shown in the above figure, the file has been as copied to tftp server.
Now, we will delete the IOS image from the router:

router(config)#delete flash:

Note –
Now, as the file is deleted still the router is running because the IOS has already been loaded into RAM. Therefore, when we will reload the router, it will enter ROMMON mode.

Therefore,now to copy the IOS file from tftp server we will use the command:

rommon 1>tftpdnld

Now, as soon as we type this command, we see that the parameters which we have to enter next.

ROMMON 6>TFTP_FILE=routerios

After we have entered these commands, we will again enter the command tftpdnld.

After that it will ask us to continue say yes (as shown in the figure) if we have entered the right parameters otherwise enter no and again specify the correct parameters.

ROMMON 7>reset

After that just enter command reset to reload the router.

Attention reader! Don’t stop learning now. Get hold of all the important CS Theory concepts for SDE interviews with the CS Theory Course at a student-friendly price and become industry ready.

Article Tags :