Bellevue University CIS 240, Introduction to UNIX Fall Days 2001 - PowerPoint PPT Presentation

1 / 16
About This Presentation
Title:

Bellevue University CIS 240, Introduction to UNIX Fall Days 2001

Description:

Planning for Disasters and Everyday Needs. Backup Media ... Leaving out information will cause tar to hang Ctrl C will break you out of tar ... – PowerPoint PPT presentation

Number of Views:46
Avg rating:3.0/5.0
Slides: 17
Provided by: JohnRu
Category:

less

Transcript and Presenter's Notes

Title: Bellevue University CIS 240, Introduction to UNIX Fall Days 2001


1
Bellevue UniversityCIS 240, Introduction to
UNIXFall Days 2001
  • November 20, 2001
  • Backup and Restore

2
Backup and Restore
  • Planning for Disasters and Everyday Needs
  • Backup Media
  • Backing Up and Restoring Files and Filesystems
  • Backing Up and Restoring the System Filesystems

3
Planning for Disasters and Everyday Needs
  • Factors to consider
  • Backup Strategies
  • Storage Considerations

4
Factors to consider
  • What files need to be backed up?
  • Where are these files?
  • Who will back up the files?
  • Where, when, and under what conditions should
    backups be performed?
  • How often do these files change?
  • How quickly does an important missing or damaged
    file need to be restored?
  • Where will the data be restored?

5
Backup Strategies
  • Full Backup
  • All files are backed up
  • Incremental Backup
  • Files changed since the last backup are backed up
  • Unattended Backups
  • Backups are automatically started at a scheduled
    time

6
Storage Considerations
  • Know where things are
  • Make routine restorations easy
  • Write-protect backup media
  • Environmental considerations
  • Handle media properly
  • Take security into account

7
Backup Media
  • Magnetic tape
  • Floppy disks
  • Removable disks
  • Floptical and Magneto Optical Disks
  • Write-once CD-ROMS
  • Jukeboxes, Stackloaders, and Similar Devices
  • Hard disks

8
Backing Up and restoring Files and Filesystems
  • Tape archive (tar)
  • Copy files to and from archive (cpio)
  • Selective backup (dump)

9
tar
  • Format
  • tar ltoptionsgt ltarchivegt ltfile(s)gt

10
ltoptionsgt
  • c Create an archive file and add files to it
  • f ltarchivegt name of archive file
  • r Record files at the end of the archive
    (append)
  • t List the contents of an archive file
  • u Update by adding new or changed files
  • v Verbose mode
  • x Extract files from archive (restore)
  • z Compress files (gzip/gunzip)

11
ltarchivegt
  • Can be device, such as tape backup,
    recordable/rewritable CD ROM, or floppy
  • Can be a path name on an existing mounted device
    (hard drive, floppy, etc)

12
ltfile(s)gt
  • Relative or absolute path name of files
  • Must be specified for backup (tar responds with
    Cowardly refusing to create empty tape archive
    error message if you dont)
  • A period indicates all files at the current
    location are to be backed up.
  • Default for restore operation is all files in the
    archive.

13
Backup Example
  • tar cvf archive1.tar /lab8a/.
  • Backs up all files in the /lab8a directory to an
    archive file called archive1.tar. Provides a
    complete list of backup operations.

14
View Example
  • tar tvf archive1.tar
  • Prints a list of all files and directories in
    the archive.

15
Restore Example
  • tar xvf archive1.tar /lab8a
  • Restores all files and directories in
    archive1.tar to the /lab8a directory

16
Tips on using tar
  • Case is important
  • Spaces are important
  • Using an incorrect option will cause
    unpredictable results
  • Leaving out information will cause tar to hang
  • ltCtrl Cgt will break you out of tar
Write a Comment
User Comments (0)
About PowerShow.com