Subject: [LON-CAPA-dev] "lite"-weight httpd-daemon for serving junk

From: Gerd Kortemeyer <[email-masked]>
Date: Tue, 29 Oct 2002 11:03:49 -0500

Subject: "lite"-weight httpd-daemon for serving junk
From: Gerd Kortemeyer <[email-masked]>
To: [email-masked]
Date: Tue, 29 Oct 2002 11:03:05 -0500

Hi,

As it turns out, httpd-processes are pretty chunky with our heavy
modperl-usage:

www      30527  0.0  3.2 37676 30248 ?       S    Oct28   0:00 httpd
www      30566  0.0  5.4 56484 49624 ?       S    Oct28   0:16 httpd
www      30571  0.0  3.5 39356 32600 ?       S    Oct28   0:00 httpd
www      30574  0.0  7.1 73300 65964 ?       S    Oct28   0:29 httpd
www      30575  0.0  5.1 54068 47068 ?       S    Oct28   0:22 httpd
www      30576  0.0  6.4 67124 59528 ?       S    Oct28   0:28 httpd
www      30580  0.0  3.2 37640 30216 ?       S    Oct28   0:00 httpd
www      30594  0.0  5.5 58408 51128 ?       S    Oct28   0:26 httpd
www      30626  0.0  4.3 47392 40304 ?       S    Oct28   0:09 httpd
www      30627  0.0  5.6 58904 51404 ?       S    Oct28   0:24 httpd
www      30735  0.0  3.2 37640 30216 ?       S    00:04   0:00 httpd
www      30736  0.0  4.5 49156 42088 ?       S    00:04   0:06 httpd
www      30749  0.0  4.4 47476 40420 ?       S    00:20   0:17 httpd
www      30766  0.0  3.2 37640 30216 ?       S    00:56   0:00 httpd
www      30767  0.0  3.2 37640 30216 ?       S    00:56   0:00 httpd
www      30768  0.0  3.2 37640 30216 ?       S    00:56   0:00 httpd

I wonder if it would make sense to run a small lightweight server on
another port to serve our public static resources, like the header-gifs,
remote control characters, RAT GIFs, etc:

  http://www.acme.com/software/thttpd/

Because of our access control, replication, and logging, however, it is
not possible to serve all static resources this way.

An alternative would be to install a second Apache on another port, and
have it load only the bare minimum modperls, like lonacc.pm and
lonnet.pm (which do load a bunch of others, but still not the full
codebase). See

  http://take23.org/docs/guide/strategy.xml/3

We could direct the simple GIFs directly to the port of the
lightweight-Apache, and have the <img>, <embed>, and <applet>-tags add
the port address of the lightweight Apache. In a way, this would be a
safe transition: if we do a good job of distinguishing "static" from
"non-static" requests, the children of the second Apache would remain
small, but if we mess up, things would keep running - it's just that the
children of the second Apache would grow.

I hesitate to introduce the big revolution in LON-CAPA architecture,
since we need to aim for stability. Any ideas/input?

- Gerd.

---

From: Scott Harrison <[email-masked]>
Date: Tue, 29 Oct 2002 12:19:02 -0500

> remote control characters, RAT GIFs, etc:

Yes.

> since we need to aim for stability. Any ideas/input?

To deal with multiple issues at once:

http://www.webmin.com/ is something that might make sense to introduce
into LON-CAPA in the future (to create a cushion between diagnosing/updating
the system versus typing in bash terminal commands).

It comes packaged with miniserv.pl.  Probably the smallest, lightest-weight
web server out there.  I don't think it handles modules though.

Regards,
Scott

-- 
Scott Harrison, [email-masked]