This is the mail archive of the mailing list for the Cygwin project.

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: Apache on cygwin

Hallo Frank,

Am Sonntag, 30. März 2003 um 16:51 schriebst du:

> Hello

> I'm wondering how to start the Apache server provided as a Cygwin
> package. I can only find httpd.dll but no httpd.exe, so do I have to
> work with rundll32 or is this package not intended to work as a stand
> alone server but only to fulfill dependencies?

> I also couldn't find a man or info page and the stuff under /usr/docs
> wasn't really helpful either.

There is a Cygwin manual page included with the dist:

There is a 'hint' how to install it as a service:
$ cygrunsrv -I service_name-p /usr/local/apache/bin/httpd.exe [-a arguments] \
      [-e VAR=VALUE] [-t auto|manual] [-u user] [-w passwd]

This resolves to:
$ cygrunsrv -I apache -p /usr/sbin/httpd.exe -a -k

Run the service with NT service manager or:
$ cygrunsrv -S apache

End the service with NT service manager or:
$ cygrunsrv -E apache

Without using a special user it will be installed under SYSTEM
account (which is a good thing).  The -k switch is needed to
install it as a service because the parent (main process) would
detach from the console and run in the background without this
switch, this will cause the service be logged as failed to start
after starting on Windows (although apache is still running),
see also:

$ /usr/sbin/httpd -h
Usage: /usr/sbin/httpd [-R directory] [-D name] [-d directory] [-f file]
                       [-C "directive"] [-c "directive"]
                       [-v] [-V] [-h] [-l] [-L] [-S] [-t] [-T]
  -R directory     : specify an alternate location for shared object files
  -D name          : define a name for use in <IfDefine name> directives
  -d directory     : specify an alternate initial ServerRoot
  -f file          : specify an alternate ServerConfigFile
  -C "directive"   : process directive before reading config files
  -c "directive"   : process directive after  reading config files
  -v               : show version number
  -V               : show compile settings
  -h               : list available command line options (this page)
  -l               : list compiled-in modules
  -L               : list available configuration directives
  -S               : show parsed settings (currently only vhost settings)
  -t               : run syntax check for config files (with docroot check)
  -T               : run syntax check for config files (without docroot check)
  -k               : do not detach from parent process (keep attached)

The rest of configuration (/etc/apache/httpd.conf) is pretty complete
besides some default settings for server name, emailadress of the
webmaster, the ports to run on,  ...

I agree that the /usr/doc/Cygwin/apache-x.xx.README could need a little
bit more details in this point.


Unsubscribe info:
Bug reporting:

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]