BloodyIron•

Have you considered back-porting this to a GNOME version that is used by Ubuntu 20.04? I noticed that it's GNOME 40 and 41, which is good, but considering 20.04 is LTS, you might get more users if you add that earlier support.

I suspect you may also add more features over time?

Yay! \o/

3
hubickOP•

Hey.

You can download the zip and do

`mkdir -p ~/.local/share/gnome-shell/extensions/zfs-[email protected]; unzip -u [email protected]_v1.zip -d ~/.local/share/gnome-shell/extensions/zfs-[email protected]`

and then edit the shell-version in the `metadata.json` file, restart Gnome and run

`gnome-extensions enable [email protected]`

It might actually run on an older version of Gnome.

It's my first extension and I had to google how to do just about everything, so I don't know if any functionality I used wasn't available previously. I've actually only tested on my laptop with Fedora 35 and two SSD's in a ZFS mirror. I honestly just guessed at the "40" compatibility declaration thinking probably not much changed since then under version 41 I use.

My other thought was that, since the extension is reading data from the /proc/spl/kstat/zfs/*/state files, which I believe is a recent addition to ZFS as well, that also won't be available on the older ZFS version that comes out of the box on Ubuntu 20.04, so this whole thing is basically gonna be a "newer distro" kinda thing anyway.

I don't even have VM's setup yet to install and run an older Gnome... though if someone wants to edit the metadata and give it a rip and report back, I could potentially update the compatibility and push a new release.

And, as for features, I don't plan on doing much, as it scratches my itch as it stands now, which is giving me that "heads up" that something is wrong with my pool, and I need to open a terminal and use the actual zfs tools to diagnose that.

5
BloodyIron•

Oh right, I forgot 20.04 uses ZFS 0.8.3. That might be a legit concern there. I was more talking from a position where people might be using 20.04 for many years before switching to 22.04 or something newer. But I guess we're talking desktop version here, so it's more likely they would upgrade to 22.04 than if it were server... hmmm...

I think I agree with you, this might not be worth putting the work in for 20.04. You make very compelling points. Also, I'm not currently using ZFS on my desktop, so I'm not in a position to be useful for such, just trying to contribute thoughts is all. :)

An idea for a possible easy new feature, maybe if the pool is doing scrub to get some info from the scrub status in the taskbar widget?

Either way, I think your widget is pretty cool, so thanks for your work!

2
AngryAdmi•

Pretty nifty. Now you just need to make it a centralized application that gets the zfs status from several hosts :)

2
hubickOP•

Yeah, I think there's a number of more comprehensive monitoring solutions, where you can get ZFS plugins that work with the rest of your server monitoring. This was really meant to be something where, if you have an array in your desktop box, you can just click 'enable' with zero extra setup required :-)

1
JJGadgets•

Seeing this gave me a good idea.

Could you have an option where you can specify which pools are kind of “expected” to be online, so you hide the Online status, but show when it’s any other statuses (Degraded, Offline etc)? Like a “blacklist showing Online status for selected pools” or if it’s too hard, just a “Don’t show if pools are online” option.

Because I already have other extensions and system tray icons in my GNOME status bar, adding something like this would take up space that I’d prefer having for other icons if the pool that I use daily is going to be Online most of the time. However, I’d still appreciate a warning status in my status bar if the pool is in any state except Online.

1
hubickOP•

It's a good idea.

From the perspective of writing the extension, as soon as you want to store settings, you need to write a schema for those settings, and there's a compiler for the schema, so then you get into needing a "build" mechanism (Makefile) vs just a Javascript file you zip up, and then you have to create a preferences user interface definition... and adding all that will basically double the size of the entire extension. Being my first extension, I was kinda happy to not have to write all of that lol.

I could also just consider making the default not to display anything for ONLINE pools.

Originally, I had wanted to just display the name of the pool, with it green or orange or red, with a tooltip to show the actual status when you hover over it... but it appears as though Gnome actually removed tooltips at some point around version 3.4. So then I just stuck the status right in the display, but yeah, it is kinda big now.

1