Hyper-V Gen 2
|
2017-05-25, 17:40
Post: #1
|
|||
|
|||
Hyper-V Gen 2
Hello guys, long time no posting.
We have a new bug/issue that needs some pretty strong help. We've determined the cause was introduced in: https://github.com/ipxe/ipxe/commit/a0f6...d9663f5269 And made more difficult to patch with: https://github.com/ipxe/ipxe/commit/276d...d5a93b20d6 By reverting the changes in these two commits, Gen 2 Hyper-V systems are able to boot. I don't know if it's a big problem to correct for, or if simply reverting will be the best bet. I suspect the problem is specific to the lack of the return -EBUSY statement as that's all that changed in a0f6e7. |
|||
2017-05-26, 10:59
Post: #2
|
|||
|
|||
RE: Hyper-V Gen 2
(2017-05-25 17:40)mastacontrola Wrote: We've determined the cause was introduced in: Those patches cannot simply be reverted. hv_map_hypercall() and hv_map_synic() are now used on the hv_unquiesce() path, and we rely on hv_map_hypercall() accepting a situation in which the guest OS ID MSR is already non-zero in order to recover from having our network connection dropped in the middle of an iSCSI boot: http://git.ipxe.org/ipxe.git/commitdiff/b91cc98. How are you starting iPXE within your Gen 2 VM? Michael |
|||
2017-05-26, 12:23
(This post was last modified: 2017-05-26 12:24 by mastacontrola.)
Post: #3
|
|||
|
|||
RE: Hyper-V Gen 2
(2017-05-26 10:59)mcb30 Wrote:(2017-05-25 17:40)mastacontrola Wrote: We've determined the cause was introduced in: All we're doing is our normal boot processes. It works for Gen 1 Hyper-V (as far as I know) for UEFI/EFI booting on. We build the boot system fairly dynamically via a php script. A task boot script would like like: Code: #!ipxe |
|||
2017-05-26, 13:38
Post: #4
|
|||
|
|||
RE: Hyper-V Gen 2
(2017-05-26 12:23)mastacontrola Wrote: All we're doing is our normal boot processes. It works for Gen 1 Hyper-V (as far as I know) for UEFI/EFI booting on. We build the boot system fairly dynamically via a php script. Sorry; I wasn't clear. I meant to ask how you are loading the iPXE binary itself. Are you using a bootable disk image, bootable ISO image, chainloading, ...? Michael |
|||
2017-05-27, 01:35
Post: #5
|
|||
|
|||
RE: Hyper-V Gen 2
(2017-05-26 13:38)mcb30 Wrote:(2017-05-26 12:23)mastacontrola Wrote: All we're doing is our normal boot processes. It works for Gen 1 Hyper-V (as far as I know) for UEFI/EFI booting on. We build the boot system fairly dynamically via a php script. My bad too, it's normally loaded via pxe boot. So UEFI PXE Boot requests ipxe.efi in this particular case. I don't know if you would call that chainloading, persay though I guess I can't say it's "not" chainloading. |
|||
2017-05-31, 18:00
Post: #6
|
|||
|
|||
RE: Hyper-V Gen 2
So my reversions, from what i can tell, didn't impact any functionality, it just made it so the functions returned as int's and used the values returned to perform the same feats as earlier. I didn't change large segments of code.
Can you explain, more directly, what the repercussions of the reversions I made had on the whole process? Of note: here's the exact diff: Code: --- a/src/arch/x86/drivers/hyperv/hyperv.c I did not do a full on code reversion, just updated things to try to get them functional again. It would seem the -EBUSY was needed, in my head. I did not lose the functionality of the calls, just reintegrated what was removed. And this seems to work, even with the head state, where without these things it seems to not work for Hyper-V Gen 2. I don't have Hyper-V VM's so I'm not a good test subject, but I know people who can get us information as needed. |
|||
2017-05-31, 18:05
Post: #7
|
|||
|
|||
RE: Hyper-V Gen 2
(2017-05-31 18:00)mastacontrola Wrote: Can you explain, more directly, what the repercussions of the reversions I made had on the whole process? It introduces a potential unhandled failure case into the recovery path used to restore the VMBus connection when booting Windows Server 2016 via iSCSI. Michael |
|||
2017-05-31, 18:48
Post: #8
|
|||
|
|||
RE: Hyper-V Gen 2
(2017-05-31 18:05)mcb30 Wrote:(2017-05-31 18:00)mastacontrola Wrote: Can you explain, more directly, what the repercussions of the reversions I made had on the whole process? So while not optimal, our stuff is usually used to boot into an embedded linux OS for the purposes imaging (capturing and/or deploying). From "FOG's" perspective this has limited potential problem. For those who customize their ipxe menu they would need to be made aware of the problem here. What I can say, leaving out the "return -EBUSY" is what seems to have been the "breaking" point of the problem. It doesn't make sense to me why. Any suggestions you might have so I can more appropriately and generically fix what might be causing it? The only reason I reverted those potential files is because they were side by side and the "least" effort involved to correct the problems. The only reason I had to do the second file reversion is so I could have the return -EBUSY and successfully build. |
|||
2017-06-08, 13:57
Post: #9
|
|||
|
|||
RE: Hyper-V Gen 2
Hello there.
I am meeting the same problem. I found Hyper-V VMM watchdog timeout Error log. It seems that this error is caused by efix86_cpu_nap() in src/arch/x86/interface/efi/efix86_nap.c(by printf debugging!). Code: <Event xmlns="http://schemas.microsoft.com/win/2004/08/events/event"> |
|||
2017-06-13, 14:45
Post: #10
|
|||
|
|||
RE: Hyper-V Gen 2
Is there anything we can do to try to correct the problems? Any other information we need to provide?
|
|||
2017-07-25, 16:35
Post: #11
|
|||
|
|||
RE: Hyper-V Gen 2
It seems that this issue also matches what Clemlar reported on IRC
Using Gen 2 machine current code just caused reboot almost immediately after iPXE banner Using parent of a0f6e75 it supposedly works. Maybe building with DEBUG=hyperv:3 and comparing output between working and non working might shed some light on best way to fix this? (will update if I get more info on IRC) Use GitHub Discussions VRAM bin |
|||
2017-07-27, 10:58
Post: #12
|
|||
|
|||
RE: Hyper-V Gen 2
For now the recommendation is to use snponly.efi when using Hyper-V Gen 2
From mcb30: What is needed for proper fix is to find which EFI device that represents ownership of VMbus and have iPXE take ownership instead. Use GitHub Discussions VRAM bin |
|||
2017-07-28, 21:32
Post: #13
|
|||
|
|||
RE: Hyper-V Gen 2 | |||
2017-07-31, 00:25
Post: #14
|
|||
|
|||
RE: Hyper-V Gen 2
(2017-07-28 21:32)mcb30 Wrote: There is now a workaround in place: http://git.ipxe.org/ipxe.git/commitdiff/9366578. Building after resetting my changes to allow me to keep up to date. Will have people test and report back. Thank you for getting back and letting us know. |
|||
« Next Oldest | Next Newest »
|
User(s) browsing this thread: 2 Guest(s)