Добавил:
Upload Опубликованный материал нарушает ваши авторские права? Сообщите нам.
Вуз: Предмет: Файл:
Linux+ Certification Bible.pdf
Скачиваний:
48
Добавлен:
15.03.2015
Размер:
3.78 Mб
Скачать

Chapter 15 Study Guide 475

Scenarios

1.A company wants to implement a new backup plan for their enterprise network. They have several large database servers that need to be backed up nightly, and they need to receive extensive reports on the backup logs and messages. The data needs to be retained for at least two years. What backup system would you recommend for this company?

2.A user’s home directory, /home/jsmith needs to be restored from tape. The files were backed up using the dump command, which backs up the entire /home directory every night. It is always the first file archive on the tape, and the tape can be accessed using the device /dev/tape. What commands would you use to restore the file?

Lab Exercises

Lab 15-1 Dump and Restore files

The objective for this hands-on lab is to gain experience in using the dump and restore commands to back up and extract files. You should be able to use any default Linux installation for this exercise.

1.Logged in as root, change to your home directory of /home/root, and create a test file by using this command:

ls -al > file.txt

This will take a directory listing, and print the output to a file called file.txt.

2.Logged in as root, use the dump command to dump the entire /home directory to tape. Use the zero level argument to indicate a full backup.

dump -f /dev/tape -0 /home

3.Delete the file you just created after the backup is complete. rm file.txt

4.Rewind the tape to the beginning, and mount it to the first file archive dump that you just created:

mt rewind

mt -f /dev/tape asf 0

5.After the command finishes, you can invoke the restore command to begin the restore process.

restore

6.Use the cd command to go down to the location of your file in /home/root: restore> cd /home/root