# dump -C16 -0uanL -h0 -f - / | gzip -2 | ssh -c blowfish user@otherhost dd of=root.dump.gz
# ssh -c blowfish usr@otherhost gzcat root.dump.gz | (cd / && restore -ruf -)
# ssh -c blowfish usr@otherhost gzcat root.dump.gz | (cd /dev && restore -ruf -)
# ssh -c blowfish usr@otherhost gzcat root.dump.gz | (cd /temp && restore -ruf -)
# ssh -c blowfish usr@otherhost gzcat root.dump.gz | (cd /usr restore -ruf -)
# ssh -c blowfish usr@otherhost gzcat root.dump.gz | (cd /usr/home && restore -ruf -)
# ssh -c blowfish usr@otherhost gzcat root.dump.gz | (cd /var && restore -ruf -)
# mkdir /tmp/root /tmp/var /tmp/usr
# ssh -c blowfish usr@otherhost gzcat root.dump.gz | (cd /tmp/root && restore -ruf -)
# ssh -c blowfish usr@otherhost gzcat var.dump.gz | (cd /tmp/var && restore -ruf -)
# ssh -c blowfish usr@otherhost gzcat usr.dump.gz | (cd /tmp/usr && restore -ruf -)
kantshoot said:Thanks Warren,
I did read about dump(8)in the FAQ section but am not knowledgeable enough to transfer the files in the manner recommended. I reviewed you links regarding dump Via SSH and have a question.
The new system has the following directories:
/ , /dev, /temp, /usr, /usr/home, /var
If I use dump to gz the files from each directory to the new server under my acct
Code:# dump -C16 -0uanL -h0 -f - / | gzip -2 | ssh -c blowfish user@otherhost dd of=root.dump.gz
Can I do the following to restore the files to each of the new existing directories:
Code:# ssh -c blowfish usr@otherhost gzcat root.dump.gz | (cd / && restore -ruf -) # ssh -c blowfish usr@otherhost gzcat root.dump.gz | (cd /dev && restore -ruf -) # ssh -c blowfish usr@otherhost gzcat root.dump.gz | (cd /temp && restore -ruf -) # ssh -c blowfish usr@otherhost gzcat root.dump.gz | (cd /usr restore -ruf -) # ssh -c blowfish usr@otherhost gzcat root.dump.gz | (cd /usr/home && restore -ruf -) # ssh -c blowfish usr@otherhost gzcat root.dump.gz | (cd /var && restore -ruf -)
The restore recommends making files:
Code:# mkdir /tmp/root /tmp/var /tmp/usr # ssh -c blowfish usr@otherhost gzcat root.dump.gz | (cd /tmp/root && restore -ruf -) # ssh -c blowfish usr@otherhost gzcat var.dump.gz | (cd /tmp/var && restore -ruf -) # ssh -c blowfish usr@otherhost gzcat usr.dump.gz | (cd /tmp/usr && restore -ruf -)
I do not understand why I need to first set the files up under a tmp directory when the directories the file need to be in are already created. Am I wrong??