Skip to contentSkip to conversation

nvme-cli 3.0

ANNOUNCE Daniel Wagner 1 participant 1 message Sep 7 NVMe

lore
Share & tools
lore
#0 lore raw

nvme-cli 3.0 is finally out. Here is the story how we got here, plus some stats, because I think that's more interesting than a plain changelog.

nvme-cli 2.x life started back in 2020, right after the 1.10 release, when Keith Busch started with libnvme. Splitting the nvme-cli 1.x code base into a CLI part and a library. Hannes Reinecke saw the opportunity to provide a Python binding via libnvme which was the base for the nvme-stas project.

The split was not easy and took quite a while, which meant we had nvme-cli 1.x still shipping and an unreleased 2.x branch sitting on top of it at the same time. Around that time, at an ALPSS conference, I asked Keith Busch if he needed help getting nvme-cli 2.0 out the door, and suddenly I was a maintainer.

As one can imagine, if a library is cut out of an existing project it usually ends up with some rather unusual APIs. Fine for an internal API, not so great for a library interface. I tried for the initial 2.0 release to get this sorted out, but it was clear that would take too long. So the decision was made to release it anyway and do another major version a couple of years later, once we'd figured out how to do it better. nvme-cli 2.0 shipped on 2022-04-08.

It took a bit longer than that until the 3.x project actually started. The wish list grew over the years, but I thought it would be good to just do a refactoring/cleanup release. No new features, just get the existing API sorted out, and do it quickly, a few months at max. Dennis Maisenbacher and Tokunori Ikegami helped a lot in that early 3.x phase, where we manually went through the existing API and refactored it. Very tedious work.

When presenting these plans and status at ALPSS 2025, Christoph Hellwig suggested we take the time and do it properly. So we did. Around May 2026 the code base was in good shape and I considered it 3.0-ready.

At LSF/MM 2026 I presented the status, plus some future plans, accompanied by prototypes of how to move forward with connection management for NVMe over Fabrics. Bring these things into the current millennium. Again, Christoph suggested to get this done properly, so the 3.0 release got postponed again, to look into the future plans and the new features that were originally not planned for 3.0 at all.

And this is when we started using AI in earnest. The impact was huge. All the "this would be really cool to have, but too much work right now" features suddenly became doable. Martin Belanger started bringing major features from the nvme-stas project into libnvme, while I was busy splitting up the code base further to make it more portable.

We moved a lot of code from left to right (some would call it code churn), but my mindset for this phase was progress over perfection. The result is that we haven't just cleaned up the public libnvme API. We have a much cleaner code base overall, and a few major new features on top.

This cleanup, and the abstraction of some base types out of the library, enabled another interesting side project. Brandon Busacker asked me early this year if I was open to porting the project to Windows, and a few months later, after getting libnvme into shape, it was actually reasonably doable. Broc Going and Jim Munn provided the platform-specific parts, and voila, it runs on Windows now.

I thought I needed to counterbalance this, so I asked Claude if it could do a port to FreeBSD, and a few minutes later nvme-cli was also running on FreeBSD (not merged yet, because first I want CI working so any bit-rot gets noticed in time).

Another effort worth mentioning: Sarah Ahmed, Brooke Ellis, Fahim Hassan and Laraib Javed, all from IBM, started bug-squashing the reports from clang-analyzer and Coverity, with guidance from Nilay Shroff. Nilay also contributed the new 'nvme top' feature, after I convinced him at LSF/MM 2025 it would be a great thing to have. These bug-hunting efforts got extra support from Prabhakar Pujeri in the final weeks before release.

The whole effort shows up in the numbers, too: nvme-cli 2.x/libnvme 1.x had roughly 47 test cases total, with code coverage around 2%. nvme-cli 3.x/libnvme 3.x has over 140 tests now, and coverage around 24%. Still not great, but clearly progress.

git log naively reports 3,681 commits since v2.16, but that walks into libnvme's own pre-2.16 history too, since the "lib: import libnvme sources" merge preserved it instead of squashing it. Follow the real mainline only and it's 1,711 commits from 58 people. The incremental work since v2.16 comes out to roughly +113,600 / -38,686 lines.

I also went looking for how much of that came from AI. Counting commits with an "Assisted-by"/"Co-authored-by" trailer, an explicit mention in the message body, the em-dash-heavy prose style that basically no human here actually writes in, or my spec-update commits pulling into libnvme, that's at least 168 commits, 98 of them Martin Belanger's and 59 mine, adding up to roughly +32,500 / -14,000 of the real lines above.

58 people committed code between v2.16 and v3.0. In alphabetical order:

Alexandr Goncharov, Ben Reese, Brandon Busacker, Brandon Capener, Brandon Paupore, Brenden Bain, Broc Going, Brooke Ellis, Carl Moran, Daniel Wagner, David Santamaría Rogado, Dennis Maisenbacher, Fahim Hassan, Federico Iezzi, Flavien Solt, fyodor-soiguine-sndk, g0l4, Gopinath P, Guangzong Chen, Guzebing, Hannes Reinecke, Haro Panosyan, hsdhillo, jeff-lien-sndk, Jesse Taube, Jian Zhang, Jim Munn, jinhua.huang, Kou Wenqi, Laraib Javed, Leonardo da Cunha, Markus Kurz, Martin Belanger, Martin George, Martin Wilck, Maurizio Lombardi, Michal Rábek, Mitsuru Kariya, Nate Thornton, Nick darkfiberiru Wolff, Nilay Shroff, orbisai0security, Prabhakar Pujeri, Praveen Kumar B, Robin-YMTC, Sarah Ahmed, Sebastian Chlad, sfindley102892, Stephen Cheng, Steve Chang, Steven Seungcheol Lee, Stuart Hayes, Swapna Samoju, Tokunori Ikegami, Tomas Bzatek, Utkarsh Singh, Zhen Wang, 胡玮文.

Plus everyone who filed a bug, tested an rc, or reviewed a patch without their name ending up in git log.

So, many thanks to anyone who contributed to the 3.0 release. If I forgot to mention you it's not on purpose, just lossy brain function on my side.

This release is certainly not perfect, e.g. the libnvme API is way better than in the previous major version, but still not where it should be. So let's find out what's broken in the 3.x API next, and fix that in the following major version.

See https://github.com/linux-nvme/nvme-cli/blob/master/NEWS.md
for more details.

--
Daniel