Hi There
I created the test below as a quick check of the servers committed write capability. This scripts runs acceptably fast on my laptop, (which is about 3 year old 7200rpm hard disk, 2.something GHZ pentium processor. 2gb memory. Windows XP 32 bit.)
By comparision we have a 64 bit server that is Windows Server 2003 Enterprise, 8gb of memory, 2 quadcore processors and Raid 1+0 146GB SCSI harddrives.(not ideal config for SQL Server, but should be OK for our purposes). Its running SQL 2005 Standard.
However problem is the test query below runs about 70 times faster on my old laptop. Whats going on?? SHouldn't the smoking server be much faster??!
I eliminated a problem with McAfee already. I created a simple .net app that just writes strings to a text file. We got about a 25 increase in performance by preventing "access scans" which is read and write scans for the 32 bit McAfee virus scanner.
However SQL Server has not seen any change in performance, as a result of the 32 bit McAfee being disabled. Orinally when the Text files were able to be written much faster by disabling McAfee, we thought this would solve the problem for SQL Server, but the SQL Query below still runs about 1-2 orders of magnitude slower than on much more modest machines that are in use. This new server is still getting commissioned but its SQL Server is acting like a dog. Any ideas??
WHen I look at the disk queue length in PerfMon it is sitting about 100%.
I am using remote desktop to view the server, but even when turning off remote desktop, the query doesn't speed up.
The server isn't doing anything else and perfmon shows this.
There is only 1 logical disk (as per the other machines that i have tested this on, with a fraction of the hardware).
I checked the IsStall (as per http://www.sql-server-performance.com/tips/gen_tips_p3.aspx) and its only 8ms.
Here is the query below that is of concern to me. Its just a dummy query but highlights a significant performance problem on the "to-be" production server.
Help! What am I missing here? I'm satisfied with the pure writing to a text file from a .net console app but something is severely wrong with SQL Server committed writes indicating that there is some bad configuration issue at stake within SQL Server. Any ideas?
USE [master]
GO
DBCC DROPCLEANBUFFERS
GO
USE [master]
GO
/****** Object: Database [test] Script Date: 10/14/2008 15:33:58 ******/
IF EXISTS (SELECT name FROM sys.databases WHERE name = N'test')
DROP DATABASE [test]
go
create database test
go
USE TEST
GO
CREATE TABLE [dbo].[sqlcounter](
[id] [int] primary key NOT NULL
)
GO
SET NOCOUNT ON
declare @Counter int
set @counter = 0
--BEGIN TRAN
while (@counter