Michael Sullivan wrote:
Why is it stupid? What is xinetd anyway? What does it do?

xinetd is what's often called a super-daemon. It sits there listening for connections on ports you've configured. When connections come in xinetd answers and then calls the correct server to handle it. Once the connection is done, the client exits, xinetd drops the connection, and the server daemon shuts down... not exactly sure on the order for all that, but it doesn't matter much for our purposes.


The nice thing about this is that you don't need ten ftp daemons sitting around using RAM while waiting for incoming connections. This helps keep resourvces free on a small system with little RAM that runs many services, but doesn't need to do them all the time.

The bad thing is that you have to reread all data and may have some significant start time associated with the daemons. Also you lose any caching of data when the daemon exits. In the case of a busy server that has a dedicated function, xinetd is going to slow things down. Or for real fun try running a database out of xinetd.

Back to imap, unless you like the idea of rescanning your entire dir every time you make an imap connection, standalone is better most of the time... for imap/http/mysql. However other daemons with low overhead like pop3/telnet/ftp/tftp would be fine.

Here's a bit of link on it, about a third down the page.
http://www.squirrelmail.org/wiki/en_US/SquirrelMailPerformance

And finally to end with funny inetd story. I once ran ssh 1.2-ish on my Sparc2 out of inetd. It took 30+ seconds to connect each time since ssh had to generate the session keys from scratch, which was no mean feat on a 20mhz chip.

kashani

--
gentoo-user@gentoo.org mailing list



Reply via email to