Skip to content

Instantly share code, notes, and snippets.

View ovms342.ks
# Kickstart file for Oracle VM Server 3.4.2
install
eula Accepted
url --url=$tree
lang ja_JP.UTF-8
keyboard jp106
network --onboot yes --device eth0 --bootproto dhcp --noipv6
ovsagent --iscrypted XXXXXXXXXX
View ce.vmdk
# Disk DescriptorFile
version=4
encoding="UTF-8"
parentCID=ffffffff
isNativeSnapshot="no"
createType="vmfs"
# Extent description
RW 14540800 VMFS "ce.img"
View ntnx-cloud-init-test.txt
#cloud-config
hostname: cloudinit-test-01
write_files:
- path: /opt/test.f
content: |
cloud-init no
test file
View powernsx-prompt.ps1
$module_list = @(
"VMware.VimAutomation.Core",
"VMware.VimAutomation.Vds",
"PowerNSX"
)
Import-Module $module_list
$window_width = 120
$window_height = 40
$window_buffer = 3000
View vc-task.csv
Key Label Summary
host.OperationCleanupManager.createEntry createEntry createEntry
host.OperationCleanupManager.updateEntry updateEntry updateEntry
host.OperationCleanupManager.queryEntry queryEntry queryEntry
vm.guest.GuestOperationsManager.queryDisabledMethods Query disabled guest operations Returns a list of guest operations not supported by a virtual machine
profile.host.HostSpecificationManager.updateHostSpecification updateHostSpecification updateHostSpecification
profile.host.HostSpecificationManager.updateHostSubSpecification updateHostSubSpecification updateHostSubSpecification
profile.host.HostSpecificationManager.retrieveHostSpecification retrieveHostSpecification retrieveHostSpecification
profile.host.HostSpecificationManager.deleteHostSubSpecification deleteHostSubSpecification deleteHostSubSpecification
profile.host.HostSpecificationManager.deleteHostSpecification deleteHostSpecification deleteHostSpecification
View ntnx-health_checks.py
import json
import requests
cvm_ip = 'NutanixクラスタVIP'
cvm_user = 'ユーザ'
cvm_pass = 'パスワード'
def main():
base_url = 'https://' + cvm_ip + ':9440/PrismGateway/services/rest/v2.0/'
requests.packages.urllib3.disable_warnings()
View ntnx-health_checks.csv
0005566f-98ae-3f49-14de-0050568a38fb::111000 E-mail alerts check
0005566f-98ae-3f49-14de-0050568a38fb::103069 Host FQDN resolution
0005566f-98ae-3f49-14de-0050568a38fb::110253 Vstore VM Files Consistency Check
0005566f-98ae-3f49-14de-0050568a38fb::6005 CVM to CVM Connectivity
0005566f-98ae-3f49-14de-0050568a38fb::110012 Cloud Gflags Check
0005566f-98ae-3f49-14de-0050568a38fb::110248 Metro Vstore Symlinks Check
0005566f-98ae-3f49-14de-0050568a38fb::110006 Remote Site configuration
0005566f-98ae-3f49-14de-0050568a38fb::110007 Remote Site virtual external IP(VIP)
0005566f-98ae-3f49-14de-0050568a38fb::110249 Remote Stargate Version Check
0005566f-98ae-3f49-14de-0050568a38fb::110246 Clone Count Check
View ntnx-vm-ip.py
import sys
import json
import requests
args = sys.argv
vm_name = args[1]
cvm_ip = 'NutanixクラスタVIP'
cvm_user = 'ユーザ'
cvm_pass = 'パスワード'
View ntnx-host-stats.py
import sys
import json
import requests
import datetime
args = sys.argv
conf_file = args[1]
metrics_file_name = args[2]
with open(conf_file, "r") as file:
View prism-config.json
{
"prism_address": "Nutanix Cluster VIP",
"user_name": "ユーザ",
"password": "パスワード"
}
You can’t perform that action at this time.