Search icon CANCEL
Subscription
0
Cart icon
Your Cart (0 item)
Close icon
You have no products in your basket yet
Arrow left icon
Explore Products
Best Sellers
New Releases
Books
Videos
Audiobooks
Learning Hub
Conferences
Free Learning
Arrow right icon
Arrow up icon
GO TO TOP
Understanding TCP/IP

You're reading from   Understanding TCP/IP A clear and comprehensive guide to TCP/IP protocols

Arrow left icon
Product type Paperback
Published in May 2006
Publisher Packt
ISBN-13 9781904811718
Length
Edition 1st Edition
Concepts
Arrow right icon
Author (1):
Arrow left icon
CP Books a.s. CP Books a.s.
Author Profile Icon CP Books a.s.
CP Books a.s.
Arrow right icon
View More author details
Toc

Table of Contents (20) Chapters Close

Preface 1. Introduction to Network Protocols FREE CHAPTER 2. Network Monitoring Tools 3. Physical Layer 4. Link Layer 5. Internet Protocol 6. IP Address 7. Routing 8. IP Version 6 9. Transmission Control Protocol 10. User Datagram Protocol 11. Domain Name System 12. Telnet 13. File Transfer Protocol 14. Hypertext Transfer Protocol 15. Email 16. Forums 17. Lightweight Directory Access Protocol A. CISCO Routers Index

9.4 Determining the Connection State

You can list all the actual TCP and UDP connections using the netstat command with the — a parameter.

$ netstat -an

Active Internet connections (including servers)
Proto Recv-Q Send-Q Local Address Foreign Address (state)
tcp 0 0 194.149.105.18.22 194.149.103.204.24695 TIME_WAIT
tcp 0 0 194.149.105.18.3099 194.108.145.128.25 SYN_SENT
tcp 0 34472 194.149.105.18.3079 195.47.32.245.25 ESTABLISHED
tcp 0 0 *.22 *.* LISTEN
tcp 0 0 *.25 *.* LISTEN
tcp 0 0 *.53 *.* LISTEN
udp 0 0 *.53 *.*
udp 0 0 127.0.0.1.53 *.*

Note

If the switch — n is used, it means that the IP addresses will not be replaced with DNS names by reverse transltion.

The first two lines are the list header. The columns have the following meanings:

  • The Proto column contains the name of the protocol used (TCP or UDP).
  • The Recv-Q column displays the number of bytes in the connection input queue (waiting to be processed by an application).
  • The Send-Q column displays the number of bytes...
lock icon The rest of the chapter is locked
Register for a free Packt account to unlock a world of extra content!
A free Packt account unlocks extra newsletters, articles, discounted offers, and much more. Start advancing your knowledge today.
Unlock this book and the full library FREE for 7 days
Get unlimited access to 7000+ expert-authored eBooks and videos courses covering every tech area you can think of
Renews at $19.99/month. Cancel anytime
Banner background image