vmware-powercli 用户命令管理手册

合集下载
相关主题
  1. 1、下载文档前请自行甄别文档内容的完整性,平台不提供额外的编辑、内容补充、找答案等附加服务。
  2. 2、"仅部分预览"的文档,不可在线预览部分如存在完整性等问题,可反馈申请退款(可完整预览的文档不适用该条件!)。
  3. 3、如文档侵犯您的权益,请联系客服反馈,我们会尽快为您处理(人工客服工作时间:9:00-18:30)。

VMware PowerCLI User's Guide

VMware PowerCLI 6.5.4

VMware PowerCLI User's Guide

You can find the most up-to-date technical documentation on the VMware website at:

https:///

If you have comments about this documentation, submit your feedback to

docfeedback@

VMware, Inc.

3401 Hillview Ave.

Palo Alto, CA 94304

Copyright © 1998–2017 VMware, Inc. All rights reserved. Copyright and trademark information.

Contents

VMware PowerCLI User's Guide8

1Introduction to VMware PowerCLI9

Microsoft PowerShell Basics9

PowerShell Command-Line Syntax10

PowerShell Pipelines10

PowerShell Wildcards10

PowerShell Common Parameters10

PowerCLI Concepts11

PowerCLI Modules12

Interoperability Between the PowerCLI and vCloud Director PowerCLI Modules13

Selecting Objects in PowerCLI14

Providing Login Credentials15

Running PowerCLI Cmdlets Asynchronously15

Managing Default Server Connections16

Customization Specification Objects in PowerCLI16

Using ESXCLI with PowerCLI16

PowerCLI Inventory Provider17

PowerCLI Datastore Provider17

PowerCLI About Articles17

2Installing VMware PowerCLI19

Supported Operating Systems20

Supported VMware Products20

Supported Windows PowerShell Versions20

Prerequisites for Installing and Running PowerCLI20

Install PowerCLI20

Allow Execution of Local Scripts21

Update a PowerCLI Module21

Uninstall PowerCLI22

3Configuring VMware PowerCLI23

Scoped Settings of PowerCLI23

Configuring the Scope of the PowerCLI Settings23

Priority of Settings Scopes in PowerCLI24

PowerCLI Configuration Files24

Using Custom Scripts to Extend the Operating System Support for PowerCLI Cmdlets25

4Configuring Customer Experience Improvement Program26

Categories of Information That VMware Receives26

Join the Customer Experience Improvement Program in PowerCLI26

5Sample Scripts for Managing vSphere with VMware PowerCLI27 Connect to a vCenter Server System31

Manage Virtual Machines on vSphere32

Add a Standalone Host to a vCenter Server System33

Set the License Key for a Host on vCenter Server33

Activate Maintenance Mode for a Host on vCenter Server34

Create vSphere Inventory Objects34

Create Virtual Machines on vCenter Server Using an XML Specification File36

Manage Virtual Machine Templates on vCenter Server36

Create and Use Snapshots on vCenter Server37

Update the Resource Configuration Settings of a Virtual Machine on vCenter Server38

Get a List of Hosts on a vCenter Server System and View Their Properties38

Change the Host Advanced Configuration Settings on vCenter Server39

Move a Virtual Machine to a Different Host Using VMware vSphere vMotion40

Move a Virtual Machine to a Different Datastore Using VMware vSphere Storage vMotion40 Create a Host Profile on a vCenter Server System41

Apply a Host Profile to a Host on vCenter Server41

Manage Statistics and Statistics Intervals on vCenter Server42

Modify the Settings of the NIC Teaming Policy for a Virtual Switch43

Create a vApp on vCenter Server43

Modify the Properties of a vApp44

Export or Import vApps44

Create an iSCSI Host Storage45

Add Passthrough Devices to a Host and Virtual Machine45

Create a Custom Property Based on an Extension Data Property46

Create a Script-Based Custom Property for a vSphere Object46

Apply a Customization Object to a Cloned Virtual Machine47

Modify the Default NIC Mapping Object of a Customization Specification48

Modify Multiple NIC Mapping Objects of a Customization Specification48

Create Multiple Virtual Machines that Use Static IP Addresses49

Create Multiple Virtual Machines with Two Network Adapters51

Create a vSphere Role and Assign Permissions to a User52

View the Action Triggers for an Alarm on vCenter Server53

Create and Modify Alarm Actions and Alarm Triggers on vCenter Server53

Remove Alarm Actions and Triggers54

Create and Modify Advanced Settings for a Cluster55

Modify the vCenter Server Email Configuration55

Modify the vCenter Server SNMP Configuration56

相关文档
最新文档