SQL Stress Tool Benchmark

Our first benchmark was custom-written in .NET, using ADO.NET to connect to the database. The AnandTech Forums database, which is over 14GB in size at the time of the benchmark, was used as the source database. We'll dub this benchmark tool "SQL Stress Tool" for the purposes of discussing what it does. We have done some updates to the tool since we first used it; it now supports Oracle, and MySQL. We also adjusted the test time for this test and future tests to 20 minutes. The reason for this was to ensure that we used as much memory as possible for future planned 64 bit tests.


Click to enlarge.

SQL Stress allows us to specify the following: an XML based workload file for the test, how long the test should run, and how many threads it should use in which to load the database. The XML workload file contains queries that we want executed against the database, and some random ID generator queries that populate a memory resident array with ID's to be used in conjunction with our workload queries. The purpose of using random ID's is to keep the test as real-world as possible by selecting random data. This test should give us a lot of room for growth, as the workload can be whatever we want in future tests.

Example workload:


    Select1
    select count(iuserid) as usercount from ftdb_forumusers where iforumid = 1


    Select2
    select count(u.iuserid) as currusercount from ftdb_users u,ftdb_forumusers fu where fu.iforumid = 1 and u.iuserid = fu.iuserid and dtlastvisiteddate > '[q]qGetLastVisitDate[/q]'

Example Random ID Generator:


    qGetLastVisitDate
    select dtlastvisiteddate,newid() as ldate from ftdb_users where dtlastvisiteddate is not null order by ldate


The workload used for the test was based on every day use of the Forums, which are running FuseTalk. We took the most popular queries and put them in the workload. Functions, such as reading threads and messages, getting user information, inserting threads and messages, and reading private messages, were in the spotlight. Each reiteration of the test was run for 20 minutes, with the first being from a cold boot. SQL was restarted in-between each test that was run consecutively.

The importance of this test is that it is as real world as you can get; for us, the performance in this test directly influences what upgrade decisions we make for our own IT infrastructure.


Test hardware configuration SQL Stress Results
Comments Locked

97 Comments

View All Comments

  • Zan Lynx - Monday, February 14, 2005 - link

    I see Viditor explained what he really wanted. That was my first comment and by the time I'd filled out all the forms and received the email with my password he had already explained. Sorry. Please ignore me.
  • Zan Lynx - Monday, February 14, 2005 - link

    Viditor, the test hardware used 8GB RAM for both the Xeon and Opteron systems according to page 2.
  • Viditor - Monday, February 14, 2005 - link

    Jason - Let me expand on my request...

    Because there is still no hardware IOMMU on Xeon chipsets, I believe they must use PAE for 64bit addressing over 4GB, however Opteron doesn't have this problem and can address directly up to 128GB.
    I would very much like to see the results of a comparison on the same testbed you used for this article (8GB Ram) to compare and see how much this effects performance as this seems a very typical model to me.

    Cheers!
  • Viditor - Monday, February 14, 2005 - link

    Jason - Very well done test and article!

    I too would be very interested in a 64bit Linux (or even Windows Beta) test with that configuration...
    One of the things I am anxious to see is Xeons reaction to >4GB of ram on its performance. There are still NO results (that I have seen) with that configuration.

    Cheers, and thanks for the article.
  • sri2000 - Monday, February 14, 2005 - link

    Someone mentioned adding other database functions to provide different kind of stresses. How about using SQL Server Data Transfromation Services (DTS) to perform a variety of mass imports/exports from the test database?

    You could also perform some Full-Text searches mixed in with the regular queries on appropriately indexed tables - though those are really disk intensive rather than CPU-intensive (though the CPU usage does spike significantly when these queries are run).

    I also wonder if adding queries which hit Views in addition to regular tables would affect anything, the result being that you're essentially running nested queries (though this doesn't likely reflect the type of usage seen in your forums, which was the basis of this test).

    By the same token, having queries that use wildcards, user functions, sub-queries, etc (rather than just simple selects & inserts) will also add complexity to the searches & might affect the results.

  • Marlin1975 - Monday, February 14, 2005 - link

    Like someone else pointed out, when will you do some test to see what the SSE3 did for AMD.

    Also what were the temps on both of the NEW Cpus. Haveing hundreds of them in a server room can cost a arm and a leg to keep cool, so I think temps do matter here.
  • fitten - Monday, February 14, 2005 - link

    #39, we don't need to point out that 64-bit Intel P4 Xeons have been out and available for a while even though WindowsXP64 isn't available yet. You can run the RC WindowsXP64 on those and on Opterons/Athlon64s.
  • rgb - Monday, February 14, 2005 - link

    I don't think the BIOS of the test machine was adapted to Revision E Opterons.

    I adapted LinuxBIOS to the Rev E stepping last week and the 1 GHz support is really the easiest thing (was already present in revision D processors). Changing the HT speed while the operating system is running is _very_ difficult. It requires a reset or LDTSTOP on both CPUs for the new frequency to be effective, so this is normally done a boot time in the BIOS. I guess ntune does not really change the HT frequency.

    In addition Revision E has a number of errata fixed which result in improved performance (for example Errata 94).

    The most important point is the new memory controller mode that reduces the DRAM bank conflicts. It improves STREAM benchmarks scores around 30%. This modes has to be automatically enabled by the BIOS, so please rerun the benchmark on a mainboard that supports Rev E processors.

  • Quanticles - Monday, February 14, 2005 - link

    I'd really want to see tests run on Linux, even if it is 32-bit. There are too many Windows programs that are tailored to Intel processors.

    I dont need to point out that Microsoft is delaying the 64 bit version of Windows until Intel has their 64 bit processor come out. If they're going to delay like that then I wonder how well the Opteron will preform on it.
  • Phiro - Monday, February 14, 2005 - link

    Jason: Ignore all the 64-bit idiots. Please keep supplying 32-bit sql benchmarks for a LONG time - in the real world 99.5% of production dbs are running on 32-bit sql servers and that number will remain quite high for a long, long time no matter how fast 64-bit takes off.

Log in

Don't have an account? Sign up now