True NTFS Read/Write
How to install and enable the NTFS-3g driver. The NTFS-3G driver is an open source, freely available NTFS driver for Linux with read and write support. It provides safe and fast handling of the Windows XP, Windows Server 2003 and Windows 2000 file systems. Most POSIX file system operations are supported, with the exception of full file ownership and access right support.
Applicable to Fedora Versions
- Fedora Core 9+
Requirements
- None
Doing the Work
Basic description of what will be done and what is expected.
- NTFS-3g should be installed by default, however if it is not perform the following:
- Once the ntfs-3g is installed you need to set up the mount point.
- Now you need to locate your windows partition, do this with the following command.
- That command should return something similar to the following.
- Now an entry is needed in the files system table, to do so enter the following.
- Now in text editor make and entry similar to the follwing as the last line of the file.
- Now you need to mount your new partitions.
- At the prompt enter your root password and press enter.
- Close the terminal.
- Your Windows partition should now be available in Nautilus under "/mnt/windows".
su -c 'yum install ntfs-3g'
su -c 'mkdir /mnt/windows'
su -c '/sbin/fdisk -l'
Disk /dev/sda: 200.0 GB, 200048565760 bytes
255 heads, 63 sectors/track, 24321 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Device Boot Start End Blocks Id System
/dev/sda1 * 1 11572 92952058+ 7 HPFS/NTFS
/dev/sda2 11573 23321 94373842+ 83 Linux
/dev/sda3 23322 24321 8032500 82 Linux swap / Solaris
Disk /dev/sdb: 200.0 GB, 200048565760 bytes
255 heads, 63 sectors/track, 24321 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Device Boot Start End Blocks Id System
/dev/sdb1 * 1 24321 195358401 b W95 FAT32
su -c 'nano /etc/fstab'
/dev/sda1 /mnt/windows ntfs-3g defaults,fmask=0000,dmask=0000,uid=500 0 0If your partition identifier is not "/dev/sda1" substitute the correct device. (For example it might be "/dev/sda1" if you have a SATA /SCSI drive.) Once the new line is added press ctrl+o, at the File Name to Write: /etc/fstab prompt; press enter, this will save the file. Then press ctrl+x to exit the editor.
su -c 'mount -a'
Troubleshooting
How to test
- Use Nautilus and browse your newly mounted Windows directory.
- If the filesystem has been mounted already, fstab will need to be re-read and the drive re-mounted. The principle is that the fstab is only read when the drive is being mounted thus any changes to the fstab on an already mounted drive will result in the changes happening on the next mount and/or on reboot. To unmount an already incorrectly mounted drive at /mnt/windows do the following: (please unmount the correct location)
- If you have SELinux turned on you will have to redo the mount commands a simple alternative is to disable SELinux
- Change your file to look similar to this one
- Another way to bypass this is to manually mount it on boot and maintain SELinux
- Your file should look like this
- Add this line at the end of the file
umount /mnt/windowsAssuming you have correctly set everything up, you may return to step 7 above.
su -c 'nano /etc/selinux/config'
# This file controls the state of SELinux on the system.The bold part is the essential section.
# SELINUX= can take one of these three values:
# enforcing - SELinux security policy is enforced.
# permissive - SELinux prints warnings instead of enforcing.
# disabled - SELinux is fully disabled.
SELINUX=permissive
# SELINUXTYPE= type of policy in use. Possible values are:
# targeted - Only targeted network daemons are protected.
# strict - Full SELinux protection.
SELINUXTYPE=targeted
# SETLOCALDEFS= Check local definition changes
SETLOCALDEFS=0
su -c 'nano /etc/rc.local'
#!/bin/sh
#
# This script will be executed *after* all the other init scripts.
# You can put your own initialization stuff in here if you don't
# want to do the full Sys V style init stuff.
touch /var/lock/subsys/local
su -c 'mount -t ntfs-3g /dev/sda1 /mnt/windows -O uid=500,rw,fmask=0000,dmask=0000'This should auto mount your windows partition while maintaining SELinux for security reasons.
Common problems and fixes
Describe common problems here, include links to known common problems if on another site
- You will have problems with SELinux. This is currently getting fixed. Red Hat Bugzilla
More Information
Disclaimer
We test this stuff on our own machines, really we do. But you may run into problems, if you do, come to #fedora on irc.freenode.net

