Backup and Restore - PowerPoint PPT Presentation

1 / 23
About This Presentation
Title:

Backup and Restore

Description:

Accidental deletion is one cause, while erroneous programs or hardware failures ... Make routine restoration easy. ... or replace tapes as often as every year. ... – PowerPoint PPT presentation

Number of Views:42
Avg rating:3.0/5.0
Slides: 24
Provided by: scie192
Category:

less

Transcript and Presenter's Notes

Title: Backup and Restore


1
Backup and Restore
2
References
  • Textbook reference
  • Nemeth et al 2001, chapter 10
  • Limoncelli et al 2002, Chapter 21
  • Burgess 2000, ch 10
  • Frisch 1995, ch 10.
  • Lecture Objectives
  • Lecture Questions
  • FreeBSD reference Backups

3
Theory
  • Everybody loses files from time to time.
    Accidental deletion is one cause, while erroneous
    programs or hardware failures are more serious.
  • Backups are a mechanism to reduce the
    inconvenience of small problems and to provide
    survivability when something more serious
    happens, like a disk crash, fire in the machine
    room, flood, sabotage,terrorism, or warfare.

4
  • Usually, backup strategy (where one exists at
    all) is based on what used to be done years ago.
  • It really is time to consider everything now from
    first principles.
  • Backups are like insurance - they represent an
    amount of time and effort expended now to reduce
    time and effort required in the future.
  • Future costs might be decreased productivity,
    schedule slippage, or even a total inability to
    continue business.

5
Questions
  • Things to consider include
  • What files need to be backed up?
  • Files which hold only ephemeral, scratch data
    don't need backup.
  • Anything in the operating system which is
    identical to the original CD-ROM release doesn't
    need backup.
  • However, it might be more convenient to back
    everything up than to exclude certain files or
    directories.

6
  • Although the kinds of things to be done to
    increase convenience when a draft letter needs to
    be recreated may differ from those needed when
    reestablishing a business on a new computer after
    a natural disaster, a proper backup strategy will
    handle both.

7
  • Where are they?
  • Data which is gathered into a single partition or
    directory will be much easier to backup in one
    piece.
  • Who will do it?
  • Files on an individual's workstation may never be
    backed up if the workstation user has to do the
    job.
  • Where, when, and under what conditions will
    backups be done?
  • Ideally, backups are done after hours on
    unmounted filesystems. Often this is not
    possible.
  • How often do these files change?
  • Something changing slowly may only need weekly
    backup, while a busy database may need to be
    backed up several times a day.

8
  • How quickly must a file be restored?
  • Something on a large medium may take a while to
    find. If it's a licence file controlling your
    everyday use of software, you want to get it very
    quickly.
  • It may be possible to order material on the
    medium so that key data is most quickly found.
  • Alternatively, you may put such files onto a
    small medium like a floppy, and leave everything
    else on a multi-GB tape.
  • Where must the data be restored?
  • If you might need to restore onto another
    machine, this may change what software, hardware,
    or recording format you use.

9
  • Another question which may control some of your
    decisions is the storage capacity of the media
    used.
  • If you are using tapes with a capacity much
    bigger than your disks, you may choose to back
    everything up, even if you don't otherwise need
    to.
  • If your medium is smaller than a particular
    partition or file (such as a very large database
    occupying several disks), you may need to do
    attended backups so that somebody can change the
    medium when required.

10
Strategies
  • A full backup means that all data on a computer
    (or a disk partition) are backed up.
  • This can be time-consuming, and restoring a file
    from such a backup may take as long (attended) as
    the original medium took to write (unattended).

11
  • If a full backup takes several tapes (or whatever
    media), a restore can take ages, even if you do
    know which tape the needed file is on.
  • Some system will require you mount all tapes in
    order, not just the needed one.

12
  • An incremental backup means that files are backed
    up only if they have changed since a previous
    backup.
  • Finding the appropriate tape (or whatever) in a
    sequence of incremental backups can also be
    time-consuming.

13
Backup Levels
  • There is the concept of a backup level.
  • A full backup is level 0, while an incremental
    backup has a higher level, say 1 or 2.
  • A level 2 backup contains all files changed since
    the last backup at a lower level (like 0 or 1).

14
  • One typical scheme has a full (level 0) backup
    done each Monday, and a level 1 (incremental)
    backup done each other day.
  • An alternative has a level 0 backup on the first
    Monday of each month, a level 1 incremental
    backup on each other Monday, and a level 2
    incremental backup every other day.
  • This could be extended to include quarterly or
    annual backups.

15
  • Whatever plan is chosen, think about how the
    system is used.
  • You don't need frequent backup of the parts of
    your system which change infrequently (such as
    the root filesystem and commands).
  • You do, however, need current backup of essential
    configuration files.
  • Some areas, like /tmp do not need to be backed up
    at all.
  • If you provide large scratch areas to users, you
    may decide to make them responsible for backup.

16
  • Whether backups must be attended or whether they
    may be unattended depends on a number of things.
  • If your tape drive is shared with users, or is in
    heavy use, an unattended backup hogging the
    device all night may be impractical, impolitic,
    or just a plain security hole.

17
Storage of Backups
  • It's no use making backups if you can't find the
    media when you need to restore from them.
  • Know where things belong, and always keep them
    there. This also applies to non-backup media like
    software distributions, etc.
  • Know what is on each medium. You can't restore a
    file if you don't know which tape it's on.

18
  • Make routine restoration easy.
  • Keep recent backup media available, although not
    necessarily too near the computer room.
  • Ideally, the same medium is used consistently for
    the same kind of backup.
  • Some places use colour coding, some print
    detailed sticky labels at the end of each backup.
  • Write-protect media after backup (but not
    during...). You don't want an attempted restore
    to destroy your backup.
  • Consider environmental aspects.
  • Avoid excess humidity or temperature.
  • Avoid dust and similar air polutants.

19
  • Keep media some distance from the computers or
    you might lose your backups at the same time as
    the disks.
  • Handle media properly.
  • Protect media as any other secure item - consider
    theft and vandalism.

20
  • For more significant threats (in terms of damage,
    even if not risk) consider long-term and offsite
    storage.
  • If your organisation would be unable to function
    without your data, keep such copies.
  • These should be full backups, and may be produced
    monthly, or at whatever frequency is appropriate
    to your level of risk and discomfort.
  • If you could restart with data a week old, but no
    older, then make copies weekly for offsite
    storage, even if you don't actually move them
    offsite until you make the next one.

21
  • These backups should be verified to ensure they
    are good copies, and must be stored far enough
    away from your originals not to be subject to the
    same problems (whether fire, bombs, earthquake,
    etc.).
  • Keep them in a locked, fireproof, environmentally
    controlled location.
  • Another consideration for such long-term backups
    is the lifetime of your media - you may need to
    copy or replace tapes as often as every year.
  • Another time to make full, verified, backups is
    when you're rebuilding a filesystem.

22
Media
  • Many media exist suitable for backup
  • magnetic tape
  • floppy disks
  • removable disks
  • floptical and magneto-optical disks
  • recordable CD-ROMs
  • hard disks

23
UNIX Backup Tools
  • find
  • cpio
  • tar
  • dd
  • dump/restore ufsdump/ufsrestore
  • Commercial Products
Write a Comment
User Comments (0)
About PowerShow.com