As part of DXA 1.7 I'm setting up the SDL Web Context Service.
Sadly the service won't start, I get this from the Services snap-in:
Checking the Event Viewer, I can see the staggeringly inconclusive message:
The SDL Web Context Service service terminated with the following service-specific error: The system cannot open the file.
I ran Process Monitor to try and see if any error appeared when the procrun.exe started and couldn't see any clear problem, but what I did see was some additional logging written to C:\Windows\System32\LogFiles\Apache\commons-daemon.2017-03-21.log.
When I open this, I can see:
[2017-03-21 10:04:05] [info] [19484] Commons Daemon procrun (1.0.15.0 64-bit) started
[2017-03-21 10:04:05] [info] [19484] Running 'SDLWebContextService' Service...
[2017-03-21 10:04:05] [info] [43920] Starting service...
[2017-03-21 10:04:05] [error] [ 9688] CreateJavaVM Failed
[2017-03-21 10:04:05] [error] [ 9688] The system could not find the environment option that was entered.
[2017-03-21 10:04:05] [error] [43920] Failed to start Java
[2017-03-21 10:04:05] [error] [43920] ServiceStart returned 4
[2017-03-21 10:04:05] [info] [19484] Run service finished.
[2017-03-21 10:04:05] [info] [19484] Commons Daemon procrun finished
Anyone know what environment variable is required?
I have a correct JAVA_HOME set up:
C:\Program Files\Java\jre1.8.0_121
And as this is a single server setup, a TRIDION_HOME:
C:\Program Files (x86)\SDL Web\
UPDATE
At Pete's suggestion, I ran start.ps1:
Everything appeared to run OK? I can see log files written and everything. If I close the script and try the service again, same error.
Something specific to the procrun.exe perhaps?