Automount of external hard disk
Solution 1
It's an old question but I figured this might still help someone.
I've had the same problem with this hdd. The source turned out to be the initial format of the partition. Reformatting as NTFS using the Disks (gnome-disks) tool made it behave like any other usb hdd.
Solution 2
Here you have a good guide on how to mounting drives.
https://help.ubuntu.com/community/AutomaticallyMountPartitions
You should add your drive to the /etc/fstab file which controls the mounted devices, with parameters such as
- the mounting drive,
- the mounting point
- used filesystem
- and several other options
good luck!
EDIT: If you modify fstab manually instead of using some interface, be careful with the lines you change. Do a backup of the file first or you could make your system to not boot properly.
Martin Thoma
I also have a blog about Code, the Web and Cyberculture and a career profile on Stackoverflow. My interests are mainly machine-learning, neural-networks, data-analysis.
Updated on September 18, 2022Comments
-
Martin Thoma over 1 year
I have an Intenso 6002560 1TB Memory Station - an external hard disk. This hard disk gets connected via Y-USB cable. When I connect both USB-ends to my Notebook, it gets recognized by my Ubuntu 10.04.4 LTS system:
moose@pc07:~$ lsusb [...] Bus 002 Device 005: ID 13fd:1840 Initio Corporation [...]
and
Disk /dev/sda: 320.1 GB, 320072933376 bytes 255 heads, 63 sectors/track, 38913 cylinders Units = cylinders of 16065 * 512 = 8225280 bytes Sector size (logical/physical): 512 bytes / 512 bytes I/O size (minimum/optimal): 512 bytes / 512 bytes Disk identifier: 0x00065e10 Device Boot Start End Blocks Id System /dev/sda1 * 1 37810 303704064 83 Linux /dev/sda2 37810 38914 8864769 5 Extended /dev/sda5 37810 38914 8864768 82 Linux swap / Solaris Disk /dev/sdc: 1000.2 GB, 1000204886016 bytes 255 heads, 63 sectors/track, 121601 cylinders Units = cylinders of 16065 * 512 = 8225280 bytes Sector size (logical/physical): 512 bytes / 512 bytes I/O size (minimum/optimal): 512 bytes / 512 bytes Disk identifier: 0x0d6ea32a Device Boot Start End Blocks Id System /dev/sdc1 1 121601 976759008+ c W95 FAT32 (LBA)
But it did not get mounted:
moose@pc07:/dev$ mount -l /dev/sda1 on / type ext4 (rw,errors=remount-ro,user_xattr) proc on /proc type proc (rw,noexec,nosuid,nodev) none on /sys type sysfs (rw,noexec,nosuid,nodev) none on /sys/fs/fuse/connections type fusectl (rw) none on /sys/kernel/debug type debugfs (rw) none on /sys/kernel/security type securityfs (rw) none on /dev type devtmpfs (rw,mode=0755) none on /dev/pts type devpts (rw,noexec,nosuid,gid=5,mode=0620) none on /dev/shm type tmpfs (rw,nosuid,nodev) none on /var/run type tmpfs (rw,nosuid,mode=0755) none on /var/lock type tmpfs (rw,noexec,nosuid,nodev) none on /lib/init/rw type tmpfs (rw,nosuid,mode=0755) binfmt_misc on /proc/sys/fs/binfmt_misc type binfmt_misc (rw,noexec,nosuid,nodev) gvfs-fuse-daemon on /home/moose/.gvfs type fuse.gvfs-fuse-daemon (rw,nosuid,nodev,user=moose)
However, I could mount it manually with
mount -t vfat /dev/sdc1 /mnt/sdc1
as you can see here:
moose@pc07:~$ mount -l /dev/sda1 on / type ext4 (rw,errors=remount-ro,user_xattr) proc on /proc type proc (rw,noexec,nosuid,nodev) none on /sys type sysfs (rw,noexec,nosuid,nodev) none on /sys/fs/fuse/connections type fusectl (rw) none on /sys/kernel/debug type debugfs (rw) none on /sys/kernel/security type securityfs (rw) none on /dev type devtmpfs (rw,mode=0755) none on /dev/pts type devpts (rw,noexec,nosuid,gid=5,mode=0620) none on /dev/shm type tmpfs (rw,nosuid,nodev) none on /var/run type tmpfs (rw,nosuid,mode=0755) none on /var/lock type tmpfs (rw,noexec,nosuid,nodev) none on /lib/init/rw type tmpfs (rw,nosuid,mode=0755) binfmt_misc on /proc/sys/fs/binfmt_misc type binfmt_misc (rw,noexec,nosuid,nodev) gvfs-fuse-daemon on /home/moose/.gvfs type fuse.gvfs-fuse-daemon (rw,nosuid,nodev,user=moose) /dev/sdc1 on /mnt/sdc1 type vfat (rw)
edit: Another command:
moose@pc07:~$ sudo blkid -o list device fs_type label mount point UUID ---------------------------------------------------------------------------------------------------------------------- /dev/sda1 ext4 / 45eb611b-517e-425b-8057-0391726cccd5 /dev/sda5 swap <swap> e9dc42f3-594c-4b62-874a-305eda5eed41 moose@pc07:~$ blkid -o list device fs_type label mount point UUID ---------------------------------------------------------------------------------------------------------------------- /dev/sda1 ext4 / 45eb611b-517e-425b-8057-0391726cccd5 /dev/sda5 swap <swap> e9dc42f3-594c-4b62-874a-305eda5eed41 /dev/sdc1 /mnt/sdc1
edit: another command:
moose@pc07:~$ ls -l /dev/disk/by-uuid/ total 0 lrwxrwxrwx 1 root root 10 2012-09-30 09:31 45eb611b-517e-425b-8057-0391726cccd5 -> ../../sda1 lrwxrwxrwx 1 root root 10 2012-09-30 09:31 e9dc42f3-594c-4b62-874a-305eda5eed41 -> ../../sda5
Here is a link to a Launchpad question about this problem.
But I would like it to mount automatically. What do I have to do?
-
Martin Thoma over 11 years@user81022: it outputs only the two partitions of my internal hdd, see edited post.
-
bob over 11 yearsI think since the drive is fat32, you should mount it as sdb type (not sdc). So, first sudo umount /dev/sdc1 and then re-mount it (/dev/sdb1). I wish I could help more.
-
Martin Thoma over 11 years
/dev/sdb1
does not exist (mount: special device /dev/sdb1 does not exist
). If I try to mount/dev/sdb
it saysmount: no medium found on /dev/sdb
. By the way,chkdisk
on a windows machine did not reveal any errors. It worked on Windows out of the box.
-
-
Martin Thoma over 11 yearsit seems not to have a UUID (see my edit). What do I do now? (and why isn't the device displayed when I run
blkid
withsudo
?) -
Martin Thoma over 10 yearsThis did the trick! Thank you so much! Do you know if there is a MATE tool with which this can be done?