commands.sh

pct

linux

Manage LXC containers in Proxmox.

More info →

Options (6)

boolean

Access a specific container's shell

Example: pct {{[en|enter]}} {{100}}
boolean

Create a container from template with 4GB size

Example: pct {{[cr|create]}} {{100}} {{local:vztmpl/distro-name.tar.zst}} --rootfs {{local-lvm}}:4
boolean

Resize the container's disk to 20G

Example: pct {{[resi|resize]}} {{100}} {{rootfs|mpX}} {{20G}}
boolean

Show the configuration of a container, specifying its ID

Example: pct {{[conf|config]}} {{100}}
boolean

Snapshot a specific container with description

Example: pct {{[sn|snapshot]}} {{100}} {{my-snapshot}} --description {{My snapshot description}}
boolean

Destroy a container and remove all related resources

Example: pct {{[des|destroy]}} {{100}} --purge

Examples (8)

List all containers

pct list

Start/Stop/Reboot a specific container

pct start|stop|reboot 100

Access a specific container's shell

pct [en|enter] 100

Create a container from template with 4GB size

pct [cr|create] 100 local:vztmpl/distro-name.tar.zst --rootfs local-lvm:4

Resize the container's disk to 20G

pct [resi|resize] 100 rootfs|mpX 20G

Show the configuration of a container, specifying its ID

pct [conf|config] 100

Snapshot a specific container with description

pct [sn|snapshot] 100 my-snapshot --description My snapshot description

Destroy a container and remove all related resources

pct [des|destroy] 100 --purge
made by @shridhargupta | data from tldr-pages