-
Notifications
You must be signed in to change notification settings - Fork 1.8k
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
zfs-2.2.0 building native-deb-utils target fails early on #15404
Comments
Since you already checked out
The release tar is broken, yeah. |
It looks like the I was able to successfully build the Debian packages with
|
|
@mwpastore Yes, these native deb packages are in some weird state, probably gonna have to postpone upgrade to 2.2 until those conflicts are fixed... |
There are three targets for native packaging,
There two ways to build the Debian packages. RPM converted packages from Alien can be built by using The conflicts were added intentionally with RPM converted Debian packages and the downstream Debian packages. This was done to make sure, the local native Debian packages cannot co-install with other Debian packages maintained by downstream distributions and RPM converted packages. To install native Debian packages, please remove the previously installed packages and then install the native Debian packages. Alternatively, RPM converted Debian packages can be installed to upgrade the previously installed ones. |
Sadly it does not work like this, at least in Ubuntu - Which is actually strange - why kernel should provide DKMS which is purposely created for out-of-kernel modules.
|
@blind-oracle |
@AllKind No it does not. But when you try to install
|
So it's like usaleem-ix said. You have to remove the old package first. |
No, no old packages are installed, I've purged all 2.1.13 stuff. It just wants to remove the kernel, for sure it's wrong. |
It just looked like you still have zfs-dkms installed. |
@AllKind Can be seen here in the |
@blind-oracle searching for all virtual packages and grepping for zfs:
|
Yeah, the conflicts with the provides is probably not going to work. Hm. I'm not sure what the right way to resolve this is, tbh - Ubuntu's kernel is probably correct to say it provides zfs-dkms, in some sense. Really, it'd be nice if we could have a provides: zfs-modules and then zfs-dkms also provides that and we just have the Conflicts on zfs-dkms, not zfs-modules, but, I don't think that's necessarily feasible to get everyone to do Right Now. The simplest way might just be to drop the conflicts for zfs-dkms for now and try to get zfs-dkms and Ubuntu's kernel tree to have a different provides so that we can conflict with zfs-dkms the package later, not the virtual thing it's providing. But I'm not an expert in best practices on this. |
@AllKind I don't get what you mean. I don't have a real @rincebrain Well, I would be happy with how it was working in 2.1.x and before (with alien + rpm conversion). Probably it still works now, but having native debs are probably nicer. There were no conflicts, everything worked like a charm. Update:
|
I hadn't realized it now forces you to build the native deb packages either way in 2.2. How...well thought out, in literally no way. |
@rincebrain maybe the old way works (thru alien), I haven't yet tried. But I wanted to have the native ones if they were announced... |
@blind-oracle I didn't know, that @rincebrain |
And then you could easily run into #15253 which is likely the same as #15328. |
The entire point of the prefix was to ensure you couldn't end up with a mix of the two package sets or have to worry about the versioning causing weird hard to debug problems. You could just drop the Replaces, but then you could wind up with both module packages installed. You could, I imagine, try having something janky like a post-install step that checks if zfs-dkms is virtual and if not, removes it, if you still wanted to try enforcing that. |
Hm, are you saying apt does not recognize version 2.2 is higher than 2.1? |
I'm saying that this prefix avoids you winding up with Ubuntu's patched libzfs5-2.2.0 and OpenZFS's vanilla userland, for example. An additional remark is that, if Ubuntu 24.04, for example, shipped 2.2.0, and you wanted to install OpenZFS's 2.2.0, and hypothetically the package names were the same, apt treats 2.2.0 as less than 2.2.0ubuntu1 for version numbering purposes, I believe, so it would always want to upgrade to the stock packages unless you put an explicit version freeze in. |
I can confirm that after removing
|
I am perplexed as to why the Ubuntu kernel image package provides zfs-dkms and spl-dkms. I can understand why it provides zfs-modules and spl-modules—and it makes sense that those would conflict with modules installed by another package. But it kind of defeats the point of a DKMS package to say that the kernel image package provides it. Also, why is the provides set on the package containing vmlinux (linux-image-6.2.0-34-generic) and not the metapackage (linux-generic-hwe-22.04) or modules package (linux-modules-6.2.0-34-generic)? Even the headers package (linux-headers-6.2.0-34-generic) would make more sense (to me, but I am naive). Anyway, I'm sure the good folks over at Ubuntu have sound reasons for having done this—probably to prevent someone shooting themselves in the foot—but it's quite frustrating. I suppose these new native debs created by OpenZFS have the Conflicts directive in the control file to ensure it doesn't get installed alongside an older zfs-dkms package (i.e. one not provided by the Ubuntu kernel). I wonder if there's a way to write the Conflicts directive so that it excludes such packages without conflicting with the Ubuntu kernel? EDIT: One other note. I edited the control file in the openzfs-zfs-dkms package I built and removed the Conflicts directive, per @blind-oracle, and it installed fine. However, it didn't automatically uninstall the openzfs-zfs-modules package I installed yesterday. Surely these two things should be mutually exclusive? Maybe the Conflicts was being used for this too? |
I can confirm the same, EchterAgo@8553e34 |
@mwpastore Yeah I agree that the kernel should not provide anything DKMS related since it defeats DKMS's purpose. Maybe we should file a bug to Ubuntu, but it will take a long time to be acted upon for sure. So I guess we need to decide smth on OpenZFS side for now... |
2.2.1 tar.gz still fails with same
|
@tonyhutter |
@AllKind, @tonyhutter, @blind-oracle: See my analysis #15586 (comment) It seems that one tarball works and the other one doesn't. Depends which one URL you take. |
@luckylinux well that's obvious since using the 1st link you just get the GIT revision which is .tar.gz-ed by github, similar to And the "normal" link (from release page) leads to some |
@blind-oracle maybe it was obvious for you which tarball to take, for me it wasn't. And something tells me that I'm not the only one, because I wasn't the only one with that error. Anyway, I just wanted to share my experience, hoping it could help somebody in similar situation. |
Ideally there should be some github action set up here which build DEB and RPM packages for most recent Ubuntu/Debian/Fedora and published them along with the |
That is exactly the way it should be. |
Well, reading through that one, it is obvious, that the current approach is NOT always the best. While I am also very conservative on upgrading ZFS, I got hit fully by the last two weeks events. And Ubuntu has still no bugfix release version 2.2.1 available for mantic (which doesn't fix it fully as we know now, but helps), IMHO this is nuts. So at least there should be an option to install a hotfix on those systems possible being hit, (which is in case of the events of the last two weeks every system running ZFS for a long time, with agreeable difference in probability, BUT we didn't know that two weeks ago when everything boild up and a hotfix was required to "stop the bleeding". This hotfix still has not made it in Ubuntu Mantic which IMHO is a shame! So I am right now building packages for Ubuntu 2.2.2 after reading through a LOT of threads here over the last two weeks. So while for sure it is not the fault of the ZFS developers that Ubuntu is ignoring this issue it would help massively in the case of a bug like the one we had now to go here on GitHub and get a hotfix deb package from the release page. This would greatly help! So finally I was just able to build all the deb packages for Ubuntu 23.10 and they installed with just a minor hickup. So if my system boots (fingers crossed) and nothing blows up I will post the script for others. It would be great if the ZFS developers could have a look over it then (I had to fix a bit from the documentation available to make it working.) and integrate something similar in the build scripts. The filesystem driver used is such an important part of the OS that downloading it directly from the developers would give us users much more confidence than having to relay on private PPAs of enthusiastic but unknown (and so not well trusted) unofficial folks like me on GitHub. I would propose packges for Debian stable, Ubuntu LTS and Ubuntu current, THX! |
Thanks for the update. I didn't know ZFS 2.2.2 was just released. But @FL140, are you able to boot "normally" using Ubuntu Mantic 23.10 ? I was and still am hit by For me the workaround was to type root password at the prompt, then
And
Ubuntu until 23.04 was working fine in that regards. Concerning the potential silent corruption issue on ZFS 2.2.0 which should be fixed on ZFS 2.2.1 I see
But on the thread it is said that a value of "0" is not a sufficient condition to indicate that NO corruption is taking place. |
Well me too, it just got released while I build the package from the tonyhutter 2.2.2 branch. As for your boot error, no I don't run into that one! BUT I will have to say, that I am using dracut and not initramfs, so probably this has an impact regarding the initramfs. I had to switch because GRUB, how to put it nicely? "Had problems" with after Upgrading to 23.10 with ZFS on LUKS. You can find my build script here: But be warned! I ran into a bad pool crash while testing some block cloned data, see here: |
I didn't use your script, I used mine ... But this builds 2.2.2 as expected
While the git command wanted to build 2.2.99 for whatever reason
|
@FL140 But are you using bclone ? |
The thing is that blone was active between 2.2.0 and 2.2.1 producing ~750MB of cloned data IIRC. I wanted to check which files are affected by bclone and the investigate if there is a problem with those files. Yes 2.2.2 runs here with zfs_bclone_enabled=0 and zfs_dmu_offset_next_sync=1 which I verified just prior executing the bclone information script, which led to the panic. |
So you mean it's kind of ... "The damage is already done" ? I tried the script but in my case all I get is
Probably related to needing a "special" zdb (according to https://github.com/0x5c/zfs-bclonecheck), but I don't know how/where to get one. |
git zdb knows how to print the BRT. I don't think 2.2.x got a backport of that yet. The top of the link to the script repo points this out and has a link to the PR for it. |
It got merged in #15602 |
exactly, but this has to be investigated
Hmmm, that is interesting as the script started here without a problem and it worked until the panic. The two BRT related commits are in 2.2.2. I think those include all we need. |
I installed zfs 2.2.2 but I didn't reboot thud the kernel module is still zfs 2.2.0 |
Running kernel modules don't matter to zdb. |
Even more weird that the check script doesn't work for me then, since zfs 2.2.2 has already been installed |
Are you able to run zdb on the pool at all? like |
Nope. It's weird.
But
And
Running zdb without arguments yields
But the cache is usually in /etc/zfs/zfs-list.cache/rpool. And
|
As shown in openzfs#15404#issuecomment-1765002181, Ubuntu kernel has 'Provides: zfs-dkms', which will cause uninstall of the kernel, when attempting to install openzfs-zfs-dkms. As a workaround remove the 'Conflicts: zfs-dkms' definition from the debian control file. Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov> Signed-off-by: Mart Frauenlob <AllKind@fastest.cc> Closes openzfs#15503
The recently tagged 2.3.0-rc1 release included a couple of fixed. It'd be very helpful if anyone who had issues could try again so we can work through any potential removing issues. We'll backport these for 2.2.7. |
I don't file many bug reports. I did my best to fill out the template and provide useful information. I have no fixes for the issue so far. Thank you.
There was a lot more dh_missing errors, however I hit the max character limit in a bug report, which is fair.
System information
Distribution Name | Ubuntu
Distribution Version | 22.04.03
Kernel Version | 6.2.0-32-generic
Architecture | AMD64
OpenZFS Version | 2.2.0
zfs-2.1.12-1
zfs-kmod-2.1.12-1
6.2.0-32-generic
Describe the problem you're observing
building native-deb or native-deb-utils fails.
I thought this would work per: https://openzfs.github.io/openzfs-docs/Developer%20Resources/Building%20ZFS.html#build-options
Support for native Debian packaging will be available starting from openzfs-2.2 release.
Describe how to reproduce the problem
extract fresh 2.2.0 source tree
If I copy over contrib/debian/control* and changelog from git version 2.2.0 into the 2.2.0 release directory, it builds a bit longer, but then seems to fail when it gets to
Also
make native-deb-kmod fails with
If I copy over that file from the 2.2.0 tagged git source, I get
The text was updated successfully, but these errors were encountered: