Я пытаюсь выяснить, где происходит сброс tcp на моем веб-сервере. У меня есть следующий захват:
tcpdump -fnni bond0:-nnvvS -w dump.pcap 'tcp[tcpflags] & (tcp-rst) !=0'
Когда я смотрю на pcap в wirehark, я вижу сброс:
Flags: 0x004 (RST)
.... .... .1.. = Reset: Set
.... .... ..0. = Syn: Not set
.... .... ...0 = Fin: Not set
Window size value: 0
Calculated window size: 0
Window size scaling factor: -1 (unknown)
Checksum: 0x0f2f [validation disabled]
Good Checksum: False
Bad Checksum: False
но не показывает мне, кто сбросил соединение. Я считаю, что в tcpdump есть переключатели, которые позволят мне увидеть, кто сбросил соединение и, возможно, почему. Я безуспешно пробовал разные переключатели.
Заранее спасибо за вашу помощь.
Обратите внимание на Src Port
и Dst Port
:
Transmission Control Protocol, Src Port: http (80), Dst Port: norton-lambert (2338), Seq: 1406431331, Len: 0
Source port: http (80)
Destination port: norton-lambert (2338)
[Stream index: 3]
Sequence number: 1406431331
Header length: 20 bytes
Flags: 0x004 (RST)
000. .... .... = Reserved: Not set
...0 .... .... = Nonce: Not set
.... 0... .... = Congestion Window Reduced (CWR): Not set
.... .0.. .... = ECN-Echo: Not set
.... ..0. .... = Urgent: Not set
.... ...0 .... = Acknowledgment: Not set
.... .... 0... = Push: Not set
.... .... .1.. = Reset: Set
[Expert Info (Chat/Sequence): Connection reset (RST)]
[Message: Connection reset (RST)]
[Severity level: Chat]
[Group: Sequence]
.... .... ..0. = Syn: Not set
.... .... ...0 = Fin: Not set
Src Port: http (80)
означает, что это RST
пакет был отправлен со стороны сервера.
Если он исходит со стороны клиента, то вы должны увидеть причину:
Transmission Control Protocol, Src Port: 57715 (57715), Dst Port: http (80), Seq: 3509013939, Len: 0
Source port: 57715 (57715)
Destination port: http (80)
[Stream index: 32]
Sequence number: 3509013939
Acknowledgment Number: 0xd1274db3 [should be 0x00000000 because ACK flag is not set]
[Expert Info (Warn/Protocol): Acknowledgment number: Broken TCP. The acknowledge field is nonzero while the ACK flag is no
t set]
[Message: Acknowledgment number: Broken TCP. The acknowledge field is nonzero while the ACK flag is not set]
[Severity level: Warn]
[Group: Protocol]
Header length: 20 bytes
Flags: 0x004 (RST)
000. .... .... = Reserved: Not set
...0 .... .... = Nonce: Not set
.... 0... .... = Congestion Window Reduced (CWR): Not set
.... .0.. .... = ECN-Echo: Not set
.... ..0. .... = Urgent: Not set
.... ...0 .... = Acknowledgment: Not set
.... .... 0... = Push: Not set
.... .... .1.. = Reset: Set
[Expert Info (Chat/Sequence): Connection reset (RST)]
[Message: Connection reset (RST)]
[Severity level: Chat]
[Group: Sequence]
.... .... ..0. = Syn: Not set
.... .... ...0 = Fin: Not set