troubleshooting Question

Script to mount drives on boot or via a script file

Avatar of Emanuel
EmanuelFlag for United Kingdom of Great Britain and Northern Ireland asked on
Shell ScriptingLinux
6 Comments1 Solution590 ViewsLast Modified:
Hi I am running Ubuntu Lucid Lynx and would like to know how I can get it to automatically mount additional partitions of my primary drive.
I have five partitions on my drive and would ideally like to mount them via a script file.  In addition I would like to mount the 5th partition on boot and have an icon on the desktop appear for the drive.

Additionally how can I install a desktop shortcut for the Computer function, enabling me to browse the drives?

My partitions are;
Disk /dev/sda: 500.1 GB, 500107862016 bytes
255 heads, 63 sectors/track, 60801 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: 0xdf81dcc2

   Device Boot      Start         End      Blocks   Id  System
/dev/sda1   *           1          13      102400    7  HPFS/NTFS
Partition 1 does not end on cylinder boundary.
/dev/sda2              13        7012    56217600    7  HPFS/NTFS
/dev/sda3            7012       10837    30720000    7  HPFS/NTFS
/dev/sda4           10837       60802   401344512    f  W95 Ext'd (LBA)
/dev/sda5           10837       60802   401343488    7  HPFS/NTFS

Many thanks,


Our community of experts have been thoroughly vetted for their expertise and industry experience.

Join our community to see this answer!
Unlock 1 Answer and 6 Comments.
Start Free Trial
Learn from the best

Network and collaborate with thousands of CTOs, CISOs, and IT Pros rooting for you and your success.

Andrew Hancock - VMware vExpert
See if this solution works for you by signing up for a 7 day free trial.
Unlock 1 Answer and 6 Comments.
Try for 7 days

”The time we save is the biggest benefit of E-E to our team. What could take multiple guys 2 hours or more each to find is accessed in around 15 minutes on Experts Exchange.

-Mike Kapnisakis, Warner Bros