Scheduled Maintenance: We are aware of an issue with Google, AOL, and Yahoo services as email providers which are blocking new registrations. We are trying to fix the issue and we have several internal and external support tickets in process to resolve the issue. Please see: viewtopic.php?t=158230

 

 

 

[SOLVED] Dual boot Windows 10

If none of the specific sub-forums seem right for your thread, ask here.
Message
Author
Chrisdb
Posts: 279
Joined: 2018-04-10 07:16

[SOLVED] Dual boot Windows 10

#1 Post by Chrisdb »

Just installed Debian 9 alongside w10 with netinstall.
The problem though is that when I choose to start Debian, I see a black screen with a couple of logs. But nothing else happens and the screen is suspended.

If I set the boot mode in bios to legacy support, the system does start.

Can anyone explain why legacy works and uefi not?

Extra info: laptop is a Lenovo ideapad and Debian was installed in uefi mode.
Last edited by Chrisdb on 2018-04-19 06:14, edited 1 time in total.

Wheelerof4te
Posts: 1454
Joined: 2015-08-30 20:14

Re: Dual boot Windows 10

#2 Post by Wheelerof4te »

Have you disabled secure boot in Windows? Debian does not start in UEFI when Secure boot is turned on. Disable fast startup while you're at it.
Ideally, you will wipe Windows when you see how much Debian is better. Unless you need Windows-only software and you play Windows-specific games, of course :mrgreen:

Chrisdb
Posts: 279
Joined: 2018-04-10 07:16

Re: Dual boot Windows 10

#3 Post by Chrisdb »

Yeah I cleared both fast and secure boot...

It's really strange. Should I've done something with the efi partition?

Wheelerof4te
Posts: 1454
Joined: 2015-08-30 20:14

Re: Dual boot Windows 10

#4 Post by Wheelerof4te »

^I have no experience in setting up dual-boot of Windows 10 and Debian. But I suspect that you need one EFI partition for both OSes. This confirms it.
It's for Ubuntu, but should be applicable to Debian as well.

Chrisdb
Posts: 279
Joined: 2018-04-10 07:16

Re: Dual boot Windows 10

#5 Post by Chrisdb »

I left the original efi partition untouched...

User avatar
Head_on_a_Stick
Posts: 14114
Joined: 2014-06-01 17:46
Location: London, England
Has thanked: 81 times
Been thanked: 132 times

Re: Dual boot Windows 10

#6 Post by Head_on_a_Stick »

Please post the output of

Code: Select all

apt policy grub-pc
find /boot/efi
# parted --list
If you can get a "live" system booting in UEFI mode then It may also be useful to see the output of this command:

Code: Select all

# efibootmgr -v
deadbang

Chrisdb
Posts: 279
Joined: 2018-04-10 07:16

Re: Dual boot Windows 10

#7 Post by Chrisdb »

apt policy grub-pc

Code: Select all

grub-pc:
  Installed: (none)
  Candidate: 2.02~beta3-5
  Version table:
     2.02~beta3-5 500
        500 http://ftp.be.debian.org/debian stretch/main amd64 Packages
        500 http://ftp.debian.org/debian stretch/main amd64 Packages
find /boot/efi

Code: Select all

/boot/efi
/boot/efi/EFI
/boot/efi/EFI/debian
/boot/efi/EFI/debian/grubx64.efi
parted --list

Code: Select all

Model: ATA ST1000LM035-1RK1 (scsi)
Disk /dev/sda: 1000GB
Sector size (logical/physical): 512B/4096B
Partition Table: gpt
Disk Flags: 

Number  Start   End     Size    File system     Name                          Flags
 1      1049kB  274MB   273MB   fat32           EFI system partition          boot, esp
 2      274MB   290MB   16.8MB                  Microsoft reserved partition  msftres
 3      290MB   488GB   488GB   ntfs            Basic data partition          msftdata
 6      488GB   960GB   472GB   ext4
 7      960GB   972GB   12.2GB  linux-swap(v1)
 4      972GB   999GB   26.8GB  ntfs            Basic data partition          msftdata
 5      999GB   1000GB  1049MB  ntfs            Basic data partition          hidden, diag
efibootmgr -v

Code: Select all

BootCurrent: 0002
Timeout: 2 seconds
BootOrder: 0002,0000,0014,0015,0016,0017,0018,0019,001A,001B
Boot0000* Windows Boot Manager	HD(1,GPT,413549c5-b356-4cd4-977e-fd683e8c3ca5,0x800,0x82000)/File(\EFI\Microsoft\Boot\bootmgfw.efi)WINDOWS.........x...B.C.D.O.B.J.E.C.T.=.{.9.d.e.a.8.6.2.c.-.5.c.d.d.-.4.e.7.0.-.a.c.c.1.-.f.3.2.b.3.4.4.d.4.7.9.5.}....................
Boot0002* debian	HD(1,GPT,413549c5-b356-4cd4-977e-fd683e8c3ca5,0x800,0x82000)/File(\EFI\debian\grubx64.efi)
Boot0010  Setup	FvFile(721c8b66-426c-4e86-8e99-3457c46ab0b9)
Boot0011  Boot Menu	FvFile(86488440-41bb-42c7-93ac-450fbf7766bf)
Boot0012  Diagnostic Splash	FvFile(a7d8d9a6-6ab0-4aeb-ad9d-163e59a7a380)
Boot0013  OilDiagApp	FvFile(f8397897-e203-4a62-b977-9e7e5d94d91b)
Boot0014* ATA HDD: ST1000LM035-1RK172                      	PciRoot(0x0)/Pci(0x11,0x0)/Sata(0,0,0)..bYVD.A...O.*..
Boot0015* ATA HDD1:	VenMsg(bc7838d2-0f82-4d60-8316-c068ee79d25b,91af625956449f41a7b91f4f892ab0f601)
Boot0016* ATAPI CD:	VenMsg(bc7838d2-0f82-4d60-8316-c068ee79d25b,aea2090adfde214e8b3a5e471856a354)
Boot0017* USB HDD:	VenMsg(bc7838d2-0f82-4d60-8316-c068ee79d25b,33e821aaaf33bc4789bd419f88c50803)
Boot0018* PCI LAN: Realtek PXE B02 D00	BBS(Network,Realtek PXE B02 D00,0x0)............................................................................A.....................
Boot0019* USB FDD:	VenMsg(bc7838d2-0f82-4d60-8316-c068ee79d25b,6ff015a28830b543a8b8641009461e49)
Boot001A* USB CD:	VenMsg(bc7838d2-0f82-4d60-8316-c068ee79d25b,86701296aa5a7848b66cd49dd3ba6a55)
Boot001B* NVMe:	VenMsg(bc7838d2-0f82-4d60-8316-c068ee79d25b,001c199932d94c4eae9aa0b6e98eb8a4)

Wheelerof4te
Posts: 1454
Joined: 2015-08-30 20:14

Re: Dual boot Windows 10

#8 Post by Wheelerof4te »

Code: Select all

apt install grub-pc
update-grub
You somehow didn't install grub.

Chrisdb
Posts: 279
Joined: 2018-04-10 07:16

Re: Dual boot Windows 10

#9 Post by Chrisdb »

Wheelerof4te wrote:

Code: Select all

apt install grub-pc
update-grub
You somehow didn't install grub.
I did like you said, but when I change to EFI boot instead of Legacy, still the same problem

Btw the message I got when installing grub-pc was:
removing "grub-efi-amd64"....

Is grub-pc only for i386?
I'm running on 64bit

Wheelerof4te
Posts: 1454
Joined: 2015-08-30 20:14

Re: Dual boot Windows 10

#10 Post by Wheelerof4te »

I see.
Have you run

Code: Select all

update-grub
?
Also,

Code: Select all

grub-install /dev/sda
You need grub-efi.

User avatar
Head_on_a_Stick
Posts: 14114
Joined: 2014-06-01 17:46
Location: London, England
Has thanked: 81 times
Been thanked: 132 times

Re: Dual boot Windows 10

#11 Post by Head_on_a_Stick »

Chrisdb wrote:Is grub-pc only for i386?
No, grub-pc is the non-UEFI version of GRUB and it conflicts with grub-efi.

Your system appears to be installed and booting in UEFI mode and cannot be booted in non-UEFI ("Legacy") mode using GRUB because you have a GUID partition table on your hard drive but it lacks the BIOS boot partition that is needed to hold GRUB's second stage.
deadbang

Chrisdb
Posts: 279
Joined: 2018-04-10 07:16

Re: Dual boot Windows 10

#12 Post by Chrisdb »

Head_on_a_Stick wrote:
Chrisdb wrote:Is grub-pc only for i386?
No, grub-pc is the non-UEFI version of GRUB and it conflicts with grub-efi.

Your system appears to be installed and booting in UEFI mode and cannot be booted in non-UEFI ("Legacy") mode using GRUB because you have a GUID partition table on your hard drive but it lacks the BIOS boot partition that is needed to hold GRUB's second stage.
I'm not sure I understand correctly.

I have an UEFI based system and I installed Debian in this mode.
After installation, when I try to boot into Debian, the system is suspended, but when I enable legacy mode, debian is booted correctly.

It is because I do not understand what you're trying to say, but why do I need a BIOS partition when I should run in UEFI mode?

User avatar
Head_on_a_Stick
Posts: 14114
Joined: 2014-06-01 17:46
Location: London, England
Has thanked: 81 times
Been thanked: 132 times

Re: Dual boot Windows 10

#13 Post by Head_on_a_Stick »

Chrisdb wrote:when I enable legacy mode, debian is booted correctly
Does the `efibootmgr` command work after you have booted in "Legacy" mode?
deadbang

User avatar
Head_on_a_Stick
Posts: 14114
Joined: 2014-06-01 17:46
Location: London, England
Has thanked: 81 times
Been thanked: 132 times

Re: Dual boot Windows 10

#14 Post by Head_on_a_Stick »

Chrisdb wrote:why do I need a BIOS partition when I should run in UEFI mode?
You don't.

A BIOS boot partition is needed by GRUB to start a non-UEFI system on a GPT disk:

https://en.wikipedia.org/wiki/BIOS_boot ... onents.svg

As you do not have such a partition then you cannot be booting in non-UEFI mode with GRUB.
deadbang

User avatar
sunrat
Administrator
Administrator
Posts: 6412
Joined: 2006-08-29 09:12
Location: Melbourne, Australia
Has thanked: 116 times
Been thanked: 462 times

Re: Dual boot Windows 10

#15 Post by sunrat »

You said Debian starts but goes to a blank screen. Maybe you have a graphics problem rather than a grub problem. Once you manage to get back to having Debian boot with grub-efi, try adding "nomodeset" to the grub kernel line. You may get a basic graphical interface from where you can set up your graphics properly.
“ computer users can be divided into 2 categories:
Those who have lost data
...and those who have not lost data YET ”
Remember to BACKUP!

Chrisdb
Posts: 279
Joined: 2018-04-10 07:16

Re: Dual boot Windows 10

#16 Post by Chrisdb »

Head_on_a_Stick wrote:
Chrisdb wrote:why do I need a BIOS partition when I should run in UEFI mode?
You don't.

A BIOS boot partition is needed by GRUB to start a non-UEFI system on a GPT disk:

https://en.wikipedia.org/wiki/BIOS_boot ... onents.svg

As you do not have such a partition then you cannot be booting in non-UEFI mode with GRUB.
So what is the best approach to do this?
sunrat wrote:You said Debian starts but goes to a blank screen. Maybe you have a graphics problem rather than a grub problem. Once you manage to get back to having Debian boot with grub-efi, try adding "nomodeset" to the grub kernel line. You may get a basic graphical interface from where you can set up your graphics properly.
But it works in legacy mode without problems

User avatar
Head_on_a_Stick
Posts: 14114
Joined: 2014-06-01 17:46
Location: London, England
Has thanked: 81 times
Been thanked: 132 times

Re: Dual boot Windows 10

#17 Post by Head_on_a_Stick »

Head_on_a_Stick wrote:Does the `efibootmgr` command work after you have booted in "Legacy" mode?
^ Please answer this question.

I think that perhaps you are in fact booted in UEFI mode even though you have selected "Legacy" mode — UEFI firmware is absolute rubbish in my experience so perhaps that knob is broken on your machine.

Otherwise you must be booting by some other method (which seems highly unlikely) but I have no idea why the boot would succeed with "Legacy" mode enabled but not otherwise :?

The only thing I can suggest is to attempt to re-install the bootloader:

https://wiki.debian.org/GrubEFIReinstall

@p.H, any ideas?
deadbang

Chrisdb
Posts: 279
Joined: 2018-04-10 07:16

Re: Dual boot Windows 10

#18 Post by Chrisdb »

Head_on_a_Stick wrote:
Head_on_a_Stick wrote:Does the `efibootmgr` command work after you have booted in "Legacy" mode?
^ Please answer this question.

I think that perhaps you are in fact booted in UEFI mode even though you have selected "Legacy" mode — UEFI firmware is absolute rubbish in my experience so perhaps that knob is broken on your machine.

Otherwise you must be booting by some other method (which seems highly unlikely) but I have no idea why the boot would succeed with "Legacy" mode enabled but not otherwise :?

The only thing I can suggest is to attempt to re-install the bootloader:

https://wiki.debian.org/GrubEFIReinstall

@p.H, any ideas?
Yep efibootmgr works

User avatar
Head_on_a_Stick
Posts: 14114
Joined: 2014-06-01 17:46
Location: London, England
Has thanked: 81 times
Been thanked: 132 times

Re: Dual boot Windows 10

#19 Post by Head_on_a_Stick »

^ In which case you are booted in UEFI mode and your firmware is a POS :mrgreen:

Leave "Legacy" mode enabled and forget about it.
deadbang

Chrisdb
Posts: 279
Joined: 2018-04-10 07:16

Re: Dual boot Windows 10

#20 Post by Chrisdb »

I was thinking the same thing :D

Just one last question, when I try to power off or reboot, I get a black screen and it takes a while before
the shutdown actually happens.

Could this be related to the efi mode?

Post Reply