📄 netstat.txt
字号:
Answers to the questions in Part 1:
1.(1)
There is only one TCP connection when the program excutes;
The number matches the TCP counter exactly.
Before the program executes: (copy from the command line window)
TCP Statistics for IPv4
Active Opens = 365
Passive Opens = 16
Failed Connection Attempts = 6
Reset Connections = 135
Current Connections = 0
Segments Received = 46444
Segments Sent = 46820
Segments Retransmitted = 13
After the program excutes: (copy from the command line window)
TCP Statistics for IPv4
Active Opens = 366
Passive Opens = 16
Failed Connection Attempts = 6
Reset Connections = 135
Current Connections = 1
Segments Received = 46453
Segments Sent = 46829
Segments Retransmitted = 13
We can see that the connections increase one when the program is excuting.
(2)
Before the program excutes,
Packets Received = 115899
when excuting the program,
Packets Received = 115953
The packages received are: 115953-115899=54.
I sent the request "GET /cn/xxgk/index.htm HTTP/1.0" to the server www.whu.edu.cn, the detailed result is:
You have sent 35 bytes to server.
You received 8652 bytes from server.
Since there is only one package to the server,the average size of sent package is:35 bytes;
And the average size of received package is: 8652/54, 160 bytes approximately.
I think the reason for the difference of the size between the sent package and the received package is that the content of the package is different.The send package only contains the request header,but the received package contains both the header and the entity body. As a result, the received package will be larger than the send package.
2.
I use my IE to read a Web pages that have 21 embedded pictures in baidu.
There are one page and 21 pictures currently.
But during the session, there are tow connections built, as the following:
TCP Statistics for IPv4
Active Opens = 379
Passive Opens = 0
Failed Connection Attempts = 8
Reset Connections = 92
Current Connections = 2
Segments Received = 8502
Segments Sent = 6760
Segments Retransmitted = 23
Older versions of HTTP opened a new TCP connection for each file fetched, but HTTP 1.1 tries to maintain the TCP connection across multiple GET requests. So I think it uses a more recent version of HTTP
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -