Hello,
do you want a basic xen server environment mapping script ?, you got it.
for starting it will list all the hosts and guests, in the future I will add UUID and more...
================================
echo off
set user=[]
set password=[]
set server=[]
del auto_host_list.txt /q
del auto_vm_list.txt /q
"C:\Program Files\Citrix\XenCenter\xe.exe" -s %server% -u %user% -pw %Password% host-list params=name-label,uuid >auto_host_list1.txt
for /f "tokens=1,2,3,4 delims=( " %%A in (auto_host_list1.txt) do (echo %%D >> auto_host_list.txt)
"C:\Program Files\Citrix\XenCenter\xe.exe" -s %server% -u %user% -pw %Password% vm-list params=name-label >auto_vm_list1.txt
for /f "tokens=1,2,3,4 delims=( " %%A in (auto_vm_list1.txt) do (
if NOT %%D==Control echo %%D >> auto_vm_list.txt
)
del auto_host_list1.txt /q
del auto_vm_list1.txt /q
================================
No comments:
Post a Comment