天天看點

XenDesktop 之powershell 使用

1、禁止pvs類型桌面登出自動關機

set-brokerdesktopgroup -name "desktop group name" -shutdowndesktopsafteruse $false

2、調整傳遞組預設開啟計算機百分比,可用通配符“*”

set-brokerdesktopgroup "desktop group name"-peakbuffersizepercent 100 

3、為添加好的托管主機添加網絡

get-item xdhyp:\hostingunits\desktop02   擷取托管主機資訊以及相應配置格式參數

為托管主機添加網加網絡

 add-hyphostingunitnetwork -networkpathxdhyp:\connections\xs-cluster02\【desktop02.network這裡是要添加的網絡】 -literalpath xdhyp:\hostingunits\desktop02

 add-hyphostingunitnetwork -literalpath xdhyp:\hostingunits\ctx-pvs(連接配接)\ -networkpath xdhyp:\connections\bjvcsa\bj-datacenter.datacenter\vdi-pool.cluster\vlan1015.network

4、添加删除托管主機存儲

   預設存儲類型為 osstorage  ,pvd存儲類型為:personalvdiskstorage

添加存儲:add-hyphostingunitstorage -literalpath xdhyp:\hostingunits\desktop01 -storagepath xdhyp:\hostingunits\desktop01\lun01.storage

删除存儲:

remove-hyphostingunitstorage -literalpath xdhyp:\hostingunits\desktop01 -storagepath xdhyp:\hostingunits\desktoop\01\lun01.storage

删除pvd類型存儲:

remove-hyphostingunitstorage -literalpath xdhyp:\hostingunits\desktop01 -storagetype personalvdiskstorage -storagepath xdhyp:\hostingunits\desktoop\01\lun01.storage

删除臨時類型存儲

remove-hyphostingunitstorage -literalpath xdhyp:\hostingunits\ctx-mcs -storagetype temporarystorage -storagepath xdhyp:\hostingunits\ctx-mcs\lun01-8tb.storage

繼續閱讀