In article <
[email protected]>, Kees
Nuyt <
[email protected]> wrote:
On Sat, 26 Sep 2015 18:05:58 +0100, Tim Streater
<[email protected]> wrote:
I'm running 2.2.31 under Win7, quite satisfactorily. I obtained this
Win32 version from Apache Haus. However, I seem unable to use the -k >>option. I want to use it to have the server restart gracefully when I
have rotated the log files.
My attempts to use it fail. What I see in the error log is the Usage: >>information, followed by:
httpd.exe: illegal option -- k
Suggestions appreciated. I'm supposing this can't be a config file
matter, as I would assume the startup options are processed first. The >>failing command looks like:
httpd.exe -k restart -f "e:\path\to\httpd.conf"
The -k option has a different meaning in MSWindows, it handles
(un)installing Apache as a windows service.
http://httpd.apache.org/docs/2.2/platform/windows.html
Stopping/restarting can be done with the MSWindows service
commands (net.exe, sc.exe) or the management GUI.
I'm not sure whether "graceful" is an option in MSWindows.
Yes, I saw those docs before, although perhaps at the time I read them
I perhaps didn't quite appreciate what a "service" is in Windows. The
commands I am giving, to start/restart are being sent from a PHP
script, using popen. I can start it OK, it's the restart that's giving
the problem (I think restart implies graceful).
Since posting I've tried such as:
httpd.exe -k install -n "myservicename" -f "e:\path\to\httpd.conf"
followed by:
httpd.exe -k start -n "myservicename"
which at least don't (seem) to be giving me "illegal option -- k" any
longer so that might be progress but they are failing silently. I might
do better than to simplify my test setup and try again so I can get at
the fail error messages.
Thanks for the response.
--
"People don't buy Microsoft for quality, they buy it for compatibility
with what Bob in accounting bought last year. Trace it back - they buy Microsoft because the IBM Selectric didn't suck much" - P Seebach, afc
--- SoupGate-Win32 v1.05
* Origin: fsxNet Usenet Gateway (21:1/5)