You are not logged in.

#1 2008-10-08 17:17:37

kcr
Member
Registered: 2007-02-09
Posts: 21

Can't mount NTFS external HD

Hello, i can't mount my ntfs external hd on kdemod 4.1.2 like a normal user... i installed nfts-3g like the wiki says and this is my fstab:

/dev/fd0 /media/fd0   auto    user,noauto   0      0
/dev/sda2 /boot ext2 defaults 0 1
/dev/sda3 / jfs defaults 0 1
/dev/sda5 swap swap defaults 0 0

#------ USB disk -------------
/dev/sdc1  /mnt/usbdisk  ntfs-3g  defaults,user,gid=users  0    0

but when i try to open the disk in Dolphin it says this:

Error opening '/dev/sdc1': Permission denied
Failed to mount '/dev/sdc1': Permission denied
Pease check '/dev/sdc1' and the ntfs binary permissions, 
and the mounting user ID. More explanation is provided at
http://ntfs-3g.org/support.html#unpriviledged

this is my groups list

tty wheel video audio optical floppy storage scanner power users usb

what can i do?
thanks..

Offline

#2 2008-10-08 17:24:37

X/ax
Member
From: Oost vlaanderen, Belgium
Registered: 2008-01-13
Posts: 275
Website

Re: Can't mount NTFS external HD

Try adding forced.

/dev/sdc1  /mnt/usbdisk  ntfs-3g  defaults,user,gid=users  0    0

Would become

/dev/sdc1  /mnt/usbdisk  ntfs-3g  defaults,forced,user,gid=users  0    0

Also, generally, I don't do the user, gid=users and defaults thing. It works just fine here.


My coding blog (or an attempt at it)
Archer start page (or an attempt at it)

Offline

#3 2008-10-08 17:33:15

kcr
Member
Registered: 2007-02-09
Posts: 21

Re: Can't mount NTFS external HD

nope, nothing changes...
is it possible that i need setuid-root like here http://ntfs-3g.org/support.html#unprivileged?

Offline

#4 2008-10-08 18:28:08

scrllock
Member
From: Michigan, USA
Registered: 2008-06-04
Posts: 19

Re: Can't mount NTFS external HD

For options, try just

defaults,users,rw

Also, if you're having trouble because the volume is dirty (Windows wasn't shutdown properly or something like that), you can mount with force (not forced), but that won't help if you don't have the proper permissions to mount in the first place. "users" should just let normal users mount/umount the volume, assuming your user has ownership of the directory the volume is mounting to (in this case, /mnt/usbdisk).

Hope that helps.

Offline

#5 2008-10-08 18:53:47

Mashi
Member
Registered: 2007-02-19
Posts: 38

Re: Can't mount NTFS external HD

Try changing the owner of /mnt/usbdisk to your user, if it isnt already owned by him.

Offline

#6 2008-10-08 19:11:05

kcr
Member
Registered: 2007-02-09
Posts: 21

Re: Can't mount NTFS external HD

Now my fstab is:

/dev/sdc1      /mnt/usbdisk  ntfs-3g    defaults,users,rw,force  0  0

i have typed from root:

chown kcr /mnt/usbdisk

but nothing...
i need to reboot the system?

i readed in the forum that someone talked about a problem with fuse...is it possible?

thanks..

Last edited by kcr (2008-10-08 19:15:07)

Offline

#7 2008-10-08 19:15:13

scrllock
Member
From: Michigan, USA
Registered: 2008-06-04
Posts: 19

Re: Can't mount NTFS external HD

After

chown kcr /mnt/usbdisk/

do

chmod u+rw -R /mnt/usbdisk/

and then reboot, just to be completely sure. Also, make sure your normal user is a member of all the standard groups (wheel,users,optical,storage,audio,etc.) in /etc/group.

Offline

#8 2008-10-08 19:24:48

kcr
Member
Registered: 2007-02-09
Posts: 21

Re: Can't mount NTFS external HD

still not working....i don't believe it...
maybe the problem is with mount+ntfs-3g or udev?
there are just suggestion...:(

Offline

#9 2008-10-09 04:57:26

kaola_linux
Member
From: Bacolod City/Philippines
Registered: 2008-09-23
Posts: 513

Re: Can't mount NTFS external HD

Hello kcr, been dealing with this problem long enough...I did manage to mount ntfs partitions though...It automounts through Hal...If you have installed Hal, then you won't have problems...

But before Hal automates you must clear the entries related to your partition on the /etc/fstab


Hope that helps coz it did for me....^ ^


Netbook (Acer Aspire One 110 || 160gb SATA HD || 1.5gb ram): archlinux i686 / KDEmod 4.3
Registered Linux User # 481212 / Machine Registration # 390468
"In a world without walls and fences, who needs windows and gates?"

Offline

#10 2008-10-09 07:33:58

max.bra
Member
From: Bologna - Italy
Registered: 2008-06-02
Posts: 82

Re: Can't mount NTFS external HD

kcr wrote:

nope, nothing changes...
is it possible that i need setuid-root like here http://ntfs-3g.org/support.html#unprivileged?

yes, it's your solution for the "unprivileged" problem.

the current usb automount udev bug is another film.

as that guide say:

Please note that using setuid-root can result unforeseen privilege escalation and its usage is discouraged. Only the absolutely trusted users must be granted such access. Below is an example how this can be done for users in the ntfsuser group to be able to mount any NTFS volume if they have also the needed volume access rights.

  chown root.ntfsuser $(which ntfs-3g)
  chmod 4750 $(which ntfs-3g)

The setuid-root ntfs-3g driver applies the principle of least privilege during its lifetime as a safety measure.

Last edited by max.bra (2008-10-09 07:36:48)

Offline

#11 2008-10-09 15:13:03

kcr
Member
Registered: 2007-02-09
Posts: 21

Re: Can't mount NTFS external HD

So i simply type this like root:

chown root.ntfsuser $(which ntfs-3g)
chmod 4750 $(which ntfs-3g)

or i need to give the path of nfts-3g's binary, because like this it's still not working...

thanks..

Offline

#12 2008-10-09 15:19:03

kcr
Member
Registered: 2007-02-09
Posts: 21

Re: Can't mount NTFS external HD

i resolve the problem typing this like root:

chmod +s /sbin/mount.ntfs-3g

and now i can mount my external drive with write permissions...
it's a good solution?
thanks..

Offline

#13 2008-10-10 10:16:21

max.bra
Member
From: Bologna - Italy
Registered: 2008-06-02
Posts: 82

Re: Can't mount NTFS external HD

for a little bit more security:

fallback your settings:

chmod -s /sbin/mount.ntfs-3g

create ntfsuser group

groupadd ntfsuser

add your user account to ntfsuser group

gpasswd -a <yourusername> ntfsuser

trim ntfs-3g main executable:
change owner of the binary

chown root.ntfsuser /bin/ntfs-3g

cut out all but root and ntfsuser members group, and set suid

chmod 4750 /bin/ntfs-3g

this two last steps must be redone every ntfs-3g update

checkout  (ls -la /bin/ntfs-3g)

-rwsr-x--- 1 root ntfsuser 36080 29 ago 11:49 /bin/ntfs-3g

in above line, last /bin/ntfs-3g sould be red backgrounded

cya

Last edited by max.bra (2008-10-10 12:06:11)

Offline

#14 2008-10-16 20:59:29

matchil
Member
From: Poland
Registered: 2006-11-06
Posts: 56

Re: Can't mount NTFS external HD

My (somehow related) problem: http://bbs.archlinux.org/viewtopic.php?pid=435366

Last edited by matchil (2008-10-16 21:42:15)

Offline

#15 2008-10-16 21:33:23

fukawi2
Forum Moderator
From: .vic.au
Registered: 2007-09-28
Posts: 5,304
Website

Re: Can't mount NTFS external HD

Please start a new topic for a new problem smile

Offline

#16 2008-12-21 11:17:21

kcr
Member
Registered: 2007-02-09
Posts: 21

Re: Can't mount NTFS external HD

Hello,
I'm very very sorry for "exhume" this post again...
First of all thanks max.bra for your help, now it doesn't bother with ntfs-3g and unprivileged but with this:

mount: only root can mount /dev/sdc1 on /mnt/usbdisk

So i followed the wiki here http://wiki.archlinux.org/index.php/HAL#NTFS and it worked..
BUT (always there is a but..) now every ntfs partition that i mount is in write mode.. it's ok for my external disk but NOT for my primary partition with xp (that i want in read-only mode)..

what can i do?

thanks again

p.s. i use kdemod

Offline

Board footer

Powered by FluxBB