Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Processes remain after service stop attempt #6

Open
mdobrovnik opened this issue Apr 9, 2024 · 0 comments
Open

Processes remain after service stop attempt #6

mdobrovnik opened this issue Apr 9, 2024 · 0 comments

Comments

@mdobrovnik
Copy link

hi,
we have been using svcbatch 2.0.0 as a startup mechanism for our java
application (via a *.bat file) for some time. worked quite fine.

after switching to svcbatch 2.1.2 an "interesting" behaviour emerged:
while the service started successfully, stopping the service was not so easy:

the conhost and the java processes kept being actice while the state of the service said "STOPPED".

i have to mention that the *.bat script has a peculiarity:

...
:run
java .... 
if %ERRORLEVEL% geq 2 goto :run

our service offers the ability to restart itself. if triggered (by whatever means), it exits with code 2
and the service restarts.

if i start the *.bat file interactively and hit ctrl-c, the reaction is:

Batchvorgang abbrechen (J/N)?

yes, the server language is German.

svcbatch has a mechanism to write "Y" back. but our german server would like an "J"
after hex-editing svcbatch.exe (replacing the Y by J), stopping via the service manager worked fine again.

let me stress again that this behaviour has been introduced between 2.0.0 and 2.1.2 of svcbatch, everything else is the same.

Regards

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant