This section provides sample scripts for PowerCLI with basic and advanced tasks in vCenter Server and host management. What to read next Get a List of Hosts on a vCenter Server System and View Their PropertiesWith PowerCLI, you can get information about all available hosts in a data center and view their properties. Add a Standalone Host to a vCenter Server SystemYou can add standalone hosts to a vCenter Server system by using the Add-VMHost cmdlet. After adding the hosts, you will be able to manage them through the vCenter Server system. Set the License Key for a Host on vCenter ServerYou can set the license key for a host on a vCenter Server system by using the LicenseKey parameter of the Set-VMHost cmdlet. Activate Maintenance Mode for a Host on vCenter ServerTo complete some specific administration tasks, you might need to activate maintenance mode for a host. On vCenter Server, you can activate maintenance mode by using the Set-VMHost cmdlet. Change the Host Advanced Configuration Settings on vCenter ServerYou can modify host configuration, including advanced settings related to virtual machine migration, and apply them to another host. Create a Host Profile on a vCenter Server SystemThe VMware Host Profiles feature enables you to create standard configurations for ESXi hosts. With PowerCLI, you can automate creation and modifying of host profiles. Apply a Host Profile to a Host on vCenter ServerTo simplify operational management of large-scale environments, you can apply standard configurations called host profiles to hosts on vCenter Server. If you want to set up a host to use the same host profile as a reference host, you can attach the host to a profile. Create a vSphere Role and Assign Permissions to a UserWith PowerCLI, you can automate management of vSphere permissions, roles, and privileges. Modify the vCenter Server Email ConfigurationYou can modify the email configuration settings of a vCenter Server. Modify the vCenter Server SNMP ConfigurationTo use SNMP, you must first configure the SNMP settings of the vCenter Server. Parent topic: Managing vSphere with VMware PowerCLI