dentproject/dentOS

Migrate to Yocto based build system

Opened this issue · 14 comments

Migrate to Yocto based build system

I gave this thing a bit of thought, and the big steps I see are:

  • Create appropriate machines per architecture (since we still want to support multiple platforms with one image)
  • Convert boot process (initrd => switch to rootfs) to appropriate image definitions
  • Create a recipe for Yocto to create ONIE installer images using the above images
  • Create a recipe for ONL userspace code and include it in the images

Some questions to answer would be:

  • scope: do we want to do a full conversion, or do we try to limit ourselves to e.g. dent supported/verified machines?
  • do we want to try to convert it 1:1, or do we want to try to improve the architecture?
  • which Yocto version do we wan to target? LTS? If so, then kirkstone (current LTS) or scarthgap (next LTS, Q2 24). Though no idea if scarthgap will still support 5.15.
  • how do we want to organize the ONL userspace parts? one monolithic build? multiple sub projects?

Some complications:

  • Single kernel rootfs only; cannot support multiple kernels at the same time AFACT.
  • Python2 is not really supported anymore. The debian 12 update has the same issue, so conversion to python 3 would be shared work.
  • ONL build is currently a monolithic build, very much tied into the infra build system (which requires python2).

Going away from infra is probably unavoidable, but still a lot of work.

I would try to avoid putting the ONL and platform code directly into the Yocto layer. Having separate subprojects for these would make is easier to re-use it in other projects or istributions, do CI testing etc. And you would need to wrap the code in an appropriate build system anyways (make, meson, ninja, etc).

Hi,
I heard there is a meeting where the yocto plan will be presented on Dec 11th. We at Amazon are working on Yocto solution for Dent, and I just want to make sure we are duplicating efforts. How can we participate in this review ? Thanks in advance.

@aravind1379 reminder to drop me an email

Me, Jordan, and Taskin will join the feature and roadmap meeting on Dec 7, 2023 09:00 AM Mountain Time (US and Canada)

And Jordan will be ready to present a plan for yocto on Dent.

Great to hear. Unfortunately I will only be able to attend for about 30 minutes, so if we could squeeze that in first I would be very grateful.

Next week is testing, so the next features meeting would be in two weeks, and I assume many will be on vacation by then (at least I will be). Maybe we could record the presentation and discussion? Then we could at least see what you guys did and plan to do.

Has this been further discussed in the background? Have @KanjiMonster’s questions been answered?

The biggest thing is, if “onlpdump interface” is going to be supported, or everything is put in the Linux kernel.

Another question is, if all kinds of “security” and “reliability” features should be thought of. A/B partitions, updates, verification, …. Like what Chromium OS/ChromeOS and Android are doing.

Hi,
I attended the features and roadmap meeting this morning but there were only three of us. I was hoping to get a better idea of the history/focus of the Yocto work as I was driving the initial work on the onlbuilder to Yocto conversion when I was at Amazon. Are you still based off of my initial work or have you completely restarted everything from scratch?

Jan and Jonas,
Let us know when we can review your document on the roadmap to provide our input.
Thank you,

I pushed our first draft as a PR at dentproject/hldd#1 (<- edited by Jan Klare to keep all links consistent) for now, since we weren't quite sure where to put it. PR so it can easily commented on.

I moved the hldd project to the DENT github namespace now and also updated the link of the PR Jonas send before. Let's continue editing here: dentproject/hldd#1.