-
Notifications
You must be signed in to change notification settings - Fork 40
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
Replace ubuntu-jammy-rpi with ubuntu-noble-rpi #102
Conversation
Unfortunately the build is still broken (with box build) after updating the URL:
I'm not sure what it's looking for or expecting here. |
Hi @IsaacJT
That's great, we missed you :) The proposed change looks good and it can be merged. Due to python issues I could not build the latest version for Ubuntu Jammy anymore. The oldest entry-point I could built it for was xUbuntu_23.04, that's why you need to jump to the deprecated space for anything older and I hope it doesn't cause trouble
However, I could reproduce the build problem you found and its also related to an older version of apt. This part I could "fix" in kiwi. See a PR here: OSInside/kiwi#2639 As background information; We dropped the use of debootstrap and use a bootstrap system that only uses apt. If you want to see the details on this change: OSInside/kiwi#2602 So with the kiwi fix I don't see the apt issue anymore but the installation fails on the post script of systemd in Jammy
If I repeat the call chfn tells me that there is no "Network" user. I'm not sure if this is a problem of how kiwi created the bootstrap or rather an issue of the packaging. I appreciate your help at this point. Thanks much |
@IsaacJT thinking more about this and also what Neal said on the kiwi PR, we actually don't support Ubuntu <= 24.04 with the new kiwi version 10.x.x. The fix to support older versions is also not nice and as you are using boxbuild you should be able to build the image with the following command
I have tested a jammy build and that worked for me Let me know if this also works for you Thanks |
Hi Marcus,
I originally ran into this issue while trying to demonstrate how Kiwi does cross architecture builds to a coworker using this description. If the newest versions of Kiwi are no longer supporting 22.04, maybe the "correct" solution for this is to uplift this description to support 24.04 instead? It would be great to have a working foreign architecture reference description that people can just be pointed to and use.
I'm happy to give it a go and modify the PR.
Cheers,
Isaac
…-------- Original Message --------
On 5/09/24 22:21, Marcus Schäfer wrote:
@IsaacJT thinking more about this and also what Neal said on the kiwi PR, we actually don't support Ubuntu <= 24.04 with the new kiwi version 10.x.x. The fix to support older versions is also not nice and as you are using boxbuild you should be able to build the image with the following command
kiwi-ng system boxbuild --box universal --kiwi-version 9.25.22 -- --description ... --target-dir ...
I have tested a jammy build and that worked for me
Let me know if this also works for you
Thanks
—
Reply to this email directly, view it on GitHub, or unsubscribe.
You are receiving this because you were mentioned.Message ID: ***@***.***>
|
I would agree to this plan |
I updated the lunar and noble descriptions for x86_64 and tested the boxbuild. So far so good. Please take a look at the changes I did to the package list. When we moved from debootstrap to an apt based process for the bootstrap some packages needs to be mentioned explicitly now. |
Thanks for the pointers. I'm not sure exactly which bootstrap package you mean (I added
It's trying to install the amd64 package even though it's running in an arm64 box. Command line is:
|
yep I meant those
yeah and I stumbled over the exact same issue. The only solution I found was dropping the security repo, then it resolves clean. See: commit f91f44d I find this apt behavior completely strange. As you can see from my patch for the x86_64 image the issue was vice versa. So it was requesting apt:arm64 on an amd64 box. It seems there is something in that security repo that makes app to think it has to request a multiarch package I only see this behavior on noble, not on lunar |
Hmm, but I see for the arm build the ports.ubuntu.com repo is used, so the same "fix" I did on the x86 side cannot applied here. I have no idea how to debug this because all you get from apt is
yeah which one ? |
Yeah unfortunately it doesn't help :( I'll push the current state if you want to have a look |
e043c30
to
b0ab0f3
Compare
This is very strange, I could reproduce it once but now it works... without having changed anything. Can you try to run with this keeps the box open with a shell. You can re-run the build by
|
It's quite bizarre. Seems to work about 10% of the time... |
yes really strange. I have the following patch diff --git a/ubuntu/aarch64/ubuntu-jammy-rpi/appliance.kiwi b/ubuntu/aarch64/ubuntu-jammy-rpi/appliance.kiwi
index c7286d7..58a1c50 100644
--- a/ubuntu/aarch64/ubuntu-jammy-rpi/appliance.kiwi
+++ b/ubuntu/aarch64/ubuntu-jammy-rpi/appliance.kiwi
@@ -29,12 +29,14 @@
<user password="$1$wYJUgpM5$RXMMeASDc035eX.NbYWFl0" home="/home/ubuntu" name="ubuntu" groups="users,kvm" shell="/bin/bash"/>
</users>
<repository type="apt-deb" repository_gpgcheck="false" package_gpgcheck="false" imageinclude="true">
- <source path="obs://Virtualization:Appliances:Builder/xUbuntu_22.04"/>
+ <source path="obs://Virtualization:Appliances:Builder/xUbuntu_23.04"/>
</repository>
- <repository type="apt-deb" alias="Jammy" distribution="jammy" components="main multiverse restricted universe" repository_gpgcheck="false">
+ <repository type="apt-deb" alias="Lunar" distribution="lunar" components="main multiverse restricted universe" repository_gpgcheck="false">
<source path="http://ports.ubuntu.com/ubuntu-ports"/>
</repository>
<packages type="image">
+ <package name="libpam-runtime"/>
+ <package name="language-pack-en"/>
<package name="linux-raspi"/>
<package name="ubuntu-raspi-settings"/>
<package name="linux-firmware"/>
@@ -63,13 +65,11 @@
<package name="mawk"/>
<package name="openssh-client"/>
<package name="openssh-server"/>
- <package name="netcat"/>
<package name="zstd"/>
<package name="util-linux"/>
<package name="less"/>
<package name="vim"/>
<package name="python3-kiwi"/>
- <package name="python3-kiwi-boxed-plugin"/>
<package name="kiwi-systemdeps"/>
<package name="jing"/>
<package name="qemu-kvm"/>
diff --git a/ubuntu/aarch64/ubuntu-jammy-rpi/pre_disk_sync.sh b/ubuntu/aarch64/ubuntu-jammy-rpi/pre_disk_sync.sh
index 770f803..95bee9a 100644
--- a/ubuntu/aarch64/ubuntu-jammy-rpi/pre_disk_sync.sh
+++ b/ubuntu/aarch64/ubuntu-jammy-rpi/pre_disk_sync.sh
@@ -17,7 +17,7 @@ cp -a /usr/lib/firmware/*-raspi/device-tree/broadcom/* /boot/efi/
#==========================================
# copy initrd and kernel
#------------------------------------------
-cp /boot/initrd.img-*-raspi /boot/efi/initrd.img
+cp /boot/initrd-*-raspi /boot/efi/initrd.img
cp /boot/vmlinuz-*-raspi /boot/efi/vmlinuz
#========================================== and this builds in 1 out of 10 times |
So here is a reproducer create /tmp/foo.config
now call
Sometimes this works, sometimes not what the heck |
@IsaacJT I think I found it. If I remove the OBS created kiwi repo Virtualization:Appliances:Builder/xUbuntu_23.04 then it works reliable. I have no idea why though. Do you see anything suspicious here: https://download.opensuse.org/repositories/Virtualization:/Appliances:/Builder/xUbuntu_23.04/ I have pushed an ubuntu-noble-rpi/ description without using the kiwi repo, this one builds reliable for me |
My guess is that apt has an issue when it should resolve on multiarch flat repos, but it doesn't look like a bug in kiwi |
I wonder if it would make sense to add |
Signed-off-by: Isaac True <[email protected]>
577bf58
to
e96bdd3
Compare
Annoyingly it's now working every time I try it.... Maybe it was some intermittent problem on some mirror? |
When apt resolves packages on a multiarch repo it can happen that dependencies for packages from other architectures are pulled into the solver process but are not provided by any repository. To overcome this behavior the repository can be setup to serve packages only for a specified architecture or list of architectures. This is related to OSInside/kiwi-descriptions#102
yes this is a very good idea. I coded it in a way that you can specify the architectures via the kiwi definition file. It would be great if you can give it a review. Thanks much |
🤣 really annyoing if it works every time I think this PR can be merged, it looks good to me, or do you plan any further changes ? If we agree to the change in kiwi, we can pin the architecture for the Virt:App repo in a new PR once a new kiwi version with the feature is out |
When apt resolves packages on a multiarch repo it can happen that dependencies for packages from other architectures are pulled into the solver process but are not provided by any repository. To overcome this behavior the repository can be setup to serve packages only for a specified architecture or list of architectures. This is related to OSInside/kiwi-descriptions#102
I unfortunately don't have a RPi to test the output right now. I'll see if I can dig one up or get it working in QEMU (I think there's an RPi emulation mode?) |
yes qemu has a --machine emulation for several pi's. I have some PI's here on my desk. If you want I can test your result build. btw: I never build something for production with the slow cross arch emulation mode of a boxbuild. For aarch64 I usually build on PI 's 4/5 with 8G of RAM and using boxbuild together with KVM. KVM is supported on the PI's and works really well. In the past I also had access to a NXP lx2160 which was really fast. The cross building model in boxbuild works, but I think it's really more for debugging as it's super slow. Using a cross-arch container with binfmts is faster in this case |
@IsaacJT kiwi >= v10.1.7 has the architectures flag, the boxes will auto rebuild in a few minutes. I'm going to merge this PR now |
Sorry only just got around to testing it again now. It doesn't build in its current form ( |
Interestingly I'm now getting
again... |
Hi @schaefi,
I'm jumping back into some Kiwi topics after a long time away ;)
ubuntu-jammy-rpi
no longer builds due to the repo being moved underDeprecated
ondownload.opensuse.org
. This updates the OBS URL to bring it in line with the change made in 7d41510.