So I have unmounted a usb external hard drive but I went to re-mount it. Is there a command that I can use to remount the drive? Only way I know to re-mount a drive is to disconnect the usb cable from my Mac and reconnect it.
diskutil mount also accepts a volume name, so there is no need to grep the output of
diskutil list. If the disk has multiple volumes (like a Time Machine volume and another volume), you can use
diskutil mountDisk to mount all volumes:
$ diskutil mount WD Volume WD on WD mounted $ osascript -e 'tell app "Finder" to disks where ejectable is true' disk WD $ diskutil eject Untitled Disk WD ejected $ diskutil mountDisk WD Volume(s) mounted successfully $ osascript -e 'tell app "Finder" to disks where ejectable is true' disk Time Machine, disk WD
eject apply to all volumes even if you specify the name of one volume.
In addition to the answers already given, there is also a GUI app for this, which I really like: Mountain.
It's a $2 app that sits in the menu bar and keeps track of both mounted and unmounted drives. Unmounted drives can be remounted from there as well.
You can download a free trial from the website.
(Also note that once you install the Mac App Store version, there is an update available directly from the developer. I assume the update isn't on the Mac App Store because of Apple's sandboxing rules.)