[benchmarks] GSoC report

[email protected] (Alexander Hjalmarsson) Wed, 29 Jul 2009 17:59:01 +0200
Newsgroups php.gsoc
Message-ID <[email protected]>
--001636c5ac7a0272a5046fda44a0
Content-Type: text/plain; charset=ISO-8859-1
Content-Transfer-Encoding: 7bit

Since the last report (about a week ago) I've tried to customize and get the
phpBB application to work in this scenario:

./deploy.php IP
where IP will be the web-server ip, and ip+1 the client ip and ip+2 the
database ip. The user would then run a command like:

./installphpbb

Which will automatically upload the files to the web server, fix the config
with the right data and the database with the right data.

This is working pretty well, but there are some problems. First of all, I
wasn't able to get a database from anyone (tried the internals and the phpbb
development irc channel, they don't have a mailing list). Therefore, I
thought that it was the best to create a database with random data much like
the RUBBOS benchmark, until we can find a better database. But I ran into
some trouble with sessions and such.

The problem is that to be able to use siege (or pretty much any benchmark
tool that works with a list of urls) you provide a file of static URLs to be
accessed and a optionally some POST arguments which is needed for posting
threads, comments and registering. But you will also need a GET variable
that is a session variable that is created when you access a page without a
session, and this is we're the ideas here fall apart. I would need to access
a page and get the created session id and use that as a GET-variable inside
the list of urls to be able to post a comment or thread as that user. This
isn't really easy to handle so I'm thinking about two solutions:

The first is to create a couple of thousand sessions before the siege starts
and in the list of urls, there will be correct sessions ids responding to
each user and provide static urls that will make it possible to post the
data. In this scenario all users can occur as logged in.

The second idea is to for each thread post, create a new custom SID that is
used for all users. When a user has created a thread or post, the SID will
change to another user so when the next time it's called, another user will
create a post/thread etc. The bad thing about this is that the session table
wouldn't match a "real" session table from a real scenario, but since
sessions isn't really the most of the work for the application, it might be
OK anyway.

These session problem exists since phpBB is using a way of making sure that
it's the right user by adding &sid=...... for each user, and a new sid is
created with each login.

I will try to figure out a better solution that won't have the drawback that
these have, but if you got any better ideas feel free to tell me :)

--001636c5ac7a0272a5046fda44a0--