Mount your widows Partitions and make it read/writable in ubuntu

This tutorial will show you how to mount NTFS and FAT partitions in ubuntu

For mounting TFS we are going to use one small tool called NTFS-3G this is very powerfull and simple tool.

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 notable exception of file ownership and access right changes.

You need to edit the sources.list file using the following command

sudo gedit /etc/apt/sources.list

and add the following repositories which is suitable for you

If you are running Ubuntu Dapper enter the following lines save and exit the file

deb http://givre.cabspace.com/ubuntu/ dapper main main-all
deb http://ntfs-3g.sitesweetsite.info/ubuntu/ dapper main main-all
deb http://flomertens.keo.in/ubuntu/ dapper main main-all

If you are running Ubuntu Edgy enter the following lines save and exit the file

deb http://givre.cabspace.com/ubuntu/ edgy main
deb http://ntfs-3g.sitesweetsite.info/ubuntu/ edgy main
deb http://flomertens.keo.in/ubuntu/ edgy main

Now you need to import th GPG key for these repositories using the any one of the following command

wget http://flomertens.keo.in/ubuntu/givre_key.asc -O- | sudo apt-key add -

wget http://givre.cabspace.com/ubuntu/givre_key.asc -O- | sudo apt-key add -

Now you need to update the source list using the following command

sudo apt-get update

Install ntfs-3g in Ubuntu

If you want to install ntfs-3g run the following command from your terminal

sudo apt-get install ntfs-3g

Configuring ntfs-3g

Now you need to use the following command to determine all the available partitions

sudo fdisk -l

Now you need to configure your NTFS partitions in /etc/fstab file before doing any changes in /etc/fstab file we will take a backup of this file using the following command (Highly Recommended)

sudo cp /etc/fstab /etc/fstab.bak

Now you need to create a directory where do you mount your windows partitions in this example i ma creating windows directory

sudo mkdir /media/windows

If you want to mount /dev/hda1 is your windows partition you need to enter the following line in /etc/fstab file

/dev/ /media/ ntfs-3g defaults,locale=en_US.utf8 0 0

You need to replace your partition and mount point with your details

Example

/dev/hda3 /media/windows ntfs-3g defaults,locale=en_US.utf8 0 0

save and exit the file

If you want to mount as read only you need to enter the following line in /etc/fstabfile

/dev/hda3 /media/windows ntfs-3g ro,locale=en_US.utf8,uid=1000 0 0

If You want to change your locale option you need to run the following command in a terminal to know which one is supported by your system.

locale -a

Now if you want these new chnages to take effect there are two options one is you can simply reboot your machine and the second one is without rebooting you need to run the following commands

To unmount

sudo umount -a

To Mount

sudo mount -a

If you want to know more available options for ntfs-3g check man page

If you want to mount and unmount Windows partitions (FAT) manually, and allow all users to read and write

Follow the same procedure to get the list of your windows partitions,create a directory where do you want to mount and you do the following command from your teminal replace /dev/hda3,/media/windows/ to your environment

sudo mount /dev/hda3 /media/windows/ -t vfat -o iocharset=utf8,umask=000

If you want to mount FAT partitions on boot-up to allow users to read and write use the following command in your /etc/fstab file you can see the above procedure how to take backup of fstab file before you do any changes

/dev/hda3 /media/windows vfat iocharset=utf8,umask=000 0 0

 
评论 1
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值