Subject: | Many chown failures when uid/gid does not exist |
Archive::Tar properly tries to set the uid/gid of the extracted files to those stored in the archive. The problem is that many archives have the uid on the remote machine of the user that created the archive. The result is either that the files are extracted with a random local user. Or that the chown call fails producing lots of "Could not set uid/gid" messages.
GNU tar does not report a warning when it can't change the owner. It also has a flag, --same-owner, which should probably be used more often.
I think the best solution would be to implement a same-owner option for Archive::Tar and use that in CPANPLUS or other places.