VMware Horizon Community
antmorano
Contributor
Contributor

Post Synchronization Script With Linked Clone Desktops- View 6

Hi All,

New to the board here, but I've learned a lot thus far.  I have a question regarding post-synchronization scripts.  I created two windows bath files.  One, just calls the second one.  In my second batch file, I've received help on scripting a netsh command to change the IP Address, Gateway, Subnet Mask, and DNS Servers based on the computer name.  The script works when I run it manually.  When I login to the VM, I can check the temp files and see that the log says that is started the .bat file; however, it doesn't says if it has ever completed it.  I don't receive any error codes either.  I'm very puzzled by this and would appreciate any help with this.

I've attached the two files that I've been using...

Thank you all.

P.S. In my PostSync.bat file, I call another file that is sitting in the directory, so I know that part of the code works as well.  This file lists the computer names, ip addresses, and etc. 

0 Kudos
1 Reply
mpryor
Commander
Commander

Not tried it myself but I don't think "start" will work. That attempts to start a new command prompt in a window to run the file, which is not applicable for a launch from the service. Instead you should call it directly with "call myfile.bat"

0 Kudos