Ubuntu – Dual boot Windows 7 and Ubuntu, SSD + HDD

dual-boothard drivessdwindows 7

I am new to linux and Ubuntu and wish to create a system that can boot both Windows 7 (for windows specific applications) and Ubuntu (I wish to become familiar with linux and Ubuntu for work). I have already read through a lot of material, but found nothing for quite what I am looking to do, and I am not sure how or where I should start.

I have a 120GB solid state drive on which I want to locate the windows and linux OS, as well as other applications that would benefit from the SSD.
I additionally have a 1TB hard drive that I want to use for data/storage.

From what I have read, I understand that I will need to partition the drive(s) or use Logical Volume Management to set up the dual boot environment that I envision. I hope to share the data stored on the 1TB hard drive between the two operating systems, but if this is not feasible then splitting the 1TB hard drive into two or more smaller partitions would be fine.

I have previously installed windows to the SSD and 'migrated' the User's folder to my 1TB data drive (without manually setting up a partition or anything). This worked fine for a while, but the system proved unstable and no longer works, except in 'safe mode'. I have all of my data backed up, so I intend on "starting over" and re-installing windows along with ubuntu. I don't want to keep anything that is currently on the ssd or hdd.

In short:
–I have a 120 GB solid state drive I want to put Windows 7 and Ubuntu on.
–I have a 1TB hard disk drive that I want to use as data storage for the two operating systems.
–What is the best way of going about this? I want the system to be as stable as possible while maximizing the benefits of using an SSD to boot from/run applications.
+ Any advice or information would be appreciated!


Best Answer

I actually did this for myself a few months ago. The process is a bit long, and read through the entire thing before you make any decisions as to whether you want to do it or not. You will need to change your registry, and although I have not experienced any problems so far, you may if you don't do everything as I did.

First, set up your partitions in a Ubuntu live disk. Copy all your information to a safe volume in case something happens. Then, wipe all your drives.

Install Windows first. When you create your account during installation, choose a spare account name. It doesn't matter what this name is, except for the fact that it cannot be the name you want to use in the future. I would call it something like "spare."

After installing Windows, create an account with your real account name, but do not log into it yet. Go into regedit, and change all instances of C:/Users to D:/Users (or whatever drive you have your storage on, be it D:, E:, F:, G:, etc. Don't change anything like C:/Users/Administrator, though, only the ones with C:/Users and the ones that would pertain to you.

After doing this load of registry edits, go and restart your computer and log into your new account. If you've done everything right, your new account's profile should be in the drive you had set it to be.

If it is, great. Delete the spare whose account is still on C:/. Do whatever you want on Windows, and after that, install Ubuntu.

I can expect that you can install Ubuntu without any instruction. During installation, I installed my user folder in the normal directory in the same partition as my main installation. I then created symlinks on my user folders by using the commands:

rm -r ./Documents
ln -s /media/Storage/Users/Tyler/Documents ./Documents
rm -r ./Downloads
ln -s /media/Storage/Users/Tyler/Downloads ./Downloads
rm -r ./Music
ln -s /media/Storage/Users/Tyler/Music ./Music
rm -r ./Pictures
ln -s /media/Storage/Users/Tyler/Pictures ./Pictures
rm -r ./Videos
ln -s /media/Storage/Users/Tyler/Videos ./Videos

Tyler is my username on Windows, and Storage is the name of my storage partition.

These commands don't include the templates and the Desktop folder, although I expect that they would be easy to implement.

These symlinks do not have the pretty images, and I have not found a permanent fix for that at this moment. I can set the icon image, but it is reset. I suspect that this is because it needs to mount every time I start up, and that resets the images. I'll post a fix if I find one.

If you want to automount your storage partition upon startup in Ubuntu, you'll need find which partition to mount. In a terminal, use

sudo fdisk -l

You should receive a list of partitions. Mine looks like this.

tyler@Tyler-PC:/$ sudo fdisk -l
[sudo] password for tyler: 

Disk /dev/sda: 320.1 GB, 320072933376 bytes
255 heads, 63 sectors/track, 38913 cylinders, total 625142448 sectors
Units = sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk identifier: 0xf64a0fce

   Device Boot      Start         End      Blocks   Id  System
/dev/sda1   *        2048   125831167    62914560    7  HPFS/NTFS/exFAT
/dev/sda2       125831168   188745727    31457280   83  Linux
/dev/sda3       188745728   608364543   209809408    7  HPFS/NTFS/exFAT
/dev/sda4       608364544   625141759     8388608   82  Linux swap / Solaris

Search "Startup Applications" and add the command

udisks --mount /dev/sda3

sda3 should be replaced with the one for the disk you have. I had remembered that I had set mine to sda3 when I made my partitions. Also, it is my largest.

After that command, upon startup, you shouldn't need to navigate to your storage partition via nautilus to mount it. I'd only discovered that fix yesterday; as I use Eclipse to develop in Java, needing to mount it via nautilus every time was extremely obnoxious.

Good luck!

Related Question