Are you running mapserver on the same machine as the database? What does 'top' say its doing during the 5 seconds? dave