Table of Contents
Here’s a Proxmox command cheat sheet to help you navigate and manage Proxmox Virtual Environment (PVE) using the command line:
Proxmox Node Commands:
- Display Node Status:
pveversion - Check Node Resources:
pvesh get /nodes/<node>/status - List Virtual Machines:
qm list - Start/Stop/Shutdown a VM:
qm start <vmid> qm stop <vmid> qm shutdown <vmid> - Create a Virtual Machine:
qm create <vmid> --name <vm_name> --memory <memory_size> --net0 virtio,bridge=vmbr0 --cores <cpu_cores> --sockets <cpu_sockets> --virtio0 local:<storage_id>:<vm_size> - Show VM Configuration:
qm config <vmid> - Delete a Virtual Machine:
qm destroy <vmid> - Clone a Virtual Machine:
qm clone <source_vmid> <new_vmid> --name <new_vm_name> - Snapshot a Virtual Machine:
qm snapshot <vmid> <snapshot_name> - Restore VM from Snapshot:
qm rollback <vmid> <snapshot_name>
Storage Commands:
- List Storage:
pvesh get /storage - Show Storage Configuration:
pvesh get /storage/<storage_id> - Create Storage:
pvesh create /storage --storage <storage_id> --type <storage_type> --content <content_type> --path <storage_path> - Remove Storage:
pvesh delete /storage/<storage_id>
Networking Commands:
- List Network Interfaces:
ifconfig -a - List Bridges:
brctl show - List Firewall Rules:
iptables -L -n - Configure Network:
nano /etc/network/interfaces
Cluster Commands:
- Display Cluster Status:
pvecm status - Join a Node to the Cluster:
pvecm add <node_ip_or_hostname> - Remove a Node from the Cluster:
pvecm delnode <node_id> - Show Quorum Status:
pvecm quorum - Display CIB (Cluster Information Base):
corosync-cmapctl
Maintenance Commands:
- Update Proxmox VE:
apt update apt dist-upgrade - Reboot Node:
reboot - Check for Updates:
pveupdate check - Backup VM:
vzdump <vmid> --compress <backup_type> --storage <storage_id> - Restore VM from Backup:
vzrestore <backup_file> <new_vmid>
These commands should help you perform various tasks and manage your Proxmox environment from the command line. Adjust the parameters based on your specific configurations and requirements.