Main index | Section 8 | Options |
bectl
[
Boot environments allow the system to be upgraded, while preserving the old system environment in a separate ZFS dataset.
The following commands are supported by bectl:
activate
[ | |||||||||||||
check Performs a silent sanity check on the current system. If boot environments are supported and used, bectl will exit with a status code of 0. Any other status code is not currently defined and may, in the future, grow special meaning for different degrees of sanity check failures. | |||||||||||||
create
[
If the
If the
If bectl is creating from another boot environment, a snapshot of that boot environment will be created to clone from. | |||||||||||||
create
[
If the
No new boot environment is created with this command. | |||||||||||||
destroy
[
By default,
bectl
will warn that it is not destroying the origin of
beName.
The
| |||||||||||||
export sourceBe | |||||||||||||
Export sourceBe to stdout(4). stdout(4) must be piped or redirected to a file. | |||||||||||||
import targetBe | |||||||||||||
Import targetBe from stdin(4). | |||||||||||||
jail
[
By default, jails are created in interactive mode and
/bin/sh
is
executed within the jail.
If
utility
is specified, it will be executed instead of
/bin/sh.
The jail will be destroyed and the boot environment unmounted when the command
finishes executing, unless the
The
The name, host.hostname, and path must be set, the default values are specified below. All key =value pairs are interpreted as jail parameters as described in jail(8). The following default parameters are provided:
All default parameters may be overwritten. | |||||||||||||
list
[ Display all boot environments. The Active field indicates whether the boot environment is active now ( amp;N); active on reboot ( amp;R); or both ( amp;NR).
| |||||||||||||
| |
Display all datasets. | |
| |
Display the full space usage for each boot environment, assuming all other boot environments were destroyed. | |
| |
Used for scripting. Do not print headers and separate fields by a single tab instead of arbitrary white space. | |
| |
Display all snapshots as well. | |
| |
Sort boot environments by given property name.
The following properties are supported:
| |
name (default output)
creation origin used usedds usedsnap usedrefreserv | |
| |
Same as the
| |
The
mount beName [mountpoint] | |
Temporarily mount the boot environment. Mount at the specified mountpoint if provided. | |
rename origBeName newBeName | |
Rename the given origBeName to the given newBeName. The boot environment will not be unmounted in order for this rename to occur. | |
ujail {jailId | jailName | beName}
unjail {jailId | jailName | beName} | |
Destroy the jail created from the given boot environment. | |
umount
[ | |
unmount
[ | |
bectl
prints usage information if
% zfs list -o name,canmount,mountpoint NAME CANMOUNT MOUNTPOINT zroot zroot/ROOT noauto none zroot/ROOT/default noauto none zroot/usr off /usr zroot/usr/home on /usr/home zroot/var on /var
In that example, zroot/usr has canmount set to off, thus files in /usr typically fall into the boot environment because this dataset is not mounted. zroot/usr/home is mounted, thus files in /usr/home are not in the boot environment.
The other style of boot environments in use, frequently called "deep boot environments", organizes some or all of the boot environment as subordinate to the boot environment dataset. For example:
% zfs list -o name,canmount,mountpoint NAME CANMOUNT MOUNTPOINT zroot zroot/ROOT noauto none zroot/ROOT/default noauto none zroot/ROOT/default/usr noauto /usr zroot/ROOT/default/usr/local noauto /usr/local zroot/var on /var
Note that the subordinate datasets now have canmount set to noauto. These are more obviously a part of the boot environment, as indicated by their positioning in the layout. These subordinate datasets will be mounted by the zfsbe rc(8) script at boot time. In this example, /var is excluded from the boot environment.
bectl
commands that have their own
beadm(1) was written and is maintained by Slawomir Wojciech Wojtczak (vermaden) <Mt vermaden@interia.pl>.
Bryan Drewery (bdrewery) <Mt bryan@shatow.net> wrote the original beadm(1) manual page that this one is derived from.
BECTL (8) | March 31, 2022 |
Main index | Section 8 | Options |
Please direct any comments about this manual page service to Ben Bullock. Privacy policy.
“ | Unix’s “power tools” are more like power switchblades that slice off the operator’s fingers quickly and efficiently. | ” |
— The Unix Haters' handbook |