Файл /etc/fstab содержит информацию необходимую для автоматического монтирования разделов.
Обычно, после редактирования этого файла Вы перезагружаете Linux систему чтобы изменения вступили в силу.
Существует простой способ перемонтирования всех разделов из /etc/fstab
без перезагрузки системы.
Выполните следующую команду от рута:
# mount -a
Эта простая команда перемонтирует все файловые системы указанные в /etc/fstab
, за исключением разделов с опцией noauto
.
I was hoping this was possible, thank you!
So if I change what is mounted on /mnt/myshare , and execute mount -a, it will unmount was there, and mount what I changed it to?
it //server/share1 /mnt/share
I change it to //server/share2 /mnt/share
then execute mount -a
//server/share2 will be mounted on /mnt/share ?
mount: /mnt/$PATH_I_CHOSE: bad option; for several filesystems (e.g. nfs, cifs) you might need a /sbin/mount. helper program.
I think this method needs some updating…
which method? «mount -a»? It works flawlessly for me in Debian 10.5 and LMDE 4, so Im not sure if it really needs an update.
In the past, I have gotten the «mount: /mnt/$PATH_I_CHOSE: bad option; for several filesystems (e.g. nfs, cifs) you might need a /sbin/mount. helper program.» error, mainly when I tried to mount an nfs share with no ‘nfs-common’ installed on my client computer.
Doesn’t seem to be working for me on Gentoo. I have a tmpfs mounted @ /var/tmp/portage and wanted to change the size. It doesn’t seem to be happening after running mount -a
You are a saint! This is also really useful if you have an NFS mount that timed out at boot, so it did not mount, but is now available.
Thanks!