dual booting Win 7 and Linux on separate HDDs

registerforfree

Senior Member
Joined
Sep 25, 2014
Messages
647
Reaction score
0
I'm completely new to Linux and would like to install it on my second HDD for development purposes. Could someone point me to a helpful tutorial explaining how this is done or explain why it is not advisable? No need to explain the process, but I'm having a hard time pinning down a tutorial that accurately describes how to do it. Most of them seem to assume you're trying to install it on a single HDD that has been partitioned.
 
What happens when you install them normally on separate hard drives?
 
What Linux do you want to run? A few of them you can run the live CD while in Windows and install in Windows (like installing an app and later you can uninstall from control panel) and that would give you a dual boot with Linux. Probably the easiest and safest for someone with little background. I know Ubuntu and Fedora can do that.
 
yes mint ubuntu and fedora's installer can make your pc dual boot automatically if you ran the installer
 
Install it on the second HDD from Linux install DVD and then boot from the second HDD through the bios when you want it and change it back when you don't? Seems easiest.
 
Install it on the second HDD from Linux install DVD and then boot from the second HDD through the bios when you want it and change it back when you don't? Seems easiest.

It seems I can do it like this. The only thing I'm unsure of is what mount point to use. I've figured out the file system (ext4) and everything else. I apparently just have to install grub on the hdd I'm installing Linux on, then update it from the terminal and it should allow me to boot into either OS fine.
 
It seems I can do it like this. The only thing I'm unsure of is what mount point to use. I've figured out the file system (ext4) and everything else. I apparently just have to install grub on the hdd I'm installing Linux on, then update it from the terminal and it should allow me to boot into either OS fine.

Just be careful with NTFS, linux seems to have problems writing to it, just portion off a piece of the second HDD as ext4 to install Linux on. Your OS might/should recognize it as 2 separate HDDs.
 
I'm completely new to Linux and would like to install it on my second HDD for development purposes. Could someone point me to a helpful tutorial explaining how this is done or explain why it is not advisable? No need to explain the process, but I'm having a hard time pinning down a tutorial that accurately describes how to do it. Most of them seem to assume you're trying to install it on a single HDD that has been partitioned.

Just load up the install disk, choose "Something else", don't choose "alongside windows 7 " option.
Create you partitions (swap,root,home) by choosing the second hdd.If you don't want to use the whole drive, i'd like to make my linux partitions to 20-50gb of drive in ext4, then format the rest to ntfs.

Once you are done, reboot, and grub will pick up your windows automatically on startup. Choose your OS in grub, no need to change in the bios. I'm no linux boffin but that's how i did it on 2 boxes in the past.
 
Last edited:
If you want to do this in an absolutely bulletproof way without getting it wrong then disconnect your current HDD and connect only the new Linux HDD.

Now install the flavour you want and then shut down and connect the other drive.

Simply select which one you want to boot to from the BIOS.
 
^ is the best way to go. This means that there is no chance of the Linux install interfering with the Windows disk. Also grub goes onto the Linux disk rather than into the MBR of the Widows disk, which has the potential to cause issues down the line.

As mentioned above you can select the boot disk from the BIOS when you start up. Another way is to have an entry in the grub file so that you can select your OS from a menu which comes up when you boot. You can not edit the grub2 file directly, so this entry must be placed in the 40_custom file which is then incorporated into the grub2. A quick Google will tell you about this stuff.

To do this you need to have the Linux disk set as the boot disk in the BIOS. The problem is that if you select Windows in the menu then Windows expects that it should have been the boot disk instead. To get by this the Windows entry in grub should also include a change in drive mapping to satisfy this requirement. An example of a 40_custom file that I have on one of my machines is as follows:

#!/bin/sh
exec tail -n +3 $0
#
menuentry “Windows 7” {
set root =(hd1,1)
savedefault
makeactive
map (hd0) (hd1)
map (hd1) (hd0)
chainloader +1
}
 
I used a bootloader thingy (forget the name) you can download, that downloads the ISO for you (or you choose an ISO). It then reboots your machine and you can then boot up using the ISO without a USB or CD. Once there, you can install linux onto the new drive. Once installed, change your BIOS to boot from the new disk.

Linux will then automatically detect that you have a windows installation and GRUB will ask you if you want to boot into windows or linux (it has a countdown and will auto boot into Linux)

I was surprised by linux when it allowed me to boot into windows without changing the bios/boot disk each time. It's like the less clingy girlfriend, she allows you to go out with your other female friends, unlike windows, who is the obsessive bitch who grabs hold of everything she can without letting breathing room and has you "dump" your female friends because she's too jealous
 
try using Vagrant + VirtualBox on your Windows machine for development!
 
What I've done for a number of years is:
- Install Windows on the primary HDD (Windows doesn't like booting of a non-primary disk last time I checked).
- Move the Windows HDD to secondary (slave) HDD using jumpers and install a new HDD as a primary HDD for the Linux OS.
- Install a Linux distro and in most cases the Grub boot loader will auto detect and allow you to boot the Windows OS on the slave HDD.

Logic for the above:
1. Your Grub boot loader only installs on the MBR on the Linux HDD. The Windows boot loader and MBR are not touched.
2. You can remove the Linux disk at any time and boot the Windows disk as if nothing ever happened because of point 1.
 
What I've done for a number of years is:
- Install Windows on the primary HDD (Windows doesn't like booting of a non-primary disk last time I checked).
- Move the Windows HDD to secondary (slave) HDD using jumpers and install a new HDD as a primary HDD for the Linux OS.
- Install a Linux distro and in most cases the Grub boot loader will auto detect and allow you to boot the Windows OS on the slave HDD.

Logic for the above:
1. Your Grub boot loader only installs on the MBR on the Linux HDD. The Windows boot loader and MBR are not touched.
2. You can remove the Linux disk at any time and boot the Windows disk as if nothing ever happened because of point 1.
I've set up one machine like this before that primarily runs Windows. If you have two drives, I'd say this is the best setup.
 
unetbootin is what I used to install linux on my 2nd drive and then switch the bios to boot from that drive instead, automatically giving me the ability to boot into linux by default or go into my windows installation
 
Sorry, I almost forgot about this thread.

So in the end I simply installed Linux on the second HDD and made sure to put grub on it too. I formatted the entire HDD in Ext4. It ran fine except that I couldn't boot into Win7 and it booted straight into Linux be default. So I just opened the terminal, ran "sudo update-grub" and now it asks me which OS I'd like to boot into whenever I restart the PC.

Virtual box, then you can play around with different flavours till your hearts content!

I'm not too fussed about testing the different flavors. I'm toying around with a website I'm building for myself and I've been using Ruby gems for it, some of which don't play nicely with Windows. With Linux I know that the majority of gems should at least be compatible.
 
Top
Sign up to the MyBroadband newsletter
X