問題タブ [umount]
For questions regarding programming in ECMAScript (JavaScript/JS) and its various dialects/implementations (excluding ActionScript). Note JavaScript is NOT the same as Java! Please include all relevant tags on your question; e.g., [node.js], [jquery], [json], [reactjs], [angular], [ember.js], [vue.js], [typescript], [svelte], etc.
bash - bash - ユーザーが選択したドライブのすべてのパーティションをアンマウントする
Porteus ISO を USB ドライブにインストールするための BASH スクリプトを作成しました。まず、ユーザーはダイアログで作成されたメニュー内でドライブを選択できます。次に、スクリプトは選択したドライブのすべてのパーティションをアンマウントします。ここに私の問題があります。
[...] コードの残りの部分は重要ではありません。問題は「タイプセット パーティション」の直後にあり、$partition が正しい値を受け取っていないように見えることに注意してください。
bash - Bash umount command substitution
I'm running RHEL 7 and bash here. It seems command substitution does not work for the umount command. It does, however, work as usual for other commands. For example:
#xA;What I can probably do is to use mountpoint first and then umount if the mountpoint exists. Then check for umount status - if there is an error I guess the device must be busy.