I have two hard-drives (one internal and one external) that I want to mount on start up (ntfs, but it doesn’t matter).

I can mount them fine with the "Disk Utility" aplication and I can mount them fine with the comands

/usr/bin/udisks --mount /dev/disk/by-uuid/21318E3E64707B4D

/usr/bin/udisks --mount /dev/disk/by-uuid/6439FB1D652606C4

respectively (I followed this tutorial; https://help.ubuntu.com/community/AutomaticallyMountPartitions#Per-User_Mounts and used the Per-User Mounts).

But when I put these commands, separated by a semicolon, in the Startup Application to run on startup, it only mounts one of the partitions (always the same one). Why is this and how to fix it?

(At first I tried to have each mounting-command as a separate "startup program" but then the start-up program removed one of the programs, leaving me with only one mounted hard drive...)

I'm using Ubuntu 12.04 LTS.

Thank's in advance!

  • from the link you pasted Adding to startup gnome-session-properties Push the Add button. Choose a name, paste in your command and push the Add button what do you see in this gnome-session-screen ? are the two disks you want present there , if you remove the semicolon there and do add one by one do you get desired result Mar 15, 2013 at 7:44
  • Hi, when press Add, paste my comand, and choose name and save, then I see both startup programs there. but when I exit the "startup application" and enter it again, I only see one, thus the startup program removed one of the programs...
    – user136459
    Mar 15, 2013 at 7:55
  • Hmmm the external hard drive you mentioned is it always attached to your system or it is a portable device I tried the same on my system what I noticed is my disk got mounted at /dev/media what is the output on terminal when you type /usr/bin/udisks --mount /dev/disk/by-uuid/21318E3E64707B4D where does it gets mounted and while it is mounted and you type in /usr/bin/udisks --mount /dev/disk/by-uuid/6439FB1D652606C4 where does the second mount gets mounted does it go in same /media Mar 15, 2013 at 7:58
  • Your link says ` This method is only available in Hardy and Karmic.` and below it says to use pysdm package and when I checked pysdm package links ubuntuforums.org/… it says this package is obsolete so you need to manually edit the fstab file Mar 15, 2013 at 8:05

1 Answer 1


To mount hard drives on startup, you need to edit the /etc/fstab file. Just open the file in your favourite editor(be sure to use sudo)

sudo gedit /etc/fstab

and add the appropriate lines for your hard drives

UUID="UUID here" /mount/point filesystem-type defaults 0 0

Just put in the UUID, mount point and filesystem type. See this for more info.

  • Great! That solved it! I also had to create a folder manually where I wanted them to be mounted, but everything was explained at your link! Thanks!
    – user136459
    Mar 15, 2013 at 8:57
  • this link is now dead, also I am having the same problem but can not see any folder named "fstab". Only a fodler named "fstab.d" which seems to be empty. Could someone elaborate on what was done here? Mar 26, 2014 at 5:35
  • @KalamalkaKid I fixed the link using wayback machine. fstab is not a folder, it's a file. Open it in an editor and add the line above. Mar 26, 2014 at 17: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.