Index.
09-Nov-2011: initial release. 11-Nov-2011: added firewall information. 12-Nov-2011: added dump/restore.
Introduction.
In the previous article the Amanda server setup was explained, now a client installation is done on one of the virtual client computers, the web server. We will use the special maintenance network for the backup traffic to prevent saturation of the regular network.
Client installation.
Install the client software and dump/restore:
[root@websrv ~]# pacman -S amanda_client dump resolving dependencies... looking for inter-conflicts... Targets (2): xinetd-2.3.14-7 amanda_client-3.3.0-1 dump-0.4b43-1 Total Download Size: 1.17 MB Total Installed Size: 5.80 MB Proceed with installation? [Y/n] :: Retrieving packages from core... xinetd-2.3.14-7-i686 83.3K 343.3K/s 00:00:00 [######################] 100% :: Retrieving packages from mbse-extra... amanda_client-3.3.... 1113.4K 2.1M/s 00:00:01 [######################] 100% dump-0.4b43-1-i686 92.2K 2.2M/s 00:00:00 [######################] 100% (3/3) checking package integrity [######################] 100% (3/3) checking for file conflicts [######################] 100% (1/3) installing xinetd [######################] 100% Optional dependencies for xinetd perl: for xconv.pl script (2/3) installing amanda_client [######################] 100% useradd: warning: the home directory already exists. Not copying any file from skel directory into it. amanda: Visit the Amanda wiki to configure your backup sets:" amanda: http://wiki.zmanda.com/index.php/Quick_start#Configuring_the_backup_se rver" amanda: Examples are in /etc/amanda/examples/ amanda: The daemon is run by xinetd so restart xinetd to start the daemon listen ing for connections. New optional dependencies for amanda_client dump: dump/restore programs support (3/3) installing dump [######################] 100% [root@websrv ~]#
In this case xinetd is installed, so we must start it instead of restart it. It must also be added to /etc/rc.conf.
[root@websrv ~]# rc.d start xinetd :: Starting xinetd [DONE] [root@websrv ~]#
Client configuration.
Login into the client machine and make sure /etc/dumpdates is usable for amanda.Then add permissions to the .amandahosts file, use the homsrv IP address of the maintenance network here:
[root@websrv ~]# touch /etc/dumpdates [root@websrv ~]# chmod 666 /etc/dumpdates [root@websrv ~]# su - amanda Welcome at websrv.wpl.ym - DISPLAY on 2001:1af8:fecf:7ea1::2:0.0 Wed Nov 9 20:06:07 CET 2011 [amanda@websrv ~]$ echo "10.126.164.1 amanda amdump" >> .amandahosts [amanda@websrv ~]$ exit logout [root@websrv ~]#
Login into the home server machine where the amanda server package lives. Here add the following three lines to /etc/hosts:
10.126.164.1 homsrv.amanda 10.126.164.2 gateway.amanda 10.126.164.3 websrv.amanda
There is no need to add these entries to the DNS, only this host needs these addresses. Then add these entries to /etc/amanda/wpl/disklist:
#
# Backups on websrv
#
websrv.amanda root / {
comp-root
comment "websrv root partition"
} 1 local
#
websrv.amanda boot /boot {
comp-root
comment "websrv boot partition"
} 1 local
#
websrv.amanda www /srv/http {
comp-user-tar
comment "websrv Web partition"
} 1 local
Now still on the Home Server check if the web server is available, add the client to .amandahosts so that recovery works, and test with a backup to see if all is ok:
[root@homsrv ~]# su - amanda Welcome at homsrv.wpl.ym - DISPLAY on xxxx.xxx.xx:0.0 Wed Nov 9 20:42:34 CET 2011 [amanda@homsrv ~]$ echo "websrv.amanda root amindexd amidxtaped" >> .amandahosts [amanda@homsrv ~]$ amcheck wpl Amanda Tape Server Host Check ----------------------------- Holding disk /mnt/users/.holding/wpl: 76352 MB disk space available, using 66112 MB Holding disk /home/.holding/wpl: 76324 MB disk space available, using 66084 MB slot 7: volume 'WPL-7' Will write to volume 'WPL-7' in slot 7. NOTE: skipping tape-writable test NOTE: host info dir /var/amanda/wpl/curinfo/websrv.amanda does not exist NOTE: it will be created on the next run. NOTE: index dir /var/amanda/wpl/index/websrv.amanda does not exist NOTE: it will be created on the next run. Server check took 0.798 seconds Amanda Backup Client Hosts Check -------------------------------- Client check: 2 hosts checked in 2.592 seconds. 0 problems found. (brought to you by Amanda 3.3.0) [amanda@homsrv ~]$ amdump wpl [amanda@homsrv ~]$
Firewall.
Today amanda needs only one port open on the firewall, TCP 10080. In our setup this means to open this port on all maintenance network cards on all hosts. Open the port for inbound and outbound traffic. If in your situation amanda traffic must pass a Linux router, then on that router you can load the kernel module nf_conntrack_amanda that helps forwarding amanda traffic. If amanda traffic must pass a NAT router, then you should also load nf_nat_amanda.
Download.
The complete configuration of the home server systems.
