New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Setting EFI cmdline arguments via efibootmgr is unreliable #2046

Closed
marmarek opened this Issue Jun 5, 2016 · 17 comments

Comments

@marmarek
Member

marmarek commented Jun 5, 2016

Apparently on some machines (Thinkpad W540) setting xen.efi arguments using efibootmgr doesn't have effect. This may be only related issue (for example about handling unicode or so), but still - having to recreate an entry is inconvenient and error-prone.

This is all about an UEFI BIOS bug workaround common on Thinpad systems.

@marmarek marmarek added this to the Release 3.2 milestone Jun 5, 2016

marmarek added a commit to QubesOS/qubes-doc that referenced this issue Jun 7, 2016

@MMihelic

This comment has been minimized.

Show comment
Hide comment
@MMihelic

MMihelic Jun 13, 2016

@marmarek : I am unable to get this feature working. Do you have an updated ISO that I could try?
I've rebuilt the 3.2 ISO from the repository and tried to do a clean install but the parameters in the xen.cfg are not taking effect. I can boot the OS if I add the parameters myself using the rEFInd on a USB drive.

You were right about the missing "placeholder" for the additional Xen parameters during setup. This time I was able to install Qubes directly using ISO.

Hmm... I just realised that I have not verified that this patch was pulled from the repository while building the ISO. I'll double check and let you know the results in the afternoon.

Will these kernel parameters get copied on a new kernel install? Otherwise, the user might end up with an unbootable system after a kernel upgrade. Sometimes in the future, time permitting, it might be wise to add detection of the current boot parameters at the end of the install phase and add or copy these settings automatically to the boot configuration. For instance, if you added more possible boot configurations to the EFI installer boot menu covering the ones with various common EFI boot workarounds like this one, the user could easily pick the boot configuration that works for him. At the end of install phase the script could read the current boot parameters and add the entries to the xen.cfg or to the EFI boot definition. This would work also for manually added boot parameters for the configurations that would not be covered by the known workarounds.

Regards, Matej.

@marmarek : I am unable to get this feature working. Do you have an updated ISO that I could try?
I've rebuilt the 3.2 ISO from the repository and tried to do a clean install but the parameters in the xen.cfg are not taking effect. I can boot the OS if I add the parameters myself using the rEFInd on a USB drive.

You were right about the missing "placeholder" for the additional Xen parameters during setup. This time I was able to install Qubes directly using ISO.

Hmm... I just realised that I have not verified that this patch was pulled from the repository while building the ISO. I'll double check and let you know the results in the afternoon.

Will these kernel parameters get copied on a new kernel install? Otherwise, the user might end up with an unbootable system after a kernel upgrade. Sometimes in the future, time permitting, it might be wise to add detection of the current boot parameters at the end of the install phase and add or copy these settings automatically to the boot configuration. For instance, if you added more possible boot configurations to the EFI installer boot menu covering the ones with various common EFI boot workarounds like this one, the user could easily pick the boot configuration that works for him. At the end of install phase the script could read the current boot parameters and add the entries to the xen.cfg or to the EFI boot definition. This would work also for manually added boot parameters for the configurations that would not be covered by the known workarounds.

Regards, Matej.

@MMihelic

This comment has been minimized.

Show comment
Hide comment
@MMihelic

MMihelic Jun 14, 2016

@marmarek : I can confirm that the procedure works.
I have two questions:

  • Would it work if I just put the new keys in the [global] section? To me it seems that this would be the most appropriate one as it would apply to all entries - of course with optional override, and it would also be kept between kernel installs.
  • Is it possible that the installer would have kept the old xen.efi loader when installing from the Qubes R3.2 ISO? I have a feeling that this is what had happened to me. I had to manually copy the xen-4.6.1.efi over the existing one. I am definitely not certain that this was the case so, take it with a grain of salt!

@marmarek : I can confirm that the procedure works.
I have two questions:

  • Would it work if I just put the new keys in the [global] section? To me it seems that this would be the most appropriate one as it would apply to all entries - of course with optional override, and it would also be kept between kernel installs.
  • Is it possible that the installer would have kept the old xen.efi loader when installing from the Qubes R3.2 ISO? I have a feeling that this is what had happened to me. I had to manually copy the xen-4.6.1.efi over the existing one. I am definitely not certain that this was the case so, take it with a grain of salt!
@marmarek

This comment has been minimized.

Show comment
Hide comment
@marmarek

marmarek Jun 14, 2016

Member

Sometimes in the future, time permitting, it might be wise to add detection of the current boot parameters at the end of the install phase and add or copy these settings automatically to the boot configuration.

This is already done for Linux kernel parameters, but unfortunately EFI xen loader doesn't give this information at runtime, so there is nothing to copy from...

Would it work if I just put the new keys in the [global] section? To me it seems that this would be the most appropriate one as it would apply to all entries - of course with optional override, and it would also be kept between kernel installs.

No, xen.cfg syntax allows only two options in [global] section: default and chain (including other file). Others are ignored...
Anyway parameters should be preserved at kernel upgrade (section for new kernel is created based on default one).

Is it possible that the installer would have kept the old xen.efi loader when installing from the Qubes R3.2 ISO? I have a feeling that this is what had happened to me. I had to manually copy the xen-4.6.1.efi over the existing one. I am definitely not certain that this was the case so, take it with a grain of salt!

There may be a bug like this, haven't checked that. Somehow related (but not exactly the same): #1605
If you could confirm your observation, please open new issue for this.

Member

marmarek commented Jun 14, 2016

Sometimes in the future, time permitting, it might be wise to add detection of the current boot parameters at the end of the install phase and add or copy these settings automatically to the boot configuration.

This is already done for Linux kernel parameters, but unfortunately EFI xen loader doesn't give this information at runtime, so there is nothing to copy from...

Would it work if I just put the new keys in the [global] section? To me it seems that this would be the most appropriate one as it would apply to all entries - of course with optional override, and it would also be kept between kernel installs.

No, xen.cfg syntax allows only two options in [global] section: default and chain (including other file). Others are ignored...
Anyway parameters should be preserved at kernel upgrade (section for new kernel is created based on default one).

Is it possible that the installer would have kept the old xen.efi loader when installing from the Qubes R3.2 ISO? I have a feeling that this is what had happened to me. I had to manually copy the xen-4.6.1.efi over the existing one. I am definitely not certain that this was the case so, take it with a grain of salt!

There may be a bug like this, haven't checked that. Somehow related (but not exactly the same): #1605
If you could confirm your observation, please open new issue for this.

@marmarek

This comment has been minimized.

Show comment
Hide comment
@marmarek

marmarek Jun 25, 2016

Member

Automated announcement from builder-github

The package xen-4.6.1-17.fc21 has been pushed to the r3.1 testing repository for the Fedora fc21 template.
To test this update, please install it with the following command:

sudo yum update --enablerepo=qubes-vm-r3.1-current-testing

Changes included in this update

Member

marmarek commented Jun 25, 2016

Automated announcement from builder-github

The package xen-4.6.1-17.fc21 has been pushed to the r3.1 testing repository for the Fedora fc21 template.
To test this update, please install it with the following command:

sudo yum update --enablerepo=qubes-vm-r3.1-current-testing

Changes included in this update

@marmarek

This comment has been minimized.

Show comment
Hide comment
@marmarek

marmarek Jun 25, 2016

Member

Automated announcement from builder-github

The package xen-4.6.1-17.fc22 has been pushed to the r3.1 testing repository for the Fedora fc22 template.
To test this update, please install it with the following command:

sudo yum update --enablerepo=qubes-vm-r3.1-current-testing

Changes included in this update

Member

marmarek commented Jun 25, 2016

Automated announcement from builder-github

The package xen-4.6.1-17.fc22 has been pushed to the r3.1 testing repository for the Fedora fc22 template.
To test this update, please install it with the following command:

sudo yum update --enablerepo=qubes-vm-r3.1-current-testing

Changes included in this update

@marmarek

This comment has been minimized.

Show comment
Hide comment
@marmarek

marmarek Jun 25, 2016

Member

Automated announcement from builder-github

The package xen-4.6.1-17.fc23 has been pushed to the r3.1 testing repository for the Fedora fc23 template.
To test this update, please install it with the following command:

sudo yum update --enablerepo=qubes-vm-r3.1-current-testing

Changes included in this update

Member

marmarek commented Jun 25, 2016

Automated announcement from builder-github

The package xen-4.6.1-17.fc23 has been pushed to the r3.1 testing repository for the Fedora fc23 template.
To test this update, please install it with the following command:

sudo yum update --enablerepo=qubes-vm-r3.1-current-testing

Changes included in this update

@marmarek

This comment has been minimized.

Show comment
Hide comment
@marmarek

marmarek Jun 25, 2016

Member

Automated announcement from builder-github

The package xen-4.6.1-17.fc20 has been pushed to the r3.1 testing repository for dom0.
To test this update, please install it with the following command:

sudo qubes-dom0-update --enablerepo=qubes-dom0-current-testing

Changes included in this update

Member

marmarek commented Jun 25, 2016

Automated announcement from builder-github

The package xen-4.6.1-17.fc20 has been pushed to the r3.1 testing repository for dom0.
To test this update, please install it with the following command:

sudo qubes-dom0-update --enablerepo=qubes-dom0-current-testing

Changes included in this update

@marmarek

This comment has been minimized.

Show comment
Hide comment
@marmarek

marmarek Jun 25, 2016

Member

Automated announcement from builder-github

The package xen_4.6.1-17+deb8u1 has been pushed to the r3.1 testing repository for the Debian jessie template.
To test this update, first enable the testing repository in /etc/apt/sources.list.d/qubes-*.list by uncommenting the line containing jessie-testing, then use the standard update command:

sudo apt-get update && sudo apt-get dist-upgrade

Changes included in this update

Member

marmarek commented Jun 25, 2016

Automated announcement from builder-github

The package xen_4.6.1-17+deb8u1 has been pushed to the r3.1 testing repository for the Debian jessie template.
To test this update, first enable the testing repository in /etc/apt/sources.list.d/qubes-*.list by uncommenting the line containing jessie-testing, then use the standard update command:

sudo apt-get update && sudo apt-get dist-upgrade

Changes included in this update

@marmarek

This comment has been minimized.

Show comment
Hide comment
@marmarek

marmarek Jun 25, 2016

Member

Automated announcement from builder-github

The package xen_4.6.1-17+deb9u1 has been pushed to the r3.1 testing repository for the Debian stretch template.
To test this update, first enable the testing repository in /etc/apt/sources.list.d/qubes-*.list by uncommenting the line containing stretch-testing, then use the standard update command:

sudo apt-get update && sudo apt-get dist-upgrade

Changes included in this update

Member

marmarek commented Jun 25, 2016

Automated announcement from builder-github

The package xen_4.6.1-17+deb9u1 has been pushed to the r3.1 testing repository for the Debian stretch template.
To test this update, first enable the testing repository in /etc/apt/sources.list.d/qubes-*.list by uncommenting the line containing stretch-testing, then use the standard update command:

sudo apt-get update && sudo apt-get dist-upgrade

Changes included in this update

@marmarek

This comment has been minimized.

Show comment
Hide comment
@marmarek

marmarek Jun 25, 2016

Member

Automated announcement from builder-github

The package xen_4.6.1-17+deb7u1 has been pushed to the r3.1 testing repository for the Debian wheezy template.
To test this update, first enable the testing repository in /etc/apt/sources.list.d/qubes-*.list by uncommenting the line containing wheezy-testing, then use the standard update command:

sudo apt-get update && sudo apt-get dist-upgrade

Changes included in this update

Member

marmarek commented Jun 25, 2016

Automated announcement from builder-github

The package xen_4.6.1-17+deb7u1 has been pushed to the r3.1 testing repository for the Debian wheezy template.
To test this update, first enable the testing repository in /etc/apt/sources.list.d/qubes-*.list by uncommenting the line containing wheezy-testing, then use the standard update command:

sudo apt-get update && sudo apt-get dist-upgrade

Changes included in this update

@marmarek

This comment has been minimized.

Show comment
Hide comment
@marmarek

marmarek Jul 26, 2016

Member

Automated announcement from builder-github

The package xen-4.6.1-20.fc20 has been pushed to the r3.1 stable repository for dom0.
To install this update, please use the standard update command:

sudo qubes-dom0-update

Or update dom0 via Qubes Manager.

Changes included in this update

Member

marmarek commented Jul 26, 2016

Automated announcement from builder-github

The package xen-4.6.1-20.fc20 has been pushed to the r3.1 stable repository for dom0.
To install this update, please use the standard update command:

sudo qubes-dom0-update

Or update dom0 via Qubes Manager.

Changes included in this update

@marmarek

This comment has been minimized.

Show comment
Hide comment
@marmarek

marmarek Sep 16, 2016

Member

Automated announcement from builder-github

The package xen-4.6.1-20.fc21 has been pushed to the r3.1 stable repository for the Fedora fc21 template.
To install this update, please use the standard update command:

sudo yum update

Changes included in this update

Member

marmarek commented Sep 16, 2016

Automated announcement from builder-github

The package xen-4.6.1-20.fc21 has been pushed to the r3.1 stable repository for the Fedora fc21 template.
To install this update, please use the standard update command:

sudo yum update

Changes included in this update

@marmarek

This comment has been minimized.

Show comment
Hide comment
@marmarek

marmarek Sep 16, 2016

Member

Automated announcement from builder-github

The package xen-4.6.1-20.fc22 has been pushed to the r3.1 stable repository for the Fedora fc22 template.
To install this update, please use the standard update command:

sudo yum update

Changes included in this update

Member

marmarek commented Sep 16, 2016

Automated announcement from builder-github

The package xen-4.6.1-20.fc22 has been pushed to the r3.1 stable repository for the Fedora fc22 template.
To install this update, please use the standard update command:

sudo yum update

Changes included in this update

@marmarek

This comment has been minimized.

Show comment
Hide comment
@marmarek

marmarek Sep 16, 2016

Member

Automated announcement from builder-github

The package xen-4.6.1-20.fc23 has been pushed to the r3.1 stable repository for the Fedora fc23 template.
To install this update, please use the standard update command:

sudo yum update

Changes included in this update

Member

marmarek commented Sep 16, 2016

Automated announcement from builder-github

The package xen-4.6.1-20.fc23 has been pushed to the r3.1 stable repository for the Fedora fc23 template.
To install this update, please use the standard update command:

sudo yum update

Changes included in this update

@marmarek

This comment has been minimized.

Show comment
Hide comment
@marmarek

marmarek Dec 5, 2016

Member

Automated announcement from builder-github

The package xen_2001:4.6.1-20+deb8u1 has been pushed to the r3.1 stable repository for the Debian jessie template.
To install this update, please use the standard update command:

sudo apt-get update && sudo apt-get dist-upgrade

Changes included in this update

Member

marmarek commented Dec 5, 2016

Automated announcement from builder-github

The package xen_2001:4.6.1-20+deb8u1 has been pushed to the r3.1 stable repository for the Debian jessie template.
To install this update, please use the standard update command:

sudo apt-get update && sudo apt-get dist-upgrade

Changes included in this update

@marmarek

This comment has been minimized.

Show comment
Hide comment
@marmarek

marmarek Dec 5, 2016

Member

Automated announcement from builder-github

The package xen_2001:4.6.1-20+deb9u1 has been pushed to the r3.1 stable repository for the Debian stretch template.
To install this update, please use the standard update command:

sudo apt-get update && sudo apt-get dist-upgrade

Changes included in this update

Member

marmarek commented Dec 5, 2016

Automated announcement from builder-github

The package xen_2001:4.6.1-20+deb9u1 has been pushed to the r3.1 stable repository for the Debian stretch template.
To install this update, please use the standard update command:

sudo apt-get update && sudo apt-get dist-upgrade

Changes included in this update

@marmarek

This comment has been minimized.

Show comment
Hide comment
@marmarek

marmarek Dec 5, 2016

Member

Automated announcement from builder-github

The package xen_2001:4.6.1-17+deb7u1 has been pushed to the r3.1 stable repository for the Debian wheezy template.
To install this update, please use the standard update command:

sudo apt-get update && sudo apt-get dist-upgrade

Changes included in this update

Member

marmarek commented Dec 5, 2016

Automated announcement from builder-github

The package xen_2001:4.6.1-17+deb7u1 has been pushed to the r3.1 stable repository for the Debian wheezy template.
To install this update, please use the standard update command:

sudo apt-get update && sudo apt-get dist-upgrade

Changes included in this update

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment