r/vmware • u/GoneHamlot • Dec 27 '19
Me after successfully running a PowerShell script against our ESXi host
12
u/daarmstrong Dec 28 '19
I wrote a script to update my vmware hosts from a windows server in powershell. After completing all my code I realized that all my windows servers were virtual servers. I couldn't shutdown all vms and reboot. I ended up rewriting the connection piece in bash on a monitor server I have running.
5
u/pastorhack Dec 29 '19
powercli will run on linux, and cron works way better than windows task scheduler
6
u/Clydesdale_Tri Dec 27 '19
Check out the as-built report for your next piece! Tim Carmen wrote it with the help of the community.
I wrote a step by step awhile back on my blog. Https://hecktechs.com
3
u/daemon7 Dec 28 '19
Thanks for the reminder. I loved this report. I haven’t used it since 2018 so assume it’s gotten better. Sounds like Monday morning fun for me.
3
u/rhys-hammond32 Dec 29 '19
thanks for the great write-up, saved for the next customer review I need to do.
4
u/derpjutsu Dec 28 '19
Wait till you do your first, foreach($host in $hosts){stuff to do} script across a bunch. You'll need one of those red glowing eye memes. :D
2
2
32
u/[deleted] Dec 27 '19
My dude you have encapsulated the feeling.
Now start branching out to multi-host/vcenter/multi-function scripts or making commandlets and ATTAIN THE POWER OF THE GODS