LinuxQuestions.org
Share your knowledge at the LQ Wiki.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Slackware
User Name
Password
Slackware This Forum is for the discussion of Slackware Linux.

Notices


Reply
  Search this Thread
Old 08-31-2004, 11:10 AM   #1
mokojin
Member
 
Registered: Feb 2004
Location: Portugal
Distribution: OpenSUSE 10.2
Posts: 78

Rep: Reputation: 15
Post /etc/fstab problem


hi all

this is my current /etc/fstab:

/dev/hda3 / reiserfs defaults 1 1
/dev/hda1 /mnt/c ntfs auto,ro,user,exec,suid 1 0
/dev/hda2 /mnt/d vfat auto,rw,user,exec,suid 0 0
/dev/cdrom /mnt/cdrom iso9660 noauto,user,ro 0 0
devpts /dev/pts devpts gid=5,mode=620 0 0
proc /proc proc defaults 0 0


My purpose is that as user i can access hda1 for read-only and hda2 for read and write.

At the moment as user I get "permition denied" when entering the /mnt/c and /mnt/d directories.

help?
 
Old 08-31-2004, 11:25 AM   #2
m_yates
Senior Member
 
Registered: Aug 2003
Location: Upstate
Distribution: Debian, Mint, Mythbuntu
Posts: 1,249

Rep: Reputation: 101Reputation: 101
/dev/hda2 /mnt/d vfat auto,users,owner,exec,umask=000 0 0

and

/dev/hda1 /mnt/c ntfs auto,users,owner,exec,ro,umask=0222 0 0

Should work I think.
 
Old 08-31-2004, 11:28 AM   #3
rjlee
Senior Member
 
Registered: Jul 2004
Distribution: Ubuntu 7.04
Posts: 1,994

Rep: Reputation: 76
Check the permissions of the /dev/hda1 and /dev/hda2 devices. /dev/hda2 needs to be writeable by users in order to let you write to the partition.
Code:
chown root.users /dev/hda2
or
Code:
chmod o+w /dev/hda2
(Doing this with tmpfs is a bit harder).

The second thing to check is if you need a “mode” or “umask” option in fstab. “user” just allows regular users to mount and unmount the partition, and “rw” just allows something to write to the device if it has enough permissions to do so (mainly this just enables the write-caching). Read through
Code:
man fstab
This might also be a permissions issue with the /mnt/ directories. A directory needs to be both readable and executable before you can “cd” to it or list its contents, and must be writable before you can create files. You can see the permissions of a directory using:
Code:
ls -ld /mnt/c
Hope that's of some help,

— Robert J. Lee
 
Old 08-31-2004, 11:35 AM   #4
m_yates
Senior Member
 
Registered: Aug 2003
Location: Upstate
Distribution: Debian, Mint, Mythbuntu
Posts: 1,249

Rep: Reputation: 101Reputation: 101
Once you have fstab set up, you should be able to access the drives in /mnt/c or /mnt/d as a regular user, because fstab sets the permissions. If you put "noauto" in fstab, you should also be able to mount them as a regular user by running "mount /mnt/c" NOT "mount /dev/hda1 /mnt/c". To run "mount /dev/hda1 /mnt/c" you would need to be root.
 
Old 08-31-2004, 11:56 AM   #5
mokojin
Member
 
Registered: Feb 2004
Location: Portugal
Distribution: OpenSUSE 10.2
Posts: 78

Original Poster
Rep: Reputation: 15
that's my problem, setting up /etc/fstab i can't figure it out
 
Old 08-31-2004, 11:57 AM   #6
kingterr0r
Member
 
Registered: Aug 2004
Location: New York
Distribution: SuSE 9.1 Pro
Posts: 32

Rep: Reputation: 15
quick and easy way to get access to that folder containing the partition, chmod -R 777 /mnt/c
 
Old 08-31-2004, 12:06 PM   #7
mokojin
Member
 
Registered: Feb 2004
Location: Portugal
Distribution: OpenSUSE 10.2
Posts: 78

Original Poster
Rep: Reputation: 15
doesn't work
 
Old 08-31-2004, 12:08 PM   #8
m_yates
Senior Member
 
Registered: Aug 2003
Location: Upstate
Distribution: Debian, Mint, Mythbuntu
Posts: 1,249

Rep: Reputation: 101Reputation: 101
Quote:
Originally posted by mokojin
that's my problem, setting up /etc/fstab i can't figure it out
Did you try the fstab entries I posted above? They work for me.
 
Old 08-31-2004, 12:34 PM   #9
mokojin
Member
 
Registered: Feb 2004
Location: Portugal
Distribution: OpenSUSE 10.2
Posts: 78

Original Poster
Rep: Reputation: 15
Quote:
Originally posted by m_yates
Did you try the fstab entries I posted above? They work for me.
sorry i haven´t seen your first post, now it works

but the umask=000 and umask=0222 what it means?
 
  


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
fstab problem: mount: can't find dvd in /etc/fstab or /etc/mtab Nikon01 Slackware 5 11-17-2006 06:15 AM
Fstab problem JackieBrown Debian 3 11-14-2005 05:20 PM
\etc\fstab problem franklampard Linux - Newbie 5 10-03-2005 04:40 PM
fstab problem marlor Slackware 4 06-30-2004 07:44 PM
/etc/fstab problem juggler Linux - Newbie 7 10-23-2002 01:56 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Slackware

All times are GMT -5. The time now is 03:00 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