zoukankan      html  css  js  c++  java
  • 自动以读写方式挂载ntfs-黑苹果之路

    在mac下ntfs分区总是以只读方式挂载,双操作系统,尤其有些时候需要用u盘,需要手工umount再mount,很麻烦,找了一些资料,通过修改/etc/fstab文件无效,要么就是使用第三方软件,不合要求,无意搜到以下链接:

    MAC OS X与NTFS

    其中通过修改系统的/sbin/mount_ntfs脚本能很好的满足我的需要(10.9下无效),摘录如下:

    打开终端:
    
    sudo  mv /sbin/mount_ntfs /sbin/mount_ntfs.orig
    
    touch mount_ntfs
    
    之后在你的用户主目录下会生成一个mount_ntfs的空文件,用文本编辑器打开,输入以下内容后保存
    
    #!/bin/sh
    
    /sbin/mount_ntfs.orig -o rw “$@”
    
    下面继续回到你之前打开的终端执行:
    
    sudo mv mount_ntfs /sbin/mount_ntfs
    
    sudo chown root:wheel /sbin/mount_ntfs
    
    sudo chmod 755 /sbin/mount_ntfs
    
    至此,完成工作,你的系统将默认以读写的方式加载NTFS分区。今后如果需要恢复,则在终端执行:
    
    sudo mv /sbin/mount_ntfs.orig /sbin/mount_ntfs
    

     2015年5月7日编辑:

    重新上路使用yosemite,相同的问题,再研究,参考http://www.tianwaihome.com/2014/07/mac-osx-ntfs.html

    使用的是编辑/etc/fstab文件的方式(原生方式),加入一行:

    LABEL=Data none ntfs rw,auto,nobrowse

    其中Data为/Volumn目录下的卷名,nobrowse必须要,其意思是在Finder中不显示。因此需要自己在桌面建立一个指向Data的链接。

  • 相关阅读:
    fork安全的gettid高效实现
    TCP_DEFER_ACCEPT的坑
    TCP Linger的坑
    Blade和其他构建工具有什么不同
    在Blade中结合gperftools检查内存泄露
    GraphViz web版
    用户场景分析
    java-二维数组——with 刘童格
    java-四则运算-五-网页版--with刘童格
    java-四则运算-四
  • 原文地址:https://www.cnblogs.com/badwood316/p/3521364.html
Copyright © 2011-2022 走看看