LinuxQuestions.org
Review your favorite Linux distribution.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Desktop
User Name
Password
Linux - Desktop This forum is for the discussion of all Linux Software used in a desktop context.

Notices

Reply
 
Search this Thread
Old 10-22-2008, 08:50 AM   #1
KinnowGrower
Member
 
Registered: May 2008
Location: Toronto
Distribution: Centos && Debian
Posts: 341

Rep: Reputation: 34
All files/Directories owned by root (unable to change with "chown")


Hello Friends

I have 500 Gb external Hard drive. I just bought it and attached. What i had change only is that, In beginning it was showing it as icon "485 GB Media" on desktop.I dont remeber due to some reason i had changed its mount point & it stop mounting. Then i had made a entry in fstab to mount it.

now it is mounting under /mnt

Problem i am facing now is

I have some image file down loaded from inetrnet
i tried to use them in HTML prgramming. some of them shows error "may not have permissions".

What i see is every file on my hdd is owned by root root
i tried to change it by "chown". But i could not

any help please

Last edited by KinnowGrower; 10-22-2008 at 09:07 AM.
 
Old 10-22-2008, 08:55 AM   #2
odcheck
Member
 
Registered: Aug 2006
Distribution: Fedora, CentOS, RHEL, Debian
Posts: 978

Rep: Reputation: 30
You probably have mounted it as root?
Did you already thought about that?
man mount

You must mount it in the fstab as user or users
 
Old 10-22-2008, 08:56 AM   #3
CRC123
Member
 
Registered: Aug 2008
Distribution: opensuse, RHEL
Posts: 374
Blog Entries: 1

Rep: Reputation: 31
Quote:
Originally Posted by varindersingh View Post
Hello Friends

I have 500 Gb external Hard drive. I just bought it and attached. What i had change only is that, In beginning it was showing it as icon "485 GB Media" on desktop.I dont remeber due to some reason i had changed its mount point & it stop mounting. Then i had made a entry in fstab to mount it.

now it is mounting under /mnt

Problem i am facing now is

I have some image file down loaded from inetrnet
i tried to use them in HTML. some them error "may not have permissions".

What i see is every file on my hdd is owned by root root
i tried to change it by "chown". But i could not

any help please
Did you use the 'chown' command with root privileges?

You can only make changes to 'root' related settings under the root account.

'su' or 'su -' will give you the root account assuming you know the root password.
 
Old 10-22-2008, 09:22 AM   #4
KinnowGrower
Member
 
Registered: May 2008
Location: Toronto
Distribution: Centos && Debian
Posts: 341

Original Poster
Rep: Reputation: 34
Quote:
Originally Posted by CRC123 View Post
Did you use the 'chown' command with root privileges?

You can only make changes to 'root' related settings under the root account.

'su' or 'su -' will give you the root account assuming you know the root password.
Yes my freind i tried that with as root.

Even i tried with -Rv option. it shows me messages that "permission changed to 'user' But actullay when i 'll' it shows again as root
 
Old 10-22-2008, 09:31 AM   #5
KinnowGrower
Member
 
Registered: May 2008
Location: Toronto
Distribution: Centos && Debian
Posts: 341

Original Poster
Rep: Reputation: 34
Quote:
Originally Posted by odcheck View Post
You probably have mounted it as root?
Did you already thought about that?
man mount

You must mount it in the fstab as user or users
Hi friend,

What i remeber i think i have mounted it as root.

Can u please tell me how i can mount it in fstab as users

This is what i have did in fstab

/dev/sdb1 /mnt/usbhdd ntfs defaults 0 0

where i have to make change

. Even it will be greta help if we can allow it to mount as usual . Means as it was mounting automatically before changes in /etc/fstab. But i dont know the way.

Can u help me please
 
Old 10-22-2008, 09:50 AM   #6
David the H.
Bash Guru
 
Registered: Jun 2004
Location: Osaka, Japan
Distribution: Debian sid + kde 3.5 & 4.4
Posts: 6,823

Rep: Reputation: 1949Reputation: 1949Reputation: 1949Reputation: 1949Reputation: 1949Reputation: 1949Reputation: 1949Reputation: 1949Reputation: 1949Reputation: 1949Reputation: 1949
Your drive appears to be ntfs, which needs some special care in order to be usable in Linux. When you had it automounting, everything was configured for you, but you have to manually configure everything now that you've gone to fstab.

First of all, in order to get safe write support, you need to be using the fuse/ntfs-3g mount system. The native Linux ntfs is only read-safe.

Second, ntfs (and fat as well) doesn't natively support *nix permissions and ownerships, so no amount of chmod or chown'ing will do you any good. These settings have to be simulated with various mount options.

Using NTFS on Linux has been covered many times in many places, so I suggest you do a little search footwork here and on google.
 
Old 10-22-2008, 09:56 AM   #7
KinnowGrower
Member
 
Registered: May 2008
Location: Toronto
Distribution: Centos && Debian
Posts: 341

Original Poster
Rep: Reputation: 34
hi david

Thanks you very much for help

i dont know much about "fuse/ntfs-3g mount system"


but as u suggested i should read something about to handle NTFS in linux.

Definitely i will try that, if i had a problem i will back


Thanks again for help
 
Old 10-22-2008, 09:59 AM   #8
David the H.
Bash Guru
 
Registered: Jun 2004
Location: Osaka, Japan
Distribution: Debian sid + kde 3.5 & 4.4
Posts: 6,823

Rep: Reputation: 1949Reputation: 1949Reputation: 1949Reputation: 1949Reputation: 1949Reputation: 1949Reputation: 1949Reputation: 1949Reputation: 1949Reputation: 1949Reputation: 1949
By the way, a better option for you would be to try to get it working under the automounter again. fstab is not really the best way to configure removable media.

Also, if the drive isn't ever going to be plugged into a Windows system, you should consider reformatting it to ext3 or another native Linux filesystem. It would be much easier for you than having to deal with simulated permissions and ownership all the time.
 
Old 10-22-2008, 10:18 AM   #9
KinnowGrower
Member
 
Registered: May 2008
Location: Toronto
Distribution: Centos && Debian
Posts: 341

Original Poster
Rep: Reputation: 34
Quote:
Originally Posted by David the H. View Post
By the way, a better option for you would be to try to get it working under the automounter again. fstab is not really the best way to configure removable media.

Also, if the drive isn't ever going to be plugged into a Windows system, you should consider reformatting it to ext3 or another native Linux filesystem. It would be much easier for you than having to deal with simulated permissions and ownership all the time.
hi david

but i dont know how to again automount the hdd

even i dont want to work it with /etc/fstab

i have a computer that is daul booting. Some time we may have to use it under windows as well

But i want to mount it with automount. Thats it.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

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 Off
HTML code is Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Copying files and sub-directories of a directory except the directories named ".abc" sri1025 Linux - General 2 08-24-2010 08:53 AM
File owned by "root" TentativeChaos Linux - Newbie 4 03-09-2008 05:21 PM
chown-ing all files on a drive owned by one user. nkoplm Linux - General 1 10-26-2006 06:20 AM
Why doesn't a wildcard chmod change "dot" files/directories? jht2k Linux - General 1 08-09-2004 02:31 PM
empty files named "1" owned by root ??? kkempter Linux - General 3 07-09-2003 02:07 PM


All times are GMT -5. The time now is 04:35 AM.

Main Menu
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
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration