NAME
zfsbootcfg
—
specify zfsboot options for the next
boot
SYNOPSIS
zfsbootcfg |
⟨options⟩ |
zfsbootcfg |
[-n name]
[-k key]
[-p ] [-t
type] [-v
value] [-z
pool] |
zfsbootcfg |
DESCRIPTION
zfsbootcfg
is used to set
boot.config(5)-style options to be used by
zfsboot(8),
gptzfsboot(8) or
loader(8) the next time the machine is booted. Once
zfsboot(8) or
gptzfsboot(8) or
loader(8) reads the information, it is deleted. If booting fails, the
machine automatically reverts to the previous boot configuration. The
information is stored in a special boot environment area of a ZFS pool.
If used without arguments, zfsbootcfg
will
output the current boot configuration, if set.
The following options are supported by
zfsbootcfg
:
-k
key- Define key for ⟨key, value⟩ pair.
-n
name- Update nvlist name.
-p
- Print all information stored in ZFS pool bootenv area.
-t
type- Set type of value used in ⟨key, value⟩
pair. Currently supported types are:
- DATA_TYPE_BYTE
- DATA_TYPE_INT8
- DATA_TYPE_UINT8
- DATA_TYPE_INT16
- DATA_TYPE_UINT16
- DATA_TYPE_INT32
- DATA_TYPE_UINT32
- DATA_TYPE_INT64
- DATA_TYPE_UINT64
- DATA_TYPE_BOOLEAN_VALUE
- DATA_TYPE_STRING
If not specified, the default is DATA_TYPE_STRING.
-v
value- Define value for ⟨key, value⟩ pair.
-z
pool- Operate on pool.
ENVIRONMENT
vfs.root.mountfrom
- The kenv(1) variable that identifies a pool for which the options are written.
EXAMPLES
Try to boot to a new
boot
environment without changing the bootfs
property of a pool:
zfsbootcfg
"zfs:tank/ROOT/newbe:"
To clear the boot options:
zfsbootcfg ""
SEE ALSO
boot.config(5), bectl(8), gptzfsboot(8), loader(8), zfsboot(8)
HISTORY
zfsbootcfg
appeared in
FreeBSD 11.1.
AUTHORS
This manual page was written by Andriy Gapon <avg@FreeBSD.org>.