Mount a partition in Ubuntu automatically at startup
Everytime I boot Ubuntu, I have to mount all the partitions I need to get them up and running. But seriously, I find it annoying. Here’s a workaround that worked for me.
Identify the partition you want to automount. Mount that specific partition and open its content using File Browser. Keep in mind it’s mount point, the ones found on the location bar.

Open System Monitor (System -> Administration -> System Monitor). Go to the File Systems tab and find the corresponding Device of the mount point. The format would be something like /dev/sd[a-z][1-9].
Unmount the device by going to Places -> Computer. Right click the partition and click Unmount Volume.
Now, open terminal (Applications -> Accessories -> Terminal). Navigate to /dev/disk/by-id by typing this command:
cd /dev/disk/by-id.
Get the list of files and directories on the path by typing ls. Find your appropriate device. If it's /dev/sda3, it should end with something like -part3. Copy the file name and paste it somewhere else such as a text-editor.
Now, edit /etc/fstab by typing the command sudo gedit /etc/fstab. At the end of the file, paste this:
/dev/disk/by-id/[replace_01] /media/disk [replace_02] defaults 0 0
Replace replace_01 with the filename you pasted somewhere else a while ago and replace_02 with the file system of the partition (ntfs, ext3, etc).
It should look like this:
/dev/disk/by-id/scsi-SATA_ST9160821AS_5MA20LDN-part1 /media/disk ntfs defaults 0 0
Now, create the /media/disk folder by typing the command:
sudo mkdir /media/disk
Finally, mount the volume by typing:
sudo mount /media/disk
The partition should automount automatically the next time you reboot it. Have fun!
Done reading? You are free to share your comments or insights regarding my post. You may also want to get updates thru RSS feed or thru email. You may also share this article to your Facebook friends or Twitter followers for free.


Conrad Miguel E. Gozalo is a 17-year old guy from General Santos City, Philippines. He is currently taking up his BS Computer Science at the University of the Philippines Diliman. He is a proud Linux user since August 2008. He is also a big fan of Free and Open Source Software. Know more about him on the 
3 Responses to “Mount a partition in Ubuntu automatically at startup” (join them?)
July 3, 2009 at 12:56 am
Good post – I’m more command-line oriented, so I wrote this to do the same thing from the command line: http://bit.ly/CO2Wl
August 11, 2009 at 11:03 am
good guide thanks , I hope it works.
October 1, 2009 at 6:07 pm
That works fine. Nice
Leave a reply!