Git Product home page Git Product logo

svcbatch's People

Contributors

dphilips-rh avatar mturk avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar

svcbatch's Issues

Filtering environment variables issue - fix recommendation

In the code, where you want to filter out environment variables starting with "SVCBATCH_SERVICE_", the condition check is not correct.

the original condition:
if (_wcsnicmp(wenv[i], L"SVCBATCH_SERVICE_", 17) < 0)

I think that this would be the correct condition expression:
if (_wcsnicmp(wenv[i], L"SVCBATCH_SERVICE_", 17) != 0)

Otherwise you lose environment variables. This has been a problem for me since version 1.3.2 on one machine, and the service that was started stopped immediately, but fix and compile the source code fixed it. The code snippet in earlier versions provided a different filtered environment variable list than in newer versions without the modification

Best regards
Kristóf Nagy

Processes remain after service stop attempt

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

Provided binary release 1.4.0 does not forward environment variable %SystemRoot%

Provided binary release 1.4.0 does not forward system environment variables, among others %SystemRoot%
Because of that, all executables that use sockets fail with error 10106

For example
ping localhost
produces
Ping request could not find host localhost. Please check the name and try again.
Reason is because windows cannot load msock.dll under %SystemRoot%\system32

Adding
SET SystemRoot=C:\WINDOWS
at the beginning of bat file fixes that, but then somehow log rotation gets triggered endlesly.

Build using VS 2017 forwards required system variables and also log rotation does not get triggered.

Error 1053

Hi,

I try to to do it with a very simple batch file that execute one sql command in a loop.
Is there any reason why it won't work ?

Thanks for this tool.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.