views:

458

answers:

3

Hi All,

I am currently working on an n-tier system and battling some database performance issues. One area we have been investigating is the latency between the database server and the application server. In our test environment the average ping times between the two boxes is in the region of 0.2ms however on the clients site its more in the region of 8.2 ms. Is that somthing we should be worried about?

For your average system what do you guys consider a resonable latency and how would you go about testing/measuring the latency?

Karl

A: 

No. 8ms is pretty much insignificant.

vartec
+3  A: 

In short : no !

What you should monitor is the global performance of your queries (ie transport to the DB + execution + transport back to your server)

What you could do is use a performance counter to monitor the time your queries usually take to execute. You'll probably see your results are over the millisecond area.

There's no such thing as "Reasonable latency". You should rather consider the "Reasonable latency for your project", which would vary a lot depending on what you're working on. People don't have the same expectation for a real-time trading platform and for a read only amateur website.

Brann
A: 

On a linux based server you can test the effect of latency yourself by using the tc command.

For example this command will add 10ms delay to all packets going via eth0

tc qdisc add dev eth0 root netem delay 10ms

use this command to remove the delay

tc qdisc del dev eth0 root

More details available here: http://devresources.linux-foundation.org/shemminger/netem/example.html

All applications will differ, but I have definitely seen situations where 10ms latency has had a significant impact on the performance of the system.

Hamish Currie