LinuxQuestions.org
Latest LQ Deal: Linux Power User Bundle
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 08-13-2006, 10:27 PM   #1
alex1986
Member
 
Registered: Nov 2005
Location: Ottawa, Canada
Distribution: none yet
Posts: 96

Rep: Reputation: 19
mounting windows in the fstab permissions problem


mount /dev/sda2 /mnt/hd120

this command works just fine but I can only view that partition as root. AND i want it to auto mount in the fstab durring system boot AND be viewable by ALL users.

it's an NTFS but i don't know what the code line should be in the fstab.
 
Old 08-14-2006, 12:17 AM   #2
bigrigdriver
LQ Addict
 
Registered: Jul 2002
Location: East Centra Illinois, USA
Distribution: Debian stable
Posts: 5,889

Rep: Reputation: 351Reputation: 351Reputation: 351Reputation: 351
I'm not exactly certain, but something like this, perhaps:

/dev/hda1 /mnt/windows ntfs ro,users 1 2

Change /dev/hda1 to the correct partition for your system.
 
Old 08-14-2006, 01:03 AM   #3
kstan
Member
 
Registered: Sep 2004
Location: Malaysia, Johor
Distribution: Dual boot MacOS X/Ubuntu 9.10
Posts: 851

Rep: Reputation: 31
do little it change if you use fat and want user can write thing to the partition, use this:
/dev/hda1 /mnt/windows vfat rw,users 1 2
 
Old 08-14-2006, 05:34 AM   #4
oskar
Senior Member
 
Registered: Feb 2006
Location: Austria
Distribution: Ubuntu 12.10
Posts: 1,142

Rep: Reputation: 49
Quote:
Originally Posted by bigrigdriver
I'm not exactly certain, but something like this, perhaps:

/dev/hda1 /mnt/windows ntfs ro,users 1 2

Or probably better: 0 0
I don't have a windows drive attached - it might cause trouble letting linux repair stuff. - see the fstab manpage for details (nothing can go broke if you mess up those options)

Change /dev/hda1 to the correct partition for your system.
Wouldn't that be "rw,users"

I use the umask option.

You can eighter make it Umask0222
Which would mean read,write,execute for you and read,write for anybody else. Which is probably not such a bad idea, or if you don't need to execute binaries from the ntfs disk, do umask=2222.
Take a look at:
http://www.opengroup.org/onlinepubs/...xcu/umask.html for more information

So this is at least a working option:
/dev/"your device" /mnt/hdf1 ntfs defaults,umask=0222 0 2

I have most my devices defined by their uuid, because I have exchange drives, and usb drives and an mp3 player, that might be mounted at the wrong place.

If this is the case, you can mount them using the uuid, which is not complicated at all.

with:
$blkid

you see the uuid of all connected devices, and you just exchange "/dev/whatever" with uuid=whatever


---
after saving fstab, you can try the new setup doing:
$sudo mount -a

Last edited by oskar; 08-14-2006 at 05:42 AM.
 
Old 08-14-2006, 12:50 PM   #5
alex1986
Member
 
Registered: Nov 2005
Location: Ottawa, Canada
Distribution: none yet
Posts: 96

Original Poster
Rep: Reputation: 19
I have tried many many combinations of the options you are all giving me but it still will not automaitically mount. here is my fstab as is now:

/dev/hda2 swap swap defaults 0 0
/dev/hda1 / ext2 defaults 1 1
/dev/sda2 /mnt/hd120 ntfs rw,users 0 0
/dev/cdrom /mnt/cdrom auto noauto,owner,ro 0 0
/dev/fd0 /mnt/floppy auto noauto,owner 0 0
devpts /dev/pts devpts gid=5,mode=620 0 0
proc /proc proc defaults 0 0


i just can not get that ntfs partition to mount.
BLAST!!!
 
Old 08-14-2006, 03:29 PM   #6
TigerOC
Senior Member
 
Registered: Jan 2003
Location: Devon, UK
Distribution: Debian Etc/kernel 2.6.18-4K7
Posts: 2,380

Rep: Reputation: 49
Have you created the mount point (ie a directory) called hd120 under /mnt?
 
Old 08-14-2006, 08:59 PM   #7
lord-fu
Member
 
Registered: Apr 2005
Location: Ohio
Distribution: Slackware && freeBSD
Posts: 676

Rep: Reputation: 30
And make sure to add auto to that line.
 
Old 08-14-2006, 11:44 PM   #8
robingazi
Member
 
Registered: Jul 2006
Location: Bangladesh
Distribution: Ubuntu
Posts: 93

Rep: Reputation: 15
This is my fstab, this works fine for me. BTW most of the drives are vfat apart from 2 ext3 where debian and kubuntu is installed. You might want to change the 'vfat' to 'ntfs' if you are using ntfs. Hope this was helpful.

Quote:
# /etc/fstab: static file system information.
#
# <file system> <mount point> <type> <options> <dump> <pass>
proc /proc proc defaults 0 0
/dev/sda7 / ext3 defaults,errors=remount-ro 0 1
/dev/sda8 none swap sw 0 0
/dev/hdb /media/cdrom0 udf,iso9660 user,noauto 0 0
/dev/sda6 /media/kubuntu ext3 auto,user,rw,umask=0000 0 0
/dev/sda8 /media/win1 vfat auto,user,rw,umask=0000 0 0
/dev/sda9 /media/win2 vfat auto,user,rw,umask=0000 0 0
/dev/sda10 /media/win3 vfat auto,user,rw,umask=0000 0 0
/dev/sda11 /media/win4 vfat auto,user,rw,umask=0000 0 0
/dev/sda1 /media/win5 vfat auto,user,rw,umask=0000 0 0
/dev/sda5 /media/win6 vfat auto,user,rw,umask=0000 0 0
 
Old 08-15-2006, 01:09 AM   #9
kstan
Member
 
Registered: Sep 2004
Location: Malaysia, Johor
Distribution: Dual boot MacOS X/Ubuntu 9.10
Posts: 851

Rep: Reputation: 31
for your information linux not support ntfs well, use in your own risk. unless you use it as read only
 
Old 08-15-2006, 01:22 PM   #10
robingazi
Member
 
Registered: Jul 2006
Location: Bangladesh
Distribution: Ubuntu
Posts: 93

Rep: Reputation: 15
True, I'd recommend NTFS only in 'ro' mode. I changed all my drives apart two to vfat for write access.
 
  


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
mounting, hal, fstab-sync and permissions sonicbuddha Fedora 2 01-14-2006 04:40 AM
mounting, hal, fstab-sync and permissions sonicbuddha Linux - General 1 12-20-2005 12:38 PM
Permissions: Fstab and some other mounting questions azzurro Slackware 13 08-07-2004 09:30 PM
File/Folder Permissions / Mounting hdd's / fstab <-- ?Questions? EThitop Linux - Newbie 2 06-19-2004 08:19 PM
mounting windows using fstab breun006 Linux - General 7 10-02-2002 07:28 AM


All times are GMT -5. The time now is 02:58 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
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration