File: VirtualMachine.rst

package info (click to toggle)
python-pyvmomi 6.7.1-4
  • links: PTS, VCS
  • area: main
  • in suites: bookworm
  • size: 14,984 kB
  • sloc: python: 9,206; xml: 77; makefile: 9
file content (2243 lines) | stat: -rw-r--r-- 85,368 bytes parent folder | download | duplicates (3)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
1001
1002
1003
1004
1005
1006
1007
1008
1009
1010
1011
1012
1013
1014
1015
1016
1017
1018
1019
1020
1021
1022
1023
1024
1025
1026
1027
1028
1029
1030
1031
1032
1033
1034
1035
1036
1037
1038
1039
1040
1041
1042
1043
1044
1045
1046
1047
1048
1049
1050
1051
1052
1053
1054
1055
1056
1057
1058
1059
1060
1061
1062
1063
1064
1065
1066
1067
1068
1069
1070
1071
1072
1073
1074
1075
1076
1077
1078
1079
1080
1081
1082
1083
1084
1085
1086
1087
1088
1089
1090
1091
1092
1093
1094
1095
1096
1097
1098
1099
1100
1101
1102
1103
1104
1105
1106
1107
1108
1109
1110
1111
1112
1113
1114
1115
1116
1117
1118
1119
1120
1121
1122
1123
1124
1125
1126
1127
1128
1129
1130
1131
1132
1133
1134
1135
1136
1137
1138
1139
1140
1141
1142
1143
1144
1145
1146
1147
1148
1149
1150
1151
1152
1153
1154
1155
1156
1157
1158
1159
1160
1161
1162
1163
1164
1165
1166
1167
1168
1169
1170
1171
1172
1173
1174
1175
1176
1177
1178
1179
1180
1181
1182
1183
1184
1185
1186
1187
1188
1189
1190
1191
1192
1193
1194
1195
1196
1197
1198
1199
1200
1201
1202
1203
1204
1205
1206
1207
1208
1209
1210
1211
1212
1213
1214
1215
1216
1217
1218
1219
1220
1221
1222
1223
1224
1225
1226
1227
1228
1229
1230
1231
1232
1233
1234
1235
1236
1237
1238
1239
1240
1241
1242
1243
1244
1245
1246
1247
1248
1249
1250
1251
1252
1253
1254
1255
1256
1257
1258
1259
1260
1261
1262
1263
1264
1265
1266
1267
1268
1269
1270
1271
1272
1273
1274
1275
1276
1277
1278
1279
1280
1281
1282
1283
1284
1285
1286
1287
1288
1289
1290
1291
1292
1293
1294
1295
1296
1297
1298
1299
1300
1301
1302
1303
1304
1305
1306
1307
1308
1309
1310
1311
1312
1313
1314
1315
1316
1317
1318
1319
1320
1321
1322
1323
1324
1325
1326
1327
1328
1329
1330
1331
1332
1333
1334
1335
1336
1337
1338
1339
1340
1341
1342
1343
1344
1345
1346
1347
1348
1349
1350
1351
1352
1353
1354
1355
1356
1357
1358
1359
1360
1361
1362
1363
1364
1365
1366
1367
1368
1369
1370
1371
1372
1373
1374
1375
1376
1377
1378
1379
1380
1381
1382
1383
1384
1385
1386
1387
1388
1389
1390
1391
1392
1393
1394
1395
1396
1397
1398
1399
1400
1401
1402
1403
1404
1405
1406
1407
1408
1409
1410
1411
1412
1413
1414
1415
1416
1417
1418
1419
1420
1421
1422
1423
1424
1425
1426
1427
1428
1429
1430
1431
1432
1433
1434
1435
1436
1437
1438
1439
1440
1441
1442
1443
1444
1445
1446
1447
1448
1449
1450
1451
1452
1453
1454
1455
1456
1457
1458
1459
1460
1461
1462
1463
1464
1465
1466
1467
1468
1469
1470
1471
1472
1473
1474
1475
1476
1477
1478
1479
1480
1481
1482
1483
1484
1485
1486
1487
1488
1489
1490
1491
1492
1493
1494
1495
1496
1497
1498
1499
1500
1501
1502
1503
1504
1505
1506
1507
1508
1509
1510
1511
1512
1513
1514
1515
1516
1517
1518
1519
1520
1521
1522
1523
1524
1525
1526
1527
1528
1529
1530
1531
1532
1533
1534
1535
1536
1537
1538
1539
1540
1541
1542
1543
1544
1545
1546
1547
1548
1549
1550
1551
1552
1553
1554
1555
1556
1557
1558
1559
1560
1561
1562
1563
1564
1565
1566
1567
1568
1569
1570
1571
1572
1573
1574
1575
1576
1577
1578
1579
1580
1581
1582
1583
1584
1585
1586
1587
1588
1589
1590
1591
1592
1593
1594
1595
1596
1597
1598
1599
1600
1601
1602
1603
1604
1605
1606
1607
1608
1609
1610
1611
1612
1613
1614
1615
1616
1617
1618
1619
1620
1621
1622
1623
1624
1625
1626
1627
1628
1629
1630
1631
1632
1633
1634
1635
1636
1637
1638
1639
1640
1641
1642
1643
1644
1645
1646
1647
1648
1649
1650
1651
1652
1653
1654
1655
1656
1657
1658
1659
1660
1661
1662
1663
1664
1665
1666
1667
1668
1669
1670
1671
1672
1673
1674
1675
1676
1677
1678
1679
1680
1681
1682
1683
1684
1685
1686
1687
1688
1689
1690
1691
1692
1693
1694
1695
1696
1697
1698
1699
1700
1701
1702
1703
1704
1705
1706
1707
1708
1709
1710
1711
1712
1713
1714
1715
1716
1717
1718
1719
1720
1721
1722
1723
1724
1725
1726
1727
1728
1729
1730
1731
1732
1733
1734
1735
1736
1737
1738
1739
1740
1741
1742
1743
1744
1745
1746
1747
1748
1749
1750
1751
1752
1753
1754
1755
1756
1757
1758
1759
1760
1761
1762
1763
1764
1765
1766
1767
1768
1769
1770
1771
1772
1773
1774
1775
1776
1777
1778
1779
1780
1781
1782
1783
1784
1785
1786
1787
1788
1789
1790
1791
1792
1793
1794
1795
1796
1797
1798
1799
1800
1801
1802
1803
1804
1805
1806
1807
1808
1809
1810
1811
1812
1813
1814
1815
1816
1817
1818
1819
1820
1821
1822
1823
1824
1825
1826
1827
1828
1829
1830
1831
1832
1833
1834
1835
1836
1837
1838
1839
1840
1841
1842
1843
1844
1845
1846
1847
1848
1849
1850
1851
1852
1853
1854
1855
1856
1857
1858
1859
1860
1861
1862
1863
1864
1865
1866
1867
1868
1869
1870
1871
1872
1873
1874
1875
1876
1877
1878
1879
1880
1881
1882
1883
1884
1885
1886
1887
1888
1889
1890
1891
1892
1893
1894
1895
1896
1897
1898
1899
1900
1901
1902
1903
1904
1905
1906
1907
1908
1909
1910
1911
1912
1913
1914
1915
1916
1917
1918
1919
1920
1921
1922
1923
1924
1925
1926
1927
1928
1929
1930
1931
1932
1933
1934
1935
1936
1937
1938
1939
1940
1941
1942
1943
1944
1945
1946
1947
1948
1949
1950
1951
1952
1953
1954
1955
1956
1957
1958
1959
1960
1961
1962
1963
1964
1965
1966
1967
1968
1969
1970
1971
1972
1973
1974
1975
1976
1977
1978
1979
1980
1981
1982
1983
1984
1985
1986
1987
1988
1989
1990
1991
1992
1993
1994
1995
1996
1997
1998
1999
2000
2001
2002
2003
2004
2005
2006
2007
2008
2009
2010
2011
2012
2013
2014
2015
2016
2017
2018
2019
2020
2021
2022
2023
2024
2025
2026
2027
2028
2029
2030
2031
2032
2033
2034
2035
2036
2037
2038
2039
2040
2041
2042
2043
2044
2045
2046
2047
2048
2049
2050
2051
2052
2053
2054
2055
2056
2057
2058
2059
2060
2061
2062
2063
2064
2065
2066
2067
2068
2069
2070
2071
2072
2073
2074
2075
2076
2077
2078
2079
2080
2081
2082
2083
2084
2085
2086
2087
2088
2089
2090
2091
2092
2093
2094
2095
2096
2097
2098
2099
2100
2101
2102
2103
2104
2105
2106
2107
2108
2109
2110
2111
2112
2113
2114
2115
2116
2117
2118
2119
2120
2121
2122
2123
2124
2125
2126
2127
2128
2129
2130
2131
2132
2133
2134
2135
2136
2137
2138
2139
2140
2141
2142
2143
2144
2145
2146
2147
2148
2149
2150
2151
2152
2153
2154
2155
2156
2157
2158
2159
2160
2161
2162
2163
2164
2165
2166
2167
2168
2169
2170
2171
2172
2173
2174
2175
2176
2177
2178
2179
2180
2181
2182
2183
2184
2185
2186
2187
2188
2189
2190
2191
2192
2193
2194
2195
2196
2197
2198
2199
2200
2201
2202
2203
2204
2205
2206
2207
2208
2209
2210
2211
2212
2213
2214
2215
2216
2217
2218
2219
2220
2221
2222
2223
2224
2225
2226
2227
2228
2229
2230
2231
2232
2233
2234
2235
2236
2237
2238
2239
2240
2241
2242
2243
.. _str: https://docs.python.org/2/library/stdtypes.html

.. _int: https://docs.python.org/2/library/stdtypes.html

.. _long: https://docs.python.org/2/library/stdtypes.html

.. _bool: https://docs.python.org/2/library/stdtypes.html

.. _storage: ../vim/vm/Summary.rst#storage

.. _vim.Task: ../vim/Task.rst

.. _layoutEx: ../vim/VirtualMachine.rst#layoutEx

.. _vim.Folder: ../vim/Folder.rst

.. _VI API 2.5: ../vim/version.rst#vimversionversion2

.. _reconfigVM: ../vim/VirtualMachine.rst#reconfigure

.. _vim.Network: ../vim/Network.rst

.. _DrsBehavior: ../vim/cluster/DrsConfigInfo/DrsBehavior.rst

.. _HttpNfcLease: ../vim/HttpNfcLease.rst

.. _vim.Datastore: ../vim/Datastore.rst

.. _vim.HostSystem: ../vim/HostSystem.rst

.. _vim.vm.Summary: ../vim/vm/Summary.rst

.. _ComputeResource: ../vim/ComputeResource.rst

.. _vSphere API 5.0: ../vim/version.rst#vimversionversion7

.. _vSphere API 4.1: ../vim/version.rst#vimversionversion6

.. _vSphere API 4.0: ../vim/version.rst#vimversionversion5

.. _vim.vm.Snapshot: ../vim/vm/Snapshot.rst

.. _vim.vm.CloneSpec: ../vim/vm/CloneSpec.rst

.. _vim.HttpNfcLease: ../vim/HttpNfcLease.rst

.. _vim.ResourcePool: ../vim/ResourcePool.rst

.. _vim.vm.GuestInfo: ../vim/vm/GuestInfo.rst

.. _vim.vm.FileLayout: ../vim/vm/FileLayout.rst

.. _vim.vm.ConfigSpec: ../vim/vm/ConfigSpec.rst

.. _vim.vm.ConfigInfo: ../vim/vm/ConfigInfo.rst

.. _vim.ManagedEntity: ../vim/ManagedEntity.rst

.. _vmodl.MethodFault: ../vmodl/MethodFault.rst

.. _vim.vm.Capability: ../vim/vm/Capability.rst

.. _toolsVersionStatus: ../vim/vm/GuestInfo.rst#toolsVersionStatus

.. _vim.vm.StorageInfo: ../vim/vm/StorageInfo.rst

.. _vim.vm.RuntimeInfo: ../vim/vm/RuntimeInfo.rst

.. _RefreshStorageInfo: ../vim/VirtualMachine.rst#refreshStorageInfo

.. _vim.fault.Timedout: ../vim/fault/Timedout.rst

.. _toolsRunningStatus: ../vim/vm/GuestInfo.rst#toolsRunningStatus

.. _vim.VirtualMachine: ../vim/VirtualMachine.rst

.. _childConfiguration: ../vim/ResourcePool.rst#childConfiguration

.. _vim.fault.NotFound: ../vim/fault/NotFound.rst

.. _ApplyRecommendation: ../vim/ClusterComputeResource.rst#applyRecommendation

.. _vim.fault.FileFault: ../vim/fault/FileFault.rst

.. _RemoveSnapshot_Task: ../vim/vm/Snapshot.rst#remove

.. _vim.vm.SnapshotInfo: ../vim/vm/SnapshotInfo.rst

.. _CreateSnapshot_Task: ../vim/VirtualMachine.rst#createSnapshot

.. _vim.vm.FileLayoutEx: ../vim/vm/FileLayoutEx.rst

.. _PowerOnMultiVM_Task: ../vim/Datacenter.rst#powerOnVm

.. _vim.vm.RelocateSpec: ../vim/vm/RelocateSpec.rst

.. _vim.fault.NoDiskFound: ../vim/fault/NoDiskFound.rst

.. _ClusterRecommendation: ../vim/cluster/Recommendation.rst

.. _RevertToSnapshot_Task: ../vim/vm/Snapshot.rst#revert

.. _vim.fault.InvalidName: ../vim/fault/InvalidName.rst

.. _vim.ResourceConfigSpec: ../vim/ResourceConfigSpec.rst

.. _vim.fault.InvalidState: ../vim/fault/InvalidState.rst

.. _vim.EnvironmentBrowser: ../vim/EnvironmentBrowser.rst

.. _RemoveAllSnapshots_Task: ../vim/VirtualMachine.rst#removeAllSnapshots

.. _vim.fault.DuplicateName: ../vim/fault/DuplicateName.rst

.. _vim.fault.SnapshotFault: ../vim/fault/SnapshotFault.rst

.. _DisableSecondaryVM_Task: ../vim/VirtualMachine.rst#disableSecondary

.. _vim.fault.AlreadyExists: ../vim/fault/AlreadyExists.rst

.. _vim.fault.VmConfigFault: ../vim/fault/VmConfigFault.rst

.. _vim.fault.VmWwnConflict: ../vim/fault/VmWwnConflict.rst

.. _ConsolidateVMDisks_Task: ../vim/VirtualMachine.rst#consolidateDisks

.. _vim.fault.MigrationFault: ../vim/fault/MigrationFault.rst

.. _vim.fault.TaskInProgress: ../vim/fault/TaskInProgress.rst

.. _vim.ManagedEntity.Status: ../vim/ManagedEntity/Status.rst

.. _vmodl.fault.NotSupported: ../vmodl/fault/NotSupported.rst

.. _vim.fault.TooManyDevices: ../vim/fault/TooManyDevices.rst

.. _vim.VirtualMachine.Ticket: ../vim/VirtualMachine/Ticket.rst

.. _vim.fault.AlreadyUpgraded: ../vim/fault/AlreadyUpgraded.rst

.. _vim.vm.device.VirtualDisk: ../vim/vm/device/VirtualDisk.rst

.. _vim.fault.ToolsUnavailable: ../vim/fault/ToolsUnavailable.rst

.. _deltaDiskBackingsSupported: ../vim/host/Capability.rst#deltaDiskBackingsSupported

.. _vim.fault.InvalidDatastore: ../vim/fault/InvalidDatastore.rst

.. _vim.fault.ConcurrentAccess: ../vim/fault/ConcurrentAccess.rst

.. _vmodl.fault.InvalidArgument: ../vmodl/fault/InvalidArgument.rst

.. _vim.fault.InvalidPowerState: ../vim/fault/InvalidPowerState.rst

.. _vim.fault.CustomizationFault: ../vim/fault/CustomizationFault.rst

.. _RevertToCurrentSnapshot_Task: ../vim/VirtualMachine.rst#revertToCurrentSnapshot

.. _vim.VirtualMachine.MksTicket: ../vim/VirtualMachine/MksTicket.rst

.. _vim.VirtualMachine.PowerState: ../vim/VirtualMachine/PowerState.rst

.. _vmodl.fault.NotEnoughLicenses: ../vmodl/fault/NotEnoughLicenses.rst

.. _vim.fault.VmToolsUpgradeFault: ../vim/fault/VmToolsUpgradeFault.rst

.. _vim.fault.RecordReplayDisabled: ../vim/fault/RecordReplayDisabled.rst

.. _vim.fault.NoActiveHostInCluster: ../vim/fault/NoActiveHostInCluster.rst

.. _vim.VirtualMachine.MovePriority: ../vim/VirtualMachine/MovePriority.rst

.. _vim.fault.VmFaultToleranceIssue: ../vim/fault/VmFaultToleranceIssue.rst

.. _UpdateChildResourceConfiguration: ../vim/ResourcePool.rst#updateChildResourceConfiguration

.. _vim.fault.CpuHotPlugNotSupported: ../vim/fault/CpuHotPlugNotSupported.rst

.. _vmodl.fault.ManagedObjectNotFound: ../vmodl/fault/ManagedObjectNotFound.rst

.. _vim.VirtualMachine.DiskChangeInfo: ../vim/VirtualMachine/DiskChangeInfo.rst

.. _vim.VirtualMachine.DisplayTopology: ../vim/VirtualMachine/DisplayTopology.rst

.. _vim.vm.customization.Specification: ../vim/vm/customization/Specification.rst

.. _vim.fault.MemoryHotPlugNotSupported: ../vim/fault/MemoryHotPlugNotSupported.rst

.. _vim.fault.InsufficientResourcesFault: ../vim/fault/InsufficientResourcesFault.rst

.. _vim.VirtualMachine.StorageRequirement: ../vim/VirtualMachine/StorageRequirement.rst

.. _vim.vm.FaultToleranceSecondaryOpResult: ../vim/vm/FaultToleranceSecondaryOpResult.rst

.. _vim.fault.HostIncompatibleForRecordReplay: ../vim/fault/HostIncompatibleForRecordReplay.rst

.. _EstimateStorageForConsolidateSnapshots_Task: ../vim/VirtualMachine.rst#estimateStorageRequirementForConsolidate

.. _vim.fault.DisallowedOperationOnFailoverHost: ../vim/fault/DisallowedOperationOnFailoverHost.rst

.. _vim.fault.VmConfigIncompatibleForRecordReplay: ../vim/fault/VmConfigIncompatibleForRecordReplay.rst

.. _HostDatastoreSystem.ConfigureDatastorePrincipal: ../vim/host/DatastoreSystem.rst#configureDatastorePrincipal


vim.VirtualMachine
==================
  VirtualMachine is the managed object type for manipulating virtual machines, including templates that can be deployed (repeatedly) as new virtual machines. This type provides methods for configuring and controlling a virtual machine.VirtualMachine extends the ManagedEntity type because virtual machines are part of a virtual infrastructure inventory. The parent of a virtual machine must be a folder, and a virtual machine has no children.Destroying a virtual machine disposes of all associated storage, including the virtual disks. To remove a virtual machine while retaining its virtual disk storage, a client must remove the virtual disks from the virtual machine before destroying it.


:extends: vim.ManagedEntity_


Attributes
----------
    capability (`vim.vm.Capability`_):
       Information about the runtime capabilities of this virtual machine.
    config (`vim.vm.ConfigInfo`_):
       Configuration of this virtual machine, including the name and UUID.This property is set when a virtual machine is created or when the `reconfigVM`_ method is called.The virtual machine configuration is not guaranteed to be available. For example, the configuration information would be unavailable if the server is unable to access the virtual machine files on disk, and is often also unavailable during the initial phases of virtual machine creation.
    layout (`vim.vm.FileLayout`_):
       Detailed information about the files that comprise this virtual machine.
    layoutEx (`vim.vm.FileLayoutEx`_):
       Detailed information about the files that comprise this virtual machine.Can be explicitly refreshed by the `RefreshStorageInfo`_ operation. In releases after vSphere API 5.0, vSphere Servers might not generate property collector update notifications for this property. To obtain the latest value of the property, you can use PropertyCollector methods RetrievePropertiesEx or WaitForUpdatesEx. If you use the PropertyCollector.WaitForUpdatesEx method, specify an empty string for the version parameter. Any other version value will not produce any property values as no updates are generated.
    storage (`vim.vm.StorageInfo`_):
       Storage space used by the virtual machine, split by datastore. Can be explicitly refreshed by the `RefreshStorageInfo`_ operation. In releases after vSphere API 5.0, vSphere Servers might not generate property collector update notifications for this property. To obtain the latest value of the property, you can use PropertyCollector methods RetrievePropertiesEx or WaitForUpdatesEx. If you use the PropertyCollector.WaitForUpdatesEx method, specify an empty string for the version parameter. Any other version value will not produce any property values as no updates are generated.
    environmentBrowser (`vim.EnvironmentBrowser`_):
       The current virtual machine's environment browser object. This contains information on all the configurations that can be used on the virtual machine. This is identical to the environment browser on the `ComputeResource`_ to which this virtual machine belongs.
    resourcePool (`vim.ResourcePool`_):
       The current resource pool that specifies resource allocation for this virtual machine.This property is set when a virtual machine is created or associated with a different resource pool.Returns null if the virtual machine is a template or the session has no access to the resource pool.
    parentVApp (`vim.ManagedEntity`_):
       Reference to the parent vApp.
    resourceConfig (`vim.ResourceConfigSpec`_):
       The resource configuration for a virtual machine. The shares in this specification are evaluated relative to the resource pool to which it is assigned. This will return null if the product the virtual machine is registered on does not support resource configuration.To retrieve the configuration, you typically use `childConfiguration`_ .To change the configuration, use `UpdateChildResourceConfiguration`_ .
    runtime (`vim.vm.RuntimeInfo`_):
       Execution state and history for this virtual machine.The contents of this property change when:
        * the virtual machine's power state changes.
        * an execution message is pending.
        * an event occurs.
    guest (`vim.vm.GuestInfo`_):
       Information about VMware Tools and about the virtual machine from the perspective of VMware Tools. Information about the guest operating system is available in VirtualCenter. Guest operating system information reflects the last known state of the virtual machine. For powered on machines, this is current information. For powered off machines, this is the last recorded state before the virtual machine was powered off.
    summary (`vim.vm.Summary`_):
       Basic information about this virtual machine. This includes:
        * runtimeInfo
        * guest
        * basic configuration
        * alarms
        * performance information
    datastore ([`vim.Datastore`_]):
      privilege: System.View
       A collection of references to the subset of datastore objects in the datacenter that is used by this virtual machine.
    network ([`vim.Network`_]):
      privilege: System.View
       A collection of references to the subset of network objects in the datacenter that is used by this virtual machine.
    snapshot (`vim.vm.SnapshotInfo`_):
       Current snapshot and tree. The property is valid if snapshots have been created for this virtual machine.The contents of this property change in response to the methods:
        * `CreateSnapshot_Task`_
        * `RevertToCurrentSnapshot_Task`_
        * `RemoveSnapshot_Task`_
        * `RevertToSnapshot_Task`_
        * `RemoveAllSnapshots_Task`_
    rootSnapshot ([`vim.vm.Snapshot`_]):
       The roots of all snapshot trees for the virtual machine.
    guestHeartbeatStatus (`vim.ManagedEntity.Status`_):
       The guest heartbeat. The heartbeat status is classified as:
        * gray - VMware Tools are not installed or not running.
        * red - No heartbeat. Guest operating system may have stopped responding.
        * yellow - Intermittent heartbeat. May be due to guest load.
        * green - Guest operating system is responding normally.The guest heartbeat is a statistics metric. Alarms can be configured on this metric to trigger emails or other actions.


Methods
-------


RefreshStorageInfo():
   Explicitly refreshes the storage information of this virtual machine, updating properties `storage`_ , `layoutEx`_ and `storage`_ .
  since: `vSphere API 4.0`_


  Privilege:
               System.Read



  Args:


  Returns:
    None
         


CreateSnapshot(name, description, memory, quiesce):
   Creates a new snapshot of this virtual machine. As a side effect, this updates the current snapshot.Snapshots are not supported for Fault Tolerance primary and secondary virtual machines.Any % (percent) character used in this name parameter must be escaped, unless it is used to start an escape sequence. Clients may also escape any other characters in this name parameter.


  Privilege:
               VirtualMachine.State.CreateSnapshot



  Args:
    name (`str`_):
       The name for this snapshot. The name need not be unique for this virtual machine.


    description (`str`_, optional):
       A description for this snapshot. If omitted, a default description may be provided.


    memory (`bool`_):
       If TRUE, a dump of the internal state of the virtual machine (basically a memory dump) is included in the snapshot. Memory snapshots consume time and resources, and thus take longer to create. When set to FALSE, the power state of the snapshot is set to powered off. `capabilities`_ indicates whether or not this virtual machine supports this operation.


    quiesce (`bool`_):
       If TRUE and the virtual machine is powered on when the snapshot is taken, VMware Tools is used to quiesce the file system in the virtual machine. This assures that a disk snapshot represents a consistent state of the guest file systems. If the virtual machine is powered off or VMware Tools are not available, the quiesce flag is ignored.




  Returns:
     `vim.Task`_:
         the newly created Snapshot.

  Raises:

    `vim.fault.TaskInProgress`_: 
       if the virtual machine is busy.

    `vim.fault.SnapshotFault`_: 
       if an error occurs during the snapshot operation. Typically a more specific fault like MultipleSnapshotsNotSupported is thrown.

    `vim.fault.VmConfigFault`_: 
       if the virtual machine's configuration is invalid. Typically, a more specific fault like InvalidSnapshotState is thrown.

    `vim.fault.FileFault`_: 
       if there is a problem with creating or accessing one or more files needed for this operation.

    `vim.fault.InvalidName`_: 
       if the specified snapshot name is invalid.

    `vim.fault.InvalidState`_: 
       if the operation cannot be performed because of the virtual machine's current state. For example, the virtual machine configuration information is not available.

    `vmodl.fault.NotSupported`_: 
       if the host product does not support snapshots or if the host does not support quiesced snapshots and the quiesce parameter is set to true; or if the virtual machine is a Fault Tolerance primary or secondary

    `vim.fault.InvalidPowerState`_: 
       if the operation cannot be performed in the current power state of the virtual machine.


RevertToCurrentSnapshot(host, suppressPowerOn):
   Reverts the virtual machine to the current snapshot. This is equivalent to doing snapshot.currentSnapshot.revert.If no snapshot exists, then the operation does nothing, and the virtual machine state remains unchanged.


  Privilege:
               VirtualMachine.State.RevertToSnapshot



  Args:
    host (`vim.HostSystem`_, optional):
       (optional) Choice of host for the virtual machine, in case this operation causes the virtual machine to power on.If a snapshot was taken while a virtual machine was powered on, and this operation is invoked after the virtual machine was powered off, the operation causes the virtual machine to power on to reach the snapshot state. This parameter can be used to specify a choice of host where the virtual machine should power on.If this parameter is not set, and the vBalance feature is configured for automatic load balancing, a host is automatically selected. Otherwise, the virtual machine keeps its existing host affiliation.This is not supported for virtual machines associated with hosts on ESX 2.x servers.


    suppressPowerOn (`bool`_, optional, since `vSphere API 4.0`_ ):
       (optional) If set to true, the virtual machine will not be powered on regardless of the power state when the current snapshot was created. Default to false.




  Returns:
     `vim.Task`_:
         

  Raises:

    `vim.fault.TaskInProgress`_: 
       if the virtual machine is busy.

    `vim.fault.SnapshotFault`_: 
       if an error occurs during the snapshot operation. Typically, a more specific fault like InvalidSnapshotFormat is thrown.

    `vim.fault.InsufficientResourcesFault`_: 
       if this operation would violate a resource usage policy.

    `vim.fault.InvalidState`_: 
       if the operation cannot be performed because of the virtual machine's current state. For example, if the virtual machine configuration information is not available or if an OVF consumer is blocking the operation.

    `vim.fault.VmConfigFault`_: 
       if a configuration issue prevents the power-on. Typically, a more specific fault, such as UnsupportedVmxLocation, is thrown.

    `vim.fault.NotFound`_: 
       if the virtual machine does not have a current snapshot.

    `vmodl.fault.NotSupported`_: 
       if the host product does not support snapshots.

    `vim.fault.InvalidPowerState`_: 
       if the operation cannot be performed in the current power state of the virtual machine.

    `vim.fault.DisallowedOperationOnFailoverHost`_: 
       if the virtual machine is being reverted to a powered on state and the host specified is a failover host. See `ClusterFailoverHostAdmissionControlPolicy`_ .


RemoveAllSnapshots(consolidate):
   Remove all the snapshots associated with this virtual machine. If the virtual machine does not have any snapshots, then this operation simply returns successfully.


  Privilege:
               VirtualMachine.State.RemoveSnapshot



  Args:
    consolidate (`bool`_, optional, since `vSphere API 5.0`_ ):
       (optional) If set to true, the virtual disks of the deleted snapshot will be merged with other disk if possible. Default to true.




  Returns:
     `vim.Task`_:
         

  Raises:

    `vim.fault.TaskInProgress`_: 
       if the virtual machine is busy.

    `vim.fault.InvalidState`_: 
       if the operation cannot be performed because of the virtual machine's current state. For example, if the virtual machine configuration information is not available.

    `vim.fault.SnapshotFault`_: 
       if an error occurs during the snapshot operation. Typically, a more specific fault like InvalidSnapshotFormat is thrown.

    `vmodl.fault.NotSupported`_: 
       if the host product does not support snapshots.

    `vim.fault.InvalidPowerState`_: 
       if the operation cannot be performed in the current power state of the virtual machine.


ConsolidateVMDisks():
   Consolidate the virtual disk files of the virtual machine by finding hierarchies of redo logs that can be combined without violating data dependency. The redundant redo logs after merging are then deleted. Consolidation improves I/O performance since less number of virtual disk files need to be traversed; it also reduces the storage usage. However additional space is temporarily required to perform the operation. Use `EstimateStorageForConsolidateSnapshots_Task`_ to estimate the temporary space required. Consolidation can be I/O intensive, it is advisable to invoke this operation when guest is not under heavy I/O usage.
  since: `vSphere API 5.0`_


  Privilege:
               VirtualMachine.State.RemoveSnapshot



  Args:


  Returns:
     `vim.Task`_:
         

  Raises:

    `vim.fault.TaskInProgress`_: 
       if the virtual machine is busy.

    `vim.fault.InvalidState`_: 
       if the operation cannot be performed because of the virtual machine's current state. For example, if the virtual machine configuration information is not available.

    `vim.fault.FileFault`_: 
       if if there is a problem creating or accessing the virtual machine's files for this operation. Typically a more specific fault for example `NoDiskSpace`_ is thrown.

    `vim.fault.VmConfigFault`_: 
       if a virtual machine configuration issue prevents consolidation. Typically, a more specific fault is thrown such as `InvalidDiskFormat`_ if a disk cannot be read, or `InvalidSnapshotFormat`_ if the snapshot configuration is invalid.


EstimateStorageForConsolidateSnapshots():
   Estimate the temporary space required to consolidation disk files. The estimation is a lower bound if the childmost writable disk file will be consolidated for an online virtual machine, it is accurate for all other situations. This is because the space requirement depending on the size of the childmost disk file and how write intensive the guest is.This method can be used prior to invoke consolidation via `ConsolidateVMDisks_Task`_ .
  since: `vSphere API 5.0`_


  Privilege:
               VirtualMachine.State.RemoveSnapshot



  Args:


  Returns:
     `vim.Task`_:
         Space requirement for each datastore involved.

  Raises:

    `vim.fault.TaskInProgress`_: 
       if the virtual machine is busy.

    `vim.fault.InvalidState`_: 
       if the operation cannot be performed because of the virtual machine's current state. For example, if the virtual machine configuration information is not available.

    `vim.fault.FileFault`_: 
       if if there is a problem accessing the virtual machine's files for this operation. Typically a more specific fault `FileLocked`_ is thrown.

    `vim.fault.VmConfigFault`_: 
       if a virtual machine configuration issue prevents the estimation. Typically, a more specific fault is thrown.


ReconfigVM(spec):
   Reconfigures this virtual machine. All the changes in the given configuration are applied to the virtual machine as an atomic operation.Reconfiguring the virtual machine may require any of the following privileges depending on what is being changed:
    * VirtualMachine.Interact.DeviceConnection if changing the runtime connection state of a device as embodied by the Connectable property.
    * VirtualMachine.Interact.SetCDMedia if changing the backing of a CD-ROM device
    * VirtualMachine.Interact.SetFloppyMedia if changing the backing of a floppy device
    * VirtualMachine.Config.Rename if renaming the virtual machine
    * VirtualMachine.Config.Annotation if setting annotation a value
    * VirtualMachine.Config.AddExistingDisk if adding a virtual disk device that is backed by an existing virtual disk file
    * VirtualMachine.Config.AddNewDisk if adding a virtual disk device for which the backing virtual disk file is to be created
    * VirtualMachine.Config.RemoveDisk if removing a virtual disk device that refers to a virtual disk file
    * VirtualMachine.Config.CPUCount if changing the number of CPUs
    * VirtualMachine.Config.Memory if changing the amount of memory
    * VirtualMachine.Config.RawDevice if adding, removing or editing a raw device mapping (RDM) or SCSI passthrough device
    * VirtualMachine.Config.AddRemoveDevice if adding or removing any device other than disk, raw, or USB device
    * VirtualMachine.Config.EditDevice if changing the settings of any device
    * VirtualMachine.Config.Settings if changing any basic settings such as those in ToolsConfigInfo, FlagInfo, or DefaultPowerOpInfo
    * VirtualMachine.Config.Resource if changing resource allocations, affinities, or setting network traffic shaping or virtual disk shares
    * VirtualMachine.Config.AdvancedConfig if changing values in extraConfig
    * VirtualMachine.Config.SwapPlacement if changing swapPlacement
    * VirtualMachine.Config.HostUSBDevice if adding, removing or editing a VirtualUSB device backed by the host USB device.
    * VirtualMachine.Config.DiskExtend if extending an existing VirtualDisk device.
    * VirtualMachine.Config.ChangeTracking if enabling/disabling changed block tracking for the virtual machine's disks.
    * VirtualMachine.Config.MksControl if toggling display connection limits or the guest auto-lock feature.
    * DVSwitch.CanUse if connecting a VirtualEthernetAdapter to a port in a DistributedVirtualSwitch.
    * DVPortgroup.CanUse if connecting a VirtualEthernetAdapter to a DistributedVirtualPortgroup.Creating a virtual machine may require the following privileges:
    * VirtualMachine.Config.RawDevice if adding a raw device
    * VirtualMachine.Config.AddExistingDisk if adding a VirtualDisk and the fileOperation is unset
    * VirtualMachine.Config.AddNewDisk if adding a VirtualDisk and the fileOperation is set
    * VirtualMachine.Config.HostUSBDevice if adding a VirtualUSB device backed by the host USB device.In addition, this operation may require the following privileges:
    * Datastore.AllocateSpace on any datastore where virtual disks will be created or extended.
    * Network.Assign on any network the virtual machine will be connected to.


  Privilege:
               dynamic



  Args:
    spec (`vim.vm.ConfigSpec`_):
       The new configuration values.




  Returns:
     `vim.Task`_:
         

  Raises:

    `vim.fault.TaskInProgress`_: 
       if the virtual machine is busy.

    `vim.fault.VmConfigFault`_: 
       if the spec is invalid. Typically, a more specific subclass is thrown.

    `vim.fault.ConcurrentAccess`_: 
       if the changeVersion does not match the server's changeVersion for the configuration.

    `vim.fault.FileFault`_: 
       if there is a problem creating or accessing the virtual machine's files for this operation. Typically a more specific fault like NoDiskSpace or FileAlreadyExists is thrown.

    `vim.fault.InvalidName`_: 
       if the specified name is invalid.

    `vim.fault.DuplicateName`_: 
       if the specified name already exists in the parent folder.

    `vim.fault.InvalidState`_: 
       if the operation cannot be performed in the current state of the virtual machine. For example, because the virtual machine's configuration is not available.

    `vim.fault.InsufficientResourcesFault`_: 
       if this operation would violate a resource usage policy.

    `vim.fault.InvalidDatastore`_: 
       vim.fault.InvalidDatastore

    `vim.fault.InvalidPowerState`_: 
       if the power state is poweredOn and the virtual hardware cannot support the configuration changes.

    `vim.fault.TooManyDevices`_: 
       if the device specifications exceed the allowed limits.

    `vim.fault.CpuHotPlugNotSupported`_: 
       if the current configuration of the VM does not support hot-plugging of CPUs.

    `vim.fault.MemoryHotPlugNotSupported`_: 
       if the current configuration of the VM does not support hot-plugging of memory.

    `vim.fault.VmWwnConflict`_: 
       if the WWN of the virtual machine has been used by other virtual machines.


UpgradeVM(version):
   Upgrades this virtual machine's virtual hardware to the latest revision that is supported by the virtual machine's current host.


  Privilege:
               VirtualMachine.Config.UpgradeVirtualHardware



  Args:
    version (`str`_, optional):
       If specified, upgrade to that specified version. If not specified, upgrade to the most current virtual hardware supported on the host.




  Returns:
     `vim.Task`_:
         

  Raises:

    `vim.fault.InvalidState`_: 
       if the host is in maintenance mode, if an invalid version string is specified, or if the virtual machine is in a state in which the operation cannot be performed. For example, if the configuration information is not available.

    `vim.fault.TaskInProgress`_: 
       if the virtual machine is busy.

    `vim.fault.AlreadyUpgraded`_: 
       if the virtual machine's hardware is already up-to-date.

    `vim.fault.NoDiskFound`_: 
       if no virtual disks are attached to this virtual machine.

    `vim.fault.InvalidPowerState`_: 
       if the power state is not poweredOff.


ExtractOvfEnvironment():
   Returns the OVF environment for a virtual machine. If the virtual machine has no vApp configuration, an empty string is returned. Also, sensitive information is omitted, so this method is not guaranteed to return the complete OVF environment.
  since: `vSphere API 4.0`_


  Privilege:
               VApp.ExtractOvfEnvironment



  Args:


  Returns:
    `str`_:
         

  Raises:

    `vim.fault.InvalidState`_: 
       if the virtual machine is not running


PowerOnVM(host):
   Powers on this virtual machine. If the virtual machine is suspended, this method resumes execution from the suspend point.When powering on a virtual machine in a cluster, the system might implicitly or due to the host argument, do an implicit relocation of the virtual machine to another host. Hence, errors related to this relocation can be thrown. If the cluster is a DRS cluster, DRS will be invoked if the virtual machine can be automatically placed by DRS (see `DrsBehavior`_ ). Because this method does not return a DRS `ClusterRecommendation`_ , no vmotion nor host power operations will be done as part of a DRS-facilitated power on. To have DRS consider such operations use `PowerOnMultiVM_Task`_ . As of vSphere API 5.1, use of this method with vCenter Server is deprecated; use `PowerOnMultiVM_Task`_ instead.If this virtual machine is a fault tolerant primary virtual machine, its secondary virtual machines will be started on system-selected hosts. If the virtual machines are in a VMware DRS enabled cluster, then DRS will be invoked to obtain placements for the secondaries but no vmotion nor host power operations will be considered for these power ons.


  Privilege:
               VirtualMachine.Interact.PowerOn



  Args:
    host (`vim.HostSystem`_, optional):
       (optional) The host where the virtual machine is to be powered on. If no host is specified, the current associated host is used. This field must specify a host that is part of the same compute resource that the virtual machine is currently associated with. If this host is not compatible, the current host association is used.




  Returns:
     `vim.Task`_:
         

  Raises:

    `vim.fault.TaskInProgress`_: 
       if the virtual machine is busy.

    `vim.fault.InvalidState`_: 
       if the host is in maintenance mode or if the virtual machine's configuration information is not available.

    `vim.fault.InsufficientResourcesFault`_: 
       if this operation would violate a resource usage policy.

    `vim.fault.VmConfigFault`_: 
       if a configuration issue prevents the power-on. Typically, a more specific fault, such as UnsupportedVmxLocation, is thrown.

    `vim.fault.FileFault`_: 
       if there is a problem accessing the virtual machine on the filesystem.

    `vim.fault.InvalidPowerState`_: 
       if the power state is poweredOn.

    `vmodl.fault.NotEnoughLicenses`_: 
       if there are not enough licenses to power on this virtual machine.

    `vmodl.fault.NotSupported`_: 
       if the virtual machine is marked as a template.

    `vim.fault.DisallowedOperationOnFailoverHost`_: 
       if the host specified is a failover host. See `ClusterFailoverHostAdmissionControlPolicy`_ .


PowerOffVM():
   Powers off this virtual machine. If this virtual machine is a fault tolerant primary virtual machine, this will result in the secondary virtual machine(s) getting powered off as well.


  Privilege:
               VirtualMachine.Interact.PowerOff



  Args:


  Returns:
     `vim.Task`_:
         

  Raises:

    `vim.fault.TaskInProgress`_: 
       if the virtual machine is busy.

    `vim.fault.InvalidState`_: 
       if the operation cannot be performed because of the virtual machine's current state. For example, if the virtual machine configuration information is not available.

    `vim.fault.InvalidPowerState`_: 
       if the power state is not poweredOn.

    `vmodl.fault.NotSupported`_: 
       if the virtual machine is marked as a template.


SuspendVM():
   Suspends execution in this virtual machine.


  Privilege:
               VirtualMachine.Interact.Suspend



  Args:


  Returns:
     `vim.Task`_:
         

  Raises:

    `vim.fault.TaskInProgress`_: 
       if the virtual machine is busy.

    `vim.fault.InvalidState`_: 
       if the operation cannot be performed because of the virtual machine's current state. For example, if the virtual machine configuration information is not available.

    `vim.fault.InvalidPowerState`_: 
       if the power state is not poweredOn.

    `vmodl.fault.NotSupported`_: 
       if the virtual machine is marked as a template.


ResetVM():
   Resets power on this virtual machine. If the current state is poweredOn, then this method first performs powerOff(hard). Once the power state is poweredOff, then this method performs powerOn(option).Although this method functions as a powerOff followed by a powerOn, the two operations are atomic with respect to other clients, meaning that other power operations cannot be performed until the reset method completes.


  Privilege:
               VirtualMachine.Interact.Reset



  Args:


  Returns:
     `vim.Task`_:
         

  Raises:

    `vim.fault.TaskInProgress`_: 
       if the virtual machine is busy.

    `vim.fault.InvalidState`_: 
       if the host is in maintenance mode.

    `vim.fault.InvalidPowerState`_: 
       if the power state is suspended.

    `vmodl.fault.NotEnoughLicenses`_: 
       if there are not enough licenses to reset this virtual machine.

    `vmodl.fault.NotSupported`_: 
       if the virtual machine is marked as a template.


ShutdownGuest():
   Issues a command to the guest operating system asking it to perform a clean shutdown of all services. Returns immediately and does not wait for the guest operating system to complete the operation.


  Privilege:
               VirtualMachine.Interact.PowerOff



  Args:


  Returns:
    None
         

  Raises:

    `vim.fault.ToolsUnavailable`_: 
       if VMware Tools is not running.

    `vim.fault.TaskInProgress`_: 
       if the virtual machine is busy.

    `vim.fault.InvalidState`_: 
       if the operation cannot be performed because of the virtual machine's current state. For example, if the virtual machine configuration information is not available.

    `vim.fault.InvalidPowerState`_: 
       if the power state is not powered on.


RebootGuest():
   Issues a command to the guest operating system asking it to perform a reboot. Returns immediately and does not wait for the guest operating system to complete the operation.


  Privilege:
               VirtualMachine.Interact.Reset



  Args:


  Returns:
    None
         

  Raises:

    `vim.fault.ToolsUnavailable`_: 
       if VMware Tools is not running.

    `vim.fault.TaskInProgress`_: 
       if the virtual machine is busy.

    `vim.fault.InvalidState`_: 
       if the operation cannot be performed because of the virtual machine's current state. For example, if the virtual machine configuration information is not available.

    `vim.fault.InvalidPowerState`_: 
       if the power state is not powered on.


StandbyGuest():
   Issues a command to the guest operating system asking it to prepare for a suspend operation. Returns immediately and does not wait for the guest operating system to complete the operation.


  Privilege:
               VirtualMachine.Interact.Suspend



  Args:


  Returns:
    None
         

  Raises:

    `vim.fault.ToolsUnavailable`_: 
       if VMware Tools is not running.

    `vim.fault.TaskInProgress`_: 
       if the virtual machine is busy.

    `vim.fault.InvalidState`_: 
       if the operation cannot be performed because of the virtual machine's current state. For example, if the virtual machine configuration information is not available.

    `vim.fault.InvalidPowerState`_: 
       if the power state is not powered on.


AnswerVM(questionId, answerChoice):
   Responds to a question that is blocking this virtual machine.


  Privilege:
               VirtualMachine.Interact.AnswerQuestion



  Args:
    questionId (`str`_):
       The value from QuestionInfo.id that identifies the question to answer.


    answerChoice (`str`_):
       The contents of the QuestionInfo.choice.value array element that identifies the desired answer.




  Returns:
    None
         

  Raises:

    `vim.fault.ConcurrentAccess`_: 
       if the question has been or is being answered by another thread or user.

    `vmodl.fault.InvalidArgument`_: 
       if the questionId does not apply to this virtual machine. For example, this can happen if another client already answered the message.


CustomizeVM(spec):
   Customizes a virtual machine's guest operating system.


  Privilege:
               VirtualMachine.Provisioning.Customize



  Args:
    spec (`vim.vm.customization.Specification`_):
       The customization specification object.




  Returns:
     `vim.Task`_:
         

  Raises:

    `vim.fault.CustomizationFault`_: 
       A subclass of CustomizationFault is thrown.


CheckCustomizationSpec(spec):
   Checks the customization specification against the virtual machine configuration. For example, this is used on a source virtual machine before a clone operation to catch customization failure before the disk copy. This checks the specification's internal consistency as well as for compatibility with this virtual machine's configuration.


  Privilege:
               VirtualMachine.Provisioning.Customize



  Args:
    spec (`vim.vm.customization.Specification`_):
       The customization specification to check.




  Returns:
    None
         

  Raises:

    `vim.fault.CustomizationFault`_: 
       A subclass of CustomizationFault is thrown.


MigrateVM(pool, host, priority, state):
   Migrates a virtual machine's execution to a specific resource pool or host.Requires Resource.HotMigrate privilege if the virtual machine is powered on or Resource.ColdMigrate privilege if the virtual machine is powered off or suspended.


  Privilege:
               dynamic



  Args:
    pool (`vim.ResourcePool`_, optional):
       The target resource pool for the virtual machine. If the pool parameter is left unset, the virtual machine's current pool is used as the target pool.


    host (`vim.HostSystem`_, optional):
       The target host to which the virtual machine is intended to migrate. The host parameter may be left unset if the compute resource associated with the target pool represents a stand-alone host or a DRS-enabled cluster. In the former case the stand-alone host is used as the target host. In the latter case, the DRS system selects an appropriate target host from the cluster.


    priority (`vim.VirtualMachine.MovePriority`_):
       The task priority (@see vim.VirtualMachine.MovePriority).


    state (`vim.VirtualMachine.PowerState`_, optional):
       If specified, the virtual machine migrates only if its state matches the specified state.




  Returns:
     `vim.Task`_:
         

  Raises:

    `vim.fault.MigrationFault`_: 
       if it is not possible to migrate the virtual machine to the destination host. This is typically due to hosts being incompatible, such as mismatch in network polices or access to networks and datastores. Typically, a more specific subclass is thrown.

    `vim.fault.FileFault`_: 
       if, in a case where the virtual machine configuration file must be copied, the destination location for that file does not have the necessary file access permissions.

    `vim.fault.Timedout`_: 
       if one of the phases of the migration process times out.

    `vim.fault.InsufficientResourcesFault`_: 
       if this operation would violate a resource usage policy.

    `vim.fault.InvalidState`_: 
       if the operation cannot be performed because of the virtual machine's current state or the target host's current state. For example, if the virtual machine configuration information is not available or if the target host is disconnected or in maintenance mode.

    `vim.fault.VmConfigFault`_: 
       if the virtual machine is not compatible with the destination host. Typically, a specific subclass of this exception is thrown, such as IDEDiskNotSupported.

    `vmodl.fault.NotSupported`_: 
       if the virtual machine is marked as a template.

    `vmodl.fault.InvalidArgument`_: 
       if the target host and target pool are not associated with the same compute resource or if the host parameter is left unset when the target pool is associated with a non-DRS cluster.

    `vim.fault.InvalidPowerState`_: 
       if the state argument is set and the virtual machine does not have that power state.

    `vim.fault.NoActiveHostInCluster`_: 
       if a target host is not specified and the cluster associated with the target pool does not contain at least one potential target host. A host must be connected and not in maintenance mode in order to be considered as a potential target host.


RelocateVM(spec, priority):
   Relocates a virtual machine's virtual disks to a specific location; optionally moves the virtual machine to a different host as well. Starting from VCenter 5.1, this API also supports relocating a template to a new host should the current host becomes inactive. If spec.host is specified, this API attempts to relocate the template to the specified host; otherwise, this API will select a suitable host.Additionally requires the Resource.HotMigrate privilege if the virtual machine is powered on (for Storage VMotion), and Datastore.AllocateSpace on any datastore the virtual machine or its disks are relocated to.If the "pool" field of the RelocateSpec is set, additionally requires the Resource.AssignVMToPool privilege held on the specified pool.


  Privilege:
               Resource.ColdMigrate



  Args:
    spec (`vim.vm.RelocateSpec`_):
       The specification of where to relocate the virtual machine.


    priority (`vim.VirtualMachine.MovePriority`_, optional, since `vSphere API 4.0`_ ):
       The task priority (@see vim.VirtualMachine.MovePriority).




  Returns:
     `vim.Task`_:
         

  Raises:

    `vim.fault.InvalidState`_: 
       if the operation cannot be performed because of the host or virtual machine's current state. For example, if the host is in maintenance mode, or if the virtual machine's configuration information is not available.

    `vim.fault.InvalidDatastore`_: 
       if the operation cannot be performed on the target datastores.

    `vim.fault.MigrationFault`_: 
       if it is not possible to migrate the virtual machine to the destination host. This is typically due to hosts being incompatible, such as mismatch in network polices or access to networks and datastores. Typically, a more specific subclass is thrown.

    `vim.fault.VmConfigFault`_: 
       if the virtual machine is not compatible with the destination host. Typically, a specific subclass of this exception is thrown, such as IDEDiskNotSupported.

    `vim.fault.FileFault`_: 
       if there is an error accessing the virtual machine files.

    `vim.fault.Timedout`_: 
       if one of the phases of the relocate process times out.

    `vim.fault.InsufficientResourcesFault`_: 
       if this operation would violate a resource usage policy.

    `vmodl.fault.NotSupported`_: 
       if the virtual machine is marked as a template.

    `vmodl.fault.InvalidArgument`_: 
       in the following cases:
        * the target host and target pool are not associated with the same compute resource
        * the target pool represents a cluster without DRS enabled, and the host is not specified
        * Datastore in a diskLocator entry is not specified
        * the specified device ID cannot be found in the virtual machine's current configuration
        * the object specified in relocate cannot be found

    `vim.fault.DisallowedOperationOnFailoverHost`_: 
       if the virtual machine is powered on and is being migrated to a failover host. See `ClusterFailoverHostAdmissionControlPolicy`_ .


Clone(folder, name, spec):
   Creates a clone of this virtual machine. If the virtual machine is used as a template, this method corresponds to the deploy command.Any % (percent) character used in this name parameter must be escaped, unless it is used to start an escape sequence. Clients may also escape any other characters in this name parameter.The privilege required on the source virtual machine depends on the source and destination types:
    * source is virtual machine, destination is virtual machine - VirtualMachine.Provisioning.Clone
    * source is virtual machine, destination is template - VirtualMachine.Provisioning.CreateTemplateFromVM
    * source is template, destination is virtual machine - VirtualMachine.Provisioning.DeployTemplate
    * source is template, destination is template - VirtualMachine.Provisioning.CloneTemplateIf customization is requested in the CloneSpec, then the VirtualMachine.Provisioning.Customize privilege must also be held on the source virtual machine.The Resource.AssignVMToPool privilege is also required for the resource pool specified in the CloneSpec, if the destination is not a template. The Datastore.AllocateSpace privilege is required on all datastores where the clone is created.


  Privilege:



  Args:
    folder (`vim.Folder`_):
       The location of the new virtual machine.


    name (`str`_):
       The name of the new virtual machine.


    spec (`vim.vm.CloneSpec`_):
       Specifies how to clone the virtual machine.




  Returns:
     `vim.Task`_:
         the newly created VirtualMachine.

  Raises:

    `vim.fault.CustomizationFault`_: 
       if a customization error happens. Typically, a specific subclass of this exception is thrown.

    `vim.fault.InvalidState`_: 
       if the operation cannot be performed because of the virtual machine's current state. For example, if the virtual machine configuration information is not available.

    `vim.fault.InvalidDatastore`_: 
       if the operation cannot be performed on the target datastores.

    `vim.fault.TaskInProgress`_: 
       if the virtual machine is busy.

    `vim.fault.VmConfigFault`_: 
       if the virtual machine is not compatible with the destination host. Typically, a specific subclass of this exception is thrown, such as IDEDiskNotSupported.

    `vim.fault.FileFault`_: 
       if there is an error accessing the virtual machine files.

    `vim.fault.MigrationFault`_: 
       if it is not possible to migrate the virtual machine to the destination host. This is typically due to hosts being incompatible, such as mismatch in network polices or access to networks and datastores. Typically, a more specific subclass is thrown.

    `vim.fault.InsufficientResourcesFault`_: 
       if this operation would violate a resource usage policy.

    `vmodl.fault.InvalidArgument`_: 
       if the host cannot run this virtual machine.

    `vmodl.fault.NotSupported`_: 
       if the operation is not supported by the current agent.


ExportVm():
   Obtains an export lease on this virtual machine. The export lease contains a list of URLs for the virtual disks for this virtual machine, as well as a ticket giving access to the URLs.See `HttpNfcLease`_ for information on how to use the lease.
  since: `vSphere API 4.0`_


  Privilege:
               VApp.Export



  Args:


  Returns:
    `vim.HttpNfcLease`_:
         The export lease on this `VirtualMachine`_ . The export task continues running until the lease is completed by the caller.

  Raises:

    `vim.fault.InvalidPowerState`_: 
       if the virtual machine is powered on.

    `vim.fault.TaskInProgress`_: 
       if the virtual machine is busy.

    `vim.fault.InvalidState`_: 
       if the operation cannot be performed because of the virtual machine's current state. For example, if the virtual machine configuration information is not available.

    `vim.fault.FileFault`_: 
       if there is an error accessing the virtual machine files.


MarkAsTemplate():
   Marks a VirtualMachine object as being used as a template. Note: A VirtualMachine marked as a template cannot be powered on.


  Privilege:
               VirtualMachine.Provisioning.MarkAsTemplate



  Args:


  Returns:
    None
         

  Raises:

    `vim.fault.InvalidState`_: 
       if the operation cannot be performed because of the virtual machine's current state. For example, if the virtual machine configuration information is not available.

    `vim.fault.VmConfigFault`_: 
       if the template is incompatible with the host, such as the files are not accessible.

    `vim.fault.FileFault`_: 
       if there is an error accessing the virtual machine files.

    `vmodl.fault.NotSupported`_: 
       if marking a virtual machine as a template is not supported.

    `vim.fault.InvalidPowerState`_: 
       if the virtual machine is not powered off.


MarkAsVirtualMachine(pool, host):
   Clears the 'isTemplate' flag and reassociates the virtual machine with a resource pool and host.


  Privilege:
               VirtualMachine.Provisioning.MarkAsVM



  Args:
    pool (`vim.ResourcePool`_):
       Resource pool to associate with the virtual machine.


    host (`vim.HostSystem`_, optional):
       The target host on which the virtual machine is intended to run. The host parameter must specify a host that is a member of the ComputeResource indirectly specified by the pool. For a stand-alone host or a cluster with DRS, it can be omitted and the system selects a default.




  Returns:
    None
         

  Raises:

    `vim.fault.InvalidState`_: 
       if the virtual machine is not marked as a template.

    `vim.fault.InvalidDatastore`_: 
       if the operation cannot be performed on the target datastores.

    `vim.fault.VmConfigFault`_: 
       if the virtual machine is not compatible with the host. For example, a DisksNotSupported fault if the destination host does not support the disk backings of the template.

    `vim.fault.FileFault`_: 
       if there is an error accessing the virtual machine files.

    `vmodl.fault.NotSupported`_: 
       if marking a template as a virtual machine is not supported.


UnregisterVM():
   Removes this virtual machine from the inventory without removing any of the virtual machine's files on disk. All high-level information stored with the management server (ESX Server or VirtualCenter) is removed, including information such as statistics, resource pool association, permissions, and alarms.Use the Folder.RegisterVM method to recreate a VirtualMachine object from the set of virtual machine files by passing in the path to the configuration file. However, the VirtualMachine managed object that results typically has different objects ID and may inherit a different set of permissions.


  Privilege:
               VirtualMachine.Inventory.Unregister



  Args:


  Returns:
    None
         

  Raises:

    `vim.fault.TaskInProgress`_: 
       if the virtual machine is busy.

    `vim.fault.InvalidPowerState`_: 
       if the virtual machine is powered on.


ResetGuestInformation():
   Clears cached guest information. Guest information can be cleared only if the virtual machine is powered off.This method can be useful if stale information is cached, preventing an IP address or MAC address from being reused.


  Privilege:
               VirtualMachine.Config.ResetGuestInfo



  Args:


  Returns:
    None
         

  Raises:

    `vim.fault.InvalidState`_: 
       if the virtual machine is not powered off.

    `vmodl.fault.NotSupported`_: 
       if the virtual machine is marked as a template.


MountToolsInstaller():
   Mounts the VMware Tools CD installer as a CD-ROM for the guest operating system. To monitor the status of the tools install, clients should check the tools status, `toolsVersionStatus`_ and `toolsRunningStatus`_ 


  Privilege:
               VirtualMachine.Interact.ToolsInstall



  Args:


  Returns:
    None
         

  Raises:

    `vim.fault.InvalidState`_: 
       if the virtual machine is not running, or the VMware Tools CD is already mounted.

    `vim.fault.VmConfigFault`_: 
       vim.fault.VmConfigFault

    `vim.fault.VmToolsUpgradeFault`_: 
       if the VMware Tools CD failed to mount.


UnmountToolsInstaller():
   Unmounts VMware Tools installer CD.


  Privilege:
               VirtualMachine.Interact.ToolsInstall



  Args:


  Returns:
    None
         

  Raises:

    `vim.fault.InvalidState`_: 
       if the virtual machine is not running, VMware Tools is not running or the VMware Tools CD is already mounted.

    `vim.fault.VmConfigFault`_: 
       vim.fault.VmConfigFault


UpgradeTools(installerOptions):
   Begins the tools upgrade process. To monitor the status of the tools install, clients should check the tools status, `toolsVersionStatus`_ and `toolsRunningStatus`_ .


  Privilege:
               VirtualMachine.Interact.ToolsInstall



  Args:
    installerOptions (`str`_, optional):
       Command line options passed to the installer to modify the installation procedure for tools.




  Returns:
     `vim.Task`_:
         

  Raises:

    `vim.fault.InvalidState`_: 
       if the virtual machine is not running or is suspended.

    `vim.fault.TaskInProgress`_: 
       if an upgrade is already taking place.

    `vim.fault.VmToolsUpgradeFault`_: 
       if the upgrade failed.

    `vim.fault.ToolsUnavailable`_: 
       if VMware Tools is not running.

    `vim.fault.VmConfigFault`_: 
       vim.fault.VmConfigFault

    `vmodl.fault.NotSupported`_: 
       if upgrading tools is not supported.


AcquireMksTicket():
   Creates and returns a one-time credential used in establishing a remote mouse-keyboard-screen connection to this virtual machine. The correct function of this method depends on being able to retrieve TCP binding information about the server end of the client connection that is requesting the ticket. If such information is not available, the NotSupported fault is thrown. This method is appropriate for SOAP and authenticated connections, which are both TCP-based connections.


  Privilege:
               VirtualMachine.Interact.ConsoleInteract



  Args:


  Returns:
    `vim.VirtualMachine.MksTicket`_:
         A one-time credential used in establishing a remote mouse-keyboard-screen connection.

  Raises:

    `vmodl.fault.NotSupported`_: 
       if it cannot retrieve TCP binding information about the client connection. For example, TCP binding information is not available for a client connection that is not TCP-based.


AcquireTicket(ticketType):
   Creates and returns a one-time credential used in establishing a specific connection to this virtual machine, for example, a ticket type of mks can be used to establish a remote mouse-keyboard-screen connection.A client using this ticketing mechanism must have network connectivity to the ESX server where the virtual machine is running, and the ESX server must be reachable to the management client from the address made available to the client via the ticket.Acquiring a virtual machine ticket requires different privileges depending on the types of ticket:
    * VirtualMachine.Interact.DeviceConnection if requesting a device ticket.
    * VirtualMachine.Interact.GuestControl if requesting a guestControl ticket.
    * VirtualMachine.Interact.ConsoleInteract if requesting an mks ticket.
  since: `vSphere API 4.1`_


  Privilege:
               dynamic



  Args:
    ticketType (`str`_):
       The type of service to acquire, the set of possible values is described in `VirtualMachineTicketType`_ .




  Returns:
    `vim.VirtualMachine.Ticket`_:
         A one-time credential used in establishing a remote connection to this virtual machine.

  Raises:

    `vim.fault.InvalidState`_: 
       if the virtual machine is not connected.


SetScreenResolution(width, height):
   Sets the console window's resolution as specified.


  Privilege:
               VirtualMachine.Interact.ConsoleInteract



  Args:
    width (`int`_):
       The screen width that should be set.


    height (`int`_):
       The screen height that should be set.




  Returns:
    None
         

  Raises:

    `vim.fault.InvalidState`_: 
       if the virtual machine is not connected.

    `vim.fault.ToolsUnavailable`_: 
       if VMware Tools is not running.

    `vmodl.fault.NotSupported`_: 
       if the Guest Operating system does not support setting the screen resolution.

    `vim.fault.InvalidPowerState`_: 
       if the power state is not poweredOn.


DefragmentAllDisks():
   Defragment all virtual disks attached to this virtual machine.
  since: `VI API 2.5`_


  Privilege:
               VirtualMachine.Interact.DefragmentAllDisks



  Args:


  Returns:
    None
         

  Raises:

    `vim.fault.InvalidState`_: 
       if the virtual machine is not connected.

    `vim.fault.InvalidPowerState`_: 
       if the virtual machine is poweredOn.

    `vim.fault.TaskInProgress`_: 
       if the virtual machine is busy.

    `vim.fault.FileFault`_: 
       if there is an error accessing the disk files.


CreateSecondaryVM(host):
   Creates a secondary virtual machine to be part of this fault tolerant group.If a host is specified, the secondary virtual machine will be created on it. Otherwise, a host will be selected by the system.If a FaultToleranceConfigSpec is specified, the virtual machine's configuration files and disks will be created in the specified datastores.If the primary virtual machine (i.e., this virtual machine) is powered on when the secondary is created, an attempt will be made to power on the secondary on a system selected host. If the cluster is a DRS cluster, DRS will be invoked to obtain a placement for the new secondary virtual machine. If the DRS recommendation (see `ClusterRecommendation`_ ) is automatic, it will be automatically executed. Otherwise, the recommendation will be returned to the caller of this method and the secondary will remain powered off until the recommendation is approved using `ApplyRecommendation`_ . Failure to power on the secondary virtual machine will not fail the creation of the secondary.
  since: `vSphere API 4.0`_


  Privilege:
               VirtualMachine.Interact.CreateSecondary



  Args:
    host (`vim.HostSystem`_, optional):
       The host where the secondary virtual machine is to be created and powered on. If no host is specified, a compatible host will be selected by the system. If a host cannot be found for the secondary or the specified host is not suitable, the secondary will not be created and a fault will be returned.




  Returns:
     `vim.Task`_:
         

  Raises:

    `vim.fault.TaskInProgress`_: 
       if the virtual machine is busy.

    `vim.fault.InvalidState`_: 
       if the virtual machine's configuration information is not available.

    `vim.fault.InsufficientResourcesFault`_: 
       if this operation would violate a resource usage policy.

    `vim.fault.VmFaultToleranceIssue`_: 
       if any error is encountered with the fault tolerance configuration of the virtual machine. Typically, a more specific fault like FaultToleranceNotLicensed is thrown.

    `vim.fault.FileFault`_: 
       if there is a problem accessing the virtual machine on the filesystem.

    `vim.fault.VmConfigFault`_: 
       if a configuration issue prevents creating the secondary. Typically, a more specific fault such as VmConfigIncompatibleForFaultTolerance is thrown.

    `vmodl.fault.NotSupported`_: 
       if the virtual machine is marked as a template, or it is not in a vSphere HA enabled cluster.

    `vmodl.fault.ManagedObjectNotFound`_: 
       if a host is specified and it does not exist.


TurnOffFaultToleranceForVM():
   Removes all secondary virtual machines associated with the fault tolerant group and turns off protection for this virtual machine. This operation can only be invoked from the primary virtual machine in the group.
  since: `vSphere API 4.0`_


  Privilege:
               VirtualMachine.Interact.TurnOffFaultTolerance



  Args:


  Returns:
     `vim.Task`_:
         

  Raises:

    `vim.fault.TaskInProgress`_: 
       if the virtual machine is busy.

    `vim.fault.VmFaultToleranceIssue`_: 
       if any error is encountered with the fault tolerance configuration of the virtual machine. Typically, a more specific fault like InvalidOperationOnSecondaryVm is thrown.

    `vim.fault.InvalidState`_: 
       if the host is in maintenance mode or if the virtual machine's configuration information is not available.


MakePrimaryVM(vm):
   Makes the specified secondary virtual machine from this fault tolerant group as the primary virtual machine.
  since: `vSphere API 4.0`_


  Privilege:
               VirtualMachine.Interact.MakePrimary



  Args:
    vm (`vim.VirtualMachine`_):
       The secondary virtual machine specified will be made the primary virtual machine. This field must specify a secondary virtual machine that is part of the fault tolerant group that this virtual machine is currently associated with. It can only be invoked from the primary virtual machine in the group.




  Returns:
     `vim.Task`_:
         

  Raises:

    `vim.fault.TaskInProgress`_: 
       if the virtual machine is busy.

    `vim.fault.VmFaultToleranceIssue`_: 
       if any error is encountered with the fault tolerance configuration of the virtual machine. Typically, a more specific fault like InvalidOperationOnSecondaryVm is thrown.

    `vim.fault.InvalidState`_: 
       if the host is in maintenance mode or if the virtual machine's configuration information is not available.


TerminateFaultTolerantVM(vm):
   Terminates the specified secondary virtual machine in a fault tolerant group. This can be used to test fault tolerance on a given virtual machine, and should be used with care.
  since: `vSphere API 4.0`_


  Privilege:
               VirtualMachine.Interact.TerminateFaultTolerantVM



  Args:
    vm (`vim.VirtualMachine`_, optional):
       The secondary virtual machine specified will be terminated, allowing fault tolerance to activate. If no virtual machine is specified, all secondary virtual machines will be terminated. If vm is a primary, InvalidArgument exception is thrown. This field must specify a virtual machine that is part of the fault tolerant group that this virtual machine is currently associated with. It can only be invoked from the primary virtual machine in the group. If the primary virtual machine is terminated, an available secondary virtual machine will be promoted to primary. If no secondary exists, an exception will be thrown and the primary virtual machine will not be terminated. If a secondary virtual machine is terminated, it may be respawned on a potentially different host.




  Returns:
     `vim.Task`_:
         

  Raises:

    `vim.fault.TaskInProgress`_: 
       if the virtual machine is busy.

    `vim.fault.VmFaultToleranceIssue`_: 
       if any error is encountered with the fault tolerance configuration of the virtual machine. Typically, a more specific fault like InvalidOperationOnSecondaryVm is thrown.

    `vim.fault.InvalidState`_: 
       if the host is in maintenance mode or if the virtual machine's configuration information is not available.


DisableSecondaryVM(vm):
   Disables the specified secondary virtual machine in this fault tolerant group. The specified secondary will not be automatically started on a subsequent power-on of the primary virtual machine. This operation could leave the primary virtual machine in a non-fault tolerant state.
  since: `vSphere API 4.0`_


  Privilege:
               VirtualMachine.Interact.DisableSecondary



  Args:
    vm (`vim.VirtualMachine`_):
       The secondary virtual machine specified will be disabed. This field must specify a secondary virtual machine that is part of the fault tolerant group that this virtual machine is currently associated with. It can only be invoked from the primary virtual machine in the group.




  Returns:
     `vim.Task`_:
         

  Raises:

    `vim.fault.TaskInProgress`_: 
       if the virtual machine is busy.

    `vim.fault.VmFaultToleranceIssue`_: 
       if any error is encountered with the fault tolerance configuration of the virtual machine. Typically, a more specific fault like InvalidOperationOnSecondaryVm is thrown.

    `vim.fault.InvalidState`_: 
       if the host is in maintenance mode or if the virtual machine's configuration information is not available.


EnableSecondaryVM(vm, host):
   Enables the specified secondary virtual machine in this fault tolerant group.This operation is used to enable a secondary virtual machine that was previously disabled by the `DisableSecondaryVM_Task`_ call. The specified secondary will be automatically started whenever the primary is powered on.If the primary virtual machine (i.e., this virtual machine) is powered on when the secondary is enabled, an attempt will be made to power on the secondary. If a host was specified in the method call, this host will be used. If a host is not specified, one will be selected by the system. In the latter case, if the cluster is a DRS cluster, DRS will be invoked to obtain a placement for the new secondary virtual machine. If the DRS recommendation (see `ClusterRecommendation`_ ) is automatic, it will be executed. Otherwise, the recommendation will be returned to the caller of this method and the secondary will remain powered off until the recommendation is approved using `ApplyRecommendation`_ .
  since: `vSphere API 4.0`_


  Privilege:
               VirtualMachine.Interact.EnableSecondary



  Args:
    vm (`vim.VirtualMachine`_):
       The secondary virtual machine specified will be enabled. This field must specify a secondary virtual machine that is part of the fault tolerant group that this virtual machine is currently associated with. It can only be invoked from the primary virtual machine in the group.


    host (`vim.HostSystem`_, optional):
       The host on which the secondary virtual machine is to be enabled and possibly powered on. If no host is specified, a compatible host will be selected by the system. If the secondary virtual machine is not compatible with the specified host, the secondary will not be re-enabled and a fault will be returned.




  Returns:
     `vim.Task`_:
         

  Raises:

    `vim.fault.TaskInProgress`_: 
       if the virtual machine is busy.

    `vim.fault.VmFaultToleranceIssue`_: 
       if any error is encountered with the fault tolerance configuration of the virtual machine. Typically, a more specific fault like InvalidOperationOnSecondaryVm is thrown.

    `vim.fault.InvalidState`_: 
       if the virtual machine's configuration information is not available, if the secondary virtual machine is not disabled, or if a power-on is attempted and one is already in progress.

    `vim.fault.VmConfigFault`_: 
       if a configuration issue prevents enabling the secondary. Typically, a more specific fault such as VmConfigIncompatibleForFaultTolerance is thrown.

    `vmodl.fault.ManagedObjectNotFound`_: 
       if a host is specified and it does not exist.


SetDisplayTopology(displays):
   Sets the console window's display topology as specified.
  since: `vSphere API 4.0`_


  Privilege:
               VirtualMachine.Interact.ConsoleInteract



  Args:
    displays (`vim.VirtualMachine.DisplayTopology`_):
       The topology for each monitor that the virtual machine's display must span.




  Returns:
    None
         

  Raises:

    `vim.fault.InvalidState`_: 
       if the virtual machine is not connected.

    `vim.fault.ToolsUnavailable`_: 
       if VMware Tools is not running.

    `vmodl.fault.NotSupported`_: 
       if the Guest Operating system does not support setting the display topology

    `vim.fault.InvalidPowerState`_: 
       if the power state is not poweredOn.


StartRecording(name, description):
   Initiates a recording session on this virtual machine. As a side effect, this operation creates a snapshot on the virtual machine, which in turn becomes the current snapshot.This is an experimental interface that is not intended for use in production code.
  since: `vSphere API 4.0`_


  Privilege:
               VirtualMachine.Interact.Record



  Args:
    name (`str`_):
       The name for the snapshot associated with this recording. The name need not be unique for this virtual machine.


    description (`str`_, optional):
       A description for the snapshot associated with this recording. If omitted, a default description may be provided.




  Returns:
     `vim.Task`_:
         the newly created Snapshot associated with this recording.

  Raises:

    `vim.fault.InvalidState`_: 
       if the operation cannot be performed because of the virtual machine's current state. For example, the virtual machine configuration information is not available.

    `vim.fault.InvalidPowerState`_: 
       if the operation cannot be performed in the current power state of the virtual machine.

    `vim.fault.TaskInProgress`_: 
       if the virtual machine is busy.

    `vim.fault.FileFault`_: 
       if there is a problem with creating or accessing one or more files needed for this operation.

    `vim.fault.SnapshotFault`_: 
       if an error occurs during the snapshot operation. Typically, a more specific fault like MultipleSnapshotsNotSupported is thrown.

    `vim.fault.VmConfigFault`_: 
       vim.fault.VmConfigFault

    `vim.fault.RecordReplayDisabled`_: 
       if the record/replay config flag has not been enabled for this virtual machine.

    `vim.fault.HostIncompatibleForRecordReplay`_: 
       if the virtual machine is located on a host that does not support record/replay.

    `vim.fault.InvalidName`_: 
       if the specified snapshot name is invalid.

    `vmodl.fault.NotSupported`_: 
       if the host product does not support record functionality or if the virtual machine does not support this

    `vim.fault.VmConfigIncompatibleForRecordReplay`_: 
       if the virtual machine configuration is incompatible for recording.


StopRecording():
   Stops a currently active recording session on this virtual machine.This is an experimental interface that is not intended for use in production code.
  since: `vSphere API 4.0`_


  Privilege:
               VirtualMachine.Interact.Record



  Args:


  Returns:
     `vim.Task`_:
         

  Raises:

    `vim.fault.InvalidState`_: 
       if the operation cannot be performed because of the virtual machine's current state. For example, the virtual machine does not have an active recording session.

    `vim.fault.InvalidPowerState`_: 
       if the operation cannot be performed in the current power state of the virtual machine.

    `vim.fault.TaskInProgress`_: 
       if the virtual machine is busy.

    `vim.fault.FileFault`_: 
       if there is a problem with creating or accessing one or more files needed for this operation.

    `vim.fault.SnapshotFault`_: 
       if an error occurs during the snapshot operation. Typically, a more specific fault like InvalidSnapshotFormat is thrown.

    `vmodl.fault.NotSupported`_: 
       if the host product does not support record/replay functionality or if the virtual machine does not support this capability.


StartReplaying(replaySnapshot):
   Starts a replay session on this virtual machine. As a side effect, this operation updates the current snapshot of the virtual machine.This is an experimental interface that is not intended for use in production code.
  since: `vSphere API 4.0`_


  Privilege:
               VirtualMachine.Interact.Replay



  Args:
    replaySnapshot (`vim.vm.Snapshot`_):
       The snapshot from which to start the replay. This snapshot must have been created by a record operation on the virtual machine.




  Returns:
     `vim.Task`_:
         

  Raises:

    `vim.fault.InvalidState`_: 
       if the operation cannot be performed because of the virtual machine's current state. For example, the virtual machine configuration information is not available.

    `vim.fault.InvalidPowerState`_: 
       if the operation cannot be performed in the current power state of the virtual machine.

    `vim.fault.TaskInProgress`_: 
       if the virtual machine is busy.

    `vim.fault.FileFault`_: 
       if there is a problem with creating or accessing one or more files needed for this operation.

    `vim.fault.SnapshotFault`_: 
       if an error occurs during the snapshot operation. Typically, a more specific fault like InvalidSnapshotFormat is thrown.

    `vim.fault.NotFound`_: 
       if replaySnapshot is no longer present.

    `vim.fault.VmConfigFault`_: 
       vim.fault.VmConfigFault

    `vim.fault.RecordReplayDisabled`_: 
       if the record/replay config flag has not been enabled for this virtual machine.

    `vim.fault.HostIncompatibleForRecordReplay`_: 
       if the virtual machine is located on a host that does not support record/replay.

    `vmodl.fault.NotSupported`_: 
       if the host product does not support record/replay functionality or if the virtual machine does not support this capability.

    `vmodl.fault.InvalidArgument`_: 
       if replaySnapshot is not a valid snapshot associated with a recorded session on this virtual machine.

    `vim.fault.VmConfigIncompatibleForRecordReplay`_: 
       if the virtual machine configuration is incompatible for replaying.


StopReplaying():
   Stops a replay session on this virtual machine.This is an experimental interface that is not intended for use in production code.
  since: `vSphere API 4.0`_


  Privilege:
               VirtualMachine.Interact.Replay



  Args:


  Returns:
     `vim.Task`_:
         

  Raises:

    `vim.fault.InvalidState`_: 
       if the operation cannot be performed because of the virtual machine's current state. For example, the virtual machine does not have an active recording session.

    `vim.fault.InvalidPowerState`_: 
       if the operation cannot be performed in the current power state of the virtual machine.

    `vim.fault.TaskInProgress`_: 
       if the virtual machine is busy.

    `vim.fault.FileFault`_: 
       if there is a problem with creating or accessing one or more files needed for this operation.

    `vim.fault.SnapshotFault`_: 
       if an error occurs during the snapshot operation. Typically, a more specific fault like InvalidSnapshotFormat is thrown.

    `vmodl.fault.NotSupported`_: 
       if the host product does not support record/replay functionality or if the virtual machine does not support this capability.


PromoteDisks(unlink, disks):
   Promotes disks on this virtual machine that have delta disk backings.A delta disk backing is a way to preserve a virtual disk backing at some point in time. A delta disk backing is a file backing which in turn points to the original virtual disk backing (the parent). After a delta disk backing is added, all writes go to the delta disk backing. All reads first try the delta disk backing and then try the parent backing if needed.Promoting does two things
    * If the unlink parameter is true, any disk backing which is shared shared by multiple virtual machines is copied so that this virtual machine has its own unshared version. Copied files always end up in the virtual machine's home directory.
    * Any disk backing which is not shared between multiple virtual machines and is not associated with a snapshot is consolidated with its child backing.If the unlink parameter is true, the net effect of this operation is improved read performance, at the cost of disk space. If the unlink parameter is false the net effect is improved read performance at the cost of inhibiting future sharing.This operation is only supported if `deltaDiskBackingsSupported`_ is true.This operation is only supported on VirtualCenter.
  since: `vSphere API 4.0`_


  Privilege:
               VirtualMachine.Provisioning.PromoteDisks



  Args:
    unlink (`bool`_):
       If true, then these disks will be unlinked before consolidation.


    disks (`vim.vm.device.VirtualDisk`_, optional):
       The set of disks that are to be promoted. If this value is unset or the array is empty, all disks which have delta disk backings are promoted.




  Returns:
     `vim.Task`_:
         

  Raises:

    `vim.fault.InvalidState`_: 
       if the virtual machine is not ready to respond to such requests.

    `vim.fault.InvalidPowerState`_: 
       if the virtual machine is not powered off or suspended

    `vim.fault.TaskInProgress`_: 
       if the virtual machine is busy.

    `vmodl.fault.NotSupported`_: 
       if the host doesnt support disk promotion APIs.


CreateScreenshot():
   Create a screen shot of a virtual machine.
  since: `vSphere API 4.0`_


  Privilege:
               VirtualMachine.Interact.CreateScreenshot



  Args:


  Returns:
     `vim.Task`_:
         Returns the datastore path of the created screen shot.

  Raises:

    `vim.fault.TaskInProgress`_: 
       if the virtual machine is busy.

    `vim.fault.FileFault`_: 
       if there is a problem with creating or accessing one or more files needed for this operation.

    `vim.fault.InvalidState`_: 
       if the virtual machine is not ready to respond to such requests.

    `vim.fault.InvalidPowerState`_: 
       if the virtual machine is not powered on.


QueryChangedDiskAreas(snapshot, deviceKey, startOffset, changeId):
   Get a list of areas of a virtual disk belonging to this VM that have been modified since a well-defined point in the past. The beginning of the change interval is identified by "changeId", while the end of the change interval is implied by the snapshot ID passed in.Note that the result of this function may contain "false positives" (i.e: flag areas of the disk as modified that are not). However, it is guaranteed that no changes will be missed.
  since: `vSphere API 4.0`_


  Privilege:
               VirtualMachine.Provisioning.DiskRandomRead



  Args:
    snapshot (`vim.vm.Snapshot`_, optional):
       Snapshot for which changes that have been made sine "changeId" should be computed. If not set, changes are computed against the "current" snapshot of the virtual machine. However, using the "current" snapshot will only work for virtual machines that are powered off.


    deviceKey (`int`_):
       Identifies the virtual disk for which to compute changes.


    startOffset (`long`_):
       Start Offset in bytes at which to start computing changes. Typically, callers will make multiple calls to this function, starting with startOffset 0 and then examine the "length" property in the returned DiskChangeInfo structure, repeatedly calling queryChangedDiskAreas until a map forthe entire virtual disk has been obtained.


    changeId (`str`_):
       Identifyer referring to a point in the past that should be used as the point in time at which to begin including changes to the disk in the result. A typical use case would be a backup application obtaining a changeId from a virtual disk's backing info when performing a backup. When a subsequent incremental backup is to be performed, this change Id can be used to obtain a list of changed areas on disk.




  Returns:
    `vim.VirtualMachine.DiskChangeInfo`_:
         Returns a data structure specifying extents of the virtual disk that have changed since the thime the changeId string was obtained.

  Raises:

    `vim.fault.FileFault`_: 
       if the virtual disk files cannot be accessed/queried.

    `vim.fault.NotFound`_: 
       if the snapshot specified does not exist.

    `vmodl.fault.InvalidArgument`_: 
       if deviceKey does not specify a virtual disk, startOffset is beyond the end of the virtual disk or changeId is invalid or change tracking is not supported for this particular disk.


QueryUnownedFiles():
   For all files that belong to the vm, check that the file owner is set to the current datastore principal user, as set by `HostDatastoreSystem.ConfigureDatastorePrincipal`_ 
  since: `vSphere API 4.0`_


  Privilege:
               VirtualMachine.Config.QueryUnownedFiles



  Args:


  Returns:
    [`str`_]:
         The list of file paths for vm files whose ownership is not correct. Use `FileManager.ChangeOwner`_ to set the file ownership.


reloadVirtualMachineFromPath(configurationPath):
   Reloads the configuration for this virtual machine from a given datastore path. This is equivalent to unregistering and registering the virtual machine from a different path. The virtual machine's hardware configuration, snapshots, guestinfo variables etc. will be replaced based on the new configuration file. Other information associated with the virtual machine object, such as events and permissions, will be preserved.This method is only supported on vCenter Server. It can be invoked on inaccessible or orphaned virtual machines, but it cannot be invoked on powered on, connected virtual machines. Both the source virtual machine object and the destination path should be of the same type i.e. virtual machine or template. Reloading a virtual machine with a template or vice-versa is not supported.Note:Since the API replaces the source configuration with that of the destination, if the destination configuration does not refer to a valid virtual machine, it will create an invalid virtual machine object. This API should not be invoked on fault tolerant virtual machines since doing so will leave the original virtual machine's configuration in an invalid state. It is recommended that you turn off fault tolerance before invoking this API.
  since: `vSphere API 4.1`_


  Privilege:
               VirtualMachine.Config.ReloadFromPath



  Args:
    configurationPath (`str`_):




  Returns:
     `vim.Task`_:
         

  Raises:

    `vim.fault.InvalidPowerState`_: 
       if the virtual machine is powered on.

    `vim.fault.TaskInProgress`_: 
       if the virtual machine is busy.

    `vim.fault.FileFault`_: 
       if there is a problem creating or accessing the files needed for this operation.

    `vim.fault.InvalidState`_: 
       if the virtual machine is busy or not ready to respond to such requests.

    `vim.fault.VmConfigFault`_: 
       if the format / configuration of the virtual machine is invalid. Typically, a more specific fault is thrown such as InvalidFormat if the configuration file cannot be read, or InvalidDiskFormat if the disks cannot be read.

    `vim.fault.AlreadyExists`_: 
       if the virtual machine is already registered.

    `vmodl.fault.NotSupported`_: 
       if invoked on ESX server or if invoked on a virtual machine with the destination path for a template and vice-versa.


QueryFaultToleranceCompatibility():
   This API can be invoked to determine whether a virtual machine is compatible for Fault Tolerance. The API only checks for VM-specific factors that impact compatibility for Fault Tolerance. Other requirements for Fault Tolerance such as host processor compatibility, logging nic configuration and licensing are not covered by this API. The query returns a list of faults, each fault corresponding to a specific incompatibility. If a given virtual machine is compatible for Fault Tolerance, then the fault list returned will be empty.
  since: `vSphere API 4.1`_


  Privilege:
               VirtualMachine.Config.QueryFTCompatibility



  Args:


  Returns:
    [`vmodl.MethodFault`_]:
         

  Raises:

    `vim.fault.InvalidState`_: 
       if the operation cannot be performed because of the virtual machine's current state.

    `vim.fault.VmConfigFault`_: 
       if the virtual machine's configuration is invalid.

    `vmodl.fault.NotSupported`_: 
       if the virtual machine is a template or this operation is not supported.


TerminateVM():
   Do an immediate power off of a VM.This API issues a SIGKILL to the vmx process of the VM. Pending synchronous I/Os may not be written out before the vmx process dies depending on accessibility of the datastore.
  since: `vSphere API 5.0`_


  Privilege:
               VirtualMachine.Interact.PowerOff



  Args:


  Returns:
    None
         

  Raises:

    `vim.fault.InvalidState`_: 
       if the VM is not powered on or another issue prevents the operation from being performed.

    `vim.fault.TaskInProgress`_: 
       if the virtual machine is busy.

    `vmodl.fault.NotSupported`_: 
       if this operation is not supported.