CentOS Linux Mounts Windows NTFS file system __linux

Source: Internet
Author: User
Tags dmesg

CentOS can not recognize the NTFS-formatted device, search for a long time to try a variety of ways to solve, in order to make the novice less detours, I will be my solution to write out to share.

One, the first option
The first thing to see most is to install kernel-2.6.18-194.el5.i686.rpm, but not successfully,
Use Uname-r-p to view the system kernel,
[Root@centos5 ~]# Uname-r-P
2.6.18-194.el5 i686
You can also enter
[Root@centos5 ~]# rpm-q--queryformat "%{arch}\n" kernel

Next, install NTFS support
Download the appropriate RPM package for the kernel version and processor
kernel-2.6.18-194.el5.i686.rpm
This is a website that provides RPM packages with NTFS-enabled RPM packages for each Red Hat Enterprise version of the kernel.
Http://rpm.pbone.net
Download the corresponding kernel of the RPM package, first use "uname-r" to view the kernel version. Select the OS type, i386, or x64.
For example, my machine is i686, the kernel is 2.6.18-194.el5, go to search kernel-2.6.18-194.el5.i686.rpm.
Find a kernel-2.6.18-194.el5.i686.rpm.

Installation
2. Run RPM-IHV kernel-2.6.18-194.el5.i686.rpm, install this RPM package.
3. Run/sbin/modprobe NTFS load kernel module. (There is no output here)
4. Run DMESG | grep NTFS, you can view the NTFS-driven version. Show
[Root@localhost src]# DMESG | grep NTFS
NTFS driver 2.6.18[flags:r/w MODULE].
NTFS Volume version 3.1.
5. You can run Cat/proc/filesystems see that you have supported the NTFS file system.
Appear
Nodev SELINUXFS
Ext3
Nodev Rpc_pipefs
Nodev AutoFS
Vfat
Ntfs

Indicates that NTFS has been supported.
This method I tried for one night still failed to load the NTFS device. Do not know if there is no success, some words please tell me your installation method, thank you first.
The next day asked a master, said to compile the line, is not rpm, so on the Internet to find other solutions.
Ii. excerpts from the second programme are as follows:

Solution:
1. Confirm Fuse,centos 5.5 with fuse, you can use Rpm-qa | grep fuse to see if it is installed.
[Root@localhost ntfs-3g-2010.5.22]# Rpm-qa | grep fuse
Fuse-2.7.4-8.el5
Description has been installed fuse

2, install NTFS-3G, the system default software library is not updated to ntfs-3g, you can download and compile your own installation.
Baidu under Google download ntfs-3g-2010.5.22.tgz (http://www.4shared.com/file/oU-aBNkW/ntfs-3g-2010522.html), after downloading installation, installation method download point.
Brief introduction, download after decompression
[Root@localhost packages]# TAR-ZXVF ntfs-3g-2010.5.22.tgz
Enter the unpacked directory
[Root@localhost packages]# CD ntfs-3g-2010.5.22
[Root@localhost ntfs-3g-2010.5.22]#
Files in a folder
[Root@localhost ntfs-3g-2010.5.22]# ls
ACLOCAL.M4 config.h configure.ac INSTALL M4 README
AUTHORS config.h.in copying Install-sh Makefile src
autogen.sh config.log copying. LIB Libfuse-lite makefile.am stamp-h1
Changelog Config.status credits libntfs-3g makefile.in
Compile config.sub depcomp Libtool missing
Config.guess Configure include ltmain.sh NEWS
[Root@localhost ntfs-3g-2010.5.22]#
Then execute it sequentially.
[Root@localhost ntfs-3g-2010.5.22]#./configure
[Root@localhost ntfs-3g-2010.5.22] #make
[root@localhost ntfs-3g-2010.5.22] #make Install
When you're done, you can mount the NTFS file normally.
[Root@localhost ntfs-3g-2010.5.22]# mount-t ntfs-3g/dev/sda2/mnt
[Root@localhost ntfs-3g-2010.5.22]# Ls/mnt
CentOS RECYCLER vm2k3
IDE System Volume Information Vmdesk
Incoming Tddownload W2003sp2.iso
Kankan The Brothers Four Windows
Music Ubuntustudio-10.04-alternate-amd64.iso Reading
News VM

3, set up automatic mount file system
Edit the/etc/fstab file to add the partition you want to load,
If you do not know which partition, you can use the Fdisk-l
[Root@localhost ~]# Fdisk-l
disk/dev/sda:500.1 GB, 500107862016 bytes
255 heads, Sectors/track, 60801 cylinders
Units = Cylinders of 16065 * 8225280 bytes
Device Boot Start End Blocks Id System
/DEV/SDA1 1 3825 30724281 7 hpfs/ntfs
/dev/sda2 3826 29322 204804652+ 7 hpfs/ntfs
/dev/sda3 * 29323 31871 20474842+ Linux
/DEV/SDA4 31872 60801 232380225 5 Extended
/dev/sda5 31872 32125 2040223+ Linux Swap/solaris
/dev/sda6 32126 34674 20474811 Linux
[Root@localhost ~]#
As above, I would like to mount a D disk under Windows, that is/dev/sda2, if you want to mount C, that is/dev/sda1
Okay, start adding the following line to the/etc/fstab file:
/dev/sda2/wind ntfs-3g Defaults 0 0
/wind This file I built in the root directory specifically to Mount D disk, you can also be new in other places, such as:/mnt/wind
In this way, it will be changed to/dev/sda2/mnt/wind ntfs-3g defaults 0 0.
Good Official edition:
[Root@localhost ~]# Vi/etc/fstab
label=//ext3 Defaults 1 1
Label=/home/home ext3 Defaults 1 2
TMPFS/DEV/SHM TMPFS Defaults 0 0
Devpts/dev/pts devpts gid=5,mode=620 0 0
Sysfs/sys Sysfs Defaults 0 0
PROC/PROC proc Defaults 0 0
Label=swap-sda5 Swap Defaults 0 0
/dev/sda2/wind ntfs-3g Defaults 0 0
Wq Save exit. Turn on the boot to see if there is automatic Mount bar.

This article is from the "Eagle Dance Nine Days" blog, please be sure to keep this source http://zxy527.blog.51cto.com/132376/551604


Related Article

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.