httpd-bugs mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From bugzi...@apache.org
Subject DO NOT REPLY [Bug 47325] Stopping a httpd that was run from console
Date Sun, 07 Jun 2009 14:49:25 GMT
https://issues.apache.org/bugzilla/show_bug.cgi?id=47325





--- Comment #2 from jhannwong@gmail.com  2009-06-07 07:49:24 PST ---
> Can you imagine any use case, where this wouldn't be possible just
> as well?

Yes. Suppose I programmatically start a process that runs httpd.exe . I
wouldn't have any console at all. I've tried without success to send terminate
signals to the process (on win32); there doesn't seem to be any functions to
send a CTRL_C_EVENT to:

1. A non-console process (I could be wrong)

2. A process that didn't spawn from a console process (I'm sure about this).

As my program isn't itself a console process, I couldn't terminate the process
I created to run httpd.exe .

All these acrobatics with signals to processes can be avoided if we allow
`httpd.exe -k stop' on the console. I'm curious how you did this, though.
Searched for a pid? Registry key?

"-k" for commandline really won't be necessary if I simply run processes that
fire off "-k install -n ServiceName" and "-k start...". In fact, that is my
current solution now, to uninstall the service once my program exits.

I was only worried that users may not have permissions to create services.

> Of course, if we decide not to support "-k" for commandline httpd on
> Windows, we need to fix the docs.

Thanks for the confirmation of my findings. Thought I missed something there.
:)

-- 
Configure bugmail: https://issues.apache.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.

---------------------------------------------------------------------
To unsubscribe, e-mail: bugs-unsubscribe@httpd.apache.org
For additional commands, e-mail: bugs-help@httpd.apache.org


Mime
View raw message