[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Constructing a dual boot system
From: |
Helge Fredriksen |
Subject: |
Constructing a dual boot system |
Date: |
Fri, 16 Apr 2010 12:19:12 +0200 |
Hello!
We have developed our own stripped version of
a Ubuntu 8.04 system that launch our own software at boot time. The
distro is so small that it fits to a 1.5 Gb partition. The PC is setup
with only one partition /dev/sda1. We tailor this PC the way we like
it and then makes an installer when we want to deploy.
Our installer works in the following way:
* Take a dd copy of /dev/sda to a image file.
* Store this image in a Slax environment, and create a slax bootable CD image.
* When installing, the slax environment starts a script upon
startup where the user can make some choises on IP address, name of PC
etc.
* The whole template image of /dev/sda is copied directly to /dev/sda on the target PC.
* The partition table is a bit altered, adding a swap partition and a giving the rest of the space to /dev/sda3
Now,
this has worked quite fine until many customers require us to make this
a multi boot system, where the existing Windows installation is kept.
I managed to use ntfsresize to shrink the existing
partition and use parted to delete the existing + add a new smaller
windows partition.
My idea then was to add
another bootable partition immediatly following the windows partition
(/dev/sda2). I thought that copying the template PC /dev/sda1 into this
partition should then enable me to boot from here instead! Then I could
just add another entry into menu.grub with hd(0,0) as boot entry to
allow me to get to the Windows booting of /dev/sda1.
But I'm not able to boot the Linux kernel in /dev/sda2 after doing this dd copy. Any ideas why?
Any help or links to further reading on how to solve this problem would be much appreciated. I know almost all distros have this kind of functionality, but I'm having a hard time figuring out where to get
the exact info on it.
Best regards,
Helge Fredriksen
- Constructing a dual boot system,
Helge Fredriksen <=