You are not logged in.

#1 2010-11-17 03:48:18

Rician
Member
Registered: 2010-10-24
Posts: 44

File permissions

Hello. i dont have file permissions to delete/paste/create new on my two hard drives. How do i get them? file permissions as user not root.

Help.

Thanks smile

Last edited by Rician (2010-11-17 04:24:02)

Offline

#2 2010-11-17 03:51:03

Allan
Pacman
From: Brisbane, AU
Registered: 2007-06-09
Posts: 11,384
Website

Re: File permissions

More info...  at the minimum are they external hard drives and how are you mounting them.

Offline

#3 2010-11-17 04:00:59

Rician
Member
Registered: 2010-10-24
Posts: 44

Re: File permissions

The first hard drive came with my laptop and is not external , the second hard drive is external. To mount the second HD i plugin the wire that came with the HD.

Last edited by Rician (2010-11-17 04:24:20)

Offline

#4 2010-11-17 05:51:31

saint_13
Member
Registered: 2010-11-17
Posts: 26

Re: File permissions

I'm having a similar (if not the same) problem, though it's only started recently (so something broke during an upgrade I assume). I'm using an external WD hdd that plugs in via USB, mounts at /media/External. I can mount it, however I can't view any of the contents, I just get a permission denied. These are the groups my account belongs to

uid=1000(saint) gid=100(users) groups=100(users),0(root),4(adm),6(disk),7(lp),10(wheel),50(games),91(video),92(audio),93(optical),94(floppy),95(storage),96(scanner),98(power),1000(truecrypt)

Offline

#5 2010-11-17 07:11:57

Proofrific
Member
Registered: 2008-01-05
Posts: 215

Re: File permissions

Plug it in and run `mount` to see how it's being mounted.

Offline

#6 2010-11-17 07:18:40

saint_13
Member
Registered: 2010-11-17
Posts: 26

Re: File permissions

Proofrific wrote:

Plug it in and run `mount` to see how it's being mounted.

Alright, it's not mounting automatically if I plug it in, so I have to mount it through the terminal however this is what I get once it's mounted:

/dev/sdc1 on /media/External type ntfs (rw)

Offline

#7 2010-11-17 07:21:11

Proofrific
Member
Registered: 2008-01-05
Posts: 215

Re: File permissions

When you mount it through the terminal, are you mounting as root or as your regular user?  What are the permissions on /dev/sdc1 and /media/External?

Offline

#8 2010-11-17 07:30:04

saint_13
Member
Registered: 2010-11-17
Posts: 26

Re: File permissions

Proofrific wrote:

When you mount it through the terminal, are you mounting as root or as your regular user?  What are the permissions on /dev/sdc1 and /media/External?

Mounting it as a regular user using sudo. Permissions on /dev/sdc1 are: "Owner: root(root)" which has read/write access, then "Group: root" which has no access at all. /media/External is the same. However another problem lies in the fact that everytime this drive mounts, it mounts itself in /media/External_, a directory that is removed once the drive is unmounted. (I use /media/External to mount through the terminal)

Offline

#9 2010-11-17 07:43:28

Rician
Member
Registered: 2010-10-24
Posts: 44

Re: File permissions

saint_13. Why are you posting your problem in my thread? You should make yourself a thread for your problem... smile

Offline

#10 2010-11-17 07:44:54

saint_13
Member
Registered: 2010-11-17
Posts: 26

Re: File permissions

Rician wrote:

saint_13. Why are you posting your problem in my thread? You should make yourself a thread for your problem... smile

Because we seem to be having a very similar problem, plus who doesn't enjoy free bumps to their thread?

Offline

#11 2010-11-17 07:55:14

Proofrific
Member
Registered: 2008-01-05
Posts: 215

Re: File permissions

saint_13 wrote:

Mounting it as a regular user using sudo.

So, it's mounted as root.  Change the permissions of /dev/sdc1 (and perhaps also /media/External) so that you can mount it without sudo.

Or, you can mount with option "user" to allow ordinary users to mount the filesystem.  See "man mount" for details.

Offline

#12 2010-11-17 07:58:08

saint_13
Member
Registered: 2010-11-17
Posts: 26

Re: File permissions

Proofrific wrote:
saint_13 wrote:

Mounting it as a regular user using sudo.

So, it's mounted as root.  Change the permissions of /dev/sdc1 (and perhaps also /media/External) so that you can mount it without sudo.

Or, you can mount with option "user" to allow ordinary users to mount the filesystem.  See "man mount" for details.

Yeah I really have no problem mounting it through the terminal, however I am unable do to it through thunar and can't write to removable devices as well (well I can through the terminal, not thunar). Everytime I try changing the permissions of /dev/sdc1 they just revert back to "none" for group once the drive is unmounted

Offline

#13 2010-11-17 09:13:42

vadmium
Member
Registered: 2010-11-02
Posts: 63

Re: File permissions

What file system and type are you using? What are the permissions on the directories and files that you're trying to access? How (eg what command) does it get mounted?

For example, I have an NTFS partition, mounted with ntfs-3g (uses fuse) via fstab:

/etc/fstab wrote:

LABEL=frain /media/frain ntfs-3g rw,async,noatime,exec,dev,auto

/proc/mounts wrote:

/dev/sdb1 /media/frain fuseblk rw,nosuid,nodev,noatime,user_id=0,group_id=0,allow_other,blksize=4096 0 0

File permissions wrote:

$ ls -l /media/frain/svn/
total 9
drwxrwxrwx 1 root root    0 Mar 14  2009 conf
drwxrwxrwx 1 root root    0 Mar 14  2009 dav
drwxrwxrwx 1 root root 4096 Nov  9 04:22 db
-rwxrwxrwx 1 root root    2 Feb 26  2009 format
drwxrwxrwx 1 root root 4096 Mar 14  2009 hooks
drwxrwxrwx 1 root root    0 Mar 14  2009 locks
-rwxrwxrwx 1 root root  234 Dec 12  2007 README.txt

In my case I think the allow_other mount option allows any user access to all files, and they all appear owned by root, though I think this must be the default.

And to mount FAT partitions I use this command (umask was key for permissions):

mount -t vfat -o noatime,umask=0,shortname=winnt,iocharset=utf8

Offline

#14 2010-11-17 16:37:17

fsckd
Forum Fellow
Registered: 2009-06-15
Posts: 4,173

Re: File permissions

Rician wrote:

saint_13. Why are you posting your problem in my thread? You should make yourself a thread for your problem... smile

If needed, the mods can move saint_13 to a new thread. You need to give more information about your issue.
1) How do you normally mount the devices (thunar, nautilus, plain old mount, pmount, ...)?
2) What is the exact error you get (copy n' paste)?
3) What are the permissions (ls -l)?
4) What are the filesystem types of the devices (and how many partitions on each device)?
5) What is the capital of Assyria?
and so on ...

See also vadmium's comment and manuals to mount and ntfs-3g.


aur S & M :: forum rules :: Community Ethos
Resources for Women, POC, LGBT*, and allies

Offline

#15 2010-11-17 19:54:31

hwkiller
Member
Registered: 2009-07-21
Posts: 56

Re: File permissions

Iirc, you can't write to an NTFS filesystem through linux (err, rather you can't write if mounted with "ntfs" as the type)

You must mount it as ntfs-3g to have write capabilities.

That took me a while to diagnose months ago.

Offline

Board footer

Powered by FluxBB