Stargate Logo

Folder open  Stargate's Backup script [ Expand ]
  Question ?  Where can I download the stargate-backup script ?   
  Question ?  Backup script usage - Full backup first, then incremental !   
  Question ?  Known problems on the Backup-script ?   
  Question ?  What is the mirror mode ?   
  Question ?  How do I install the backup scripts ?   
  Question ?  How do I recover data from the backup archive ?   
  Question ?  What's the stargate Backup script ?   
  Question ?  Why has tar archiver been removed from the backup-script feature ?   
  Question ?  How do I configure the backup-script ?   
spacer line
Folder open  Answers
spacer line
Question ? Where can I download the stargate-backup script ?  

 Latest version of the backup-script can always be found in the download section: Networking Tools / Basic scripts section on my site. 

Entered by smurphy on Wednesday, 31 August 2005 @ 23:16:22  
Questions on specific software - Stargate's Backup script, # Hits: 70827
spacer line
Question ? Backup script usage - Full backup first, then incremental !  

 Note that the Incremental-Backups require a full-backup to be run first. The script will tell you this in case you try to run incremental backups without the system having performed a full-backup first. 

Entered by smurphy on Wednesday, 31 August 2005 @ 22:23:05  
Questions on specific software - Stargate's Backup script, # Hits: 70822
spacer line
Question ? Known problems on the Backup-script ?  

 There are actually no known problems. One issue however remains - as on every backups software. When the file-list is generated for a backup - and the time to archive the file itself has come - sometimes several minutes lay between where b.e. a User could have deleted a mail in it's cyrus-Mail spool folder. You'll have a little warning message from the cronjob - that's it. The script will not stop working. 

Entered by smurphy on Wednesday, 15 February 2006 @ 22:19:33  
Questions on specific software - Stargate's Backup script, # Hits: 70783
spacer line
Question ? What is the mirror mode ?  

 The mirror mode is actually a special case, where the mirror_list.cfg configuration file is used - which content usually is:

all;/

Note that the system will also honor the exclude_list ! even in mirror mode - this to prevent backuping stuff we don't require.
The mirror mode will make a backup of the entire system - required to restore it b.e. in case of a harddisk-crash. Backup of my own system is about 1.7GB.
Note that you might need to restore the /dev Directory by hand - as the find-process makes some junk from time to time in there. 

Entered by smurphy on Wednesday, 15 February 2006 @ 12:22:48  
Questions on specific software - Stargate's Backup script, # Hits: 70748
spacer line
Question ? How do I install the backup scripts ?  

 Install the RPM-archive with:

rpm -Uhv stargate-backup-x.xx-xmdk.noarch.rpm

If you install the tar-file - make sure the files are in the following locations:

/etc/backup/backup.cfg
/etc/backup/backup_list.cfg
/etc/backup/exclude_list.cfg
/etc/backup/mirror_list.cfg
/etc/backup/nocompress.cfg
/etc/cron.d/Backup
/usr/bin/Backup.sh
/usr/share/doc/stargate-backup-1.35/GPL_V2.txt
/usr/share/doc/stargate-backup-1.35/README
/usr/share/doc/stargate-backup-1.35/stargate_backup.spec
/var/backup

Edit the /etc/backup/*.cfg files - and adapt to your needs. Explanations are in there. Make sure you have the Backup-Directory well defined.

Make a test with - as user root:

~#Backup.sh -f # for a full backup
~#Backup.sh -i # for an Incremental Backup - since last full backup !

The report will tell you where to find your backed-up archives. If all runs fine - activate the Cronjob by editing the /etc/cron.d/Backup file (Uncomment the respective lines and adapt times).

NOTE: First run a Full-backup - else the incremental backups will fail ! 

Entered by smurphy on Wednesday, 31 August 2005 @ 22:36:22  
Questions on specific software - Stargate's Backup script, # Hits: 70732
spacer line
Question ? How do I recover data from the backup archive ?  

 First - find out what backup-file you do require in the so called list-file, e.g.:

bzip2 -dc system_www_2005-08-12_incr.list.bz | less

If you require only one specific file - extract it to a temporary directory - e.g.:

afio -i -Z -P bzip2 system_www_2005-08-12_incr.afio

Note - that you can get the options out of the regular backup-report you get:

*** Compression: yes (-Z -P bzip2 -Q -c)

If you add a supplementary -v -z - you'll also have some listing flying over your screen. 

Entered by smurphy on Thursday, 01 September 2005 @ 00:07:23  
Questions on specific software - Stargate's Backup script, # Hits: 70710
spacer line
Question ? What's the stargate Backup script ?  

 The biggest problem with all the backup solutions that do exist require loads of hardware and resources to actually work. What I was looking for - was a small solution - not requiring loads of resources, simple to set up - and providing a reliable backup of important data. This is what Stargate's backup script is providing.
The main features of the system are:

  • Compress files before writing them into the archive (e.g. you can recover part of the files if the archive is corrupt)
  • Does not compress files that are already compressed. Speeds up the backup process. Also gives the possibility to choose specific file extensions to not compress.
  • Ability to exclude files/directories using wildcards
  • Generates a report - sent out to root through cron The report also shows the actual configuration settings. Check out the attached example reports - taken from a real-backup environment
  • Perform full,mirror and incremental backups (controlled through cron)
  • Archive rotation is included, e.g. rotate archive X times before deleting them.
  • Quiet mode operation if requested
  • simple easy installation and configuration
  • Script locking - to prevent the backup script is started more than once.

Requirements: The following programs need to be installed - afio, bzip2, sed, awk, find, bash. Any Linux system should have these installed (afio needs to be explicitely installed).  

Entered by smurphy on Wednesday, 31 August 2005 @ 23:15:55  
Questions on specific software - Stargate's Backup script, # Hits: 70683

Attach   Incremental_backup.txt  [ 5,143 bytes - text/plain ]
Attach   Full_backup.txt  [ 5,580 bytes - text/plain ]
Attach   Mirror_backup.txt  [ 2,381 bytes - text/plain ]
spacer line
Question ? Why has tar archiver been removed from the backup-script feature ?  

 The tar archive is a nice tool, used by many people - however has some specific restrictions.

As afio comes in with real-nice support for exclude files/firectories xxx, nocompress file with extension xxx etc. and compression of files before writing them into an archive - some of these features would have required to be explicitely programmed - which would have bloated the script - which IMHO I kept as simple as possible. 

Entered by smurphy on Wednesday, 31 August 2005 @ 23:16:46  
Questions on specific software - Stargate's Backup script, # Hits: 70662
spacer line
Question ? How do I configure the backup-script ?  

 The following files do exist:

  • backup.cfg This is the general configuration file. You can configure the general beheaviour of the backup system, as setting defaults. Check the file itself for details.
  • exclude_list.cfg With this file - you define all files, directories you don't want to be included in the backup. wildcards (regular expressions) are allowed - Format is simple: one per line. Check the file for an example.
  • mirror_list.cfg The mirror file list configuration. This for the mirror backup. Format is simple:

    Directory/Name

    This will result in a backup-file prefix of:

    Name_YYYY-MM-DD_Type.afio
    Name_YYYY-MM-DD_Type.list.bz
    

  • backup_list.cfg The regular backup-list. This is the list ofr directories/files done on a regular base. The System will perform Incremental/Full backups using this configuration file. Format is as before:

    Directory/Name

    This will result in a backup-file prefix of:

    Name_YYYY-MM-DD_Type.afio
    Name_YYYY-MM-DD_Type.list.bz
    

  • nocompress.cfg List of file-extensions to not compress. This is a nice thing - to define special file type to not beeing compressed. Note that the system will only handle that on the file-name extensions. Format is a space separated list on one line. check the file for an example.

To make all these work nicely together - a cronjob will schedule all these to make sure you always have a nice backup of important data laying around. Following time-schedules have proved to be OK for a Private home-system:

  • 4h05am - Incremental every day - except on sunday mornings
  • 4h05am - Full backup on sundays
  • 7h05am - Mirror backup once the first of every month

Saved my Data more than once already ! 

Entered by smurphy on Wednesday, 31 August 2005 @ 22:32:55  
Questions on specific software - Stargate's Backup script, # Hits: 70564

Attach   backup.cfg  [ 1,295 bytes - text/plain ]
Attach   backup_list.cfg  [ 110 bytes - text/plain ]
Attach   mirror_list.cfg  [ 7 bytes - text/plain ]
Attach   nocompress.cfg  [ 389 bytes - text/plain ]
Attach   Backup.cron  [ 571 bytes - text/plain ]
Attach   exclude_list.cfg  [ 120 bytes - text/plain ]

This page was issued from the Stargate Website:
https://stargate.solsys.org

The URL for this page is:
https://stargate.solsys.org/mod.php?mod=faq&op=view&faq_id=


  Close