3 round trips over network for simply "select sysdate from dual"

  • From: "qihua wu" <staywithpin@xxxxxxxxx>
  • To: oracle-l <oracle-l@xxxxxxxxxxxxx>
  • Date: Fri, 20 Jun 2008 17:13:58 +0800

Hi, all

When using tcpdump to check what happen over the network when do a simple
query as
SQL> select sysdate from dual;

SYSDATE
---------
20-JUN-08

The tcpdump is as following, 3 round trips between the server and client.
Why so many trips? Don't we only need to 1 round trip as client send the
query and the server reply?

16:56:13.354672 IP host1 > host2.1580: . 7898:8 054(156) ack 6755 win 32768
16:56:13.354683 IP host2.1580 > host1: . 6755:6 836(81) ack 8054 win 32768
16:56:13.521731 IP host1 > host2.1580: . 8054:8 126(72) ack 6836 win 32768
16:56:13.521744 IP host2.1580 > host1: . 6836:6 853(17) ack 8126 win 32768
16:56:13.688967 IP host1 > host2.1580: . 8126:8 141(15) ack 6853 win 32768
16:56:13.688980 IP host2.1580 > host1: . 6853:6 874(21) ack 8141 win 32768


And the expert says below: one additional roundtrip to initiate the query.
Don't quite understand why we need additional roundtrip to initiate.
http://www.adp-gmbh.ch/ora/sqlplus/arraysize.html

Thanks,
Qihua

Other related posts: