You are not logged in.

#1 2016-09-20 10:42:19

Pazuzu
Member
Registered: 2016-09-20
Posts: 4

Issues with Sony VAIO UEFI boot/dual booting Arch and Windows 10

I run a dual boot setup with Arch and Windows 10, and I use systemd-boot as a boot manager. At first, I had trouble getting into systemd-boot, as the UEFI implementation of Sony VAIO SVS1513C5E boots bootmgfw.efi, regardless of any configuration. The dual boot tips on the installation guide did not work for me. My solution so far has been this:

  • Setup systemd-boot in efibootmgr

  • Move bootmgfw.efi to bootmgfw.nonono.efi

  • Put a Windows 10 entry into the systemd-boot loader entries pointing to bootmgfw.nonono.efi

This setup has been working for me, apart from one major issue. When I boot into Windows and it runs an update, it restores the original bootmgfw.efi file, which my laptop then boots. I usually fix it by booting the Arch ISO from a USB drive, mounting my boot partition and move the bootmgfw.efi again.

This process seems to be far from optimal. Is there a better way to deal with the improper UEFI implementation and get dual boot without moving files around? Could I prevent updates to the boot file system from Windows? Hints on how to solve these dual boot issues once and for all are much appreciated!

This is my first post, if you would like some system or configuration info, please ask, as I am not sure on what to include here.
Cheers,
Pazuzu

Offline

#2 2016-09-20 11:09:54

Slithery
Administrator
From: Norfolk, UK
Registered: 2013-12-01
Posts: 5,776

Re: Issues with Sony VAIO UEFI boot/dual booting Arch and Windows 10


No, it didn't "fix" anything. It just shifted the brokeness one space to the right. - jasonwryan
Closing -- for deletion; Banning -- for muppetry. - jasonwryan

aur - dotfiles

Offline

#3 2016-09-20 12:38:36

olive
Member
From: Belgium
Registered: 2008-06-22
Posts: 1,490

Re: Issues with Sony VAIO UEFI boot/dual booting Arch and Windows 10

All solutions mentioning bootsec or mentioning a bootsector or an MBR will not work (this is for Bios, not UEFI). It is difficult to answer because we do not know exactly what your UEFI supports. The archlinux wiki mention a possibility to convince Windows to launch another UEFI application, but I have not tested it and I doubt it, it seems only to be a possibility to change the efi firmware entry from Windows: https://wiki.archlinux.org/index.php/Un … boot_order

I would try some dirty tricks. What happens if you put two UEFI partition? Can you boot an UEFI shell from your motherboard? (you can use it to boot something other automatically via startup.nsh, for example). Do your motherboard absolutely refuse to boot something different from bootmgfw? I remember a motherboard (in a Packard Bell laptop) that has an entry to boot the "hard disk" (which means to respect the normal UEFI procedure) or Windows that it considers as a special entry and is automatically added. Windows was the default but it was possible to change that to be the "hard disk". So double check your UEFI settings to see what is available.

Last edited by olive (2016-09-20 12:51:01)

Offline

#4 2016-09-20 13:30:52

Pazuzu
Member
Registered: 2016-09-20
Posts: 4

Re: Issues with Sony VAIO UEFI boot/dual booting Arch and Windows 10

olive wrote:

It is difficult to answer because we do not know exactly what your UEFI supports.

I'm not sure how to find that out. I can give you my efivars if that helps.

AcpiGlobalVariable
ActiveVgaDev
AuthVarKeyDatabase
BackupPlatformLang
Boot0000
Boot0001
Boot0002
Boot0003
BootCurrent
BootOrder
BootPrevious
BootPreviousData
BugCheckCode
BugCheckParameter1
BugCheckProgress
ConIn
ConInCandidateDev
ConInDev
ConOut
ConOutCandidateDev
ConOutDev
Custom
CustomSecurity
db
dbx
DDR3LVoltageVariable
ErrOutDev
iFfsData
IrsiInfo
KEK
Lang
LoaderDevicePartUUID
LoaderEntrySelected
LoaderFirmwareInfo
LoaderFirmwareType
LoaderImageIdentifier
LoaderInfo
LoaderTimeExecUSec
LoaderTimeInitUSec
LoaderTimeMenuUSec
MeBiosExtensionSetup
MemoryOverwriteRequestControl
MrcS3RestoreVariable
MTC
OsIndications
OsIndicationsSupported
PBRDevicePath
PBRDevicePath
PchInit
PchS3Peim
PhysicalBootOrder
PhysicalPresenceInterfaceControl
PK
PlatformConfigurationVariable
PlatformLang
PlatformLangCodes
PowerOnPassword
RestoreFactoryDefault
S3RestoreDataVariable
SaPegData
SecureBoot
SecureBootEnforce
SecureFlashInfo
Setup
SetupMode
SignatureSupport
SmbiosPolicy
SpdData
SRID
SwitchableGraphicsVariable
Timeout
VBiosInfo
olive wrote:

The archlinux wiki mention a possibility to convince Windows to launch another UEFI application, but I have not tested it and I doubt it, it seems only to be a possibility to change the efi firmware entry from Windows: https://wiki.archlinux.org/index.php/Un … boot_order

I have tried what is mentioned under this section, sadly nothing helped.


olive wrote:

I would try some dirty tricks. What happens if you put two UEFI partition?

Wouldn't UEFI just concatenate the entries? I think windows would still be able to write /EFI/Microsoft/Boot, even if it is spread out over multiple partitions. Renaming the bootmgfw.efi is in my opinion a dirty trick already. I'm considering of replacing the bootmgfw.efi with systemd-boot's bootx64.efi. Maybe Windows will not perform a sanity check on the file and won't overwrite systemd-boot.

olive wrote:

Can you boot an UEFI shell from your motherboard? (you can use it to boot something other automatically via startup.nsh, for example). Do your motherboard absolutely refuse to boot something different from bootmgfw? I remember a motherboard (in a Packard Bell laptop) that has an entry to boot the "hard disk" (which means to respect the normal UEFI procedure) or Windows that it considers as a special entry and is automatically added. Windows was the default but it was possible to change that to be the "hard disk". So double check your UEFI settings to see what is available.

I can switch between BIOS boot and UEFI boot, that is all. The laptop's own UEFI interface lets me choose between Windows recovery tools, BIOS setup, booting from USB device and restart/poweroff etc. options, but no way to select a harddisk to boot or UEFI entries that written into the variables. I do not have a UEFI shell on the device itself. The bootmgfw.efi is only booted if it is present. The current bootx64.efi is overwritten by systemd-boot, it launches without a problem. If the bootmgfw.efi is present, my settings are overwritten.

Offline

#5 2016-09-20 13:45:43

olive
Member
From: Belgium
Registered: 2008-06-22
Posts: 1,490

Re: Issues with Sony VAIO UEFI boot/dual booting Arch and Windows 10

I don't think Windows do a sanity check, it only "updates" the files bootx64.efi and bootmgfw.efi and the problem will likely remain if you replace these files by something else. Have you properly run the efibootmgr from linux? What is its output? Have you properly check all options you have in the "Bios" setup (not only the entries you have in the boot menu)?

Since you can switch between Bios and UEFI maybe you can install Archlinux in Bios mode (with syslinux, it has no problem with GPT partitions) and select that when you want to boot Linux. You will have no real advantage in using UEFI in Linux (it is not used once the system is booted).

Last edited by olive (2016-09-20 13:46:05)

Offline

#6 2016-09-20 14:35:43

Pazuzu
Member
Registered: 2016-09-20
Posts: 4

Re: Issues with Sony VAIO UEFI boot/dual booting Arch and Windows 10

So far, Windows has only recreated the bootmgfw.efi file when updating. Throughout the updates, bootx64.efi has been untouched so far, it still is the original systemd-boot efi. My dual boot has been working fine between Windows updates. This is what leads me to the conclusion that Windows might not replace bootmgfw.efi, if there is one already present.

I have checked all the settings I have in the BIOS setup, but there is nothing aside from UEFI/BIOS boot and secure boot options. I do not even have a proper boot menu, I can only choose to boot from an USB device, not even select which one if there is multiple plugged in. I have tried setting up Arch in MBR, I did not have any success in getting it to boot my media at all. I did format the drives and flash the Arch ISO in numerous ways, not changing the outcome. The only response I got was 'No Operating System', even with selection of a proper boot order for BIOS boot.

The efibootmgr has following output at the moment, it is rewritten on Windows updates:

BootCurrent: 0000
Timeout: 0 seconds
BootOrder: 0000,2001
Boot0000* EFI HDD Device (Samsung SSD 850 PRO 512GB)	PciRoot(0x0)/Pci(0x1f,0x2)/Sata(0,0,0)/HD(2,GPT,4683bb66-a598-457c-9e52-f2e4e3617d0f,0xe1800,0x32000)RC
Boot0001* Windows Boot Manager	HD(2,GPT,4683bb66-a598-457c-9e52-f2e4e3617d0f,0xe1800,0x32000)/File(\EFI\Microsoft\Boot\bootmgfw.efi)RC
Boot0002* EFI USB Device (TOSHIBA TransMemory)	PciRoot(0x0)/Pci(0x1d,0x0)/USB(0,0)/USB(1,0)/HD(1,GPT,fe2ba533-188c-4949-b836-240d3e5abaad,0x800,0x1ce445f)RC
Boot0003* Linux Boot Manager	HD(2,GPT,4683bb66-a598-457c-9e52-f2e4e3617d0f,0xe1800,0x32000)/File(\EFI\systemd\systemd-bootx64.efi)

I tried setting it up properly, cleaning it up, deleting Windows Boot Manager entries, setting the boot order properly, but as long as bootmgfw.efi is present, it is booted. I tried setting systemd-boot via BootNext, but that was also disregarded, and Windows booted. It was actually very frustrating to see the rotating dots show up under the VAIO logo.

The most promising way right now seems to be keeping a systemd-boot copy, renamed to bootmgfw.efi, in the Windows boot folder, hoping that Windows won't override it when it updates.

Offline

#7 2016-09-20 18:16:59

Head_on_a_Stick
Member
From: London
Registered: 2014-02-20
Posts: 7,732
Website

Re: Issues with Sony VAIO UEFI boot/dual booting Arch and Windows 10

Pazuzu wrote:
olive wrote:

The archlinux wiki mention a possibility to convince Windows to launch another UEFI application, but I have not tested it and I doubt it, it seems only to be a possibility to change the efi firmware entry from Windows: https://wiki.archlinux.org/index.php/Un … boot_order

I have tried what is mentioned under this section, sadly nothing helped.

What was the *exact* command that you used in Windows?

Offline

#8 2016-09-20 22:20:31

Pazuzu
Member
Registered: 2016-09-20
Posts: 4

Re: Issues with Sony VAIO UEFI boot/dual booting Arch and Windows 10

Head_on_a_Stick wrote:
Pazuzu wrote:
olive wrote:

The archlinux wiki mention a possibility to convince Windows to launch another UEFI application, but I have not tested it and I doubt it, it seems only to be a possibility to change the efi firmware entry from Windows: https://wiki.archlinux.org/index.php/Un … boot_order

I have tried what is mentioned under this section, sadly nothing helped.

What was the *exact* command that you used in Windows?

I followed the hints that are given in your link. Here's two commands I launched, all under administrator command line.

bcdedit \set {bootmgr} path \EFI\systemd\systemd-bootx64.efi
bcdedit \set {bootmgr} path \EFI\Boot\bootx64.efi

I also tried the alternative variant from the guide, with the appropriate boot entry identities inserted, according to the bcdedit enumeration. It's not explicitly said in the guide, but I also did not change the device with \set {...} device, since all my EFI apps reside on the same partition as the original boot manager, I'll add my ESP's content below. After playing around with some options and looking through some bcdedit options, which led to no success, I've also consulted some BCD editors that have been recommended in other dual boot contexts, same result here.

ls -R /boot
---------------------------------------------------------------------
/boot:
EFI
initramfs-linux-fallback.img
initramfs-linux.img
intel-ucode.img
loader
vmlinuz-linux

/boot/EFI:
Boot
Microsoft
systemd

/boot/EFI/Boot:
bootx64.efi

/boot/EFI/Microsoft:
Boot
Recovery

/boot/EFI/Microsoft/Boot:
BCD
BCD.LOG
BCD.LOG1
BCD.LOG2
bootmgfw.nonono.efi
bootmgr.efi
BOOTSTAT.DAT
boot.stl
cs-CZ
da-DK
de-DE
el-GR
en-US
es-ES
fi-FI
Fonts
fr-FR
hu-HU
it-IT
ja-JP
kd_02_10df.dll
kd_02_10ec.dll
kd_02_1137.dll
kd_02_14e4.dll
kd_02_15b3.dll
kd_02_1969.dll
kd_02_19a2.dll
kd_02_8086.dll
kd_07_1415.dll
kd_0C_8086.dll
kdstub.dll
ko-KR
memtest.efi
nb-NO
nl-NL
pl-PL
pt-BR
pt-PT
qps-ploc
Resources
ru-RU
sr-Latn-CS
sv-SE
tr-TR
zh-CN
zh-HK
zh-TW

/boot/EFI/Microsoft/Boot/cs-CZ:
memtest.efi.mui

/boot/EFI/Microsoft/Boot/da-DK:
memtest.efi.mui

/boot/EFI/Microsoft/Boot/de-DE:
memtest.efi.mui

/boot/EFI/Microsoft/Boot/el-GR:
memtest.efi.mui

/boot/EFI/Microsoft/Boot/en-US:
bootmgfw.efi.mui
bootmgr.efi.mui
memtest.efi.mui

/boot/EFI/Microsoft/Boot/es-ES:
memtest.efi.mui

/boot/EFI/Microsoft/Boot/fi-FI:
memtest.efi.mui

/boot/EFI/Microsoft/Boot/Fonts:
chs_boot.ttf
cht_boot.ttf
jpn_boot.ttf
kor_boot.ttf
malgun_boot.ttf
malgunn_boot.ttf
meiryo_boot.ttf
meiryon_boot.ttf
msjh_boot.ttf
msjhn_boot.ttf
msyh_boot.ttf
msyhn_boot.ttf
segmono_boot.ttf
segoen_slboot.ttf
segoe_slboot.ttf
wgl4_boot.ttf

/boot/EFI/Microsoft/Boot/fr-FR:
memtest.efi.mui

/boot/EFI/Microsoft/Boot/hu-HU:
memtest.efi.mui

/boot/EFI/Microsoft/Boot/it-IT:
memtest.efi.mui

/boot/EFI/Microsoft/Boot/ja-JP:
memtest.efi.mui

/boot/EFI/Microsoft/Boot/ko-KR:
memtest.efi.mui

/boot/EFI/Microsoft/Boot/nb-NO:
memtest.efi.mui

/boot/EFI/Microsoft/Boot/nl-NL:
memtest.efi.mui

/boot/EFI/Microsoft/Boot/pl-PL:
memtest.efi.mui

/boot/EFI/Microsoft/Boot/pt-BR:
memtest.efi.mui

/boot/EFI/Microsoft/Boot/pt-PT:
memtest.efi.mui

/boot/EFI/Microsoft/Boot/qps-ploc:
memtest.efi.mui

/boot/EFI/Microsoft/Boot/Resources:
bootres.dll
en-US

/boot/EFI/Microsoft/Boot/Resources/en-US:
bootres.dll.mui

/boot/EFI/Microsoft/Boot/ru-RU:
memtest.efi.mui

/boot/EFI/Microsoft/Boot/sr-Latn-CS:
memtest.efi.mui

/boot/EFI/Microsoft/Boot/sv-SE:
memtest.efi.mui

/boot/EFI/Microsoft/Boot/tr-TR:
memtest.efi.mui

/boot/EFI/Microsoft/Boot/zh-CN:
memtest.efi.mui

/boot/EFI/Microsoft/Boot/zh-HK:
memtest.efi.mui

/boot/EFI/Microsoft/Boot/zh-TW:
memtest.efi.mui

/boot/EFI/Microsoft/Recovery:
BCD
BCD.LOG
BCD.LOG1
BCD.LOG2

/boot/EFI/systemd:
systemd-bootx64.efi

/boot/loader:
entries
loader.conf

/boot/loader/entries:
arch.conf
win.conf

Offline

Board footer

Powered by FluxBB