]> CyberLeo.Net >> Repos - FreeBSD/FreeBSD.git/commit
bectl(8): Add a "check" command
authorkevans <kevans@FreeBSD.org>
Wed, 11 Sep 2019 13:27:10 +0000 (13:27 +0000)
committerkevans <kevans@FreeBSD.org>
Wed, 11 Sep 2019 13:27:10 +0000 (13:27 +0000)
commitadd96fb8ab0607d1a7997c8c7fb7ae91aa2d9c99
tree3238f617808e0ac29f81f25e797dae8415808230
parentc1fe73ee39192b29843ecfb1e8c14d6b100f8fcb
bectl(8): Add a "check" command

This command simply returns 0 at the moment and explicitly takes no
arguments. This should be used by utilities wanting to see if bectl can
operate on the system they're running, or with a specific root (`bectl -r`).
It may grow more checks than "will libbe successfully init" in the future,
but for now this is enough as that checks for the dataset mounted at "/" and
that it looks capable of being a BE root (e.g. it's not a top-level dataset)

bectl commands can now specify if they want to be silent, and this will turn
off libbe_print_on_error so they can control the output as needed. This is
already used in `bectl check`, and may be turned on in the future for some
other commands where libbe errors are better suppressed as the failure mode
may be obvious.

Requested by: David Fullard
MFC after: 3 days
sbin/bectl/bectl.8
sbin/bectl/bectl.c