TIP: Click on subject to list as thread! ANSI
echo: linux
to: ALL
from: RICK SMITH
date: 2020-12-09 22:34:00
subject: Tar backup script

Greetings All!

I am finally getting around to making backups of all my machines and I have a
nifty script that does in fact work as I intended..  It could be better tho..
My question is can I set the two backup directories?  So when the backup runs
it copies the tar to a backup dir local, but I want it to also copy it to a
mounted nfs drive, without running the backup twice if that is possible?

#!/bin/bash 
rm -rf ~/.local/share/Trash/* 
DATE=$(date +%d-%m-%Y) BACKUP_DIR="/z/backups" #BACKUP_DIR2="/home/fido/backup"
#To backup fido's home directory cd /home/fido tar 
--exclude="/home/fido/Downloads" --exclude="/home/fido/backup"
--exclude="/home/fido/.cache" --exclude="/home/fid>
#tar  --exclude="/home/fido/Downloads" --exclude="/home/fido/backup"
--exclude="/home/fido/.cache" --exclude="/home/fi> 
The second tar line that is commented out is the nfs drive I would also like
the backup to go to, is there a way I guess to incorporate both destinations in
one command line?



----
Regards,


 Rick Smith (Nitro)

... BBSing is irrelevant. You will be assimilated. --Sysop of Borg
--- GoldED+/LNX 1.1.5-b20180707
* Origin: ----> Abacus Sysop Point --->>>>bbs.abon.us:2323 (1:105/10.1)

SOURCE: echomail via QWK@docsplace.org

Email questions or comments to sysop@ipingthereforeiam.com
All parts of this website painstakingly hand-crafted in the U.S.A.!
IPTIA BBS/MUD/Terminal/Game Server List, © 2025 IPTIA Consulting™.