[Xitami] Load/Stress Testing Xitami
Russel Olinger
rolinger1 at hotmail.com
Wed Aug 1 10:04:13 CEST 2007
Thomas,
Comments inserted below
>
> Russel,
>
> You didn't mention if you are using PHP or some other scripting
I am using Win32 Perl
> language, but I'm not aware of any method to query a MySQL database
> without one. Scripting languages under Xitami typically require CGI.
>
> When CGI runs like that, the CPU gets hammered because you've got new
> processes being created left and right. The system is spending most of
> its time starting up and shutting down processes.
Doesn't Xitami create an individual Perl process per cgi script being
called? If 25 users hit the server at once then that would be 25 perl calls
with 25 instances Perl.exe running? How would Apache and IIS handle a
similar situation?
>
> I ran a similar test spread across 15 machines on a LAN once with Xitami
> via CGI and got similar results (I wrote my own tool). Xitami simply
> couldn't handle the load. Most of the time it just returned blank
> pages. I don't know what tool you are using but socket code fails if
Using Microsoft Web Application Stress Tool ver1.1 . Do you recall the load
it was able to handle? And is there anyway you could think of to push the
25 connections per second without moving to PHP? And doesn't the Xitami PHP
get handled by the CGI processor so there is no real advantage to moving to
PHP?
> you mass connect to a server in rapid succession (Windows hangs onto
> socket handles until TCP closes down cleanly or times out)...for my
> test, I wrote a tool to manage the process and just retried the
> connection on failure (i.e. it is almost always the client that fails to
> connect because all sockets are in use). Keep in mind that this test
The Client fails to connect because the client sockets are in use or the
Server sockets are in use? If its the Server sockets in use, using Win2003
Server is there away to increase buffers specfically for more web sockets to
be created ?
> was many years ago, so I've forgotten a lot of the details but from what
> you've described, you're running into many of the same issues I ran into.
>
> I do seem to recall the web document root getting flooded with bogus
> files from stdin/stdout. Search the Xitami archives and there should be
> a warning from me about a DDoS issue with CGI support in Xitami. I
> remember looking at the source code to CGI support to see how it would
> need to be fixed and something about incorrect filename selection was
> the cause of bogus files and the blank pages (i.e. too many requests in
> too short of a time resulted in lousy/incorrect filename selection).
> Also because the files are in the web root, it is conceivable that
> security is drastically reduced (i.e. someone could remotely gain access
> to passwords/credit card info/etc).
>
> In theory, if you are using PHP, you should be able to drastically
> improve performance and security by using Xitami LRWP, multiple
> instances of the ISAPI LRWP daemon (isapid - probably still a 'beta'),
> and the ISAPI PHP module. Then, in your PHP code, use persistent
> connections to the MySQL database (i.e. mysql_pconnect()). LRWP, IMO,
> is a weak protocol - it can only handle one request at a time. For the
> load you describe, 10-12 instances of the ISAPI LRWP daemon will
> probably be sufficient. The server will still be hammered but should be
> able to handle the load.
>
> --
> Thomas Hruska
> Shining Light Productions
>
>
>
> --
> Xitami Users Mailing List -- For Xitami support
> To unsubscribe: http://lists.xitami.org/mailman/listinfo/xitami
>
More information about the Xitami
mailing list