LinuxQuestions.org
Visit Jeremy's Blog.
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 02-12-2003, 10:56 PM   #1
SIR_Taco
LQ Newbie
 
Registered: Feb 2003
Posts: 14

Rep: Reputation: 0
Angry Lost Mout Rights..... ARGH



ok, here's the story. I've been using Slackware for about 4 years now, and I thought I had seen it all, however just recently I've run into a problem I can't seem to fix by any of my usual tricks.

I had all my hard-drives mounted, my digital camera mounted, cd-rom, scsi devices, etc and allowed access to my 'users' group. Fine and dandy, I could get to my MP3 files on my FAT32 and what not.
One day I boot and suddenly I get an "bash: cd: /G: Permission denied", without even touching my /etc/fstab or anything.... so I tried re-mounting, editing my /etc/fstab, chaning permissions to /dev's etc..... but nothing....

So this is the case of the disappearing permissions.... anyone have any ideas?


help help
Thanks
SIR_Taco
 
Old 02-13-2003, 04:51 AM   #2
Mik
Senior Member
 
Registered: Dec 2001
Location: The Netherlands
Distribution: Ubuntu
Posts: 1,316

Rep: Reputation: 47
Could you post the entries in the /etc/fstab file. And does it just not mount as the user anymore or does it also not mount as root?
Maybe it's me reading it wrong but it's not clear from your post whether you are having troubles mounting the partition or just troubles accessing the partition. If you could explain exactly what's failing plus error messages a little better I'm sure someone will be able to help you out.
For mount options in your fstab file you should check the mount man page. You should probably go down to the section 'Mount options for fat'.
Also you should make sure the user option is set so a normal user can mount the drive. And the s bit should be set on the mount executable to allow normal users to mount properly.
 
Old 02-13-2003, 07:52 AM   #3
acid2000
Member
 
Registered: Nov 2001
Location: Exeter, UK
Distribution: Gentoo 1.4
Posts: 243

Rep: Reputation: 30
If it's a FAT32 drive have you run scandisk on it?
 
Old 02-13-2003, 08:07 AM   #4
williamwbishop
Member
 
Registered: Feb 2003
Location: god's judge
Posts: 376

Rep: Reputation: 30
omg.
 
Old 02-13-2003, 12:05 PM   #5
SIR_Taco
LQ Newbie
 
Registered: Feb 2003
Posts: 14

Original Poster
Rep: Reputation: 0
Clear some things up

I'm having trouble accessing my drives as the 'users' group

fstab:
<#cut#>
/dev/hda5 / ext2 defaults 1 1
/dev/hda1 /C vfat defaults 0 1
/dev/hdg1 /G vfat defaults 0 1
/dev/cdrom /mnt/cdrom iso9660 noauto,users,ro 0 0
/dev/fd0 /mnt/floppy auto noauto,users,rw 0 0
/dev/sda1 /mnt/A203 vfat owner 0 0
none /dev/pts devpts gid=5,mode=620 0 0
none /proc proc defaults 0 0
none /proc/bus/usb usbfs defaults 0 0
<#paste#>

Now, 'users' dont' have permissions to hda1,hdg1,cdrom, or sda1 and I think the same problem has killed printing permissions too.

hope this helps.... if you need more info just let me know

thanks
SIR_Taco
 
Old 02-14-2003, 03:07 AM   #6
Mik
Senior Member
 
Registered: Dec 2001
Location: The Netherlands
Distribution: Ubuntu
Posts: 1,316

Rep: Reputation: 47
For /dev/hda1 and /dev/hdg1 you've just set it to defaults.
This would imply the following options:
rw, suid, dev, exec, auto, nouser, and async

nouser implies that a non-root user can't mount the drive. But since the auto option is set they will all get mounted on startup so you probably wouldn't need to mount them as a normal user anyway.

A fat partition doesn't contain permissions in the same way as any normal *nix filesystem. So you have to set the permissions for the whole drive. Now the defaults for uid gid and umask is to inherit the values of the current process (this means the one that mounts the drives). Now since you got these entries in your fstab file and they have the auto flag set they will be mounted on startup which will most likely be done by root. So the uid and gid of all the files on the partition will be root. I don't know what the umask is set to before this is done but most likely it's not leniant enough to allow other users to access the files. If all you want to do is allow the users to be able to read the files then just adding umask=0002 should be enough. If you want the users group to be able to also have write access then you'd probably also want to set the gid=xxx (gid of the group users).

The owner you've set for /dev/sda1 requires the user that wants to mount the drive also to be owner of the /dev/sda1 file. Probably not something you really want to specify.
 
Old 02-14-2003, 03:36 PM   #7
SIR_Taco
LQ Newbie
 
Registered: Feb 2003
Posts: 14

Original Poster
Rep: Reputation: 0
Thanks a lot man.... that did the trick... I just can't figure out how come it was working exactly how I wanted it before and then suddenly stopped.... but the main thing is it's working now.

Thanks a million
SIR_Taco
 
  


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



Similar Threads
Thread Thread Starter Forum Replies Last Post
Can't See. . . Argh Hive DamnSmallLinux 2 04-21-2005 03:38 PM
can't mout iso jackandking Linux - Software 2 12-02-2004 07:30 AM
Lost Execution rights of "chmod" arkus Linux - General 2 10-05-2004 09:58 AM
root has lost its rights DoubleM Linux - General 3 03-19-2003 02:10 PM
argh espositopm Linux - General 1 02-28-2003 02:01 PM

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

All times are GMT -5. The time now is 04:24 PM.

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