English | 简体中文 | 繁體中文 | Русский язык | Français | Español | Português | Deutsch | 日本語 | 한국어 | Italiano | بالعربية

Linux umount Command

Linux Command大全

Linux umount Command (full English name: unmount)

The umount command can unmount the filesystem currently mounted in the Linux directory.

Syntax

umount [-ahnrvV][-t <filesystem type>][filesystem]

Parameter:

  • -a Unmount/etc/All filesystems recorded in mtab.
  • -h Display help.
  • -n Do not store information in/etc/in mtab file.
  • -r If it fails to unmount successfully, try to remount the filesystem in read-only mode.
  • -t<filesystem type> Only unmount the filesystem specified in the options.
  • -v Display detailed information when executed.
  • -V Display version information.
  • [Filesystem] In addition to specifying the filesystem directly, it can also be represented by the device name or mount point.

Online Examples

The following two commands unmount the filesystem through device name and mount point, and output detailed information at the same time:

 -v /dev/sda1          Unmount through Device Name  
/dev/sda1 Unmounted  
 -v /mnt/mymount/      Unmount through Mount Point  
/tmp/diskboot.img umounted 

If the device is busy, the unmount operation will fail. Common reasons for unmount failure include that the current directory of an open shell is a directory within the mounted point:

 -v /mnt/mymount/  
umount: /mnt/mymount: device is busy  
umount: /mnt/mymount: device is busy 

Linux Command大全