I have configured my Raspberry PI 2 with Ubuntu Server 16.04.1, which is working like a charm.

My only issue is that my external HDD is not automatically mounted. I tried using the fstab and UUID, not working. I was reading that on Ubuntu server, you need USBMount. the only thing is that I want that drive to be mounted on /media/NAS

For now, I did a schedule cron job to mount the drive.

Any help is appreciated.

Thanks :)


[   23.834487] audit: type=1400 audit(1455208086.487:9): apparmor="STATUS" operation="profile_load" profile="unconfined" name="/usr/lib/lxd/lxd-bridge-proxy" pid=887 comm="apparmor_parser"
[   23.842573] audit: type=1400 audit(1455208086.495:10): apparmor="STATUS" operation="profile_load" profile="unconfined" name="/usr/lib/snapd/snap-confine" pid=888 comm="apparmor_parser"
[   23.842655] audit: type=1400 audit(1455208086.495:11): apparmor="STATUS" operation="profile_load" profile="unconfined" name="/usr/lib/snapd/snap-confine//mount-namespace-capture-helper" pid=888 comm="apparmor_parser"
[   24.394638] cgroup: new mount options do not match the existing superblock, will be ignored
[   28.213436] EXT4-fs error (device mmcblk0p2): ext4_mb_generate_buddy:758: group 1, block bitmap and bg descriptor inconsistent: 1258 vs 1257 free clusters
[   28.237744] JBD2: Spotted dirty metadata buffer (dev = mmcblk0p2, blocknr = 0). There's a risk of filesystem corruption in case of system crash.
[   29.169243] smsc95xx 1-1.1:1.0 eth0: hardware isn't capable of remote wakeup
[   29.169478] IPv6: ADDRCONF(NETDEV_UP): eth0: link is not ready
[   30.828279] IPv6: ADDRCONF(NETDEV_CHANGE): eth0: link becomes ready
[   30.829360] smsc95xx 1-1.1:1.0 eth0: link up, 100Mbps, full-duplex, lpa 0xCDE1


df: /media/NAS: Transport endpoint is not connected
Filesystem      Size  Used Avail Use% Mounted on
udev            448M     0  448M   0% /dev
tmpfs            93M  8.3M   84M   9% /run
/dev/mmcblk0p2  7.0G  3.5G  3.5G  50% /
tmpfs           461M     0  461M   0% /dev/shm
tmpfs           5.0M  4.0K  5.0M   1% /run/lock
tmpfs           461M     0  461M   0% /sys/fs/cgroup
/dev/mmcblk0p1  128M   56M   72M  44% /boot/firmware
tmpfs            93M     0   93M   0% /run/user/1000
  • Ok, can you please unmount the drive, then unplug, and plug it back in again, then post a fresh dmesg | tail? Also, is this drive an SSD (or was it previously?) Nov 7 '16 at 1:34
  • I will do so tomorrow after work. it has been never an SSD, it was an HDD connected to a windows server 2008 R2 (4TB, GPT). I'll let you know Nov 7 '16 at 2:36

sudo apt-get install usbmount

It creates entries for usb devices in /media, then automounts the USB devices there.

Beware of FAT & NTFS drives, you may need to edit the /etc/usbmount/usbmount.conf file for filesystems that aren't supported by default. Everything is commented well, so should be simple to do.

You may also need to sudo apt-get install ntfs-3g for NTFS support etc.

ext3 and ext4 (for example) should be fine.

Once installed, you can edit lines 12 & 13 of /etc/usbmount/usbmount.conf, changing the mount points to /media/NAS etc.

  • Thanks for your answer. I tried this, but when I boot, the drive isn't connected when I do a DF -h. it seems the drive is mounted no where... Nov 7 '16 at 1:21
  • Mounted to nowhere? Can you be more specific? What does your df -h look like? and can you post the output of dmesg | tail after you plug in a device? Nov 7 '16 at 1:24
  • Actually, I am remotely connect to my PI. The drive is connected at boot. See first post for the new details you asked me! Nov 7 '16 at 1:27
  • 1
    oh and to let you know, if I try to mount it manually, it says it's already mounted, but can't find the folder.. I do umount, the mount, it works to media/NAS. Thanks again for your help! Nov 7 '16 at 1:35

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.