VMware Cloud Community
khaled1111
Contributor
Contributor

start up and shut down scripts

Hi

I want to run scripts when esxi start and shutdown , where can i put these scripts?

When i execute `vim-cmd vmsvc/power.off` on machine run linux , are the scripts which be run when the system shutdown executed , or it is considered unclean shutdown?

0 Kudos
4 Replies
Troy_Clavell
Immortal
Immortal

not that this may answer your question directly, but... If you have a host that is not part of an HA cluster, why not use the built in startup/shutdown options?

These can be configured by going to the configuration tab of the ESXi Host--Virtual Machine Startup/Shutdown--Properties.

0 Kudos
rickardnobel
Champion
Champion

khaledatteya wrote:

I want to run scripts when esxi start and shutdown , where can i put these scripts?

Do you want to run scripts on the ESXi host itself at the host startup or do you mean to run scripts inside the VMs when they power on?

My VMware blog: www.rickardnobel.se
0 Kudos
khaled1111
Contributor
Contributor

Hi rickardnobel

I want to run scripts on the ESXi host itself at the host startup.

0 Kudos
rickardnobel
Champion
Champion

khaledatteya wrote:

I want to run scripts when esxi start and shutdown , where can i put these scripts?

Since the way ESXi is built, with almost all of the hypervisor OS is inside a compressed image and just unpacked into RAM at startup, it is harder to save custom files into this file system. I am not sure it is possible, but it might be. Have you seen any official documentation on if this is supported?

My VMware blog: www.rickardnobel.se
0 Kudos