Is it safe to run a full system backup with tar on an ext4 filesystem?

Clash Royale CLAN TAG#URR8PPP
up vote
1
down vote
favorite
I'd like to make a backup of a live system, I'm running the command tar -cvpzf backup-latest.tar.gz --exclude=/backup-latest.tar.gz --one-file-system /
But I just got an error of: tar: /: file changed as we read it - I'm unsure if it's dropped any files or the backup succeeded.
I'm not too concerned about file permissions - just the file data most importantly.
backup tar
add a comment |Â
up vote
1
down vote
favorite
I'd like to make a backup of a live system, I'm running the command tar -cvpzf backup-latest.tar.gz --exclude=/backup-latest.tar.gz --one-file-system /
But I just got an error of: tar: /: file changed as we read it - I'm unsure if it's dropped any files or the backup succeeded.
I'm not too concerned about file permissions - just the file data most importantly.
backup tar
1
--one-file-systemis designed to skip things. (for example, a/devpopulated with static device nodes would be skipped, in some cases this is still required for successful booting). For a full backup of the rootfs, you canmount --bind / /mnt/rootthen backup/mnt/rootinstead of/.
â frostschutz
Jun 22 at 13:26
add a comment |Â
up vote
1
down vote
favorite
up vote
1
down vote
favorite
I'd like to make a backup of a live system, I'm running the command tar -cvpzf backup-latest.tar.gz --exclude=/backup-latest.tar.gz --one-file-system /
But I just got an error of: tar: /: file changed as we read it - I'm unsure if it's dropped any files or the backup succeeded.
I'm not too concerned about file permissions - just the file data most importantly.
backup tar
I'd like to make a backup of a live system, I'm running the command tar -cvpzf backup-latest.tar.gz --exclude=/backup-latest.tar.gz --one-file-system /
But I just got an error of: tar: /: file changed as we read it - I'm unsure if it's dropped any files or the backup succeeded.
I'm not too concerned about file permissions - just the file data most importantly.
backup tar
edited Jun 23 at 9:59
asked Jun 22 at 11:55
Chris Stryczynski
383116
383116
1
--one-file-systemis designed to skip things. (for example, a/devpopulated with static device nodes would be skipped, in some cases this is still required for successful booting). For a full backup of the rootfs, you canmount --bind / /mnt/rootthen backup/mnt/rootinstead of/.
â frostschutz
Jun 22 at 13:26
add a comment |Â
1
--one-file-systemis designed to skip things. (for example, a/devpopulated with static device nodes would be skipped, in some cases this is still required for successful booting). For a full backup of the rootfs, you canmount --bind / /mnt/rootthen backup/mnt/rootinstead of/.
â frostschutz
Jun 22 at 13:26
1
1
--one-file-system is designed to skip things. (for example, a /dev populated with static device nodes would be skipped, in some cases this is still required for successful booting). For a full backup of the rootfs, you can mount --bind / /mnt/root then backup /mnt/root instead of /.â frostschutz
Jun 22 at 13:26
--one-file-system is designed to skip things. (for example, a /dev populated with static device nodes would be skipped, in some cases this is still required for successful booting). For a full backup of the rootfs, you can mount --bind / /mnt/root then backup /mnt/root instead of /.â frostschutz
Jun 22 at 13:26
add a comment |Â
2 Answers
2
active
oldest
votes
up vote
2
down vote
It is not safe to do this on a life filesystem, better create a snapshot before you backup the data. How a snapshot is created and whether it is supported depends on the filesystem type, so I cannot give you an advise since you did not mention the filesystem you are using.
From your command line arguments, it seems that you use
gtar. This tar implementation sometimes has problems in reading it's own archives...so be careful to verify the archive you created for readability.Note that the command line you use does not allow you to archive more than the basic meta data and only archives time stamps with a one second granularity.
Meta data that would be missing is: ACLs, extended attributes, ...
A POSIX.1-1988 tar archive is able to archive directories, files, hard links, symlinks, block special, character special, named pipes. The fact that it cannot archive sockets is not a problem. So
tarin general is not a problem.
1
Also, special files (device nodes, sockets, named pipes etc.) might not get properly stored, AFAIK. And hard links...
â Kusalananda
Jun 22 at 12:37
1
Before 1988, this has been a problem with the tar format
â schily
Jun 22 at 12:49
add a comment |Â
up vote
0
down vote
Seems, like and awful old school way of making a backup. Is this a real server and not a VM? If it's a VM, VEEAm comes to mind as does ghetto backup. If it's a real server what file system are you using brts uses snapshots as does lvm. Since your doing a tar, maybe you can rsync your data to another box? I hope these ideas help.
No, "old school" would be to usedump. Usingtarto make a full system backup is just showing that they are not aware of proper backup software.
â Kusalananda
Jun 23 at 10:31
Usingdumpis indeed old school as it shows that somebody does not yet know thatstaris able to to the same asdumpin a filesystem and OS independend way since 14 years, but faster thandump.
â schily
Jun 24 at 7:38
add a comment |Â
2 Answers
2
active
oldest
votes
2 Answers
2
active
oldest
votes
active
oldest
votes
active
oldest
votes
up vote
2
down vote
It is not safe to do this on a life filesystem, better create a snapshot before you backup the data. How a snapshot is created and whether it is supported depends on the filesystem type, so I cannot give you an advise since you did not mention the filesystem you are using.
From your command line arguments, it seems that you use
gtar. This tar implementation sometimes has problems in reading it's own archives...so be careful to verify the archive you created for readability.Note that the command line you use does not allow you to archive more than the basic meta data and only archives time stamps with a one second granularity.
Meta data that would be missing is: ACLs, extended attributes, ...
A POSIX.1-1988 tar archive is able to archive directories, files, hard links, symlinks, block special, character special, named pipes. The fact that it cannot archive sockets is not a problem. So
tarin general is not a problem.
1
Also, special files (device nodes, sockets, named pipes etc.) might not get properly stored, AFAIK. And hard links...
â Kusalananda
Jun 22 at 12:37
1
Before 1988, this has been a problem with the tar format
â schily
Jun 22 at 12:49
add a comment |Â
up vote
2
down vote
It is not safe to do this on a life filesystem, better create a snapshot before you backup the data. How a snapshot is created and whether it is supported depends on the filesystem type, so I cannot give you an advise since you did not mention the filesystem you are using.
From your command line arguments, it seems that you use
gtar. This tar implementation sometimes has problems in reading it's own archives...so be careful to verify the archive you created for readability.Note that the command line you use does not allow you to archive more than the basic meta data and only archives time stamps with a one second granularity.
Meta data that would be missing is: ACLs, extended attributes, ...
A POSIX.1-1988 tar archive is able to archive directories, files, hard links, symlinks, block special, character special, named pipes. The fact that it cannot archive sockets is not a problem. So
tarin general is not a problem.
1
Also, special files (device nodes, sockets, named pipes etc.) might not get properly stored, AFAIK. And hard links...
â Kusalananda
Jun 22 at 12:37
1
Before 1988, this has been a problem with the tar format
â schily
Jun 22 at 12:49
add a comment |Â
up vote
2
down vote
up vote
2
down vote
It is not safe to do this on a life filesystem, better create a snapshot before you backup the data. How a snapshot is created and whether it is supported depends on the filesystem type, so I cannot give you an advise since you did not mention the filesystem you are using.
From your command line arguments, it seems that you use
gtar. This tar implementation sometimes has problems in reading it's own archives...so be careful to verify the archive you created for readability.Note that the command line you use does not allow you to archive more than the basic meta data and only archives time stamps with a one second granularity.
Meta data that would be missing is: ACLs, extended attributes, ...
A POSIX.1-1988 tar archive is able to archive directories, files, hard links, symlinks, block special, character special, named pipes. The fact that it cannot archive sockets is not a problem. So
tarin general is not a problem.
It is not safe to do this on a life filesystem, better create a snapshot before you backup the data. How a snapshot is created and whether it is supported depends on the filesystem type, so I cannot give you an advise since you did not mention the filesystem you are using.
From your command line arguments, it seems that you use
gtar. This tar implementation sometimes has problems in reading it's own archives...so be careful to verify the archive you created for readability.Note that the command line you use does not allow you to archive more than the basic meta data and only archives time stamps with a one second granularity.
Meta data that would be missing is: ACLs, extended attributes, ...
A POSIX.1-1988 tar archive is able to archive directories, files, hard links, symlinks, block special, character special, named pipes. The fact that it cannot archive sockets is not a problem. So
tarin general is not a problem.
edited Jun 22 at 12:47
answered Jun 22 at 12:33
schily
8,57221435
8,57221435
1
Also, special files (device nodes, sockets, named pipes etc.) might not get properly stored, AFAIK. And hard links...
â Kusalananda
Jun 22 at 12:37
1
Before 1988, this has been a problem with the tar format
â schily
Jun 22 at 12:49
add a comment |Â
1
Also, special files (device nodes, sockets, named pipes etc.) might not get properly stored, AFAIK. And hard links...
â Kusalananda
Jun 22 at 12:37
1
Before 1988, this has been a problem with the tar format
â schily
Jun 22 at 12:49
1
1
Also, special files (device nodes, sockets, named pipes etc.) might not get properly stored, AFAIK. And hard links...
â Kusalananda
Jun 22 at 12:37
Also, special files (device nodes, sockets, named pipes etc.) might not get properly stored, AFAIK. And hard links...
â Kusalananda
Jun 22 at 12:37
1
1
Before 1988, this has been a problem with the tar format
â schily
Jun 22 at 12:49
Before 1988, this has been a problem with the tar format
â schily
Jun 22 at 12:49
add a comment |Â
up vote
0
down vote
Seems, like and awful old school way of making a backup. Is this a real server and not a VM? If it's a VM, VEEAm comes to mind as does ghetto backup. If it's a real server what file system are you using brts uses snapshots as does lvm. Since your doing a tar, maybe you can rsync your data to another box? I hope these ideas help.
No, "old school" would be to usedump. Usingtarto make a full system backup is just showing that they are not aware of proper backup software.
â Kusalananda
Jun 23 at 10:31
Usingdumpis indeed old school as it shows that somebody does not yet know thatstaris able to to the same asdumpin a filesystem and OS independend way since 14 years, but faster thandump.
â schily
Jun 24 at 7:38
add a comment |Â
up vote
0
down vote
Seems, like and awful old school way of making a backup. Is this a real server and not a VM? If it's a VM, VEEAm comes to mind as does ghetto backup. If it's a real server what file system are you using brts uses snapshots as does lvm. Since your doing a tar, maybe you can rsync your data to another box? I hope these ideas help.
No, "old school" would be to usedump. Usingtarto make a full system backup is just showing that they are not aware of proper backup software.
â Kusalananda
Jun 23 at 10:31
Usingdumpis indeed old school as it shows that somebody does not yet know thatstaris able to to the same asdumpin a filesystem and OS independend way since 14 years, but faster thandump.
â schily
Jun 24 at 7:38
add a comment |Â
up vote
0
down vote
up vote
0
down vote
Seems, like and awful old school way of making a backup. Is this a real server and not a VM? If it's a VM, VEEAm comes to mind as does ghetto backup. If it's a real server what file system are you using brts uses snapshots as does lvm. Since your doing a tar, maybe you can rsync your data to another box? I hope these ideas help.
Seems, like and awful old school way of making a backup. Is this a real server and not a VM? If it's a VM, VEEAm comes to mind as does ghetto backup. If it's a real server what file system are you using brts uses snapshots as does lvm. Since your doing a tar, maybe you can rsync your data to another box? I hope these ideas help.
answered Jun 22 at 18:29
Mark Scheck
13
13
No, "old school" would be to usedump. Usingtarto make a full system backup is just showing that they are not aware of proper backup software.
â Kusalananda
Jun 23 at 10:31
Usingdumpis indeed old school as it shows that somebody does not yet know thatstaris able to to the same asdumpin a filesystem and OS independend way since 14 years, but faster thandump.
â schily
Jun 24 at 7:38
add a comment |Â
No, "old school" would be to usedump. Usingtarto make a full system backup is just showing that they are not aware of proper backup software.
â Kusalananda
Jun 23 at 10:31
Usingdumpis indeed old school as it shows that somebody does not yet know thatstaris able to to the same asdumpin a filesystem and OS independend way since 14 years, but faster thandump.
â schily
Jun 24 at 7:38
No, "old school" would be to use
dump. Using tar to make a full system backup is just showing that they are not aware of proper backup software.â Kusalananda
Jun 23 at 10:31
No, "old school" would be to use
dump. Using tar to make a full system backup is just showing that they are not aware of proper backup software.â Kusalananda
Jun 23 at 10:31
Using
dump is indeed old school as it shows that somebody does not yet know that star is able to to the same as dump in a filesystem and OS independend way since 14 years, but faster than dump.â schily
Jun 24 at 7:38
Using
dump is indeed old school as it shows that somebody does not yet know that star is able to to the same as dump in a filesystem and OS independend way since 14 years, but faster than dump.â schily
Jun 24 at 7:38
add a comment |Â
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
StackExchange.ready(
function ()
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2funix.stackexchange.com%2fquestions%2f451287%2fis-it-safe-to-run-a-full-system-backup-with-tar-on-an-ext4-filesystem%23new-answer', 'question_page');
);
Post as a guest
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
1
--one-file-systemis designed to skip things. (for example, a/devpopulated with static device nodes would be skipped, in some cases this is still required for successful booting). For a full backup of the rootfs, you canmount --bind / /mnt/rootthen backup/mnt/rootinstead of/.â frostschutz
Jun 22 at 13:26