This article is for Amanda Enterprise (AE)
# mkdir /tmp/restore # cd /tmp/restore
# dd if=/var/lib/amanda/vtapes/ptest2/slot346/00001.rhel6-server-64._etc.0 bs=32k count=1
Example of reading the header from a backup archive on tape:
# dd if=/dev/nst0 bs=32k count=1
You may need to scroll back up in your terminal to see the tail end of the output which will contain a system restore command such as:
To restore, position tape at start of file and run:
dd if=<tape> bs=32k skip=1 | /usr/lib/amanda/application/amgtar restore [./file-to-restore]+
Example of extracting directories ./init.d and ./rc.d/init.d from a Linux backup of the /etc directory:
# dd if=/var/lib/amanda/vtapes/ptest2/slot346/00001.rhel6-server-64._etc.0 bs=32k skip=1 | /usr/lib/amanda/application/amgtar restore ./init.d ./rc.d/init.d ./rc.d/init.d/ ./init.d ./rc.d/init.d/auditd ./rc.d/init.d/cgconfig ./rc.d/init.d/cgred ./rc.d/init.d/crond ./rc.d/init.d/functions ./rc.d/init.d/halt ./rc.d/init.d/ip6tables ./rc.d/init.d/iptables ./rc.d/init.d/iscsi ./rc.d/init.d/iscsid ./rc.d/init.d/killall ./rc.d/init.d/lvm2-monitor ./rc.d/init.d/messagebus ./rc.d/init.d/netconsole ./rc.d/init.d/netfs ./rc.d/init.d/network ./rc.d/init.d/nfs ./rc.d/init.d/nfslock ./rc.d/init.d/postfix ./rc.d/init.d/rdisc ./rc.d/init.d/restorecond ./rc.d/init.d/rhnsd ./rc.d/init.d/rpcbind ./rc.d/init.d/rpcgssd ./rc.d/init.d/rpcidmapd ./rc.d/init.d/rpcsvcgssd ./rc.d/init.d/rsyslog ./rc.d/init.d/sandbox ./rc.d/init.d/saslauthd ./rc.d/init.d/single ./rc.d/init.d/sshd ./rc.d/init.d/stinit ./rc.d/init.d/udev-post ./rc.d/init.d/vmware-tools ./rc.d/init.d/xinetd ./rc.d/init.d/zmc_aee 5954+0 records in 5954+0 records out 195100672 bytes (195 MB) copied, 0.636116 seconds, 307 MB/s /bin/gtar: Read 8192 bytes from -