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

arm: create COS_PERSISTENT instead of COS_OEM #1023

Merged
merged 4 commits into from
Jan 18, 2022
Merged

Conversation

mudler
Copy link
Contributor

@mudler mudler commented Dec 24, 2021

Add a cloud-init also to automatically expand the COS_PERSISTENT
partition on first boot.

Tied to #930

Still testing it

Signed-off-by: Ettore Di Giacinto edigiacinto@suse.com

Copy link
Contributor

@davidcassany davidcassany left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Cool, with this you are not loosing OEM functionality, you can still plug a USB having the OEM label with some custom cloud init data and it would be executed.

Note you are forgetting to update examples/odroid-c2/files/system/oem/01_layout.yaml

@mudler
Copy link
Contributor Author

mudler commented Dec 24, 2021

Cool, with this you are not loosing OEM functionality, you can still plug a USB having the OEM label with some custom cloud init data and it would be executed.

Note you are forgetting to update examples/odroid-c2/files/system/oem/01_layout.yaml

Good catch, I actually forgot to commit its deletion 😓

@mudler
Copy link
Contributor Author

mudler commented Dec 24, 2021

Oh wait, I did commit it, I've deleted both layout files as now cOS defaults should be good

@mudler mudler force-pushed the arm_adaptations branch 2 times, most recently from d47ee68 to 0777a1a Compare December 31, 2021 13:55
@mudler
Copy link
Contributor Author

mudler commented Jan 17, 2022

This might need rancher-sandbox/cos-toolkit-docs#67

@mudler mudler self-assigned this Jan 18, 2022
Add a cloud-init also to automatically expand the COS_PERSISTENT
partition on first boot

Signed-off-by: Ettore Di Giacinto <edigiacinto@suse.com>
Signed-off-by: Ettore Di Giacinto <edigiacinto@suse.com>
Signed-off-by: Ettore Di Giacinto <edigiacinto@suse.com>
@mudler
Copy link
Contributor Author

mudler commented Jan 18, 2022

seems adding rd.cos.oemlabel=COS_OEM to bootargs doesn't help. Still dropping to emergency shell from dracut

@mudler
Copy link
Contributor Author

mudler commented Jan 18, 2022

ok, seems to boot when creating an COS_OEM (even from an .img file). So looks like entries listed in VOLUMES in layout.env, once specified are mandatory. I'll create a layout file to disable oem entirely

@mudler mudler requested a review from davidcassany January 18, 2022 12:54
@mudler
Copy link
Contributor Author

mudler commented Jan 18, 2022

@davidcassany needs a re-review please as things changed slightly. It looks like the OEM partition is required if specified in VOLUMES in the layout.env file. I have still to test the recent commit, although would make sense to offer a way to mount certain paths 'optionally' like COS_OEM, in that case we can still support the scenarios of plugging an USB stick and load cloud config files from there.

Is there a way to override the default ? by looking at the code at a quick glance I didn't noticed, but not sure if I might have missed something

Signed-off-by: Ettore Di Giacinto <edigiacinto@suse.com>
@mudler
Copy link
Contributor Author

mudler commented Jan 18, 2022

ok so after discussing with @davidcassany OEM gets tried to be mounted by default even if not specified inside VOLUMES. Adding it in volumes makes it a required mount. That means we can't rely on cOS defaults for ARM here, hence why the specific cloud-config file which overrides the layout

@mudler
Copy link
Contributor Author

mudler commented Jan 18, 2022

ok now booting works. However automatic resizing of COS_PERSISTENT it doesn't. Fails silently here with an exit 2. I'd say to merge this and create a follow-up for the partition resizing as it is out of purpose (and can be workarounded easily after image creation too).

@mudler mudler merged commit 903bacf into master Jan 18, 2022
@mudler mudler deleted the arm_adaptations branch January 18, 2022 15:25
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants