News:

OS2World.com Forum is back !!!

Remember to visit OS2World at:
http://www.os2world.com

Main Menu

apache2.4 configuration

Started by Greg Pringle, March 24, 2024, 02:25:11 PM

Previous topic - Next topic

Greg Pringle

I am attempting to use apache 2.4 with Python 8.1  and use apachectl to stop the server.
Starting the server runs fine. The httpd.conf file has:
PidFile "d:/apache24/logs/httpd.pid"
and the server creates this file on startup but then "apachectl -k stop" does not work and complains that there is not a pid file.

Does anyone know how to make this work?

David McKenna

Greg,

  Hmm... I get this:

[C:\programs\apache24\bin]apachectl -k stop
SYS1041: The name apachectl is not recognized as an
internal or external command, operable program or batch file.

I'm using Paul's version 2.4.57 of httpd. Maybe report this at his Mantis site: https://mantis.smedley.id.au/my_view_page.php

Regards,

Greg Pringle


apache -k restart

will do the same thing because apachectl is a shell script


David McKenna

#3
Greg,

  Oops! forgot the 'sh' I now get this:

[C:\programs\apache24\bin]sh apachectl -k stop
apachectl: 101: apachectl: /apache24/bin/httpd: not found

Definitely something not right...

EDIT: after editing apachectl to have the correct HTTPD directory listed, if I try 'sh apachectl -f /Programs/apache24/conf/httpd.conf -k stop' I get an 'killed by SIGSEGV'  exceptq trap file...

Regards,

Greg Pringle

When I have added the -f Httpd.conf entry the pid file is not found.

The pid file holds the correct pid number so if I do a manual kill that does work.
I am not sure that is a good idea. I can write a workaround to automate the kill.

David McKenna

 Greg,

  That's what I have been doing:

/* Rexx script to shut down Apache */

pid = linein("logs\httpd.pid")
kill.exe pid

in a CMD file originally installed by AMP for OS/2 way back when. Never tried the apachectl way until you posted. There is an Apache for OS/2 google group you could post on to see if anyone there has experience with apachectl...

Regards,