NTFS-3G
From Gentoo Linux Wiki
From Wikipedia: NTFS-3G is an open source cross-platform implementation of the Microsoft Windows NTFS file system with read-write support. NTFS-3G uses the FUSE file system interface, so it can run unmodified on many different operating systems. It has been reported to work with Linux, Mac OS X, FreeBSD, NetBSD, Solaris, BeOS and Haiku. It is licensed under the GNU General Public License. It is a fork of ntfsmount and is under active development.
Contents |
[edit] Installation
NTFS-3g supports the following USE flags:
- hal: Enable Hardware Abstraction Layer (HAL) support
- debug: Enable extra debug codepaths, like asserts and extra output. If you want to get meaningful backtraces see http://www.gentoo.org/proj/en/qa/backtraces.xml
- suid: Enable setuid root for the program, with potential security risks. This flag allows simple users to mount an ntfs partition using ntfs-3g.
Check the default state of the flags:
Enable flags that you need and emerge this package.
[edit] Configuration
[edit] Kernel Configuration
| Linux Kernel Configuration: NTFS-3g kernel configuration |
File systems --->
<M> Filesystem in Userspace support
|
| Linux Kernel Configuration: NTFS-3g kernel configuration - kernel 2.6.29 |
File systems --->
<M> FUSE (Filesystem in Userspace) support
|
Build and install this module:
Load the module (this also updates /etc/modules.conf):
[edit] Usage examples
Replace /dev/hda1 with your NTFS volume and /mnt/windows with your mountpoint.
[edit] Mount a volume manually
Full access to all users, permission free (if suid USE-flag is set):
[edit] Mount at boot
To mount windows partition we need to edit /etc/fstab.
# Simple mount # /dev/hda1 /mnt/windows ntfs-3g 0 0 # Add Locale: # /dev/hda1 /mnt/windows ntfs-3g locale=en_US.utf8 0 0 # Access for non Root-Users(make ntfs partitions mountable for a normal user, unmountable for everyone else): # Set the suid flag for the ntfs-3g binary and then re-emerge it: # /dev/hda1 /mnt/windows ntfs-3g users 0 0 # To make a user/group own everything on the ntfs drive: # A User's ID and GID can be found with command: id your_username # /dev/hda1 /mnt/windows ntfs-3g users,uid=THE_ID_OF_THE_OWNER,gid=THE_ID_OF_THE_GROUP 0 0 # If you don't want the drive to be automounted at boot: # /dev/hda1 /mnt/windows ntfs-3g noauto 0 0 # One single line doing all above options /dev/hda1 /mnt/windows ntfs-3g users,locale=en_US.utf8,uid=THE_ID_OF_THE_OWNER,gid=THE_ID_OF_THE_GROUP,noauto 0 0 # Also, if you've given the partition a label (by giving it a "volume name" from Windows or a "label" using ntfslabel # from sys-fs/ntfsprogs), you can mount the partition by it's label in /etc/fstab: # LABEL=Windows-XP /mnt/windows ntfs-3g users,locale=en_US.utf8,uid=THE_ID_OF_THE_OWNER,gid=THE_ID_OF_THE_GROUP,noauto 0 0
For more mount options please read the manual:
If you added option users then now you can mount the drive as a normal user:
When using the automount features, you can set the read/write mode by default by creating the following symlink:
To disable it, just remove the symlink.
