NEW LOCATION

Olá Brazil Brazil NVMe-powered VPS Plans in Brazil Now Available.

Deploy Instantly
  • +357 2425 0808
  • Login
  • English

Home

Blog

How to Watch TCP and UDP Ports in real-t...

How to Watch TCP and UDP Ports in real-time in a Linux Server

How to Watch TCP and UDP Ports in real-time in a Linux Server

NetShop ISP

NetShop ISP · Blog Author

Jun 17, 2021 · Technical Tutorials

As a web hosting provider we work closely with our customers who, in majority, are system administrators and network engineers. One of the most frequent challenges a Linux server administrator will face, is the monitoring of network connections/sockets on the server to identify and resolve bottlenecks.

In this article we explain, in simple words, what TCP and UDP are and how you can monitor the activity on your Linux server in real-time.

What is TCP and UDP?

The Transmission Control Protocol (TCP) and the User Datagram Protocol (UDP) are both network protocols responsible for data transfers between an end-user’s device to a web server.

For example, when chatting on Skype the TCP and UDP protocols are used so that your messages can travel from your laptop or mobile, through Skype’s Servers, and reach your Skype contact; and vice-versa.

How to List all Open TCP and UDP Ports in Linux

The netstat is system administrators’ favorite command to list all open ports on a Server. However, as it has been deprecated, you can now also use the ss utility for details network statistics.

Simply type the following command:

sudo netstat -tulpn
Using netstat on Linux server to list all Open TCP and UDP Ports

Explanation of the netstat command flags/parameters

-t : Enables listing of TCP ports
-u : Enables listing of UDP ports
-l : Displays only listening sockets
-n : Displays the port number
-p : Displays the process name

How to Watch TCP and UDP Ports in Real-Time

To monitor the TCP and UDP ports on your Linux server in real-time, the following command should be used:

sudo watch netstat -tulpn

or

sudo watch ss -tulpn
Real-time monitoring of TCP and UDP ports on Linux Server

Once you are done with Ports monitoring, you can type Ctrl-C to exit the watch utility.

Press Releases
78

Free VPS Trial

No Credit Card Required.

Recent Posts

NetShop ISP CEO Stefano Sordini to Moderate Key Panel on Forex AI Automation at Cyprus Fintech Summit 2024

NetShop ISP CEO Stefano Sordini to Moderate Key Panel on Forex AI Automation at Cyprus Fintech Summit 2024

15 November, 2024

Preparing for the Daylight Saving Time (DST) Change: Essential Updates for MetaTrader 4/5 Platforms

Preparing for the Daylight Saving Time (DST) Change: Essential Updates for MetaTrader 4/5 Platforms

25 October, 2024

NetShop ISP Celebrates 20 Years of Innovation and Excellence in Hosting and Data Center Solutions

NetShop ISP Celebrates 20 Years of Innovation and Excellence in Hosting and Data Center Solutions

22 October, 2024

NetShop ISP Makes Waves at Forex Expo Dubai 2024: Showcasing Cutting-Edge Hosting for the Financial Services Industry

NetShop ISP Makes Waves at Forex Expo Dubai 2024: Showcasing Cutting-Edge Hosting for the Financial Services Industry

09 October, 2024

The Importance of Server Backups: Ensuring Data Security and Business Continuity

The Importance of Server Backups: Ensuring Data Security and Business Continuity

24 September, 2024

#letushostyou

Award Winning Hosting Provider established in 2004.

120 Faneromenis Avenue, Imperial Tower, 2nd Floor, Larnaca 6031, Cyprus

Products

Bare Metal Servers

Customized Servers

Virtual / Cloud Servers

Forex VPS

Storage VPS

cPanel Web Hosting

Reseller Web Hosting

Colocation

Addons

Premium DNS

Email Hosting

Cloud Backup

DDoS Protection

Licenses

SSL Certificates

Domain Names

Premium SLAs

About Us

Data Center Locations

Looking Glass

Our Company

Contact Us

Careers in Cyprus

Become a Partner

Awards

Certifications

© 2024 S.S. NetShop Internet Services Ltd. All rights reserved.  Terms & Conditions  |  Privacy Policy
CY Reg. Number: HE 217340 | EU VAT Number: CY10217340J

Visa
Mastercard
PayPal
Bitcoin
Tether
Ethereum
Litecoin
Wise
Revolut
Wire Transfer