Quick Tip for umount
Image by David Both via ChatGPT.
Sometimes learning a new thing can be the result of my innate curiosity.
If you’re a frequent reader on Both.org, you probably already know that I’m rather obsessive about backups. I make two backups of every computer on my network each day, one on an internal hard drive and one on an external USB HDD. I just recently added an external USB HDD for a monthly backup.
Early this morning, as I write this, I was checking to verify that all three backups were created and could be properly accessed in case I needed to restore a file, a directory, or an entire filesystem. Verifying that backups can be accessed is a critical part of any backup plan. You do test that, don’t you?
After performing my tests, I needed to unmount the three devices. Being the lazy SysAdmin, I decided I would try unmounting all three with a single command using file globbing, A.K.A, the wildcards * and ?. The umount man pages don’t state whether wildcards will work, but most Linux commands can use wildcards. So I tried it.
# umount /media/*
This worked perfectly and unmounted all three hard drives.
Note that I also tried the mount command, but that does not work with file globbing.
More Stories
Tinkering with Immutable Linux: How Fedora Cosmic Atomic Won Me Over
I have been doing a lot of reading and listening to YouTube videos about immutable distributions and why they might...
Using Wildcards on the Bash Command Line
The function of any shell, whether Bash, KSH, CSH is to take commands entered on the command line; expand any...
2025 — a Great Year for Both.org
2025 was an amazing year for Both.org. We started with only a few visitors per day and grew rapidly. Although...
How Immutable Linux Could Save Libraries Thousands
Immutable systems like Silverblue can be configured for kiosk mode in libraries and other public spaces that allow patrons to use them for internet access and other uses but do not allow those patrons to change the core system in any way.
Counting words from online articles
Here’s how I automated counting words from a series of articles.