天天看點

[How-to]如何更加友善的在FreeBSD中使用ntfs-3g

牆外你更加受到歡迎,位址:http://lzsblog.appspot.com/?p=298001

很多人應該試過在FreeBSD裡裝ntfs-3g來代替原來的mount_ntfs指令(pkg_add -r ntfs-3g),原來的那個指令在NTFS根目錄會有很多亂七八糟的東西,而且最糾結的是居然不能寫。可是FreeBSD的桌面環境們貌似是不太待見ntfs-3g。如果你用ntfs-3g的檔案替換原來在/sbin中的指令檔案,會提示如下錯誤。(俺用的KDE4)

An error occurred while accessing '19.5 GiB Hard Drive', the system responded: org.freedesktop.Hal.Device.Volume.UnknownFailure: ntfs-3g: Unknown option '-u'.  ntfs-3g 2010.10.2 external FUSE 27 - Third Generation NTFS Driver         Configuration type 1, XATTRS are off, POSIX ACLS are off  Copyright (C) 2005-2007 Yura Pakhuchiy Copyright (C) 2006-2009 Szabolcs Szakacsits Copyright (C) 2007-2010 Jean-Pierre Andre Copyright (C) 2009 Erik Larsson  Usage:    ntfs-3g [-o option[,...]] <device|image_file> <mount_point>  Options:  ro (read-only mount), remove_hiberfile, uid=, gid=,           umask=, fmask=, dmask=, streams_interface=.           Please see the details in the manual (type: man ntfs-3g).  Example: ntfs-3g /dev/sda1 /mnt/windows  Ntfs-3g news, support and information:  http://ntfs-3g.org

看來FreeBSD的加載指令比較奇葩呃。。。

我就找啊找啊,終于在某個藏的很深的檔案裡找到了辦法。

1、把/usr/local/share/hal/mount-fuse檔案拷貝到/sbin裡

cd /sbin
cp /usr/local/share/hal/mount-fuse ./mount-fuse
           

2、修改其中的内容,把FUSE_HELPER改成ntfs-3g

3、把/sbin中的mount_ntfs備份一下

mv mount_ntfs mount_ntfs.backup
           

4、替換。

mv mount-fuse mount_ntfs
           

好啦。

繼續閱讀