Automount NTFS Drives with Read-Write Permissions in GNULinux

As a developer, I love to use GNULinux because it is the one which taught me “what exactly an operating system is?” But when it comes to my profession I can’t ignore Windows. So in my PC I have the dual boot system to log in either Windows or Ubuntu. Since Ubuntu partitions cannot be seen in Windows, I decided to use a Windows drive to store all of my stuffs. So that I can access them by mounting Windows drives in Ubuntu and use them in both synonymously.

And my major requirement is, Windows partitions should mount on startup. I do not have to mount them each time I start the system and it gives me a quick access to all files from the beginning. But by default Ubuntu mount Windows drives with read only permission. We can not copy files in it or create new folder in there. For this we need to provide write permissions to those drives.

If you don’t write, you’ll get fired

First of all, let me tell you why it happens. By default Ubuntu has included “ntfsprogs“ which helps to mount Windows drives, but with read only permission. For more support this should replaced be with ntfs-3g“ .

So lets replace them:

Using terminal (the easiest and safest way)

  • Open terminal (Ctrl+Alt+t),
  • type sudo apt-get install ntfs-3g and hit enter if you are on *.deb based distro;
    su -c ‘yum -y install ntfs-3g’ on *.rpm based distro,
  • Proceed with necessary steps and its done.

Or Using an Appropriate Package Manager (another recommended way)

  • Open Synaptic Package Manager (if it is not installed, do it first using sudo apt-get install synaptic) on *.deb based distro;
    on *.rpm based distro use appropriate package manager, like ‘Add/Remove Software’ in Fedora.
  • search for ‘ntfs-3g’ in ‘Quick Filter’. Here don’t get confused with ‘ntfs-3g-dev’ and ‘ntfs-3g-dbg’ which are meant for developers.
  • Select ‘ntfs-3g’ and mark it for installation.
  • Click ‘Apply’ and proceed with further steps and install it.

Mount at startup = Automount

There are lots of applications and software which provide many options to handle drives and partitions including NTFS. For a simple automount no need to install such software. If you are confident to take a small risk it is very easy to setup.

  • Open Terminal,
  • Type sudo nautilus, a new window of nautilus file browser would open with root (administrator) permission,
  • Open File System and then open ‘media‘ or ‘mnt‘ folder,
  • Create new folder with name of your windows drive,
  • Get to back and now open ‘etc‘ folder and search for ‘fstab‘ (just type it),
  • You will see a file, ‘fstab‘, selected. open it.
  • Come to the last line and type as follows:
    <partition name> <mount point> <partition type> defaults 0 0

    To get the partition name and type of all drives available in your system, execute sudo blkid command in terminal or use applications like GParted or Disk Utility.Check out how I have done it:

fstab screenshot

  • Here /dev/sda3 is the partition (drive) name, /media/ikrz/MyDrive is the mount point where partition should be mounted, ntfs is the partition type and the rest is for default settings.
  • Now save this file and close it.

Wait… wait.. do not reboot now. We have not finished yet.

Before rebooting the system let see whether it is working or not. Because if there was any mistake, it may fail to boot.

Just execute sudo mount -a command in terminal. If you do not get any error message, check out whether that drive has mounted or not with read and write permission. If not please go through the all processes again. You may find where we have made the mistake.

Now you can just reboot your system and all drives that you did setup for automount would be waiting for you on system doors.

Happy Computing . . . :)

We always like to hear from you. Please do not forget to comment below with your feedback and opinions. They are important to us.

You can follow us on Twitter, add on your Google+ circle or Like our Facebook page to get the latest news, updates and reviews.

advertisement