1,了解系统信息:
[root@tonykorn97 etc]# uname -a
Linux tonykorn97 2.6.9-11.EL #1 Fri May 20 18:17:57 EDT 2005 i686 i686 i386 GNU/Linux
[root@tonykorn97 etc]# fdisk -l
Disk /dev/hda: 81.9 GB, 81964302336 bytes
255 heads, 63 sectors/track, 9964 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Device Boot Start End Blocks Id System
/dev/hda1 * 1 637 5116671 7 HPFS/NTFS
/dev/hda2 638 7159 52387965 f W95 Ext'd (LBA)
/dev/hda3 7160 9834 21486937+ 83 Linux
/dev/hda4 9835 9964 1044225 82 Linux swap
/dev/hda5 638 1912 10241406 7 HPFS/NTFS
/dev/hda6 1913 4462 20482843+ b W95 FAT32
/dev/hda7 4463 7159 21663621 b W95 FAT32
[root@tonykorn97 etc]# df -lh
Filesystem 容量 已用 可用 已用% 挂载点
/dev/hda3 21G 3.2G 17G 17% /
none 122M 0 122M 0% /dev/shm
/dev/hda6 20G 19G 623M 97% /mnt/e
/dev/hda7 21G 15G 6.3G 70% /mnt/f
[root@tonykorn97 etc]#
2,下载内核补丁,这个是公司的电脑,系统为redhat as 4.0.
下载地址是:http://www.linux-ntfs.org/content/view/135/71/
我下载的文件是:kernel-module-ntfs-2.6.9-11.EL-2.1.20-0.rr.6.0.i686.rpm
3,安装
[root@tonykorn97 Desktop]# rpm -iv kernel-module-ntfs-2.6.9-11.EL-2.1.20-0.rr.6.0.i686.rpm
Preparing packages for installation...
kernel-module-ntfs-2.6.9-11.EL-2.1.20-0.rr.6.0
[root@tonykorn97 Desktop]#
4,加载ntfs分区
[root@tonykorn97 mnt]# mount -t ntfs -o nls=utf8,umask=000 /dev/hda1 /mnt/c
[root@tonykorn97 mnt]# cd c
[root@tonykorn97 c]# ls
arcldr.exe Documents and Settings NTDETECT.COM System Volume Information
arcsetup.exe Downloads ntldr temp
AUTOEXEC.BAT dwnSetup pagefile.sys tmuninst.ini
bootfont.bin Inetpub PDOXUSRS.NET vga.log
boot.ini informix Program Files WINNT
chipset.log IO.SYS RECYCLER
cmd.txt MSDOS.SYS response.txt
CONFIG.SYS net.log sound.log
另,用上面的方法不能显示中文,修改为:
[root@tonykorn97 mnt]# mount -t ntfs -o iocharset=gb2312,umask=000 /dev/hda5 /mnt/d
[root@tonykorn97 mnt]# cd d
[root@tonykorn97 d]# ls
Acrobat3 ftp music router temp xntp-doc 工作资料 问题处理目录
Config.Msi landesk管理套件系统解决方案.doc Program Files sniffer TSM 个人文件 应用工具 领带打法(2).doc
DownLoads landesk补丁管理解决方案.doc RECYCLER System Volume Information WUTemp 名词解释.txt 服务器
5,修改/etc/fstab文件
# This file is edited by fstab-sync - see 'man fstab-sync' for details
#This file is edited by fstab-sync - see 'man fstab-sync' for details
LABEL=/1 / ext3 defaults 1 1
none /dev/pts devpts gid=5,mode=620 0 0
none /dev/shm tmpfs defaults 0 0
none /proc proc defaults 0 0
none /sys sysfs defaults 0 0
LABEL=SWAP-hda4 swap swap defaults 0 0
/dev/hda6 /mnt/e vfat rw,exec,umask=0,iocharset=gb2312 0 0
/dev/hda7 /mnt/f vfat rw,exec,umask=0,iocharset=gb2312 0 0
/dev/hda1 /mnt/c ntfs ro,exec,umask=0,iocharset=gb2312 0 0
/dev/hda5 /mnt/d ntfs ro,exec,umask=0,iocharset=gb2312 0 0
/dev/hdc /media/cdrom auto pamconsole,fscontext=system_u:object_r:removable_t,exec,noauto,managed 0 0
/dev/fd0 /media/floppy auto pamconsole,fscontext=system_u:object_r:removable_t,exec,noauto,managed 0 0