Posts: 3,438
Joined: Aug 2012
Reputation:
91
I think what I need is the swmc log after a reboot but before you do the manual start. I'm assuming it will show a fatal error that's responsible for it not starting. You can find the log file here:
%programdata%\vdsoftware\serverwmc\
Posts: 46
Joined: Apr 2014
Reputation:
1
2016-12-09, 05:11
(This post was last modified: 2016-12-09, 05:14 by moronim.)
That's the weird thing - there isn't a new log that is created showing a fatal error.
It is like the ServerWMC executable isn't even firing up at system start. I just rebooted the machine again to verify this and there no sign of a new log file. The last log file I have is showing the following at the end of the file (I assume this is the shutdown of swmc upon my initiation of a reboot:
2016/12/08 20:58:53.107 GetRecordingsCached> Cached recordings[26] returned to 'Kodi^LIVING-ROOM-TV' in 0.00 sec
2016/12/08 20:58:53.107 Finished request GetRecordings in 0.00s
2016/12/08 20:58:53.778 TimerCache_WorkerCompleted> [TimerMaintenance] Cache background refresh completed in 3.05 sec, client: Kodi^Playroom-TV.
2016/12/08 20:58:53.778 TimerCache_WorkerCompleted> [TimerMaintenance] Cache background refresh completed in 3.05 sec, client: Kodi^BASEMENT-TV.
2016/12/08 20:58:53.778 TimerCache_WorkerCompleted> [TimerMaintenance] Cache background refresh completed in 3.05 sec, client: Kodi^GUEST-BED-TV.
2016/12/08 20:58:53.778 TimerCache_WorkerCompleted> [TimerMaintenance] Cache background refresh completed in 3.05 sec, client: Kodi^LIVING-ROOM-TV.
2016/12/08 20:59:29.282 Session Ending: Shutdown - closing...
Thoughts on next steps? I'll do some digging on my end as well to better understand how processes/executables auto-start upon system start and see if that can lead to anything. I do have other programs that autostart (such as playon - which is actually a service). I'll also try to perhaps enable another program to run at startup and see if that fires up. That could clue me in on whether it is something with swmc or maybe something corrupt with my windows install...
Posts: 3,438
Joined: Aug 2012
Reputation:
91
2016-12-09, 06:05
(This post was last modified: 2016-12-09, 06:18 by krustyreturns.)
Oh, that is weird. So why didn't adding it to the startup folder work then?
I need to review how I did the auto start thing on my end too. I'll get back to you.
Posts: 3,438
Joined: Aug 2012
Reputation:
91
It should be in your registry:
HKey_Current_User\Software\Microsoft\Windows\CurrentVersion\Run
Posts: 46
Joined: Apr 2014
Reputation:
1
2016-12-09, 14:24
(This post was last modified: 2016-12-09, 14:25 by moronim.)
- I verified that the registry key was being written/removed for HKCU if I toggled the "Start when Windows Starts" option, so that is good.
But I think I solved the issue - and wonder if I uncovered a minor bug?
I realized I set the ServerWMC.exe file to "Run as Administrator" in the compatibility tab of the file properties. I did this because I felt I needed elevated privileges for the auto updates feature to work (if I had UAC enabled).
Anyways, after I unchecked "Run as Administrator" and I rebooted, swmc fired up just fine. Makes sense because the current user is now executing the exe and not the Administrator since the registry key is for HKCU.
I also disabled UAC (not ideal) to cover the auto updates.
So - the question is... should swmc be able to auto start if I have the ServerWMC.exe set to "Run as Administrator"?
No biggie, if it can't, but figured I'd let you know my findings...
Thanks for pointing me in the right direction!
Posts: 3,438
Joined: Aug 2012
Reputation:
91
I see, I'll look into a fix for that. I was under the impression that it had been starting with every boot but then it mysteriously stopped, but this makes more sense. Thanks for chasing it down.
Posts: 3,438
Joined: Aug 2012
Reputation:
91
It seems there is no straightforward way to handle this from code, so just for completeness sake... to make serverwmc run as admin at boot time your choices are:
1) create a windows scheduled task that starts serverwmc at boot, and set the task to run it as admin
2) run serverwmc as a service.