julp / freebsd_pkg_plugins

[C] [BSD-2] Some custom FreeBSD pkg plugins
1 stars 0 forks source link

Are the plugins actively maintained? #1

Open piotrklibert opened 1 year ago

piotrklibert commented 1 year ago

Hi,

I want to use zint plugin to make snapshots before and after package installation. On Linux (Fedora), I use snapper with a plugin for dnf package manager to this effect. It's very convenient, and when I returned to FreeBSD, I looked for an equivalent. I was very surprised to learn that there's just one such plugin (here) and... with zero ★s! I don't quite get it, do FreeBSD users make snapshots manually?

In any case, I'd like to use this plugin and wanted to know if I can count on some support if something breaks. The repo doesn't seem dead but also doesn't look like there's a new commit every other day. Not knowing the state of implementation, I can't just assume that this is due to the plugins being feature-complete with no further development necessary. So, I thought I'll ask :)

julp commented 1 year ago

Hi,

The repo doesn't seem dead but also doesn't look like there's a new commit every other day

The "raw ZFS" sub-implementation is incomplete (rollback operations) and on hold because it's difficult to implement and it would probably end similar to BE but it should at least handle the snapshots. BE seems to work well, I haven't had any issue so far (and saved my ass one or two times) and I even enabled pruning of old BE on 2 of my own systems. There is no new commit because there is nothing to update so far (no new compatibility issue with pkg, raw ZFS is on hold as said above and BE seems to work as expected)

So if you use the FreeBSD installer or manually do a BE compliant ZFS layout, zint will switch on the BE sub-implementation and offer all features. I haven't really tested the raw ZFS mode but only rollback feature should be absent if I remember correctly.

I don't quite get it, do FreeBSD users make snapshots manually?

I guess people use other tools like zfsnap or even cron directly because they probably think more globally than only running pkg but you can easily screw up your system on an update (binary breakages between packages, pkg removing packages that are absent from the repository because they couldn't be compiled and so on)

I'd like to use this plugin and wanted to know if I can count on some support if something breaks.

I'd do my best if you want to give it a try ;)

piotrklibert commented 1 year ago

I couldn't compile all the plugins as shown in the README, but I wasn't interested in them anyway, so I commented out other plugins in the top-level CMake file and then zint compiled properly and produced zint.so. I put it in /usr/local/lib/pkg/ and changed pkg.conf and... It just worked! :)

Thank you for making and publishing the plugins here, much appreciated :) For now, I have just 1 FreeBSD box, and I'll be using zint there from now on. I will be setting up another FBSD box over the weekend - I'll let you know if something breaks/crashes. I have proper backups set up already, so basically it can crash all it wants and I won't get angry over it :D

julp commented 1 year ago

Awesome, thanks for the feedback.

I couldn't compile all the plugins as shown in the README

Feel free to post more details if you want to.

I commented out other plugins in the top-level CMake file

I should mention this in the README but there is the option -DPLUGINS to only compile what you want. For example, to only compile zint and history you can add -DPLUGINS="history zint" to the cmake command.