V
V
Vladimir Kivva2012-12-27 15:36:46
linux
Vladimir Kivva, 2012-12-27 15:36:46

Error when tar-backing live linux machine?

I have only one partition on the HDD: sda1, mounted it to /mnt/root , and a network drive on another machine to /mnt/backup , now sudo tar -cvzpf /mnt/backup/ubuntu-sda1.tar.gz /mnt/root . Is it normal for a backup to go through while the system is running, what are the possible incidents, is there recursion?

UPD.
Renamed the question because I see:
tar: Exiting with a failed status due to errors encountered

When using the command:
tar -cvpzf backup.tar.gz --exclude=/backup.tar.gz --exclude=/proc --exclude=/lost+found --exclude=/sys --exclude=/mnt --exclude=/media --exclude=/dev /

What could be the reasons, how to solve?

Answer the question

In order to leave comments, you need to log in

4 answer(s)
3
3vi1_0n3, 2012-12-27
@3vi1_0n3

For backup of whole partitions I would suggest dump/restore

R
rPman, 2012-12-27
@rPman

tar --one-file-system will only back up the root partition (without /dev and /proc, of course, but if the installation is scattered over partitions like /usr, /var or /home, as some outdated guides recommend, then you will have to back them up with a separate command) .
And you need to understand that some applications, such as databases, are not recommended to be backed up by regular copying while they are running (and even harmful to the backup).

M
merlin-vrn, 2012-12-27
@merlin-vrn

Did you mount the same FS twice - on / and on /mnt/root? Oh right...

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question