This is the mail archive of the cygwin-apps@cygwin.com 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]

Re: [PATCH]webmin with camp and cygwin


Ralf,

> for an intranet project in our company I have problems with iis and try to
> migrate to apache. Apache is avaliable for windows or cygwin, but graphical
> remote configuring apache was left. As I'm using webmin for other linux based
> web server, I tried to use webmin on cygwin for doing this.
> 
> So I've downloaded camp 0.9 and webmin 0.88 and install it under cygwin 1.3.3.

you should be using the latest CAMP 1.3.20 distribution which includes
current version modules and stuff. The location is
http://apache.dev.wapme.net/packages/.

> Then after installing webmin I run into problems, because the main page could
> be loaded, but if entering other pages in the server area ,for example apache,
> fails with a "500 bad header" error.

500 means usual something went wrong while the CGI process has been
running or the output towards apache's mod_cgi module didn't work as
expected.

There have been several reports from people, that the CGI module is
harmed when php is compiled or linked in.

I suggest -- as you may not need php4 here for webmin -- to take the
latest Apache for Cygwin binary at
http://apache.dev.wapme.net/binaries/latest/ or use the latest CAMP
distribution but exclude then the dynamic loading of the php4 modules
at apache's httpd.conf.

> Because my perl knowledge isn't good enough to understand and analyse
> this problem with webmin's miniserv (with perl 5.6.1), I tried to configure
> the camp distribution to enable apache configuring with webmin.
> 
> Now it's working, except authentification. Currently it uses a default
> user 'admin' which is set in the apache VirtualHost configuration.
> 
> To enable webmin with the apache server, add/patch the below mentioned files.
> Currently I have tested not very deeply, so there might be some more
> places to patch, but for me it works.
> 
> Limitations:
> 1. restarting/stopping/starting apache does not work, because the webmin
>    frontend depends on the apache server and doing this actions causes
>    lost connections. So you have to restart apache remote over telnet or
>    something else.

you may use a seperate "extra" httpd running on a port (i.e. 13000)
which does have priviledges to restart the "usual" httpd.

> Installation
> ============
> 1. Install camp                                                                         http://apache.dev.wapme.net/packages/

ups, so you used the latest CAMP package, ok.

> 2. Install webmin                                                               http://www.webmin.com
>          use the "Linux from scratch" operations system
> 
> 3. patch the below mentioned files.
> 
> 4. restart apache
> 
> 5. Start a browser and enter    http://webmin/
>          (if you have used the below mentioned servername and HOSTS entry)
> 
> Note: Because my apache and webmin configuration knowledge is only
>       very basic, please don't ask me for relating configuration hints.
>       If you have questions, please look in the faq or mailing list on
>       the relates web sites.
> 
> Have fun
> 
> 2001/10/27
> Ralf Habacker
> IT-Manager
> Germany
> 
> /usr/local/apache/conf/http.conf - add text
> #------------------------------------------------------------
> 
> # This must be first for providing working localhost
> <VirtualHost *>
>     DocumentRoot /usr/local/apache/htdocs/
>     ServerName <your workstation name>
>     ErrorLog logs/error_log
>     CustomLog logs/access_log common
>         DirectoryIndex index.html
>                 <Directory />
>                     Options FollowSymLinks
>                     AllowOverride Options
>                 </Directory>
> </VirtualHost>
> 
> <VirtualHost *>
>     ServerAdmin webmin@localhost
>     DocumentRoot /usr/local/webmin-0.88/
>     ServerName webmin   # or something else you want
>     ErrorLog logs/webmin-error_log
>     CustomLog logs/webmin-access_log common
>                 SetEnv WEBMIN_CONFIG /etc/webmin
>                 SetEnv WEBMIN_VAR        /var/webmin
>                 SetEnv REMOTE_USER       admin

yep, these have to be passed to webmin CGIs.

>         DirectoryIndex index.cgi
>           AddHandler cgi-script cgi pl
>                 <Directory />
>                     Options FollowSymLinks +ExecCGI
>                     AllowOverride Options
>                 </Directory>
> 
> NameVirtualHost *
> #------------------------------------------------------------
> 
> /c/winnt/system32/drivers/etc/hosts - add text
> #------------------------------------------------------------
> webmin 127.0.0.1 or other ip adress your pc support
> #------------------------------------------------------------
> 
> /usr/local/webmin-0.88/apache/reconfig_form.cgi - patch
> #------------------------------------------------------------
> $ diff reconfig_form.cgi.orig  reconfig_form.cgi -ubB
> --- reconfig_form.cgi.orig      Sat Oct 27 20:52:34 2001
> +++ reconfig_form.cgi   Sat Oct 27 20:52:56 2001
> @@ -31,6 +31,12 @@
>         elsif ($l->{'words'}->[1] =~ /lib([^\/\s]+)\.so/ && -r "mod_$1.pl") {
>                 $inst{"mod_$1"}++;
>                 }
> +       elsif ($l->{'words'}->[1] =~ /(mod_\S+)\.dll/ && -r "$1.pl") {
> +               $inst{$1}++;
> +               }
> +       elsif ($l->{'words'}->[1] =~ /lib([^\/\s]+)\.dll/ && -r "mod_$1.pl") {
> +               $inst{"mod_$1"}++;
> +               }
>         }
> 
>  # build list of supported modules
> 
> #------------------------------------------------------------

thanks a lot for the patch and the HOWTO. If you don't mind, I would
be pleased to make a HOWTO out of it and put it on the Apache for
Cygwin site.

Regards,
Stipe

tolj@wapme-systems.de
-------------------------------------------------------------------
Wapme Systems AG

Münsterstr. 248
40470 Düsseldorf

Tel: +49-211-74845-0
Fax: +49-211-74845-299

E-Mail: info@wapme-systems.de
Internet: http://www.wapme-systems.de
-------------------------------------------------------------------
wapme.net - wherever you are


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