July 29, 2014
 
 
RSSRSS feed

Point-and-Click Linux LVM Filesystem Workstation Backup, Part 2

dar Backup Script and Icon Setup

  • May 31, 2007
  • By A. Lizard

In Part 1, we covered drive mirror setup for an LVM drive and an rsync backup script.

Here, we will cover the dar backup script, emergency script, icon setups, setup of a backup GUI, insertion into a Knoppix .iso, backup and restore.

#!/bin/sh 
# /usr/local/bin/dar_backup.sh - moved to knoppix
# rsync LVM backup script, Copyright 2007 by A.Lizard
# This program comes with ABSOLUTELY NO WARRANTY; 
# This is free software licensed under the terms of the GNU
# GENERAL PUBLIC LICENSE.
# information on permitted use and copying at the following URL: 
# http://www.gnu.org/licenses/gpl.txt
# if your root drive is not /dev/hda5, change script accordingly. 
# Change script to match your physical (first) and logical 
# (second) volume names. If you are not using LVM, omit vgchange
 echo "Executing archival backup script" 
 echo "mounting /boot partition" 
vgchange -ay
mount /dev/terrarium/root /media/hda5
 mount  /dev/hda1 /media/hda1 
 zip -ry /media/hda5/usr/local/backups/boot.zip /media/hda1/*
 umount /media/hda1 
 echo "unmounting /boot partition"
cd /media/hda5/usr/local/backups
#was 1450
echo "starting backup"
rm -rf *.dar
/media/hda5/usr/bin/dar_static -z5 -s 4050M -D -c /media/hda5/usr/local/backups/`date  -I`__data.dar -R /media/hda5 -Z "*.gz" -Z "*.bz2" -Z "*.zip" -Z "*.png" -P tmp  -P dev -P proc -P mnt -P sys -P selinux  -P usr/local/backups -P home/alizard/.opera/cache4
echo "backup complete"
# note: the recovery command is going to have to dump to /, 
# not /media/hda5/usr/local/backups/... unless it's run off 
# Knoppix (most likely... but the recovery will have to take this 
# into account

Set up the icon by right-clicking the Desktop and selecting "Link to Application." Right-click the icon and open Properties. Name the icon start-dar-archive, click the Application tab and enter these values:

  • Name: start-dar-archive
  • Command: sudo sh /cdrom/dar_backup-k.sh

Copy the file to /home/username/knoppix-mod.

Sitemap | Contact Us