plötzlich Backup Problem

redi78

Member
Hallo Leute,

ich nutze folgendes Script welches per Cronjob läuft:

Code:
#!/bin/bash
# Description: Sicherung von /var/log anlegen und automatisch auf einen festgelegten FTP-Server hochladen oder in ein Verzeichnis verschieben. 
# Version 1.0


# Allgemeine Angaben

# MYSQL_USER=[***]
# MYSQL_PASS=[***]
# FTP_SERVER=[***]
# FTP_USER=[***]
# FTP_PASS=[***# Festlegung des Datums - Format: 20050710
DATE=`/bin/date +"%Y%m%d"`

# Das Script

# Backup-Verzeichnis anlegen
cd /.. 
/bin/mkdir /media/backup/tmp/backup
cd /media/backup/tmp/backup
/bin/mkdir mail

# Verzeichnisse die ins Backup integriert werden sollen 
# rsync -az --delete --delete-after /srv /backup
# rsync -az --delete --delete-after /etc /backup
cd /..
/usr/bin/rsync -az --delete --delete-after /var/vmail /media/backup/tmp/backup/mail

# cd /backup/mysql

# Sicherung der Datenbanken
# mysqldump -AaCceQ --user=root --password=****** -r mysql.dbs
# mysqldump -AaCceQ -u $MYSQL_USER -p$MYSQL_PASS -r mysql.dbs

cd /media/backup/tmp/backup/mail

# Alle Dateien mit tar.bz2 komprimieren
# tar cjfp files-$DATE.tar.bz2 srv
# tar cjfp etc-$DATE.tar.bz2 etc
# tar cjfp logs-$DATE.tar.bz2 log
/bin/tar cjfp mail-$DATE.tar.bz2 mail
# tar cjfp mysql-$DATE.tar.bz2 mysql

# Alle komprimierten Dateien per FTP auf den Backup-Server laden
# ftp ftp://$FTP_USER:$FTP_PASS@$FTP_SERVER *$DATE* 21

# Alle komprimierten Dateien auf den Backup-Server verschieben
/bin/mv *$DATE* /media/backup/backups/mail

# Anschliessend alle auf den Server angelegten Dateien wieder löschen
/bin/rm -r -f /media/backup/tmp/backup
Leider erhalte ich folgende Fehlermeldungen:

Code:
/bin/tar: mail/vmail/mccormick-ersatzteile.com/office/.Junk/new: Cannot stat: No such file or directory
/bin/tar: mail/vmail/mccormick-ersatzteile.com/office/.Junk: Cannot stat: No such file or directory
/bin/tar: mail/vmail/mccormick-ersatzteile.com/office/subscriptions: Cannot stat: No such file or directory
/bin/tar: mail/vmail/mccormick-ersatzteile.com/office/.Trash: Cannot stat: No such file or directory
/bin/tar: mail/vmail/mccormick-ersatzteile.com/office/.Drafts/new: Cannot stat: No such file or directory
/bin/tar: mail/vmail/mccormick-ersatzteile.com/office/.Drafts: Cannot stat: No such file or directory
/bin/tar: mail/vmail/mccormick-ersatzteile.com/office/tmp: Cannot stat: No such file or directory
/bin/tar: mail/vmail/mccormick-ersatzteile.com/office/courierimapsubscribed: Cannot stat: No such file or directory
/bin/tar: mail/vmail/mccormick-ersatzteile.com/office/.Sent/cur: Cannot stat: No such file or directory
/bin/tar: mail/vmail/mccormick-ersatzteile.com/office/.Sent/new: Cannot stat: No such file or directory
/bin/tar: mail/vmail/mccormick-ersatzteile.com/office/.Sent: Cannot stat: No such file or directory
/bin/tar: mail/vmail/mccormick-ersatzteile.com/office/cur: file changed as we read it
/bin/tar: mail/vmail/mccormick-ersatzteile.com/office/new/1250625293.M486297P32245V0000000000000801I000D6024_0.server,S=1072: file changed as we read it
/bin/tar: mail/vmail/mccormick-ersatzteile.com/office/new/1265058560.M378677P3298V0000000000000801I000D64C0_0.server,S=64327: Cannot stat: No such file or directory
/bin/tar: mail/vmail/mccormick-ersatzteile.com/office/new/1250670930.M302282P10546V0000000000000801I000D6065_0.server,S=122913: file changed as we read it
/bin/tar: mail/vmail/mccormick-ersatzteile.com/office/new: Cannot stat: No such file or directory
/bin/tar: mail/vmail/mccormick-ersatzteile.com/office: Cannot stat: No such file or directory
/bin/tar: mail/vmail/mccormick-ersatzteile.com: Cannot stat: No such file or directory
/bin/tar: mail/vmail/mailfilters/blasmusikforum.at/admin: Cannot stat: No such file or directory
/bin/tar: mail/vmail/mailfilters/blasmusikforum.at/airwolf: Cannot stat: No such file or directory
/bin/tar: mail/vmail/mailfilters/blasmusikforum.at/service: Cannot stat: No such file or directory
/bin/tar: mail/vmail/mailfilters/blasmusikforum.at: Cannot stat: No such file or directory
/bin/tar: mail/vmail/mailfilters/rds360.at: Cannot stat: No such file or directory
/bin/tar: mail/vmail/mailfilters/privatkonkurs.co.at/office: Cannot stat: No such file or directory
/bin/tar: mail/vmail/mailfilters/privatkonkurs.co.at: Cannot stat: No such file or directory
/bin/tar: mail/vmail/mailfilters/austrovanka.at: Cannot stat: No such file or directory
/bin/tar: mail/vmail/mailfilters/top-pic.at/partmann: Cannot stat: No such file or directory
/bin/tar: mail/vmail/mailfilters/top-pic.at: Cannot stat: No such file or directory
/bin/tar: mail/vmail/mailfilters/wihag.cz: Cannot stat: No such file or directory
/bin/tar: mail/vmail/mailfilters/mccormick-ersatzteile.com/bestellung: Cannot stat: No such file or directory
/bin/tar: mail/vmail/mailfilters/mccormick-ersatzteile.com/office: Cannot stat: No such file or directory
/bin/tar: mail/vmail/mailfilters/mccormick-ersatzteile.com: Cannot stat: No such file or directory
/bin/tar: mail/vmail/mailfilters/jk-zayatal.at/stabfuehrer: Cannot stat: No such file or directory
/bin/tar: mail/vmail/mailfilters/jk-zayatal.at/kapellmeister: Cannot stat: No such file or directory
/bin/tar: mail/vmail/mailfilters/jk-zayatal.at/medienreferent: Cannot stat: No such file or directory
/bin/tar: mail/vmail/mailfilters/jk-zayatal.at/schriftfuehrer: Cannot stat: No such file or directory
/bin/tar: mail/vmail/mailfilters/jk-zayatal.at/obmann: Cannot stat: No such file or directory
/bin/tar: mail/vmail/mailfilters/jk-zayatal.at/archivar: Cannot stat: No such file or directory
/bin/tar: mail/vmail/mailfilters/jk-zayatal.at: Cannot stat: No such file or directory
/bin/tar: mail/vmail/mailfilters: Cannot stat: No such file or directory
/bin/tar: mail/vmail/.mailfilter: Cannot stat: No such file or directory
/bin/tar: mail/vmail/jk-zayatal.at/stabfuehrer/.Junk/tmp: Cannot stat: No such file or directory
/bin/tar: mail/vmail/jk-zayatal.at/stabfuehrer/.Junk/cur: Cannot stat: No such file or directory
/bin/tar: mail/vmail/jk-zayatal.at/stabfuehrer/.Junk/new: Cannot stat: No such file or directory
/bin/tar: mail/vmail/jk-zayatal.at/stabfuehrer/.Junk: Cannot stat: No such file or directory
/bin/tar: mail/vmail/jk-zayatal.at/stabfuehrer/subscriptions: Cannot stat: No such file or directory
/bin/tar: mail/vmail/jk-zayatal.at/stabfuehrer/.Trash: file changed as we read it
/bin/tar: mail/vmail/jk-zayatal.at/stabfuehrer/.Drafts/tmp: Cannot stat: No such file or directory
/bin/tar: mail/vmail/jk-zayatal.at/stabfuehrer/.Drafts/cur: Cannot stat: No such file or directory
/bin/tar: mail/vmail/jk-zayatal.at/stabfuehrer/.Drafts/new: Cannot stat: No such file or directory
/bin/tar: mail/vmail/jk-zayatal.at/stabfuehrer/.Drafts: Cannot stat: No such file or directory
/bin/tar: mail/vmail/jk-zayatal.at/stabfuehrer/tmp: Cannot stat: No such file or directory
/bin/tar: mail/vmail/jk-zayatal.at/stabfuehrer/courierimapsubscribed: Cannot stat: No such file or directory
/bin/tar: mail/vmail/jk-zayatal.at/stabfuehrer/.Sent/new: Cannot stat: No such file or directory
/bin/tar: mail/vmail/jk-zayatal.at/stabfuehrer/.Sent: Cannot stat: No such file or directory
/bin/tar: mail/vmail/jk-zayatal.at/stabfuehrer/cur: Cannot stat: No such file or directory
/bin/tar: mail/vmail/jk-zayatal.at/stabfuehrer/new/1295636880.M753964P2710V0000000000000801I000C4887_0.server,S=660912: file changed as we read it
/bin/tar: mail/vmail/jk-zayatal.at/stabfuehrer/new/1265058735.M640299P3435V0000000000000801I000C4921_0.server,S=64299: Cannot stat: No such file or directory
/bin/tar: mail/vmail/jk-zayatal.at/stabfuehrer/new/1250708988.M29378P19657V0000000000000801I000C46D7_0.server,S=1051: Cannot stat: No such file or directory
/bin/tar: mail/vmail/jk-zayatal.at/stabfuehrer/new/1273609408.M818784P18905V0000000000000801I000C4770_0.server,S=8391: Cannot stat: No such file or directory
/bin/tar: mail/vmail/jk-zayatal.at/stabfuehrer/new/1276751443.M751529P4961V0000000000000801I000C478E_0.server,S=3204: Cannot stat: No such file or directory
/bin/tar: mail/vmail/jk-zayatal.at/stabfuehrer/new/1267972044.M841054P4895V0000000000000801I000C474C_0.server,S=8902: Cannot stat: No such file or directory
/bin/tar: mail/vmail/jk-zayatal.at/stabfuehrer/new/1276620102.M546402P8768V0000000000000801I000C47BA_0.server,S=132733: Cannot stat: No such file or directory
/bin/tar: mail/vmail/jk-zayatal.at/stabfuehrer/new/1295779886.M76002P26010V0000000000000801I000C485B_0.server,S=4475: Cannot stat: No such file or directory
/bin/tar: mail/vmail/jk-zayatal.at/stabfuehrer/new/1276769390.M103503P11588V0000000000000801I000C47C0_0.server,S=2754: Cannot stat: No such file or directory
/bin/tar: mail/vmail/jk-zayatal.at/stabfuehrer/new/1280226629.M122445P25195V0000000000000801I000C4A88_0.server,S=8476: Cannot stat: No such file or directory
/bin/tar: mail/vmail/jk-zayatal.at/stabfuehrer/new: Cannot stat: No such file or directory
/bin/tar: mail/vmail/jk-zayatal.at/stabfuehrer: Cannot stat: No such file or directory
/bin/tar: mail/vmail/jk-zayatal.at/kapellmeister: Cannot stat: No such file or directory
/bin/tar: mail/vmail/jk-zayatal.at/medienreferent: Cannot stat: No such file or directory
/bin/tar: mail/vmail/jk-zayatal.at/kapellmeisterl: Cannot stat: No such file or directory
/bin/tar: mail/vmail/jk-zayatal.at/schriftfuehrer: Cannot stat: No such file or directory
/bin/tar: mail/vmail/jk-zayatal.at/jugendreferent: Cannot stat: No such file or directory
/bin/tar: mail/vmail/jk-zayatal.at/obmann: Cannot stat: No such file or directory
/bin/tar: mail/vmail/jk-zayatal.at/archivar: Cannot stat: No such file or directory
/bin/tar: mail/vmail/jk-zayatal.at: Cannot stat: No such file or directory
/bin/tar: mail/vmail: Cannot stat: No such file or directory
/bin/tar: mail: Cannot stat: No such file or directory
/bin/tar: Error exit delayed from previous errors
/bin/mv: cannot stat `*20110410*': No such file or directory
Ich versteh das nicht. Kann mir jemand helfen?

Danke und lg,
Rene
 
Zuletzt bearbeitet:

redi78

Member
Oje vielen Dank, das hab ich total übersehen. PW geändert. Ne Idee bezüglich dem Fehler?

lg
 
Zuletzt bearbeitet:

redi78

Member
mhhh wieder Fehlermeldung:

Code:
root@server:~/scripts# ./backupmail.sh
/bin/mkdir: cannot create directory `/media/backup/tmp/backup': File exists
tar: mail: Cannot stat: No such file or directory
tar: Error exit delayed from previous errors
 

funsurfer

New Member
mhhh wieder Fehlermeldung:

Code:
root@server:~/scripts# ./backupmail.sh
/bin/mkdir: cannot create directory `/media/backup/tmp/backup': File exists
tar: mail: Cannot stat: No such file or directory
tar: Error exit delayed from previous errors

hat das script jemals funktioniert?

Jetzt hast du ein Problem die backupdir zu schreiben....
Check nochmal das verzeichnis, und ob du die Berechtigungen zum schreiben hast.


LG
 

Werbung

Top