Multibooting fails: Windows won't start and other Linux can't be found

97 views
Skip to first unread message

Tobias Kah

unread,
Oct 9, 2016, 11:04:18 AM10/9/16
to qubes...@googlegroups.com
I did what the Documentation for Multibooting said and added Stanzas for Windows and Linux Mint to Grub 2 to /etc/grub.d/40_custom after installing Qubes.

My Partitions are the following:

sda1 "DellUtility" vfat
sda2 "RECOVERY" ntfs
sda3 "OS" ntfs
sda4 extended
sda7 Qubes ext4
sda8 Qubes crypto_LUKS
sda5 Linux Mint Swap
sda6 Linux Mint ext4

My /etc/grub.d/40_custom looks like this after adding the stanzas:

#!/bin/sh
exec tail -n +3 $0
#
#
#
#
menuentry "Linux Mint 18" {
set root=(hd0,5)
chainloader +1
}

menuentry "Winodws 7" {
insmod part_msdos
insmod ntldr
insmod ntfs
ntldr (hd0,2)/bootmgr
}

I've tried out all possible partitions for root=() and ntldr () but the Linux always gives me "error: Invalid Signature. Press any key to continue."
Did I do any mistake while editing the 40_custom file?

For Windows I get something like

"Windows failed to start. A recent hardware or software change might be the cause. To fix this problem:
1. Insert your Windows installation disk
2. Choose language
3. Click repair your computer

file: \boot\BCD
Status: 0xc0000225
Info: An error occurred while attempting to read the boot configuration data."

Is that really necessary (I don't have such a disk)? There should not have been made any changes to the Windows Partition so I do not understand why it won't boot...


I really appreciate any ideas on how to fix this issue.
Message has been deleted

pleo...@gmail.com

unread,
Oct 9, 2016, 11:26:06 AM10/9/16
to qubes-users
Try export file from /boot/grub2/grub.cfg on disk where you have acces i.e. pastebin or whatever .Then in rescatux bring back grub from Mint,log into and change grub difference to your config.

Unman

unread,
Oct 9, 2016, 6:40:21 PM10/9/16
to Tobias Kah, qubes...@googlegroups.com
On Sun, Oct 09, 2016 at 05:04:05PM +0200, Tobias Kah wrote:
> I did what the Documentation for Multibooting said and added Stanzas for
> Windows and Linux Mint to Grub 2 to /etc/grub.d/40_custom after installing
> Qubes.
>
> My Partitions are the following:
>
>
> *sda1 "DellUtility" vfat*
>
> *sda2 "RECOVERY" ntfs*
>
> *sda3 "OS" ntfs*
>
> *sda4 extended*
>
> *sda7 Qubes ext4*
>
> *sda8 Qubes crypto_LUKS*
>
> *sda5 Linux Mint Swap *
>
> *sda6 Linux Mint ext4*
>
> My /etc/grub.d/40_custom looks like this after adding the stanzas:
>
>
> *#!/bin/sh*
>
>
>
>
>
> *exec tail -n +3 $0####*
>
> *menuentry "Linux Mint 18" {*
>
> *set root=(hd0,5)*
>
> *chainloader +1*
>
>
> *}*
>
> *menuentry "Winodws 7" {*
>
> *insmod part_msdos*
>
> *insmod ntldr*
>
> *insmod ntfs*
>
> *ntldr (hd0,2)/bootmgr*
> *}*
>
> I've tried out all possible partitions for root=() and ntldr () but the
> Linux always gives me "error: Invalid Signature. Press any key to continue."
> Did I do any mistake while editing the 40_custom file?
>
> For Windows I get something like
>
>
> *"Windows failed to start. A recent hardware or software change might be
> the cause. To fix this problem:*
>
> *1. Insert your Windows installation disk*
>
> *2. Choose language*
>
>
> *3. Click repair your computer*
>
> *file: \boot\BCD*
>
> *Status: 0xc0000225*
> *Info: An error occurred while attempting to read the boot configuration
> data."*
>
> Is that really necessary (I don't have such a disk)? There should not have
> been made any changes to the Windows Partition so I do not understand why
> it won't boot...
>
>
> I really appreciate any ideas on how to fix this issue.

This is grub2, which numbers partitions from 1.
So your entry is pointing to sda5 which is apparently the Mint swap.
Change it to hd0,6

Similarly you're pointing at the windows RECOVERY partition.

unman

pleo...@gmail.com

unread,
Oct 9, 2016, 6:50:55 PM10/9/16
to qubes-users, t.k.t.k.t.k...@gmail.com
WTF you r doing you are crazy or what ,simply back to your boot from Mint,you can do this by rescatux to fix it and then log to your Min end edit your grub to suport Qubes loading.

pleo...@gmail.com

unread,
Oct 9, 2016, 6:52:24 PM10/9/16
to qubes-users

you can download rescatux via this site http://www.supergrubdisk.org/rescatux/

raah...@gmail.com

unread,
Oct 10, 2016, 12:13:22 AM10/10/16
to qubes-users, t.k.t.k.t.k...@gmail.com

load a live mint disk. follow these instructions to reinstall grub https://community.linuxmint.com/tutorial/view/245

Then boot into mint. then go to /etc/grub.d/40_custom file. in there you will paste everything from the qubes /boot partition. from /boot/grub/grub2/grub.cfg file (or something like that) the whole section between where it says xen. then update grub and reboot and qubes and windows should be in the mint grub.

Unman

unread,
Oct 10, 2016, 9:04:52 AM10/10/16
to t.k.t.k.t.k...@gmail.com, qubes-users
I don't understand these suggestions to reinstall grub, when there
is a working grub.It's the configuration that is wrong as I pointed
out.

Also, there's no need to run a live distro of any sort, assuming Qubes
boots fine. It would be simpler to mount the mint partition, grab the
files from there and paste directly in to the /boot partition.

But I'd suggest trying to fig the partition references in grub.cfg first.

unman

t.k.t.k.t.k...@gmail.com

unread,
Oct 10, 2016, 11:08:57 AM10/10/16
to qubes-users, t.k.t.k.t.k...@gmail.com, un...@thirdeyesecurity.org
Thank you for you answers.

As I tried to point out, I have already tried all possible partitions for root=(hdx,y), including hd0,6 and none of them worked.

I'd prefer fixing it without a life distro by mounting the mint partition on qubes. Which files do I have to get and paste to the /boot partition? And how do I paste them there? Is the /boot partition the folder /boot in the dom0 filesystem?

pleo...@gmail.com

unread,
Oct 10, 2016, 1:29:27 PM10/10/16
to qubes-users

you can copy menuentry for linux mint and windows from linux mint boot partition.Mount it go to /boot/grub2/grub.cfg and copy menuentry Mint Windows to your boot grub.cfg in qubes.Then it should work.

If not i suggest u use rescatoox because its most simple way.

raah...@gmail.com

unread,
Oct 10, 2016, 3:13:10 PM10/10/16
to qubes-users, t.k.t.k.t.k...@gmail.com, un...@thirdeyesecurity.org

just saying what i find simpler, and how I do it myself.

t.k.t.k.t.k...@gmail.com

unread,
Oct 10, 2016, 4:25:47 PM10/10/16
to qubes-users, t.k.t.k.t.k...@gmail.com, un...@thirdeyesecurity.org
Thank you so much, this fixed it, now everything works perfectly fine, although I get an error "command recordfail not found
command gfxmode not found
press any key to continue"
when booting into Mint. The grub.cfg file contained these commands and I copied them. The error seems to have no influence, when I hit a key, it boots normally, so I think I can ignore this?

And are the changes I made persistent if I update-grub? (I'm not planning to do that but if I do in a year or so I probably won't remember if it is not persistent)

raah...@gmail.com

unread,
Oct 10, 2016, 4:49:11 PM10/10/16
to qubes-users, t.k.t.k.t.k...@gmail.com, un...@thirdeyesecurity.org

what fixed it? What commands? Are you booting qubes from a mint grub? If you doint the /etc/grub.d/40_custom method. make sure to paste in ther eeverything in the qubes grub.cfg between where it starts ### BEGIN /etc/grub.d/20_linux_xen ###

Its persistent but when qubes upgrade a kernel or initrd or something you will want to repeat this step and do update-grub again.

Unman

unread,
Oct 10, 2016, 4:58:29 PM10/10/16
to t.k.t.k.t.k...@gmail.com, qubes-users
Neither of these are needed, and you can delete those entries, as you
thought.

If you have made the change in grub.cfg then it wont be persistent.
You need to put the same entry in to /etc/grub.d/40_custom, and then it
will be picked up on a future grub update.


pleo...@gmail.com

unread,
Oct 10, 2016, 5:30:49 PM10/10/16
to qubes-users
command recordfail not found
command gfxmode not found
press any key to continue

This variables

recordfail
gfxmode

are not needed,coment it or delete.Then boot should be clean with no errors.

raah...@gmail.com

unread,
Oct 11, 2016, 1:05:09 AM10/11/16
to qubes-users, t.k.t.k.t.k...@gmail.com, un...@thirdeyesecurity.org

ok well then if he copied the menuentry or pasted from the mint boot partition's grub.cfg then its just opposite. might want to update it if mint updates its kernel.

Reply all
Reply to author
Forward
0 new messages