Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
Low memory web server?
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Networking & Security
View previous topic :: View next topic  
Author Message
wishkah
Guru
Guru


Joined: 09 May 2003
Posts: 441
Location: de

PostPosted: Tue May 18, 2004 8:08 am    Post subject: Low memory web server? Reply with quote

Hi,

I've got an old libretto with 16 MB ram and 75 MHz pentium1 processor. I'd like to run a webserver and mysql db locally, so I can have wikipedia on it (6 gb hdd). I installed gentoo (LAMP) and after some hacking it actually works, but it's VERY slow. I reconfigured apache to use fewer ressources, but it still uses 20% of the whole address space (that includes 64 MB hdd swap, which is causing the slowdown I guess). Mysql is configured to use very few ressources and only uses 5 % of the virtual memory.

My question is: Is there a low-ressources alternative to apache? Or can I somehow get apache to use <4 MB ram? I don't think mysql is THAT slow on this machine, I'm pretty sure it's apache that uses too much RAM and causes linux to swap, which then again causes the long response time.

My cflag is set to -Os, but I *think* that apache got compiled with the default (O2) gcc parameter... I guess portage knows why it's doing this, but maybe I can do something there?

edit: I've looked at the commonapache2.conf file and there are plenty of modules loaded in there. Are those necessary? How can I check which ones I need?
_________________
if only I could fill my heart with love...
Back to top
View user's profile Send private message
NeddySeagoon
Administrator
Administrator


Joined: 05 Jul 2003
Posts: 54851
Location: 56N 3W

PostPosted: Tue May 18, 2004 10:30 am    Post subject: Reply with quote

littleendian,

Don't get too hung up on whats loaded but not used. It willl get swapped out and stay out. You need to minimise the resident set.

Have you got a modular kernel with no junk built in?
Build everything you don't need for booting as modules. Then if you never need it its not loaded.
_________________
Regards,

NeddySeagoon

Computer users fall into two groups:-
those that do backups
those that have never had a hard drive fail.
Back to top
View user's profile Send private message
wishkah
Guru
Guru


Joined: 09 May 2003
Posts: 441
Location: de

PostPosted: Tue May 18, 2004 12:27 pm    Post subject: Reply with quote

NeddySeagoon wrote:
littleendian,

Don't get too hung up on whats loaded but not used. It willl get swapped out and stay out. You need to minimise the resident set.

Have you got a modular kernel with no junk built in?
Build everything you don't need for booting as modules. Then if you never need it its not loaded.


The kernel is really slim. I didn't modularize it because I think it doesn't matter whether I have something in the kernel or load it after boot (the RAM usage should be the same). The kernel only has compiled in what I really need, not a bit more.

free tells me there are only 13.xx megabyte physical RAM available, but there should be 16mb. These 13mb are 16mb minus the amound of memory the kernel uses, right?

Actually, nevermind. I found a tool (wiki2static) with which I can convert the wiki database sql dump to a static HTML tree, and it works okay (not great, because it uses javascript code for searching. And links2 doesn't understand that (lynx doesn't have JS support at all). But I guess I can write a little perl script to perform searches :-)).
_________________
if only I could fill my heart with love...
Back to top
View user's profile Send private message
zul
Retired Dev
Retired Dev


Joined: 27 Mar 2003
Posts: 20
Location: Ottawa,Ontario

PostPosted: Tue May 18, 2004 6:38 pm    Post subject: Reply with quote

net-www/boa is probaly what you are looking for

Regards
chuck
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Networking & Security All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum