What happens when you read a tar file?
So, when tar tries to read the directory it finds the tar file as a member of the directory, starts to read it and write it out to the tar file, and so between the time it starts to read the tar file and when it finishes reading the tar file, the tar file has changed. tar cf ./foo.tar .
How to exclude a dir from a tar file?
I’m trying to tar a whole directory except some subdirs.. The dir my-base-dir is zipped but the excluded dirs/files are also included? The excluded paths are correct relative to the current working dir.. Because the output tar file is put in one of them
Can a tar file be created outside the work space?
There can be reasons why can’t create the archive outside the work space. Worked around it by creating a temporary directory for putting the archive as: Solution 2: This one I like. create the archive file before running tar: If you want help debugging a problem like this you need to provide the make rule or at least the tar command you invoked.
When does makefile-tar show file changed as we read it?
When executing makefile, tar command shows file changed as we read it. In this case, the tar package is ok when the warning comes up; but it stops the tar command for the following backup; the file showing the warning in fact doesn’t change — it is really strange that the warning comes up
What does makefile-tar change as we read it?
When executing makefile, tar command shows file changed as we read it. In this case, –ignore-failed-read doesn’t help. I am using tar 1.23 in MinGW I just changed my computer to WIN7 64 bit. The script works well in old WIN7 32 bit. But the tar version is not as new as the 1.23.
How to make a tar file in Bash?
The backup is invoked by a bash shell script. It scans the target directory and builds makefile then invokes make to use tar command for backup. Followed is a typical makefile built by the bash shell script.