Portal Home > Knowledgebase > Articles Database > tar: file changed as we read it


tar: file changed as we read it




Posted by bingowings23456, 11-12-2013, 11:49 PM
Hi there, I got the "tar: file changed as we read it" message. I fixed it using --ignore-failed-read in the command line. If it is being ignored, will the file still tar? Does it mean it will not be the most recent version i.e. not the version after it read it? Thanks

Posted by ngardiner, 11-18-2013, 11:54 AM
It means that while the file was being streamed to the tar archive, the contents changed. Doing a tar isn't atomic, the bytes stream and something could be added to the file while that happens. If it's a file that just gets added on to the end like a log file you will be fine. If it's a file whose contents changes dramatically, you could have been halfway through the file backup when stuff at the start and end gets updated. If so, you get the changes at the end but not the start. Some systems such as a database which does binary logs will still cope with this, some may end with a corrupted file. It might be a good idea to take a look at which file it is and decide if you need to stop a service before the backup to avoid corruption.



Was this answer helpful?

Add to Favourites Add to Favourites    Print this Article Print this Article

Also Read
http://www.e-starr.net (Views: 661)

Language: