stratisd
stratisd copied to clipboard
Check CLI versions if there is a known minimum version
Although we try to avoid invoking CLI tools from Stratis, there are some cases it is needed (XFS, thin provisioning).
Given we've got a known problem with "thin_check" version 2.8 or lower - should we adopt a strategy for a baseline on CLIs?
If we document a minimum required version (which we should, prominently), this is the sort of thing that distro packaging scripts would typically enforce.
But, I still am of the opinion this is still worth doing, since developers and do-it-yourselfers won't be using a distro-packaged Stratis, and the consequences for using a too-old version are that it certainly won't be a tested configuration, and we can't guarantee there won't be data loss.
Our first step should be to reduce the places where we use Command to a very small set, even if it can't be empty.
Does libblockdev allow client to specify the version of a command-line tool that libblockdev wraps that it requires? Most likely not, although I haven't checked.
The minimum supported version doesn't always make sense to think about. For example, for https://github.com/stratis-storage/stratisd/pull/3511, we can support multiple versions, but have to make a choice about the options we pass depending on the version. So, we might as well close this as too generic.