Ubuntu UEFI boot with disk encryption

Discussions about using Linux guests in VirtualBox.
Post Reply
jay73910
Posts: 5
Joined: 16. Mar 2016, 16:04

Ubuntu UEFI boot with disk encryption

Post by jay73910 »

Hi. I'm having problems booting normally into my Ubuntu guest system using the EFI mode. I'm using EFI for testing purposes, and managed to install it after a few hiccups, and edit the startup.nsh file. During installation, I chose the Ubuntu disk encryption option. This now seems to be causing some issues with the EFI boot.

When it gets to the decrypt password entry, VB doesn't register my key strokes at all. Nothing is entered in the decrypt password box.

The way I've managed to get around this is by shutting down the Guest system with a power off, which means the next time I boot I'm given the option of an advanced boot (because I guess Ubuntu thinks the power was pulled and there could be a problem). I can then boot using the recovery mode, and am presented with the command line boot. Then, when I am asked to decrypt the disk using the password, my key entry is registered by the CLI, and I can then proceed with a normal boot at the recovery mode window.

So is there a reason VB isn't getting my keystrokes to the EFI GUI? Any help would be appreciated
Last edited by jay73910 on 16. Mar 2016, 16:40, edited 2 times in total.
Perryg
Site Moderator
Posts: 34369
Joined: 6. Sep 2008, 22:55
Primary OS: Linux other
VBox Version: OSE self-compiled
Guest OSses: *NIX

Re: Ubuntu UEFI boot with disk encryption

Post by Perryg »

Post the guests log file ( as an attachment ). Right click on the guest in the Main Manager then click show log. Save and post as an attachment. Compress if it is too large to post.
jay73910
Posts: 5
Joined: 16. Mar 2016, 16:04

Re: Ubuntu UEFI boot with disk encryption

Post by jay73910 »

Here you go
Attachments
Ubuntu-2016-03-16-15-43-53.log
(79.85 KiB) Downloaded 24 times
Perryg
Site Moderator
Posts: 34369
Joined: 6. Sep 2008, 22:55
Primary OS: Linux other
VBox Version: OSE self-compiled
Guest OSses: *NIX

Re: Ubuntu UEFI boot with disk encryption

Post by Perryg »

I just did a fresh install of Ubuntu 14.04 with EFI enabled plus encryption during the install which went flawlessly, including reboot, and normal system shut down, so it should work for you. What version of Ubuntu are you installing?
jay73910
Posts: 5
Joined: 16. Mar 2016, 16:04

Re: Ubuntu UEFI boot with disk encryption

Post by jay73910 »

Perryg wrote:I just did a fresh install of Ubuntu 14.04 with EFI enabled plus encryption during the install which went flawlessly, including reboot, and normal system shut down, so it should work for you. What version of Ubuntu are you installing?
Ah...this could be the problem. I'm testing out 16.04.
Interesting yours has no problem then. Thought it had something to do with the VB side of things
Perryg
Site Moderator
Posts: 34369
Joined: 6. Sep 2008, 22:55
Primary OS: Linux other
VBox Version: OSE self-compiled
Guest OSses: *NIX

Re: Ubuntu UEFI boot with disk encryption

Post by Perryg »

Not normally but anything can happen. I will try 16.04 in a bit but that OS is not really supported yet as it has not been released and the packages are being replaced daily. I would think that the most probable cause would be OS at this point.
jay73910
Posts: 5
Joined: 16. Mar 2016, 16:04

Re: Ubuntu UEFI boot with disk encryption

Post by jay73910 »

Perryg wrote:Not normally but anything can happen. I will try 16.04 in a bit but that OS is not really supported yet as it has not been released and the packages are being replaced daily. I would think that the most probable cause would be OS at this point.
OK. Yes, I knew that there could be some instability with using the 16.04 daily build, but I thought that perhaps I would encounter such problems after I'd booted, hence why I thought it was due to VB.

Thanks for your help though. Is there any troubleshooting you would advise I try out?
I've tried fiddling with VB's settings (changed between PIIX3 and ICH9 chipsets, and enabling/disabling PAE/NX and all possible combinations of the two - don't know why that would make a difference but gave it a go), but nothings worked thus far.

It's definitely an issue with the EFI, as I installed 16.04 (same build) at the weekend in a VB guest, with encryption enabled, and it worked fine using the normal BIOS boot (as in, my key strokes registered fine when decrypting at boot).
Perryg
Site Moderator
Posts: 34369
Joined: 6. Sep 2008, 22:55
Primary OS: Linux other
VBox Version: OSE self-compiled
Guest OSses: *NIX

Re: Ubuntu UEFI boot with disk encryption

Post by Perryg »

I did try 16.04 and it failed just like you. I suspect there is a combination of issues. One is the newer packages and VirtualBox has not caught up with them yet ( normal practice is to wait until release so you don't have to fix, refix, and refix again ) and also something to consider is the new code where Xorg is not being run with root permission now. A lot comes into play with that. I do not however suspect the EFI code at this point as it seems to be doing its thing.
jay73910
Posts: 5
Joined: 16. Mar 2016, 16:04

Re: Ubuntu UEFI boot with disk encryption

Post by jay73910 »

Perryg wrote:I did try 16.04 and it failed just like you. I suspect there is a combination of issues. One is the newer packages and VirtualBox has not caught up with them yet ( normal practice is to wait until release so you don't have to fix, refix, and refix again ) and also something to consider is the new code where Xorg is not being run with root permission now. A lot comes into play with that. I do not however suspect the EFI code at this point as it seems to be doing its thing.
Ah OK, very interesting! Thanks for testing it out and getting back to me. I'm glad to know you were able to replicate the issue - at least I know it's not user error now! Yeah, of course, that makes sense - I suppose I'll just wait until the 16.04 official build (not so long to wait now) and come back to see if this gets sorted once VB has caught up with the packages. Security issues aside, do you know if it's possible to give X.Org root privileges on 16.04? Could be worth checking to see if it's the cause?

But I suppose it's probably just easier to wait until VB gets updated post-16.04 release.

Thanks for help and info though, much appreciated :)
Perryg
Site Moderator
Posts: 34369
Joined: 6. Sep 2008, 22:55
Primary OS: Linux other
VBox Version: OSE self-compiled
Guest OSses: *NIX

Re: Ubuntu UEFI boot with disk encryption

Post by Perryg »

Not only easier but more advisable. Running Xorg with root priv., was a security issue and it will be a lot better once they get it sorted out. I know the VBox 5.0.17 ( test build ) of the guest additions address this now and as soon as Ubuntu finishes their work it should all work together.
Post Reply