2024-07-12
한어Русский языкEnglishFrançaisIndonesianSanskrit日本語DeutschPortuguêsΕλληνικάespañolItalianoSuomalainenLatina
In Linux, netstat and ss are two commands used to display network connections, routing tables, interface statistics and other related information.
Display network connections, routing tables, and statistics interfaces
netstat
-a: All active connections and listening ports
-t: TCP port
-u: UDP port
-l: Listening status socket
-n: Display port number
-r: Display routing table
Example: #netstat -tunp
ss
-a: All active connections and listening ports
-t: TCP port
-u: UDP port
-l: Listening status socket
-n: World display port number
-r: Display routing table
-o: Display timer information
-p: Display process information
ss provides features that netstat does not have, with more concise output and better performance