V
V
Vladimir2011-06-29 16:29:30
linux
Vladimir, 2011-06-29 16:29:30

How to boot linux through windows 7 bootloader?

Good time of the day. Please tell me how to add information about linux to the win7 bootloader. In this case meego(/) using grub (/boot). I tried to indicate in EasyBCD where grub lies, but the bootloader, when this item is selected, issues a “boot error”.
Please do not suggest leaving grub or using a bootloader other than win7. The task is not the same.

One physical disk is used
sda1 - win 100mb
sda2 - win7
sda3 - data
sda4
sda5 - /
sda6 - swap
sda7 - / boot
sda8 - data

If necessary, I can demolish everything and repartition it as needed to solve the problem.

Answer the question

In order to leave comments, you need to log in

3 answer(s)
N
nd0ut, 2011-06-29
@gravl

In theory, this should be done through the bcdedit utility.

V
vadiml, 2011-06-29
@vadiml


Windows, when installed on a disk where there is already a bootloader for DOS or win9x , creates the bootsect.dos file, which prescribes boot.ini in the ntloader config
: "MS-DOS 6.20" /WIN95DOS
This file contains a bit-by-bit copy of the initial sectors of the disk, i.e. ntloader does not know what lies there, but stupidly transfers control to it.
The easiest way to create such a file is with the dd command, which makes a bit-by-bit copy,
for example, copying from a 512-byte boot partition to the bootsect.lnx file on a windows partition mounted in /mnt/c:
# dd of=/dev/sda if=/ mnt/c/bootsect.lnx bs=512 count=1
If the Linux bootloader is not installed in the boot record of the disk, then you need to copy it from there
. And it remains to add it to boot.ini
C:\BOOTSECT.LNX = "Linux"
After that, you can restore the windows bootloader to the boot record of the disk.

V
vadiml, 2011-06-29
@vadiml

slightly wrong in the command, you need to
dd if=/dev/sda of=/mnt/c/bootsect.lnx bs=512 count=1

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question