You are not logged in.

#1 2012-03-15 01:51:33

phrenchax
Member
From: Glens Falls, NY, USA
Registered: 2010-11-28
Posts: 6

[SOLVED] USB drive formatted as ext2 mounts as root only

I feel like I am over looking something silly:
I have an external hard drive.  If I format it as fat32, I can mount it without issue in KDE and I have full rw access.
However, if I format it as ext2, I can still mount it but I do not have write access as a regular user.  I can write to it as root.
Is this normal behavior, or am I doing something wrong?
Thanks!

Last edited by phrenchax (2012-03-16 00:38:41)

Offline

#2 2012-03-15 02:28:56

dodo3773
Member
Registered: 2011-03-17
Posts: 818

Re: [SOLVED] USB drive formatted as ext2 mounts as root only

Can't you just chown the partition / directory?

Offline

#3 2012-03-15 02:49:14

thisoldman
Member
From: Pittsburgh
Registered: 2009-04-25
Posts: 1,172

Re: [SOLVED] USB drive formatted as ext2 mounts as root only

Fat32 doesn't have file permissions or file ownership, modern file systems incorporate these.  If you wish to mount a partition as a normal user, you should read and use the udev article in the wiki.  It's also possible to set permissions for a specific external drive using fstab.

Offline

#4 2012-03-15 04:02:44

ewaller
Administrator
From: Pasadena, CA
Registered: 2009-07-13
Posts: 19,797

Re: [SOLVED] USB drive formatted as ext2 mounts as root only

How are you mounting it?  Have you created an /etc/fstab entry for it? Are you counting on udev ?


Nothing is too wonderful to be true, if it be consistent with the laws of nature -- Michael Faraday
Sometimes it is the people no one can imagine anything of who do the things no one can imagine. -- Alan Turing
---
How to Ask Questions the Smart Way

Offline

#5 2012-03-15 11:32:47

phrenchax
Member
From: Glens Falls, NY, USA
Registered: 2010-11-28
Posts: 6

Re: [SOLVED] USB drive formatted as ext2 mounts as root only

Thanks for the replies guys!

dodo3773: I can use chown, but I would have to do this every time I mount it.

thisoldman: I could use fstab, but what I want is to have any usb drive I plug in rw accessible to normal users, even if formatted as ext.  I will dig into udev and see what I can find out...

ewaller: I am mounting it by clicking on it in Dolphin (KDE).

I guess what I probably want is to make sure the users group is granted rw access.

Offline

#6 2012-03-15 12:33:03

Mr.Elendig
#archlinux@freenode channel op
From: The intertubes
Registered: 2004-11-07
Posts: 4,092

Re: [SOLVED] USB drive formatted as ext2 mounts as root only

just chmod the content of the stick to 0777


Evil #archlinux@libera.chat channel op and general support dude.
. files on github, Screenshots, Random pics and the rest

Offline

#7 2012-03-15 17:45:49

dodo3773
Member
Registered: 2011-03-17
Posts: 818

Re: [SOLVED] USB drive formatted as ext2 mounts as root only

phrenchax wrote:

I am mounting it by clicking on it in Dolphin (KDE).

I guess what I probably want is to make sure the users group is granted rw access.

Is your user in the storage group? Also, have you tried an alternate file manager to make sure that isn't the problem? You are running consolekit, dbus, etc.. right?

Offline

#8 2012-03-16 00:38:14

phrenchax
Member
From: Glens Falls, NY, USA
Registered: 2010-11-28
Posts: 6

Re: [SOLVED] USB drive formatted as ext2 mounts as root only

The more I think about it, the more I am coming to realize that this is normal behavior.  I guess every flash drive I have used in the past has been fat16/32, for which permissions don't matter: just plug it in and anybody can write to it.  I guess I was expecting the same behavior with a ext2 formatted usb drive, but obviously that can't be so.

I have created a directory on my usb drive as root, changed ownership to my user name, and I can now plug in and write to that folder as regular user without any problem.

Marking this one as solved; thanks all for your thoughts!

Offline

Board footer

Powered by FluxBB