-
Notifications
You must be signed in to change notification settings - Fork 4
Performing Host Maintenance
Here's how to perform maintenance on an ESXi host in a Photon Controller cluster by using the Photon command-line interface.
If the maintenance could affect the version of software, you should first remove the host from the Photon Controller cluster with photon host delete
. After the maintenance is complete, you can add the host back into the cluster, which reinstalls the Photon Controller agent on the host.
Photon Controller holds an ESXi host in a state, usually a ready
state. To perform maintenance, you must first place an ESXi host in a suspended state, remove all the VMs on it, and then place the host into a maintenance state.
-
CREATING
Host is being created. -
NOT_PROVISIONED
Host added, but no agent installed yet -
READY
Host is ready. -
MAINTENANCE
Host is in maintenance. No VM is running on the host. -
SUSPENDED
Host suspended. Existing VMs are still running but won't allow to add new VMs. -
ERROR
Host Error states. Such as provisioning failed, etc. -
DELETED
Infrastructure use only.
First, suspend the host. You can only suspend a host if it's in the READY state, and you can enter maintenance mode for a host only if it's in the suspended state and there are no VMs on it. Here's an example of how to suspend a host:
photon host suspend 40778c18-570b-479e-a92e-5801395376b9
SUSPEND_HOST completed for host entity 40778c18-570b-479e-a92e-5801395376b9
Second, remove all the VMs from the host.
photon host list-vms 40778c18-570b-479e-a92e-5801395376b9
ID Name State
4f2fe2d3-7c2a-4f35-b70a-a1d6fec90600 vm-1 READY
photon vm delete 4f2fe2d3-7c2a-4f35-b70a-a1d6fec90600
DELETE_VM completed for 'vm' entity 4f2fe2d3-7c2a-4f35-b70a-a1d6fec90600
Third, place the host in maintenance mode. A host cannot be put into maintenance mode if it contains VMs.
photon host enter-maintenance 40778c18-570b-479e-a92e-5801395376b9
ENTER_MAINTENANCE_MODE completed for host entity 40778c18-570b-479e-a92e-5801395376b9
Fourth, perform your maintenance and then exit maintenance mode:
photon host exit-maintenance 40778c18-570b-479e-a92e-5801395376b9
EXIT_MAINTENANCE_MODE completed for host entity 40778c18-570b-479e-a92e-5801395376b9
- Home
- Installation Guide
- Download Photon Controller
- Release Notes
- User Guide
- Installation and Setup
- Administration and Operations
- Command-Line Cheat Sheet
- Overview of Commands
- Authenticating Multitenant Users and Groups
- Authorization Model
- Connecting to the Load Balancer and Logging In
- Tenants, Quotas, and Projects
- Creating Tenants, Projects, and Quotas
- Working with Tenants
- Creating a Project
- Uploading Images
- Creating Images
- Replicating Images in Datastores
- Creating Flavors
- Working with Virtual Machines
- Using a Photon OS VM
- Creating a Network
- Performing Host Maintenance
- Working with ESXi Hosts
- Configuring Your Own Load Balancer
- Troubleshooting
- Deploying Clusters
- Integration
- API
- Information for Developers
- References
- Legal