How to Stop Ubuntu from Automatically Mounting Network Drives

The Hanging Boot Process

In Ubuntu, system administrators frequently mount network drives (like NAS devices, Samba shares, or NFS exports) by adding entries to the /etc/fstab file. By default, Ubuntu attempts to automatically mount every drive listed in this file during the system boot sequence. If you are using a laptop that has been disconnected from your home network, or if the server hosting the network drive is temporarily offline, Ubuntu will stall during the boot process, waiting for a network timeout before it finally gives up and allows you to reach the login screen. This turns a 10-second boot into a 3-minute wait.

Configuring On-Demand Mounting

To ensure a fast, reliable boot and stop Ubuntu from automatically mounting specific network drives at startup, you must add the “noauto” parameter to the drive’s fstab entry.

You must edit the file system table via the terminal. Open your terminal by pressing Ctrl+Alt+T. Type sudo nano /etc/fstab and press Enter (provide your password). Carefully locate the specific line corresponding to your network drive (it will usually contain IP addresses or mention CIFS/NFS). Look at the fourth column in that line, which contains the mount options (e.g., defaults,uid=1000). You need to add noauto to this comma-separated list. The options section should now look something like defaults,noauto,uid=1000. Press Ctrl+O then Enter to save the file, and Ctrl+X to exit. Your computer will now boot quickly. To access the drive later, you must manually run sudo mount /path/to/mountpoint or click the drive in your file manager.

Get the best tech tips delivered straight to your inbox.

Join thousands of readers mastering Apple, Google, Microsoft, and Linux.