I have SSD + HDD setup and planned to have OS on SSD (/dev/sdb) and use HDD (/dev/sda) as storage. I want HDD to be mounted during system start to the subfolder of home (full path /home/artemm/large). I put into fstab:
UUID=627cd586-cfb1-49eb-83b4-ee52e95b36bf /home/artemm/large ext4 defaults,errors=remount-ro 0 2
Or
/dev/sda3 /home/artemm/large ext4 defaults 0 2
Or generate with disks utility:
/dev/disk/by-uuid/627cd586-cfb1-49eb-83b4-ee52e95b36bf /home/artemm/large auto nosuid,nodev,nofail 0 0
Or even add to /etc/bash.bashrc
mount /dev/sda3 /home/artemm/large/
All produces the same result: After boot I got my HDD mounted but I don't see any folders or files. In Nautilus in devices section hdd looks mounted but empty.
Here is screenshot of manual mount:
and here is result of automount (no files/folders but it seems it determines free space):
Here are some additional facts:
- I can't unmount that disk ( http://minus.com/lNX7PEwb8IFEx ).
- If I remove automount and run fsck it runs normally (no errors).
- If I remove automount and mount manually it mounts as expected (to /home/artemm/large/).
- If I remove automount then add entry to fstab then in terminal "sudo mount -a" it mounts as expected (to /home/artemm/large/).
- Running just installed Ubuntu 14.04
Any idea what could provoke such behavior and/or how to handle my use case (mounting hdd on startup)?
It seems like even as folder is shown as device it points just to folder rather than mount
Update: I've created file in that mount point after automount (so folder was empty). It persist with automount. http://minus.com/lbj4nL0jOnK2Z9 . But "sudo mount /dev/sda3 /home/artemm/large/" changes content to "regular"/expected one (several folders I expect to see there).
Update 2: In terminal after automount and boot (folder empty):
$ mount -l | grep large
/dev/sda3 on /home/artemm/large type ext4 (rw)
Then doing:
$ mount /dev/sda3
mount: according to mtab, /dev/sda3 is already mounted on /home/artemm/large
mount failed
$ sudo mount /dev/sda3
$
After mount with sudo everything works as expected (I got my folders back).