LinuxQuestions.org
Download your favorite Linux distribution at LQ ISO.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - General
User Name
Password
Linux - General This Linux forum is for general Linux questions and discussion.
If it is Linux Related and doesn't seem to fit in any other forum then this is the place.

Notices


Reply
  Search this Thread
Old 03-22-2005, 02:28 AM   #1
tej
Member
 
Registered: Aug 2004
Location: india
Posts: 32

Rep: Reputation: 15
Lightbulb ownership problem while extracting


hello guys,

i am facing a strange problem.

i have a xxx.tar.gz file now i am login to the server as root user.

but when i try and extract the file in any particular folder then all the files takes owner ship of user not root

-rwxrwxrwx 1 root root 1561319 Mar 22 13:10 xxx.tar.gz


this is the file and i am extracting to /var/www/html


drwxrwxr-x 9 tejas tejas 4096 Feb 17 04:59 administrator
drwxrwxr-x 3 tejas tejas 4096 Feb 17 04:59 cache
-rw-rw-r-- 1 tejas tejas 23333 Feb 16 23:48 CHANGELOG
drwxrwxr-x 16 tejas tejas 4096 Feb 17 04:59 components
-rw-rw-r-- 1 tejas tejas 3663 Feb 12 09:17 configuration.php-dist
drwxrwxr-x 2 tejas tejas 4096 Feb 17 04:59 editor
-rw-rw-r-- 1 tejas tejas 1269 Jan 24 23:18 globals.php
drwxrwxr-x 3 tejas tejas 4096 Feb 17 04:59 help
-rw-rw-r-- 1 tejas tejas 580 Jan 23 04:30 htaccess.txt
drwxrwxr-x 6 tejas tejas 4096 Feb 17 04:59 images
drwxrwxr-x 9 tejas tejas 4096 Feb 17 04:59 includes
-rw-rw-r-- 1 tejas tejas 3365 Feb 10 08:42 index2.php
-rw-rw-r-- 1 tejas tejas 5332 Feb 16 07:33 index.php
-rw-rw-r-- 1 tejas tejas 3725 Jan 23 04:40 INSTALL

owner ship changes to tejas.tejas instead root.root
 
Old 03-22-2005, 02:33 AM   #2
ilikejam
Senior Member
 
Registered: Aug 2003
Location: Glasgow
Distribution: Fedora / Solaris
Posts: 3,109

Rep: Reputation: 97
That's normal - tar preserves ownership.

Just do 'chown -R root:root' on the folder the archive extracts to.

Dave
 
Old 03-22-2005, 07:32 AM   #3
makuyl
Senior Member
 
Registered: Dec 2004
Location: Helsinki
Distribution: Debian Sid
Posts: 1,107

Rep: Reputation: 54
"man tar" includes options for this, for example: tar --no-same-owner -xvzf filename.tar.gz
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
geting problem in extracting tar files p_garg Linux - Enterprise 1 09-29-2005 02:53 PM
hey geting problem in extracting tar files in version 4 p_garg Linux - Networking 1 09-29-2005 02:48 PM
grep problem in extracting special characters imppayel Programming 8 12-02-2004 07:28 AM
file ownership problem Karen61 Linux - General 2 09-29-2003 01:11 PM
Ownership Problem chem1 Linux - Software 2 07-05-2003 06:09 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - General

All times are GMT -5. The time now is 07:29 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration