ubuntu、debian下eject与safeley remove drive、umount的区别

原链: http://askubuntu.com/questions/86019/what-is-the-difference-between-eject-and-safely-remove-device

http://askubuntu.com/questions/56270/how-can-i-spin-down-external-hard-drive

You can safely unmount and spin-down an external hard disk from the terminal most easily by using the command-line functionality of udisks, which does not require the use of sudo if your system is set up correctly. (To list your device names, enter mount in the terminal first.)

When you have found your external drive, use the following commands. You must first unmount the partition (use sdb1 or whatever mount showed as the location):

udisks --unmount /dev/sdb1

Then to safely remove (i.e. spindown- you will hear it click and spin-down), use only sdb, for example:

udisks --detach /dev/sdb

NOTE: It is of crucial importance here that you use sdb or sdc without a partition number when using the detach option; i.e. sdb1 or sdc1 will not work. The partition must be unmounted first and then the disk itself spun down as the examples show.

The udisks commands work successfully for all my pata and sata external hard disks.

-----------------another answer---三者的区别--------------------------------------------------------------------

umount removes the device from the file system (mount point).

Eject and Safely remove both do basically the same thing on a flash drive.

sync the data , then un-mount (remove the drive from the file system).

In addition, eject would eject the media (think CD/DVD).

It is sort of a bug that both these options show with flash drives.

The expected behavior would be

Safely Remove - USB/Flash drive - sync data && unmount ; user then physically removes the drive

Eject - CDROM/DVD - unmount && eject physical media



总结:很多人都被这几个选项给困惑了,gnome的开发人员也给出了解释(参考链接1),算是一个bug,而且已经被提交了。

参考链接:https://bugzilla.gnome.org/show_bug.cgi?id=598690#c8====对bug的提交,回答较为官方且权威

http://thread.gmane.org/gmane.linux.usb.general/22706/focus=22748==好像是开发人员的回答,排版看不出来是什么论坛

http://git.gnome.org/browse/gvfs/commit/?id=6e70902ee77cb0bd6063bcf4d215b13a13bf5ee4===开发人员回答,且用源码解释

http://ubuntuforums.org/showthread.php?t=1301556====论坛的提问,很多人回答,可见很多人困惑。

https://bugs.launchpad.net/ubuntu/+source/nautilus/+bug/453072=====对bug的提交,回答较为官方且权威

https://bugzilla.gnome.org/show_bug.cgi?id=598690====对bug的提交,回答较为官方且权威

https://bugs.freedesktop.org/show_bug.cgi?id=24343====bug提交,底层级别回答


  • 0
    点赞
  • 1
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
USB Safely Remove是一个可以将USB设备安全删除的辅助工具,对于频繁添加或者移除USB设备的用户非常有用,能够有效帮助您解决无法删除USB设备的困扰。旧版的序列号已经失效,破解工具可以正常使用。 USB Safely Remove 6.x Multilingual 5.56 MB USB Safely Remove is a utility for effortless and speedy disconnection of any removable devices. Not only does it save time, but it ensures that all data remains on a device when it is unplugged. Safely Remove is a system utility designed for quick and safely stopping USB Flash Drives connected to your computer. With this utility you can safely stop and remove USB Flash Drives much faster then using "Safely remove hardware"" icon in the system tray. FEATURES: *Unlimited number of processes to launch You may specify to launch any number of processes for specified event. For example you may setup launching a backup of the drive before stopping and following disomounting of a TrueCrypt volume *Optional command line parameters You may pass such device parameters as drive letter, drive label, device PNP name into the process command line via parameter templates (e.g. this command line will browse a drive in Explorer on device connection: explorer.exe %DriveLetter%) *New events to launch programs Now programs can be launched after device plugging, before device stopping, after device stopping and after device removing *Global autorun You can setup a program to be launched not only for certain device, but for all hotplug devices in the system One click templates! Dislike reading boring documentation, but interested in one of the following things? * Browsing a drive with Explorer or Total Commander on device connection * Scanning a device for viruses on its connection * Making automatic backup of a flash-drive folder * Automatic mounting and dismounting a TrueCrypt volume stored on a device

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值