Problem with tar on RHEL5.8 | Unix Linux Forums | Red Hat

  Go Back    


Red Hat Red Hat is the world's leading open source technology solutions provider with offerings including Red Hat Enterprise Linux (RHEL), Fedora, open source applications, security and systems management, virtualization, and Services Oriented Architecture (SOA) solutions.

Problem with tar on RHEL5.8

Red Hat


Closed Thread    
 
Thread Tools Search this Thread Display Modes
    #1  
Old 07-05-2013
prinsh prinsh is offline
Registered User
 
Join Date: May 2011
Last Activity: 8 July 2013, 7:43 AM EDT
Posts: 15
Thanks: 0
Thanked 0 Times in 0 Posts
Problem with tar on RHEL5.8

Hi All,

I have a tar file that I want to extract, I need the permissions and owners of the file to be the same as on when they were tared.

I am using this command to un-tar the file.

tar --acl --xattrs --same-owner --same-permissions -zvxf MANJUNATH_acl_corner_cases.tgz -C /cifs1/share1/

sometimes, the files gets un-tar properly and max of the time I 'm hit with these errors...

[AIROOT@ib35-12s9 crossProtocolACLTests]$ tar --acl --xattrs --same-owner --same-permissions -p -zvxf MANJUNATH_acl_corner_cases.tgz
full/
full/TC75_file_1.py
tar: full/TC75_file_1.py: Warning: Cannot acl_from_text
full/TC76_file_1.py
tar: full/TC76_file_1.py: Warning: Cannot acl_from_text
full/.fixed
full/L1/
full/L1/L2/
full/L1/L2/L3/
full/L1/L2/L3/L4/
full/L1/L2/L3/L4/L5/
full/L1/L2/L3/L4/L5/test_file_1.py
tar: full/L1/L2/L3/L4/L5/test_file_1.py: Warning: Cannot acl_from_text
full/L1/L2/L3/L4/L5/test_folder_1/
tar: full/L1/L2/L3/L4/L5/test_folder_1: Warning: Cannot acl_from_text
tar: full/L1/L2/L3/L4/L5/test_folder_1: Warning: Cannot acl_from_text
tar: full/L1/L2/L3/L4/L5: Warning: Cannot acl_from_text
tar: full/L1/L2/L3/L4/L5: Warning: Cannot acl_from_text
tar: full/L1/L2/L3/L4: Warning: Cannot acl_from_text
tar: full/L1/L2/L3/L4: Warning: Cannot acl_from_text
tar: full/L1/L2/L3: Warning: Cannot acl_from_text
tar: full/L1: Warning: Cannot acl_from_text


[AIROOT@ib35-12s9 crossProtocolACLTests]$ tar --version
tar (GNU tar) 1.15.1

Please help me find a way to overcome this. Please find the attached tar file. waiting for a quick response :/
Attached Files
File Type: tar MANJUNATH_acl_corner_cases.tar (20.0 KB, 11 views)
Sponsored Links
    #2  
Old 07-05-2013
gacanepa gacanepa is offline
Registered User
 
Join Date: Jun 2013
Last Activity: 26 July 2014, 8:32 PM EDT
Location: Villa Mercedes, San Luis, Argentina
Posts: 164
Thanks: 21
Thanked 24 Times in 21 Posts
As far as I can see, in my RHEL box

Code:
gacanepa@redhat /home/gacanepa:cat /etc/redhat-release
Red Hat Enterprise Linux Server release 5.7 (Tikanga)
gacanepa@redhat /home/gacanepa:tar --version
tar (GNU tar) 1.15.1

the --acl option doesn't exist. It is --acls. Also, please note from the manpage of tar that --xattrs automatically sets the --acls option:

Code:
       --acls this option causes tar to store each file's ACLs in the archive.

       --selinux
              this option causes tar to store  each  file's  SELinux  security  context  information  in  the
              archive.

       --xattrs
              this  option  causes  tar  to store each file's extended attributes in the archive. This option
              also enables --acls and--selinux if they haven't been set already, due to  the  fact  that  the
              data for those are stored in special xattrs.

Hope it helps.
Sponsored Links
    #3  
Old 07-05-2013
prinsh prinsh is offline
Registered User
 
Join Date: May 2011
Last Activity: 8 July 2013, 7:43 AM EDT
Posts: 15
Thanks: 0
Thanked 0 Times in 0 Posts
Thanks for the reply..I really appreciate it.
I tried to the command with and without --acls option, and neither of it helped.
I am still getting the same error. I am more confused as the its just the warning: cannot acl from text and doesn't return and further info.

I have checked for the permissions on the file when it was successfully untar'd and there are differences in the permission and accesscontrol list for the users on the files.

Please suggest something.
    #4  
Old 07-05-2013
Peasant's Avatar
Peasant Peasant is offline
Registered User
 
Join Date: Mar 2011
Last Activity: 15 September 2014, 3:36 AM EDT
Posts: 650
Thanks: 17
Thanked 146 Times in 142 Posts
I belive you will need to patch...
Red Hat Customer Portal

What is the output of

Code:
rpm -qa tar

If it's lower version then specified in the bug, then patching is required.

Regards
Peasant.
The Following User Says Thank You to Peasant For This Useful Post:
gacanepa (07-05-2013)
Sponsored Links
    #5  
Old 07-05-2013
prinsh prinsh is offline
Registered User
 
Join Date: May 2011
Last Activity: 8 July 2013, 7:43 AM EDT
Posts: 15
Thanks: 0
Thanked 0 Times in 0 Posts
Thanks Peasant for the reply...Here is the output :

[root@ib35-19s9 0011_run_swarm]# rpm -qa tar
tar-1.15.1-31.el5
Sponsored Links
    #6  
Old 07-05-2013
gacanepa gacanepa is offline
Registered User
 
Join Date: Jun 2013
Last Activity: 26 July 2014, 8:32 PM EDT
Location: Villa Mercedes, San Luis, Argentina
Posts: 164
Thanks: 21
Thanked 24 Times in 21 Posts
Quote:
Originally Posted by prinsh View Post
Thanks Peasant for the reply...Here is the output :

[root@ib35-19s9 0011_run_swarm]# rpm -qa tar
tar-1.15.1-31.el5
That is actually a newer version than the suggested patch itself (which is tar-1.15.1-30.el5).
Just a shot in the dark here... what is the output of

Code:
tar -tvzf MANJUNATH_acl_corner_cases.tgz

?
Sponsored Links
    #7  
Old 07-08-2013
prinsh prinsh is offline
Registered User
 
Join Date: May 2011
Last Activity: 8 July 2013, 7:43 AM EDT
Posts: 15
Thanks: 0
Thanked 0 Times in 0 Posts
Sorry, for a delayed response. Please find the output mentioned below..
[root@ib35-12s9 share1]# tar -tvzf MANJUNATH_acl_corner_cases.tgz
drwxr-x--- LOCAL\cifsusr/LOCAL\cifsgrp 0 2012-03-09 21:07:34 full/
-rwxrwx--- LOCAL\cifsusr/LOCAL\cifsgrp 177 2012-02-09 22:51:01 full/TC75_file_1.py
-rwxrwx--- LOCAL\cifsusr/LOCAL\cifsgrp 177 2012-02-09 22:51:04 full/TC76_file_1.py
-rw-rw---- root/root 0 2012-03-09 20:52:53 full/.fixed
drwxrwx--- LOCAL\cifsusr/LOCAL\cifsgrp 0 2012-03-09 21:07:26 full/L1/
drwxrwx--- LOCAL\cifsusr/LOCAL\cifsgrp 0 2012-03-09 21:07:25 full/L1/L2/
drwxrwx--- LOCAL\cifsusr/LOCAL\cifsgrp 0 2012-03-09 21:07:24 full/L1/L2/L3/
drwxrwx--- LOCAL\cifsusr/LOCAL\cifsgrp 0 2012-03-09 21:07:25 full/L1/L2/L3/L4/
drwxrwx--- LOCAL\cifsusr/LOCAL\cifsgrp 0 2012-03-09 21:07:25 full/L1/L2/L3/L4/L5/
-rwxrwx--- LOCAL\cifsusr/LOCAL\cifsgrp 177 2012-02-09 22:51:43 full/L1/L2/L3/L4/L5/test_file_1.py
drwxrwx--- LOCAL\cifsusr/LOCAL\cifsgrp 0 2012-02-09 22:51:33 full/L1/L2/L3/L4/L5/test_folder_1/
Sponsored Links
Closed Thread

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

More UNIX and Linux Forum Topics You Might Find Helpful
Thread Thread Starter Forum Replies Last Post
DB2 ODBC connectivity problem in RHEL5 32 bit roopalidalvi231 Red Hat 0 04-27-2012 08:55 AM
RHEL5 - desktop problem maxlee24 Red Hat 3 11-01-2010 04:02 AM
RHEL5 Kickstart NFS & DHCP Problem apfistler Red Hat 5 07-02-2009 04:22 PM
RHEL5 Kickstart Problem... HELP! mkono Linux 3 05-08-2009 12:39 PM
tar doubts - problem with tar royalibrahim Shell Programming and Scripting 2 09-08-2008 02:54 AM



All times are GMT -4. The time now is 05:28 AM.