Operating System - Linux
1827595 Members
2747 Online
109966 Solutions
New Discussion

Re: Mounting NTFS in linux

 
Luke_21
Occasional Advisor

Mounting NTFS in linux

I am able to mount a ntfs drive as user root, but I was wonder how to make the drive available for other users who log on to my computer
Just a Linux newbie
12 REPLIES 12
Stuart Browne
Honored Contributor

Re: Mounting NTFS in linux

When you mount it as root, what permissions do the parent directory and subsequent files get?

If you want it to load automatically, you should be able to add an entry to the /etc/fstab that looks something like:

/mount/point /dev/hdaX ntfs 0 0

Options will be any '-o' stuff you passed with the 'mount' command line. If there aren't any, use the word 'defaults'. This will mount the NTFS partition upon boot-up.

If you want the users to be able to able to mount/umount it as they desire, use options of 'user,noauto' instead.
One long-haired git at your service...
Jerome Henry
Honored Contributor

Re: Mounting NTFS in linux

In your /etc/fstab, you should have :

/dev/hda3 /mnt/ntfs ntfs owner, kudzu, rw 0 0

Meaning, the parititon to be mounted is /dev/hda3, I put it in /mnt/ntfs directory (for example), it's an ntfs type, the owner of the console and kudzu can mount it in rw (the rest is option).

hth

J
You can lean only on what resists you...
Luke_21
Occasional Advisor

Re: Mounting NTFS in linux

I am very new to Linux, but I will tell you what I have done so far. I mounted my ntfs drive at /usr/mnt/winxp.
And under permissions, it will only allow me to select read only, which is fine. but the problem is that It will not allow me to select any user groups any sort of access.
Thanks for the quick reply.
Just a Linux newbie
Luke_21
Occasional Advisor

Re: Mounting NTFS in linux

sorry about all that garbage. It kept giving me error 404 when I would submit. I guess it got posted afterall.
OOOPS
Just a Linux newbie
Jerome Henry
Honored Contributor

Re: Mounting NTFS in linux

Ooops too... This time is known to have this kind of posting problem...

Do you want anybody to access the xp directory, or just some users ? If everybody, the hundred posts here give you the clue.
If just some people, add them to a group, and replace 'owner' by the group name...

hope it'll post...

J
You can lean only on what resists you...
Luke_21
Occasional Advisor

Re: Mounting NTFS in linux

I am the only user of this computer for the most part. and I can access my ntfs stuff from root. but I want to be able to do the same logged in as "luke." but really if anyone who logs on to the machine is able to view the files of ntfs, that is fine as well
Luke
Just a Linux newbie
Jerome Henry
Honored Contributor

Re: Mounting NTFS in linux

Ok,
So the 'owner' option is ok for you !

J
You can lean only on what resists you...
Luke_21
Occasional Advisor

Re: Mounting NTFS in linux

So can you give me a quick step by step for what I have to do. I dont mean to be a pain, but could you start from the begining. I am very new at this. I hope its not a huge pain for you to explain.
Just a Linux newbie
Luke_21
Occasional Advisor

Re: Mounting NTFS in linux

if I add the line
/dev/hda1 /mnt/ntfs ntfs owner, kudzu, rw 0 0
to my fstab, will that make the drive mounted for all users on my computer?
Just a Linux newbie
Andrew Cowan
Honored Contributor

Re: Mounting NTFS in linux

The basic steps are:

mkdir /mount_point

Where the "mount_point" is the name of the directory E.g. "/mnt".

chmod 777 /mnt

This sets the permissions open to everyone, however it will be superceded by the permissions of the directory that is mounted over it. E.g. if the device was a cd then the files would always be read-only.

vi /etc/fstab

Add your mount line as you've stated above then save and exit the file use :x! I use this command as it overrides file protections on the file your editing.

mount /mnt

Your filesystem should now be available. Most Linux versions can only read NTFS and will not allow you to make changes to it, but this should now be available to all users.

If it's a one-off mount you can forego the editing of "fstab" and just specify the full mount command. Eg. mount /dev/sda3 /mnt
Linux can usually work out the type of filesystem, however if it can't you can add extra options to the mount command to force it.

Claudio Cilloni
Honored Contributor

Re: Mounting NTFS in linux

The are two options that you can use to assign a filesystem to a specific user.

uid=luke,gid=luke

these will declare the user 'luke', group 'luke' as the owner of the filesystem.
so your line in /etc/fstab is:

/mountpoint /dev/hdaX ntfs uid=luke,gid=luke 0 0

This trick works well with fat32 (vfat for linux) partitions.
(I don't know if 'ntfs' is right, I never used it).

hth
Claudio
Caesar_3
Esteemed Contributor

Re: Mounting NTFS in linux

Hello!

You need to know that the suport of the ntfs
driver is for read only so you can't write
to the ntfs drive.

Caesar