How To BackUp a Cisco from Linux
This is a easy and small way to BackUp a Cisco SW or RW using GNU/Linux ( Mandriva 2008.1 )
1th we need to instal TFTP:
# urpmi tftp-server
The service must be like this:
# cat /etc/xinetd.d/tftp
#############################################################################
service tftp
{
disable = no
socket_type = dgram
protocol = udp
wait = yes
user = root
server = /usr/sbin/in.tftpd
server_args = -s /home/janux/BackUpCiscos
per_source = 11
cps = 100 2
flags = IPv4
}
#############################################################################
mkdir /home/janux/BackUpCiscos
chkconfig xinetd off
/etc/init.d/xinetd restart
Stopping xinetd [ failed ]
Starting xinetd [ OK ]
lsof -i -n | grep tftp
in.tftpd 4281 root 0u IPv4 167964 UDP *:tftp
xinetd 4699 root 5u IPv4 170073 UDP *:tftp
[DO THIS FOR EACHE ONE....]
mkdir /home/janux//BackUpCiscos/Radec0
touch /home/janux/BackUpCiscos/Radec0/runing-config
1- Copy all runing config to the flash mem:
Switch#> copy running-config startup-config
————————————————–
2- Creating a Backup
————————————————–
2.1- Upload a configuration file from a switch to a TFTP server:
Sercore# copy system:running-config tftp://192.168.3.1/Sercore/runing-config
Address or name of remote host [192.168.3.1]?
Destination filename [Sercore/runing-config]?
!!
2347 bytes copied in 0.495 secs (4741 bytes/sec)
3- Restoring a Backup
———————————————————-
From the file tokyo-confg at IP address 172.16.2.155:
Sercore#copy tftp://192.168.3.1/Sercore/runing-config nvram:startup-config
Destination filename [startup-config]?
Accessing tftp://192.168.3.1/Sercore/runing-config…
Loading Sercore/runing-config from 192.168.3.1 (via Vlan113): !
[OK - 2347 bytes]
[OK]
2347 bytes copied in 9.194 secs (255 bytes/sec)
[CAUTON] [CAUTON] [CAUTON] [CAUTON] [CAUTON] [CAUTON] [CAUTON] [CAUTON] [CAUTON]
[CAUTON] [CAUTON] [CAUTON] [CAUTON] [CAUTON] [CAUTON] [CAUTON] [CAUTON] [CAUTON]
Clearing the Startup Configuration File
erase nvram: or erase startup-config
[CAUTON] [CAUTON] [CAUTON] [CAUTON] [CAUTON] [CAUTON] [CAUTON] [CAUTON] [CAUTON]
[CAUTON] [CAUTON] [CAUTON] [CAUTON] [CAUTON] [CAUTON] [CAUTON] [CAUTON] [CAUTON]