Skip to content
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

Failure to parse OEM id causes cascading failures #16

Closed
brianredbeard opened this issue Feb 5, 2020 · 5 comments
Closed

Failure to parse OEM id causes cascading failures #16

brianredbeard opened this issue Feb 5, 2020 · 5 comments
Assignees
Labels
kind/bug Something isn't working

Comments

@brianredbeard
Copy link

When migrating a host to Flatcar from Container Linux the failure to parse the embedded OEM id causes metadata setup to fail which then cascades to networking failure, ssh key failure, etc.

In this specific case there was no backwards compatibility to parse and understand namespaced coreos. values from the kernel command line:

Feb 05 18:06:45 redbeard-2gb-1-1 coreos-metadata[682]: Error: initialization
Feb 05 18:06:45 redbeard-2gb-1-1 coreos-metadata[682]: Caused by: Couldn't find flag 'flatcar.oem.id' in cmdline file (/proc/cmdline)
Feb 05 18:06:45 redbeard-2gb-1-1 systemd[1]: motdgen.service: Succeeded.
Feb 05 18:06:45 redbeard-2gb-1-1 systemd[1]: Started Generate /run/flatcar/motd.
Feb 05 18:06:45 redbeard-2gb-1-1 systemd[1]: coreos-metadata-sshkeys@core.service: Main process exited, code=exited, status=1/FAILURE
Feb 05 18:06:45 redbeard-2gb-1-1 systemd[1]: coreos-metadata-sshkeys@core.service: Failed with result 'exit-code'.
Feb 05 18:06:45 redbeard-2gb-1-1 systemd[1]: Failed to start Flatcar Metadata Agent (SSH Keys).
Feb 05 18:06:45 redbeard-2gb-1-1 systemd[1]: Dependency failed for Multi-User System.
Feb 05 18:06:45 redbeard-2gb-1-1 systemd[1]: multi-user.target: Job multi-user.target/start failed with result 'dependency'.

this host was booted with the following command line:

Feb 05 18:06:37 localhost kernel: Command line: BOOT_IMAGE=/coreos/vmlinuz-a mount.usr=/dev/mapper/usr verity.usr=PARTUUID=7130c94a-213a-4e5a-8e26-6cce9662f132 rootflags=rw mount.usrflags=ro consoleblank=0 root=LABEL=ROOT console=ttyS0,115200n8 console=tty0 coreos.oem.id=digitalocean verity.usrhash=757b2f0595a625a89b99b6fe7e8b59bd33b3e384fd90f538067a0b7b2bc09822

If the user can successfully boot the host and be able to modify partition 6 of the boot disk (the "OEM" partition) it is possible that the missing metadata expected by the Flatcar tooling can be added as a triage by appending set linux_append="$linux flatcar.oem.id=digitalocean" to the file /usr/share/oem/grub.cfg, that being said this requires advanced knowledge of the OS in general and may not be exhaustive of all changes needed to bring the host into a good working state:

$ cat /usr/share/oem/grub.cfg 
# CoreOS GRUB settings

set oem_id="digitalocean"
set linux_append="$linux flatcar.oem.id=digitalocean"
@pothos
Copy link
Member

pothos commented Feb 6, 2020

Thanks for reporting, we added a paragraph for that in the documentation for the mean time: https://docs.flatcar-linux.org/os/migrate-from-container-linux/

We notify you here when we have a release where afterburn supports all variable names.

@pothos
Copy link
Member

pothos commented Feb 18, 2020

Sorry, yes, the recovery instructions should be on that page until the bug is fixed. The update instructions have the NOTE: General differences when migrating from CoreOS Container Linux also apply. at the beginning but I see that it may be not obvious. The next release will fix the problems and we can then remove this warning.

@pothos
Copy link
Member

pothos commented Feb 27, 2020

For the upcoming stable release we have all compatibility changes done except that flatcar.config.url or ignition.config.url are needed as command line arguments instead of coreos.config.url.

@dongsupark
Copy link
Member

Thanks.
We have been fixing numerous issues regarding backward compatibility. So the OEM ID issue would be probably already fixed.
So can you please try out latest releases, Stable 2345.3.0 or Beta 2411.1.0?

@dongsupark
Copy link
Member

Alpha 2430.0.0 or Edge 2430.99.0 should also fix the issues.
If you continue seeing the issue, feel free to reopen the issue.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
kind/bug Something isn't working
Projects
None yet
Development

No branches or pull requests

4 participants