Networking & Shell
List network attachments
Section titled “List network attachments”Inspect the networks configured for a Jail:
doas sylve jails networks --ctid 101Inside the interactive console:
jails networks 101The table includes each network record’s ID, name, switch ID, switch type, DHCP state, and MAC address. The network record ID is separate from the Jail CTID and switch ID.
If no attachments exist, the command reports the Jail name and CTID rather than returning an empty table.
Use JSON for complete network records:
doas sylve jails networks --ctid 101 --jsonRemove a network
Section titled “Remove a network”Pass both the Jail CTID and the network record ID:
doas sylve jails rmnet --ctid 101 --net-id 7The console uses positional identifiers:
jails rmnet 101 7The current CLI can list and remove Jail network records. Adding or editing an attachment is not yet exposed in this command group, so use the web interface or HTTP API for those operations.
Open a Jail shell
Section titled “Open a Jail shell”Open a local interactive shell in a running Jail:
doas sylve jails console --ctid 101This command resolves the running Jail with jls, then executes /bin/sh through jexec. The Jail must be running and the command must be executed on the Sylve node.
The shell command is intentionally unavailable from inside sylve --console because both interfaces need control of the same terminal. Exit the Sylve console first, then run the direct command from your shell.
Leave the Jail shell with:
exitExiting the shell does not stop the Jail.