Linux mount NTFS-formatted hard drives below

Source: Internet
Author: User
English, OH.
1. Install NTFS Support

For Yum users:

[Mirandam@charon ~]$ sudo yum install fuse fuse-libs ntfs-3g ntfsprogs NTFSPROGS-GNOMEVFS

Users without yum, download fuse, Fuse-lib and ntfs-3g (Ntfsprogs and Ntfsprogs-gnomevfs are) from Fedora optional. Save them to a separate directory (NTFS). They are less than 1MB download.

[Mirandam@charon downloads]$ CD NTFS
[Mirandam@charon ntfs]$ sudo rpm-ivh fuse* ntfs*

No kernel version checking is required, so long as you are using a FC6 kernel.

2. Check Your Partitions

Use the Fdisk to list partitions. Most ATA hard drives would be/dev/hda. Drives may also the AS/DEV/HDB,/DEV/SDA depending on your configuration.

[Mirandam@charon ~]$ Sudo/sbin/fdisk-lu/dev/hda | grep NTFS
/DEV/HDA1 * 33559784 16779861 7 Hpfs/ntfs
/dev/hda2 33559785 67119569 16779892+ 7 hpfs/ntfs
/dev/hda3 67119570 100679354 16779892+ 7 hpfs/ntfs

Usually the "I" is a drive "letter": C Drive, Next D, etc. HENCE/DEV/HDA1 is I c:/drive used by Windows.

3. Create Mount Points

For every partition in step 2 that's you wish to access, and you'll need a "mount point". Mount A is just a directory. Common directories are:/media/and/mnt/. Use whichever and but be consistent.

[Mirandam@charon ~]$ cd/media/
[Mirandam@charon media]$ sudo mkdir c_drive d_drive e_drive

You don't have to use this names, if you are prefer to create folders such as movies, documents, or WinXP, any name would wor K (without spaces).

4. Mount partitions

Using ntfs-3g, we can mount the NTFS partition Read-write, however it is recommended for novices as Read-only. The following mounts and sets the permissions so all users can read the contents to each partition.

[Mirandam@charon ~]$ sudo mount/dev/hda1/media/c_drive-t ntfs-3g-r-o umask=0222
[Mirandam@charon ~]$ sudo mount/dev/hda2/media/d_drive-t ntfs-3g-r-o umask=0222
[Mirandam@charon ~]$ sudo mount/dev/hda3/media/e_drive-t ntfs-3g-r-o umask=0222

Read/write access:the above is for read-only Access. In the order to mount Read/write, your must use The-rw-o umask=0000. Example:

[Mirandam@charon ~]$ sudo mount/dev/hda1/media/c_drive-t ntfs-3g-rw-o umask=0000

Highly recommended:please run mans mount to understand what umask= does.

5. Update/etc/fstab

Every Time Fedora boots, the partitions must to be mounted. To the automatically mount, you must edit/etc/fstab.

Open/etc/fstab in the editor: (use nano instead of the gedit if you don't have a GUI)

[Mirandam@charon ~]$ sudo gedit/etc/fstab

Add these lines to the "end of" the file:

/dev/hda1/media/c_drive ntfs-3g ro,defaults,umask=0222 0 0
/dev/hda2/media/d_drive ntfs-3g ro,defaults,umask=0222 0 0
/dev/hda3/media/e_drive ntfs-3g ro,defaults,umask=0222 0 0

Read/write access:the above is for read-only Access. In order for Mount Read/write, you must use the rw,defaults,umask=0000. Example:

/dev/hda1/media/c_drive ntfs-3g rw,defaults,umask=0000 0 0

done!

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.