Tar module issue

Eddie Corns eddie at holyrood.ed.ac.uk
Mon Feb 7 13:28:35 EST 2005


I don't have the original query any more but I think your problem is related
to mixing absolute and relative file paths.  That is the filenames themselves,
I think I recall in your original message you were mixing up the idea of
global variables in your code versus the filenames stored in the TAR archive.

When tar restores files it will either be doing them as relative paths
(directory + filename) or absolute paths, I think relative is the default.
This is relative to where you are now when you extract NOT where you were when
you archived them.  I think there may be extra confusion to do with the way
tar stores hard links  What might be happening is that some paths are actually
links to other files, you would need to figure out how tar is dealing with
this - is it converting links back to relative paths (unlikely I suspect)?
Either way it might be trying to create a link to a file that either doesn't
exist on the system you are restoring to or not from the directory where you
now are.

I hope that makes sense.

Eddie



More information about the Python-list mailing list