Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 24 Jun 2004 22:26:15 -0500
From:      Mark Teel <mark@teel.ws>
To:        Michael Sharp <ms@probsd.org>
Cc:        freebsd-questions@freebsd.org
Subject:   Re: two questions
Message-ID:  <40DB9B57.3050307@teel.ws>
In-Reply-To: <1793.192.168.1.1.1088132789.squirrel@192.168.1.1>
References:  <1793.192.168.1.1.1088132789.squirrel@192.168.1.1>

next in thread | previous in thread | raw e-mail | index | archive | help
Here is a script I use to backup my linux system:

#!/bin/sh

MEDIUM=/mnt/dmzserv/share/mark/BACKUP/webserver


echo "Creating system backup on $MEDIUM as dmz2-sys-backup-<date>.tar.gz..."

tar -zcvpf $MEDIUM/dmz2-sys-backup-`date '+%d-%B-%Y'`.tar.gz \
    --directory / --exclude=mnt --exclude=proc --exclude=share .

echo "...done"

This creates a system backup starting in "/", excluding mnt, proc and 
share, with the file name including the date.

MST


Michael Sharp wrote:

>I'm having a brain freeze tonight and apparently forgot some
>basic UNIX commands..
>
>what is the command to remove the file "--directory"
>
>rm *directory* = nope
>rm "*directory*" = nope
>rm \-\-\directory = nope
>rm -i * = nope and dosent even see the file
>
>Also, if I'm in / and want to tar the entire filesystem
>EXCLUDING the
>directory jail ( /jail ) what would be the switches to tar?
>
>Dana
>
>_______________________________________________
>freebsd-questions@freebsd.org mailing list
>http://lists.freebsd.org/mailman/listinfo/freebsd-questions
>To unsubscribe, send any mail to "freebsd-questions-unsubscribe@freebsd.org"
>  
>



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?40DB9B57.3050307>