You are viewing a plain text version of this content. The canonical link for it is here.
Posted to bugs@httpd.apache.org by bu...@apache.org on 2013/02/02 15:20:09 UTC

[Bug 54520] New: Command Line Stop Error

https://issues.apache.org/bugzilla/show_bug.cgi?id=54520

            Bug ID: 54520
           Summary: Command Line Stop Error
           Product: Apache httpd-2
           Version: 2.4.2
          Hardware: PC
            Status: NEW
          Severity: major
          Priority: P2
         Component: mpm_winnt
          Assignee: bugs@httpd.apache.org
          Reporter: stevenmartin99@gmail.com
    Classification: Unclassified

The Documentation says that apache can be controlled from command line when NOT
using a service,

To start apache type

httpd.exe  (works fine)

To stop restart etc   type

httpd.exe -k stop
httpd.exe -k restart


This does not work and fails with the error

[mpm_winnt:error] [pid 4480:tid 116] (OS 2)The
 system cannot find the file specified.  : AH00436: No installed service named
"
Apache2.4".


I have tried this with apache 2.2.17 and 2.2.21 and it also fails pointing to a
service  Apache2.2 not installed.

Im not using a service and have never installed the service with this name.
Why is apache not checking the PID in the httpd.pid and killing that exe like
it used to?

-- 
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


[Bug 54520] Apache Console -k failure to read PID for Running Apache, instead looking for default service name with out -n specified

Posted by bu...@apache.org.
https://issues.apache.org/bugzilla/show_bug.cgi?id=54520

--- Comment #22 from steven martin <st...@gmail.com> ---
can people not read on this forum???

for the last time i say it!


AS A CONSOLE!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!


I NEVER MENTIONED AS A SERVICE. GRR

-- 
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


[Bug 54520] Command Line Stop Error

Posted by bu...@apache.org.
https://issues.apache.org/bugzilla/show_bug.cgi?id=54520

--- Comment #19 from steven martin <st...@gmail.com> ---
It was working in an older version... 
 The documentation still said it works.. ( until you edited it)
It makes sense that it should work
And there is no reason that it shouldnt work...

that makes it a bug


The help file for httpd.exe STILL says  

1.3
-k shutdown      : tell running Apache to shutdown
-k restart       : tell running Apache to do a graceful restart

2.2
-k restart         : tell running Apache to do a graceful restart
-k stop|shutdown   : tell running Apache to shutdown

2.4
-k restart         : tell running Apache to do a graceful restart
-k stop|shutdown   : tell running Apache to shutdown
---------------------------------------------------------------------


-k is supposed to singal to the RUNNING apache, ie the PID in the PID file.

-- 
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


[Bug 54520] Command Line Stop Error

Posted by bu...@apache.org.
https://issues.apache.org/bugzilla/show_bug.cgi?id=54520

--- Comment #5 from steven martin <st...@gmail.com> ---
btw i reopened this because it is valid. 

its always been a valid way on windows to control the console

"open a new console and run the command"

-- 
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


[Bug 54520] Command Line Stop Error

Posted by bu...@apache.org.
https://issues.apache.org/bugzilla/show_bug.cgi?id=54520

--- Comment #20 from Eric Covener <co...@gmail.com> ---
okay, good luck!

-- 
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


[Bug 54520] Command Line Stop Error

Posted by bu...@apache.org.
https://issues.apache.org/bugzilla/show_bug.cgi?id=54520

--- Comment #17 from steven martin <st...@gmail.com> ---
-k is not for a service,   its used  as a reminder as kill , 

this is written in the documentation....


-n is for service name


so 

 -k stop -n apache2.2   should stop a service named apache2.2

-k stop should stop the apache running who's PID is in the pid file

-- 
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


[Bug 54520] Command Line Stop Error

Posted by bu...@apache.org.
https://issues.apache.org/bugzilla/show_bug.cgi?id=54520

Eric Covener <co...@gmail.com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|REOPENED                    |RESOLVED
         Resolution|---                         |INVALID

--- Comment #13 from Eric Covener <co...@gmail.com> ---
Marking as invalid -- No service, no -k.

-- 
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


[Bug 54520] Command Line Stop Error

Posted by bu...@apache.org.
https://issues.apache.org/bugzilla/show_bug.cgi?id=54520

--- Comment #11 from Eric Covener <co...@gmail.com> ---
(In reply to comment #9)
> 
> 
> To run Apache from the command line as a CONSOLE APPLICATION, use the
> following command:
> 
> httpd.exe
> 
> 
> You can tell a running Apache to stop by opening another CONSOLE window and
> entering:
> 
> httpd.exe -k shutdown


Read it in context.

-- 
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


[Bug 54520] Command Line Stop Error

Posted by bu...@apache.org.
https://issues.apache.org/bugzilla/show_bug.cgi?id=54520

--- Comment #6 from steven martin <st...@gmail.com> ---
Thanks for making a mess.
Now the documentation is useless

Under the heading  "Running Apache as a Console Application" you added bits
about Services... 

This used to work in apache on windows...thats why the documentation is written
as so...

 Please provide a link to where this feature has been removed in apache and the
docs were just not changed...

-- 
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


[Bug 54520] Command Line Stop Error

Posted by bu...@apache.org.
https://issues.apache.org/bugzilla/show_bug.cgi?id=54520

--- Comment #10 from Eric Covener <co...@gmail.com> ---
(In reply to comment #8)
> Can you see the documentation page as I see it?
> 
> 
> There is 2 SECTIONS.....  
> 
> The first is about services
> 
> The second was about runnig it as a console application until you edited it
> and started to add bits about services into it.
> 
> 
> IT DOESN'T SAY , "Running Apache SERVICE FROM THE COMMANDLINE"
> IT SAYS "Running Apache AS A CONSOLE APPLICATION"


Yes, the console section talks about using the shortcut and then talks about
what the shortcut does if you have a service:

========
Apache will execute, and will remain running until it is stopped by pressing
Control-C.

You can also run Apache via the shortcut Start Apache in Console placed to
Start Menu --> Programs --> Apache HTTP Server 2.4.xx --> Control Apache Server
during the installation. This will open a console window and start Apache
inside it. If you don't have Apache installed as a service, the window will
remain visible until you stop Apache by pressing Control-C in the console
window where Apache is running in. The server will exit in a few seconds.
However, if you do have Apache installed as a service, the shortcut starts the
service. If the Apache service is running already, the shortcut doesn't do
anything.

If Apache is running as a service, you can tell it to stop by opening another
console window and entering:
=========

-- 
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


[Bug 54520] Command Line Stop Error

Posted by bu...@apache.org.
https://issues.apache.org/bugzilla/show_bug.cgi?id=54520

Eric Covener <co...@gmail.com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
          Component|mod_socache_(dbm|dc|memcach |Platform
                   |e|shmcb)                    |

--- Comment #18 from Eric Covener <co...@gmail.com> ---
(In reply to comment #17)
> -k is not for a service,   its used  as a reminder as kill , 
> 
> this is written in the documentation....
> 
> 
> -n is for service name
> 
> 
> so 
> 
>  -k stop -n apache2.2   should stop a service named apache2.2
> 
> -k stop should stop the apache running who's PID is in the pid file



In all the maintained releases, -k only signals a service on Windows.   

I'd suggest changing this to an enhancement and updating the abstract.  It
won't be resolved as a bug.

-- 
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


[Bug 54520] Command Line Stop Error

Posted by bu...@apache.org.
https://issues.apache.org/bugzilla/show_bug.cgi?id=54520

Eric Covener <co...@gmail.com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|NEW                         |RESOLVED
         Resolution|---                         |INVALID
                 OS|                            |All

--- Comment #1 from Eric Covener <co...@gmail.com> ---
Apache can't be controlled like this when not running as a service on Windows.

-- 
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


[Bug 54520] Command Line Stop Error

Posted by bu...@apache.org.
https://issues.apache.org/bugzilla/show_bug.cgi?id=54520

--- Comment #8 from steven martin <st...@gmail.com> ---
Can you see the documentation page as I see it?


There is 2 SECTIONS.....  

The first is about services

The second was about runnig it as a console application until you edited it
and started to add bits about services into it.


IT DOESN'T SAY , "Running Apache SERVICE FROM THE COMMANDLINE"
IT SAYS "Running Apache AS A CONSOLE APPLICATION"

-- 
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


[Bug 54520] Command Line Stop Error

Posted by bu...@apache.org.
https://issues.apache.org/bugzilla/show_bug.cgi?id=54520

Eric Covener <co...@gmail.com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|RESOLVED                    |REOPENED
          Component|mpm_winnt                   |mod_socache_(dbm|dc|memcach
                   |                            |e|shmcb)
         Resolution|INVALID                     |---

--- Comment #14 from Eric Covener <co...@gmail.com> ---
will clarify 2.2 docs

-- 
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


[Bug 54520] Apache Console -k failure to read PID for Running Apache, instead looking for default service name with out -n specified

Posted by bu...@apache.org.
https://issues.apache.org/bugzilla/show_bug.cgi?id=54520

Eric Covener <co...@gmail.com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|REOPENED                    |RESOLVED
         Resolution|---                         |WONTFIX

-- 
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


[Bug 54520] Command Line Stop Error

Posted by bu...@apache.org.
https://issues.apache.org/bugzilla/show_bug.cgi?id=54520

steven martin <st...@gmail.com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|RESOLVED                    |REOPENED
         Resolution|INVALID                     |---

--- Comment #3 from steven martin <st...@gmail.com> ---
http://httpd.apache.org/docs/2.2/platform/windows.html#winsvc

http://httpd.apache.org/docs/2.4/platform/windows.html#winsvc

under the heading

Running Apache as a Console Application

-- 
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


[Bug 54520] Apache Console -k failure to read PID for Running Apache, instead looking for default service name with out -n specified

Posted by bu...@apache.org.
https://issues.apache.org/bugzilla/show_bug.cgi?id=54520

steven martin <st...@gmail.com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
            Summary|Command Line Stop Error     |Apache Console  -k failure
                   |                            |to read PID for Running
                   |                            |Apache, instead looking for
                   |                            |default service name with
                   |                            |out -n specified
           Severity|major                       |regression

-- 
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


[Bug 54520] Apache Console -k failure to read PID for Running Apache, instead looking for default service name with out -n specified

Posted by bu...@apache.org.
https://issues.apache.org/bugzilla/show_bug.cgi?id=54520

--- Comment #21 from vigorena <vi...@live.cl> ---
(In reply to comment #0)
> The Documentation says that apache can be controlled from command line when
> NOT using a service,
> 
> To start apache type
> 
> httpd.exe  (works fine)
> 
> To stop restart etc   type
> 
> httpd.exe -k stop
> httpd.exe -k restart
> 
> 
> This does not work and fails with the error
> 
> [mpm_winnt:error] [pid 4480:tid 116] (OS 2)The
>  system cannot find the file specified.  : AH00436: No installed service
> named "
> Apache2.4".
> 
> 
> I have tried this with apache 2.2.17 and 2.2.21 and it also fails pointing
> to a service  Apache2.2 not installed.
> 
> Im not using a service and have never installed the service with this name.
> Why is apache not checking the PID in the httpd.pid and killing that exe
> like it used to?

you need to install the service to run properly apache, you must install the
service in this way:

running the console as administrator

httpd -k install -n "ServiceName" in this case Apache

-- 
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


[Bug 54520] Command Line Stop Error

Posted by bu...@apache.org.
https://issues.apache.org/bugzilla/show_bug.cgi?id=54520

--- Comment #4 from steven martin <st...@gmail.com> ---
sorry i see you have direct links to sections

http://httpd.apache.org/docs/2.2/platform/windows.html#wincons
http://httpd.apache.org/docs/2.4/platform/windows.html#wincons

-- 
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


[Bug 54520] Apache Console -k failure to read PID for Running Apache, instead looking for default service name with out -n specified

Posted by bu...@apache.org.
https://issues.apache.org/bugzilla/show_bug.cgi?id=54520

--- Comment #23 from Gregg L. Smith <gl...@gknw.net> ---
Console ... I hear you.

I think this did work in 1.3.x and maybe 2.0.x as well running on Win95/98/ME
since they didn't have Windows services. I remember mashing ctrl+c back in
those days would leave the pid file behind, and a nice little error message
about not gracefully stopping on next start up.

I'm assuming that back in those days httpd would check if running on an NT
version or not, and use the -k signal for console or a service accordingly.

Mashing ctrl+c has been the way I've been doing for years, and at least with
2.2 and now 2.4, the pid file will get removed properly. So, since Win95/98/ME
are long dead, the pid file is properly removed when mashing ctrl+c, all
Windows versions these days are NT based, I see no big need for this 15 year
old behavior come June 20th.

Much of the old code that dealt with Win95/98/ME has been ripped out of the
source as well so I do not consider it a bug. I consider it a reality of
current times (only NT versions of Windows).

-- 
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


[Bug 54520] Command Line Stop Error

Posted by bu...@apache.org.
https://issues.apache.org/bugzilla/show_bug.cgi?id=54520

--- Comment #12 from Eric Covener <co...@gmail.com> ---
You're looking at 2.2 documentation, and I'm looking at 2.4.

Even in 2.2:

However, if you do have Apache installed as a service, the shortcut starts the
service. If the Apache service is running already, the shortcut doesn't do
anything.

You can tell a running Apache to stop by opening another console window and
entering:

-- 
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


[Bug 54520] Command Line Stop Error

Posted by bu...@apache.org.
https://issues.apache.org/bugzilla/show_bug.cgi?id=54520

--- Comment #7 from Eric Covener <co...@gmail.com> ---
(In reply to comment #6)
> Thanks for making a mess.
> Now the documentation is useless
> 
> Under the heading  "Running Apache as a Console Application" you added bits
> about Services... 

No, I added entries to the section about running it as a service.  You can even
see in the context of the diff the changes are preceded by "To start an
installed Apache service you'll use this:"

> 
> This used to work in apache on windows...thats why the documentation is
> written as so...

Used to? When?

The section of the manual you pointed to says the _shortcut_ uses a service if
it exists, at which point -k stop|start can be used.

>  Please provide a link to where this feature has been removed in apache and
> the docs were just not changed...

I've got no idea if or when anything changed.  It sounds like some fringe
feature, but if you can narrow it down I'd certainly have a look.

-- 
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


[Bug 54520] Command Line Stop Error

Posted by bu...@apache.org.
https://issues.apache.org/bugzilla/show_bug.cgi?id=54520

--- Comment #9 from steven martin <st...@gmail.com> ---



To run Apache from the command line as a CONSOLE APPLICATION, use the following
command:

httpd.exe


You can tell a running Apache to stop by opening another CONSOLE window and
entering:

httpd.exe -k shutdown

-- 
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


[Bug 54520] Command Line Stop Error

Posted by bu...@apache.org.
https://issues.apache.org/bugzilla/show_bug.cgi?id=54520

Eric Covener <co...@gmail.com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|REOPENED                    |RESOLVED
         Resolution|---                         |FIXED

--- Comment #15 from Eric Covener <co...@gmail.com> ---
Backported the emphasis on service in the conspole/shortcut text to 2.2 from
http://svn.apache.org/viewvc?rev=1031312&view=rev


See https://issues.apache.org/bugzilla/show_bug.cgi?id=47325

-- 
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


[Bug 54520] Command Line Stop Error

Posted by bu...@apache.org.
https://issues.apache.org/bugzilla/show_bug.cgi?id=54520

steven martin <st...@gmail.com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|RESOLVED                    |REOPENED
         Resolution|FIXED                       |---

--- Comment #16 from steven martin <st...@gmail.com> ---
Can i just point out , your all reading it wrong

its not from a console - ITS AS A CONSOLE

i just went to the trouble of downloading apache1.3 and IT WORKS

to start as a console  (type)

apache


to stop ( open a new cmd and type )

apache -k stop


and you look in the other console window and it has stopped.

Its a bug,  or else  its been removed and if so why...

ctrl + c   is not a solution ,  just like the original docs said

-- 
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


[Bug 54520] Command Line Stop Error

Posted by bu...@apache.org.
https://issues.apache.org/bugzilla/show_bug.cgi?id=54520

--- Comment #2 from Eric Covener <co...@gmail.com> ---
Can you quote the misleading doc?

-- 
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