Performance of Sql Server 2008

I have 2 Sql Servers 2008 on different machines. I execute the same sql query on each machine (select from table with 500000 rows). On the first machine execution time is 1min 9sec. On the second machine this time is 2:45. The hardware on the second machine is better than on the first one. Why execution time is bigger on the second machine? Maybe there are any options on which Sql Server performance depends?

Could issue be in HDD? How can I check is that HDD issue?

See query statistics below:

1st:

Client Execution Time   16:25:21
Query Profile Statistics
  Number of INSERT, DELETE and UPDATE statements    0       0.0000
  Rows affected by INSERT, DELETE, or UPDATE statements 0       0.0000
  Number of SELECT statements   2       2.0000
  Rows returned by SELECT statements    407354      407354.0000
  Number of transactions    0       0.0000
Network Statistics
  Number of server roundtrips   3       3.0000
  TDS packets sent from client  3       3.0000
  TDS packets received from server  18077       18077.0000
  Bytes sent from client    738     738.0000
  Bytes received from server    7.403454E+07        74034540.0000
Time Statistics
  Client processing time    3859        3859.0000
  Total execution time  3859        3859.0000
  Wait time on server replies   0       0.0000

2nd:

Client Execution Time   08:21:24
Query Profile Statistics
  Number of INSERT, DELETE and UPDATE statements    0       0.0000
  Rows affected by INSERT, DELETE, or UPDATE statements 0       0.0000
  Number of SELECT statements   2       2.0000
  Rows returned by SELECT statements    399952      399952.0000
  Number of transactions    0       0.0000
Network Statistics
  Number of server roundtrips   3       3.0000
  TDS packets sent from client  3       3.0000
  TDS packets received from server  17833       17833.0000
  Bytes sent from client    738     738.0000
  Bytes received from server    7.29937E+07     72993700.0000
Time Statistics
  Client processing time    5688        5688.0000
  Total execution time  5734        5734.0000
  Wait time on server replies   46      46.0000

There might be physical disk fragmentation issues. On one server, the database files are stored in consecutive blocks/sectors, while on the other the file is scattered all ove the platter. (Likely to happen if you have a db grow by 10% chunks to ginormous sizes over weeks or months, and then back it up and restore it on a mostly empty disk.)

Hello, buddy!责编内容来自:Hello, buddy! (源链) | 更多关于

阅读提示:酷辣虫无法对本内容的真实性提供任何保证,请自行验证并承担相关的风险与后果!
本站遵循[CC BY-NC-SA 4.0]。如您有版权、意见投诉等问题,请通过eMail联系我们处理。
酷辣虫 » 后端存储 » Performance of Sql Server 2008

喜欢 (0)or分享给?

专业 x 专注 x 聚合 x 分享 CC BY-NC-SA 4.0

使用声明 | 英豪名录