Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
probleme bei system-backup mit tar
View unanswered posts
View posts from last 24 hours
View posts from last 7 days

 
Reply to topic    Gentoo Forums Forum Index Deutsches Forum (German)
View previous topic :: View next topic  
Author Message
peje
Tux's lil' helper
Tux's lil' helper


Joined: 11 Jan 2003
Posts: 100

PostPosted: Sat Feb 15, 2003 10:45 pm    Post subject: probleme bei system-backup mit tar Reply with quote

Hallo allerseits kann mir jemand bei folgendem problem helfen.
um mein system zu backupen habe ich mit der gentoo cd gebootet und dann folgendes gemacht: (hda3 / ; hda7 backuppartition)
mkdir /mnt/quelle
mount /dev/hda3 /mnt/quelle
mkdir /mnt/ziel
mount /dev/hda7 /mnt/ziel
dann mit
tar -czvpf /mnt/ziel/backup1xy.tar.gz /mnt/quelle
einen tarball auf hda7 hergestellt
zurück habe ich verzeichnisse gleich benennt
und dann
tar -xzvpf /mnt/ziel/backup1xy.tar.gz /mnt/quelle

das resultat war in /mnt/quelle ein verzeichnis mnt/quelle/mit meinem system drauf, also auf hda3 /mnt/quelle/und mein system
und nicht wie gewünscht auf hda3 /mein system

kann mir jemand sagen wo ich was falsch gemacht habe, besser was ich ändern muss um korrekt abzusichern?
Notlösung war in ein anderes verzeichnis zu extrahieren und dann jedes verzeichnis mit mv nach hda3 zu transferieren
für jede hilfe vielen dank peje
Back to top
View user's profile Send private message
awiesel
Tux's lil' helper
Tux's lil' helper


Joined: 30 Jun 2002
Posts: 134

PostPosted: Sat Feb 15, 2003 11:34 pm    Post subject: Reply with quote

Wenn man mit absoluten Pfadnamen sichert, dann landet der Restore auch wieder dort. Also zum Sichern ein

cd /mnt/quelle
tar cvzf /mnt/ziel/quelle.tar.gz .

beim Restore dann

cd /mnt/neues_ziel (oder auch das alte)
tar xvzpf /mnt/ziel/quelle.tar.gz

Wenn man zwischen Partitionen verschieben will, dann macht man folgendes:

cd /mnt/quelle
tar cvf - .|(cd /mnt/ziel; tar xvfp -)

oder man benutzt cpio

cd /mnt/quelle
find . -print|cpio -pcvdum /mnt/ziel

Ich hoffe das hilft weiter, denn so ganz ist mir nicht klar um was es Dir genau geht
Back to top
View user's profile Send private message
peje
Tux's lil' helper
Tux's lil' helper


Joined: 11 Jan 2003
Posts: 100

PostPosted: Sun Feb 16, 2003 7:48 am    Post subject: Reply with quote

zuerst mal danke fürs antworten, das problem war das ich nach dem restoren die daten in /mnt/quelle/mnt/quelle/... hatte antstatt in /mnt/quelle/...
wenn ich das richtig verstanden habe entfällt das /mnt/quelle am schluss, und der - vor den optionen ist nicht nötig?
vielen dank
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Deutsches Forum (German) All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum