I have Firebird 2.0 Classic running on a Debian 64bit and run queries via the ibase functions in PHP.

Loading pages that call Firebird queries sometimes take up to 10-20 seconds compared to only a fraction of a second for static pages.

The main query that runs is just a paginated list with a join;

Code:
SELECT FIRST 15 SKIP 0 * FROM equipment e, client c WHERE c.clientid = e.clientid
Watching the 'top' command shows the firebird process spiking each time the page loads, but it only ever uses 1% of CPU.

MySQL databases on the same server run very fast.

I know this is all a bit vague, but has anybody else experienced performance issues like this?