VMware vCenter Server Appliance (VCSA) CLI Cheatsheet
#
VMware vCenter Server Appliance (VCSA) CLI provides commands to manage and configure the vCenter Server Appliance. These commands help administrators perform administrative tasks, configuration, and troubleshooting directly from the command line.
VCSA Appliance Management
#
Command/Option | Example | Description |
---|
vami-cli appliance update | vami-cli appliance update | Check for and install available updates for VCSA |
vami-cli appliance version | vami-cli appliance version | Display the current version of VCSA |
vami-cli appliance backup | vami-cli appliance backup create --backup-location <backup_path> --backup-description "Backup description" | Create a backup of the VCSA |
vami-cli appliance shutdown | vami-cli appliance shutdown | Shut down the VCSA appliance |
vami-cli appliance reboot | vami-cli appliance reboot | Reboot the VCSA appliance |
vCenter Server Service Management
#
Command/Option | Example | Description |
---|
service-control –status | service-control --status | List the status of all vCenter Server services |
service-control –start | service-control --start <service_name> | Start a specific vCenter Server service |
service-control –stop | service-control --stop <service_name> | Stop a specific vCenter Server service |
service-control –restart | service-control --restart <service_name> | Restart a specific vCenter Server service |
Network Configuration
#
Command/Option | Example | Description |
---|
vami-cli network ip show | vami-cli network ip show | Display the current IP address configuration |
vami-cli network ip update | vami-cli network ip update --ip <ip_address> --netmask <netmask> --gateway <gateway> | Update the IP address configuration |
vami-cli network dns show | vami-cli network dns show | Display the current DNS configuration |
vami-cli network dns update | vami-cli network dns update --primary-dns <primary_dns> --secondary-dns <secondary_dns> | Update the DNS configuration |
Authentication and User Management
#
Command/Option | Example | Description |
---|
vami-cli user list | vami-cli user list | List all local users on the VCSA |
vami-cli user add | vami-cli user add --username <username> --password <password> | Add a new local user |
vami-cli user delete | vami-cli user delete --username <username> | Delete a local user |
Certificate Management
#
Command/Option | Example | Description |
---|
vami-cli cert show | vami-cli cert show | Display the current SSL certificate details |
vami-cli cert import | vami-cli cert import --cert <cert_path> --key <key_path> | Import a new SSL certificate |
vami-cli cert export | vami-cli cert export --output <output_path> | Export the current SSL certificate |
Backup and Restore
#
Command/Option | Example | Description |
---|
vami-cli backup create | vami-cli backup create --backup-location <backup_path> --backup-description "Backup description" | Create a backup of the VCSA |
vami-cli backup list | vami-cli backup list --backup-location <backup_path> | List available backups at the specified location |
vami-cli backup restore | vami-cli backup restore --backup-location <backup_path> --backup-name <backup_name> | Restore the VCSA from a backup |
Logging and Troubleshooting
#
Command/Option | Example | Description |
---|
vami-cli log list | vami-cli log list | List all log files |
vami-cli log show | vami-cli log show --log <log_name> | Display the contents of a specific log file |
vami-cli log download | vami-cli log download --log <log_name> --output <output_path> | Download a specific log file |
vami-cli support bundle create | vami-cli support bundle create --output <output_path> | Create a support bundle for troubleshooting |
This cheatsheet covers the most commonly used VMware vCenter Server Appliance (VCSA) CLI commands and options, helping you to manage the appliance, configure network settings, handle authentication, manage certificates, perform backups and restores, and troubleshoot effectively.