Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
Unable to mount ntfs as user
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Other Things Gentoo
View previous topic :: View next topic  
Author Message
wpkzz
Tux's lil' helper
Tux's lil' helper


Joined: 28 Feb 2013
Posts: 80

PostPosted: Mon Aug 31, 2015 2:35 am    Post subject: Unable to mount ntfs as user Reply with quote

Hello fellow gentooers

I have followed the Gentoo Wiki article on ntfs and also the Arch Wiki article on the same issue and I still cannot mount a ntfs unit as normal user.
I have the kernel settings
Code:

File Systems-->
     <*> FUSE support
     <  > Character device in userspace support
     DOS/FAT/NT Filesystems--->
                 <*> MSDOS fs support                                                         x x 
  x x       <*> VFAT (Windows-95) fs support                                             x x 
  x x       (437) Default codepage for FAT                                               x x 
  x x       (iso8859-1) Default iocharset for FAT                                        x x 
  x x       <*> NTFS file system support                                                 x x 
  x x       [*]   NTFS debugging support                                                 x x 
  x x       [*]   NTFS write support


Then I emerged ntfs-3g with the following useflags (notice that i dissabled external-fuse as recomended in the wikis)

Code:

[I] sys-fs/ntfs3g               
     Available versions:  2013.1.13 2014.2.15 2014.2.15-r1 ~2015.3.14(0/86) {acl debug +external-fuse ntfsdecrypt +ntfsprogs static-libs suid xattr}
     Installed versions:  2014.2.15-r1(09:59:10 PM 08/30/2015)(acl ntfsprogs suid -debug -external-fuse -ntfsdecrypt -static-libs -xattr)

I double chequed that the ntfs-3g binary had the a+s attributed,
Code:

-rwsr-sr-x 1 root root 128K Aug 30 21:59 ntfs-3g


I also have this lines in my fstab:
Code:

/dev/sdb1               /media/USB1     auto            noauto,users,rw 0 0
/dev/sdc1               /media/USB2     auto            noauto,users,rw 0 0
/dev/sdb1               /media/USBntfs  ntfs-3g         noauto,users,rw 0 0

and my users are on the users group.

But then, I try to mount and this happens
Code:

karel@Coatlicue ~ $ mount /media/USBntfs/
Error opening '/dev/sdb1': Permission denied
Failed to mount '/dev/sdb1': Permission denied
Please check '/dev/sdb1' and the ntfs-3g binary permissions,
and the mounting user ID. More explanation is provided at
http://tuxera.com/community/ntfs-3g-faq/#unprivileged

I get the same message if I use the mountpoints with "auto" filesystems or if I use ntfs-3g directly as user.

I am absolutely lost here.
All other previous posts are really old and don't seem to apply here.
Back to top
View user's profile Send private message
ct85711
Veteran
Veteran


Joined: 27 Sep 2005
Posts: 1791

PostPosted: Mon Aug 31, 2015 3:01 am    Post subject: Reply with quote

It's been a while since I last had to deal with my fstab, but the part that stands out, is
Quote:
/dev/sdb1 /media/USB1 auto noauto,users,rw 0 0
/dev/sdc1 /media/USB2 auto noauto,users,rw 0 0
/dev/sdb1 /media/USBntfs ntfs-3g noauto,users,rw 0 0


According to the fstab man page:
Quote:
The fourth field (fs_mntops).
This field describes the mount options associated with the
filesystem.

It is formatted as a comma-separated list of options. It
contains at least the type of mount (ro or rw), plus any
additional options appropriate to the filesystem type
(including performance-tuning options). For details, see
mount(8) or swapon(8).

Basic filesystem-independent options are:
defaults
use default options: rw, suid, dev, exec, auto, nouser,
and async.
noauto do not mount when "mount -a" is given (e.g., at boot
time)
user allow a user to mount
owner allow device owner to mount
comment
or x-<name> for use by fstab-maintaining programs
nofail do not report errors for this device if it does not
exist.


It should be plain user not users (with the s). Give that a try, see if that helps...
Back to top
View user's profile Send private message
Roman_Gruber
Advocate
Advocate


Joined: 03 Oct 2006
Posts: 3846
Location: Austro Bavaria

PostPosted: Mon Aug 31, 2015 8:06 am    Post subject: Reply with quote

AFAIK

Do not use any kernel related ntfs driver because it is read only.

use fuse module with ntfs-3g to use ntfs completly under linux.

when you use mount you need to specify the file system type, which is in your case ntfs-3g and not ntfs!

check man mount
Back to top
View user's profile Send private message
krinn
Watchman
Watchman


Joined: 02 May 2003
Posts: 7470

PostPosted: Mon Aug 31, 2015 9:46 am    Post subject: Reply with quote

Code:
id
uid=X gid=Y...

Code:
/dev/sdb1               /media/USBntfs  ntfs-3g         noauto,user,rw,uid=X,gid=Y 0 0
Back to top
View user's profile Send private message
szatox
Advocate
Advocate


Joined: 27 Aug 2013
Posts: 3137

PostPosted: Tue Sep 01, 2015 9:37 pm    Post subject: Reply with quote

When you mention fuse, it's a good idea to mention fusermount as well. You don't need entries in /etc/fstab using it.
Back to top
View user's profile Send private message
Roman_Gruber
Advocate
Advocate


Joined: 03 Oct 2006
Posts: 3846
Location: Austro Bavaria

PostPosted: Wed Sep 02, 2015 12:19 pm    Post subject: Reply with quote

It all depends on your working style.

krin gave an example for dual boot users, who wants to mount windi 95 and read and write to that while using your linux.

and for manual mounting there are several ways. mount, pmount, fusermount and whateer anyone prefers. some even mount it through the file manager.

The worst are those autuomount features because they tend to mount it anywhere they want to.
in the lsat years that really annoyed me to check where it is mounted so i am back to the early days where you check dmesg / lsusb / whatever and than mount it by hand to a folder.

I do not get the point why those automounters never respected the FHS. in the time as i used gnome 2, and that was for quite a while, i had several different locations where it was mounted, and to look up everytime wehre it was mounted and such its kinda anooyed me a lot. Also the naming was kinda different and it was not obvious what was mounted where.

when you mount it manually you know where it is and how it was mounted and how to do it, it works always the same, but those autoscripts fail in lessen the workload and usability.
Back to top
View user's profile Send private message
wpkzz
Tux's lil' helper
Tux's lil' helper


Joined: 28 Feb 2013
Posts: 80

PostPosted: Wed Sep 02, 2015 3:30 pm    Post subject: Reply with quote

Thanks crew:

I shall then recompile the kernel without the ntfs module and use only the ntfs-3g auxiliary programs and see if it works.
I have never used fusermount, I really am used to the fstab, but it would nice to learn other options.
When I have tried your suggestioin (I have no acces to the computer in question until friday) I'll write you back.
Back to top
View user's profile Send private message
Roman_Gruber
Advocate
Advocate


Joined: 03 Oct 2006
Posts: 3846
Location: Austro Bavaria

PostPosted: Wed Sep 02, 2015 5:34 pm    Post subject: Reply with quote

you are better off with

mount --- type ntfs3g (i think its -o) /partition, taht should work on any box.
fusermount is probably just a wrapper for it, so you could also create an alias.

and i also think you can mount stuff just with ntfs-3g option /drive /mountpoint, well i have not used ntfs for ages.
Back to top
View user's profile Send private message
Polyatomic
n00b
n00b


Joined: 18 May 2014
Posts: 36

PostPosted: Wed Sep 16, 2015 9:59 am    Post subject: Reply with quote

I have a partition for music files on my rig now
Code:
/dev/sdc1 on /media/ntfs type fuseblk (rw,nosuid,nodev,relatime,user_id=0,group_id=0,allow_other,blksize=4096)


mounted from userspace with:
Code:
/sbin/mount.ntfs-3g -v -o,rw,noatime /dev/sdc1 /media/ntfs

Code:
Filesystem     1024-blocks     Used Available Capacity Mounted on
/dev/sdc1        131071996 74462752  56609244      57% /media/ntfs

as root though so probably not what you want right.

I have an fstab entry but its commented out now
Code:
#/dev/sdc1               /media/ntfs    ntfs-3g         noatime,permissions     0 0


Only for mpv pretty much
Code:
Playing: /media/ntfs/Music/F56/04 The Weigh Down.m4a
[ffmpeg/demuxer] mov,mp4,m4a,3gp,3g2,mj2: stream 0, timescale not set
     Video --vid=1 [P] (mjpeg)
 (+) Audio --aid=1 --alang=eng (*) (aac)
File tags:
 major_brand: M4A
 minor_version: 0
 compatible_brands: M4A mp42isom
 creation_time: 2023-08-25 18:56:15
 iTunSMPB:  00000000 00000840 000002B5 00000000008EA50B 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000
 iTunNORM:  000029A2 00002CDD 00007444 00008C9A 0002D887 0000F99D 00007FFF 00007FFF 0001A7C4 000258D1
 title: The Weigh Down
 artist: The Amity Affliction
 album_artist: The Amity Affliction
 composer: The Amity Affliction
 album: Let the Ocean Take Me
 genre: Metal
 track: 4/10
 disc: 1/1
 compilation: 0
 gapless_playback: 0
 date: 2014-06-06T07:00:00Z
 rating: 0
 media_type: 1
 purchase_date: 2014-06-09 14:39:35
 sort_name: Weigh Down
 sort_artist: Amity Affliction
 AO: [pulse] 44100Hz stereo 2ch float
A: 00:03:31 / 00:03:32 (99%) Cache:  0s+0KB
[------------------------------------------------------------------------------------------------------------------------------------------+-]

installed package versions:
(1) fuse-2.9.4
(2) ntfs-3g_ntfsprogs-2015.3.14

wpkzz smile man! your on Linux :D
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Other Things Gentoo All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum