Take the 2-minute tour ×
Server Fault is a question and answer site for system and network administrators. It's 100% free, no registration required.

I'm using tar 1.15.1 (CentOS 5.5) to archive a directory.

[www]$ tar -tvzf public_org.tgz 'public/files'
drwxrwxr-x root/www          0 2010-12-01 07:33:33 public/files/
-rwxrwxr-x root/www         55 2010-12-01 07:33:33 public/files/dummy.txt
[www]$ ls -ld public/files{,/*}
drwxrwxr-x 2 apache apache 4096 Dec  1 07:33 public/files
-rwxrwxr-x 1 apache apache   55 Dec  1 07:33 public/files/dummy.txt
[www]$ tar -dvzf public_org.tgz 'public/files'
public/files/
public/files/dummy.txt
public/files/dummy.txt: Uid differs
public/files/dummy.txt: Gid differs

Anybody know why I don't get Uid/Gid differs messages on the directory? I'd really like to know if any permissions changed.

I tried running as both normal user and root.

share|improve this question

1 Answer 1

up vote 0 down vote accepted

Interesting question. I saw the same behavior with tar-1.15-1 on Centos 5.5. I took a look at the source, and it apparently doesn't diff directories, as you observed.

I compiled up the most recent version (1.26) and tried that. Same behavior.

I'm not sure what, if any rationale there is behind this. There could be a good one, I suppose, or maybe it's just something that they haven't implemented yet. You might try asking on the tar help mailing list

share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.