Why is my Windows Service getting deleted after a Windows Update on Win 10

I am running a Windows 10 virtual machine on Azure.   I have deployed my application using  simple copy file approach (not MSI).   After which, i am successfully creating the service using SC.exe as follows:

sc create "VNCServer.Service" binPath="C:\server\VNCServer.exe"

net start "VNCServer.Service"

sc config "VNCServer.Service" start= auto  

Everything works as expected for weeks (including many reboots) until the next Windows update is taken.  After taking the Windows update, the service appears to have been deleted.  I need to rerun the script above to create the service each time a windows update occurs.

What is happening here?  What can I do?
RXGeorgeAsked:
Who is Participating?
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

McKnifeCommented:
Try a service name without "."
Windows setup kills services with names it dislikes the characters of. Seen that.
0

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
RXGeorgeAuthor Commented:
Not sure how to confirm that this is the answer.  It will take time to know if this is the right solution.  I hope it is, but cannot confirm until we get a few more updates to OS.
0
McKnifeCommented:
Take a test installation with windows 10 v1703, create that service, do an inplace upgrade to version v1709 and see if the service remains there. Of course you might be running other builds of windows 10, take those that you use.
0
Cloud Class® Course: C++ 11 Fundamentals

This course will introduce you to C++ 11 and teach you about syntax fundamentals.

McKnifeCommented:
RXGeorge, it is not that hard to try. Please return with feedback or this will be deleted.
0
RXGeorgeAuthor Commented:
Thanks
0
RXGeorgeAuthor Commented:
Your answer was correct.  It appears.  Thanks very much.
0
McKnifeCommented:
You are welcome.
0
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today
Windows 10

From novice to tech pro — start learning today.

Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.