Hi all Virtual server running on data store of different luns. Need to find out which VM is running on physical drive presented to esxi. (luns) For eg I have 5 lun presented to esxi.(lun1 to ...
See more...
Hi all Virtual server running on data store of different luns. Need to find out which VM is running on physical drive presented to esxi. (luns) For eg I have 5 lun presented to esxi.(lun1 to 5) now i need to find out XYZ vm running on LUN 4 and need to find lun4 is running on which physical drive of esxi. Can anyone help me Regards PS
Hi All, Is there any way to find our VM created on local attached disk of esxi of its physical deatils like disk serial number/ make and model. For eg. I have esxi running and on top of it ...
See more...
Hi All, Is there any way to find our VM created on local attached disk of esxi of its physical deatils like disk serial number/ make and model. For eg. I have esxi running and on top of it VM running on locallay attached disk (das) multiple disk (raid 1 or raid 5) want to get the physical details of those disk like serial no/make /model/vendor etc. Thanks in advance
Hi Raj Its working perfectly can we get the out put result which runn on power cli screen. Will come to know which host failed and which host completed.
Thanks siva for reply We have esxi version of 5.1 /5.5 and 6.0 in datacenter Will this script work, actually not yet tried on other version of esxi will check in some time . Thanks PS
Hi Folks, Recently our Compliance team asked to provided esxi installation date of each esxi in vcenter available. After googling found VMware KB article Determining the installation date of a...
See more...
Hi Folks, Recently our Compliance team asked to provided esxi installation date of each esxi in vcenter available. After googling found VMware KB article Determining the installation date of an ESXi host (2144905) | VMware KB it gives only for one single esxi. How do we generate report (csv)for all esxi added in vCenter which will shows its installation date. This will save our manually login to all esxi and finding the installation date. Any script will help us. Thanks in advance PS
Thanks now csv is generated. You are right Path Id for a datastore can be different per VMHost. So this one we donot required. can it possible to have datastore LUN number all added in new Colu...
See more...
Thanks now csv is generated. You are right Path Id for a datastore can be different per VMHost. So this one we donot required. can it possible to have datastore LUN number all added in new Column.
Thanks for LuCD Really appreciate for the quick reply ... Script is running but not sure where its getting saved in csv format. (searced in desktop and C drive too not found the CSV output) ...
See more...
Thanks for LuCD Really appreciate for the quick reply ... Script is running but not sure where its getting saved in csv format. (searced in desktop and C drive too not found the CSV output) and also if we can add few more columns like next to @{N='Type';E={"$($_.Type)$($_.ExtensionData.Info.Vmfs.MajorVersion)"}} Name Identifier Path ID LUN DELL Fibre Channel Disk (naa.690b11c0003d8d6600000887519c23fa) naa.690b11c0003d8d6600000887519c23fa vmhba1:C0:T0:L21 101
Hi All We are looking for Script which will provide lun Utilization in below format. This will help in provide lun details like vmfs type/ last update /Capacity of Lun/Capacity of lun(inGB) ...
See more...
Hi All We are looking for Script which will provide lun Utilization in below format. This will help in provide lun details like vmfs type/ last update /Capacity of Lun/Capacity of lun(inGB) /Free space/Used space and % of lun utilization All luns are managed by our centrally vcenter server. I am not expert in powercli hopefully from this forum i Will get assistance LUN Identification Name Type Last Update Capacity (GB) Free (GB) Used Space(GB) % of LUN Utilization LUN01_vol01 VMFS3 3/6/2017 1:30:52 PM 1863.68 901.04 962.64 51.65 LUN02_vol01 VMFS3 3/6/2017 1:30:51 PM 1536 597.64 938.36 61.09 Thanks in Advance PS
As expected LuCD the one who is the first to anser ...hats off to you Due to busy scheduled today haven't yet tried the parameter given by you. Will check if works that coool. else You are ...
See more...
As expected LuCD the one who is the first to anser ...hats off to you Due to busy scheduled today haven't yet tried the parameter given by you. Will check if works that coool. else You are there thanks for one more time regs PS
I would like to add one more steps need to increase ssh timeout value to 300 second for all host in vcenter added UserVars.ESXiShellTimeOut # Set Remove UserVars.ESXiShellTimeOut to 900 on ...
See more...
I would like to add one more steps need to increase ssh timeout value to 300 second for all host in vcenter added UserVars.ESXiShellTimeOut # Set Remove UserVars.ESXiShellTimeOut to 900 on all hosts Get-VMHost | Foreach { Set-VMHostAdvancedConfiguration -VMHost $_ -Name UserVars.ESXiShellTimeOut -Value 900 } how to do i edit this to make final script
As an VMware admin always seen in vCenter most of VMs in shutdown state, wanted to know from how many days/months these shutdown vms are in shutdown state so we can delete these unused VMs which ...
See more...
As an VMware admin always seen in vCenter most of VMs in shutdown state, wanted to know from how many days/months these shutdown vms are in shutdown state so we can delete these unused VMs which help in reclaiming storage space. If any one have script pls share it. (Note : shutdown vm from vcenter console ) Script can give the output of VM1 is shutdown from so and so date. Thanks in Advance ps
Thanks ton for help LUCD and Sejal really appreciate saved my lot of time You guys rocks If i put more esxi host in script its only create user in 1st esx . If want to give 50 server ...
See more...
Thanks ton for help LUCD and Sejal really appreciate saved my lot of time You guys rocks If i put more esxi host in script its only create user in 1st esx . If want to give 50 server with different host name or ip address. how we can modify the script. $esxName = 'esx.test.lab' $esxName = 'sserver2' $esxName = 'Xyzabc'
Thanks lot really appricate your the only one to answering on this forum tried with corrected script its given connection errror Get-VMHost : 2/22/2017 4:14:12 PM Get-VMHost You a...
See more...
Thanks lot really appricate your the only one to answering on this forum tried with corrected script its given connection errror Get-VMHost : 2/22/2017 4:14:12 PM Get-VMHost You are not currently connected to any servers. Please connect first using a Connect cmdlet. At line:1 char:8 + $esx = Get-VMHost -Name $esxName + ~~~~~~~~~~~~~~~~~~~~~~~~~ + CategoryInfo : ResourceUnavailable: (:) [Get-VMHost], ViServerConnectionException + FullyQualifiedErrorId : Core_BaseCmdlet_NotConnectedError,VMware.VimAutomation.ViCore.Cmdlets.Commands.GetVMHost PowerCLI C:\> Connect-VIServer -Server $esx.Name -User $rootUser -Password $rootPswd > $null Connect-VIServer : Cannot validate argument on parameter 'Server'. The argument is null or empty. Provide an argument that is not null or empty, and then try the command again. At line:1 char:27 + Connect-VIServer -Server $esx.Name -User $rootUser -Password $rootPswd > $null + ~~~~~~~~~ + CategoryInfo : InvalidData: (:) [Connect-VIServer], ParameterBindingValidationException + FullyQualifiedErrorId : ParameterArgumentValidationError,VMware.VimAutomation.ViCore.Cmdlets.Commands.ConnectVIS erver PowerCLI C:\> Try{ >> $user = Get-VMHostAccount -User $userName -Server $esx.Name -ErrorAction Stop >> } >> Catch{ >> $user = New-VMHostAccount -Id $userName -Password $pswd -GrantShellAccess -Server $esx.Name >> } >> $perm = Get-VIPermission -Principal $userName -Server $esx.Name >> if(!$perm){ >> $root = Get-Folder -Name root -Server $esx.Name >> New-VIPermission -Entity $root -Principal $userName -Role Admin -Server $esx.Name >> } >> Disconnect-VIServer -Server $esx.Name -Confirm:$false >>
Tried with this only user is getting created but no admin/root level premission assigned to user. Connect-VIServer -Server $esx.Name -User $rootUser -Password $rootPswd > $null Try{ ...
See more...
Tried with this only user is getting created but no admin/root level premission assigned to user. Connect-VIServer -Server $esx.Name -User $rootUser -Password $rootPswd > $null Try{ $user = Get-VMHostAccount -User $userName -Server $esx.Name -ErrorAction Stop } Catch{ $user = New-VMHostAccount -Id $userName -Password $pswd -GrantShellAccess -Server $esx.Name } $user $perm = Get-VIPermission -Principal $userName -Server $esx.Name if(!$perm){ $root = Get-Folder -Name root -Server $esx.Name New-VIPermission -Entity $root -Principal $userName -Role Admin -Server $esx.Name } Disconnect-VIServer -Server $esx.Name -Confirm:$false }
Hi LuCD How to do i edit this Script if i want to add 10 esxi in this list. For eg my esxi ip is from 10.10.10.1 to 10.10.10.10 I am sorry i am fully not aware of PowerCli. Thanks in a...
See more...
Hi LuCD How to do i edit this Script if i want to add 10 esxi in this list. For eg my esxi ip is from 10.10.10.1 to 10.10.10.10 I am sorry i am fully not aware of PowerCli. Thanks in advance PS
Thanks LucD for reply Tried links given its givens an error as attached. Upgraded powercli to latest Powercli 6.0 Relase 3 Build 3205540. Our esxi is 5.5 build 4345813. Something can be chan...
See more...
Thanks LucD for reply Tried links given its givens an error as attached. Upgraded powercli to latest Powercli 6.0 Relase 3 Build 3205540. Our esxi is 5.5 build 4345813. Something can be changes done in ps scrip kindly let us know. ++++++++++++++++++++++++++ $groupName = "group" $accountName = "user" $accountPswd = "password" $accountDescription = "A user" $esxlist = Get-VMHost foreach($esx in $esxlist){ Connect-VIServer -Server esxiserverip -User root -Password "password" Try { Get-VMHostAccount -Id $groupName -Group -ErrorAction Stop | Out-Null } Catch { New-VMHostAccount -Id $groupName -GroupAccount | Out-Null } $rootFolder = Get-Folder -Name ha-folder-root Try{ $account = Get-VMHostAccount -Id $accountName -ErrorAction Stop | Set-VMHostAccount -Password $accountPswd -Description $accountDescription -AssignGroups $groupName } Catch{ $account = New-VMHostAccount -Id $accountName -Password $accountPswd -Description $accountDescription -UserAccount -GrantShellAccess -AssignGroups $groupName } $rootFolder = Get-Folder -Name ha-folder-root New-VIPermission -Entity $rootFolder -Principal $account -Role admin Disconnect-VIServer -Confirm:$false } ++++++++++++++++++++++++++++++++++++++++++++ Thanks in advance. PS
Hi All, Recently our security team asked for enabling ssh services on all esxi running in vcenter in different datacenter and cluster to scan authentication VA on each esxi. This is bit of pain...
See more...
Hi All, Recently our security team asked for enabling ssh services on all esxi running in vcenter in different datacenter and cluster to scan authentication VA on each esxi. This is bit of pain to go to every esxi and manually enable/disable ssh.We need help and solution from script we can achieve in single click.:-) If we can get the script which will help us to enable & start ssh services on all esxi server & Once scanning is over, same service can be disable/stopped. If someone has answer or script which is tested will be grateful him/her. Thanks in advance.
Hi Need Help in creating admin user on multiple esxi in vCenter with equivalent permission of root. Also if the script gives output of user created and not created on esxi host from esxi lis...
See more...
Hi Need Help in creating admin user on multiple esxi in vCenter with equivalent permission of root. Also if the script gives output of user created and not created on esxi host from esxi list given in script. This will save our time and manual intervention on every esxi host to check user created or not. Thanks in advance
How do i setup the Vmnetwork with HP blade system if i have 4 nics (8 with reduanant) . In vsphere i can see total 8 vm Network ...what is the best practice to assin to which purpose whith out a...
See more...
How do i setup the Vmnetwork with HP blade system if i have 4 nics (8 with reduanant) . In vsphere i can see total 8 vm Network ...what is the best practice to assin to which purpose whith out any hassle in future as Virutal Infrastructure will be growing Kindly suggest Regds
Thanks for reply!!! This is was my first post and got quick reply...cooool I am newbee to Vmware..quite excited & learning ......hope will come to some point to answer to other... Good Luck & ...
See more...
Thanks for reply!!! This is was my first post and got quick reply...cooool I am newbee to Vmware..quite excited & learning ......hope will come to some point to answer to other... Good Luck & Regards