프로세스 식별자. TCP socket에 attach되는 정보 중 하나.
IP address and port number work together to exchange data on a network
An IP address determines the location of that server. A port number determines which service or program on that server it wants to use(web page, FTP service, email… ).
Whenever we use web pages, we use port num. 443 (some 80)
ip address locates google’s web server then → forward the request to its built-in web server → finally reach google’s search page
My computer also can work as a server.
⇒ ‘cuz packet format of TCP segemnt is 16-bit integers port range = 2^16 - 1 = 65535
netstat
: Network Statistics - display the current network connections & port activity on ur com-a
: display all ports-n
: "IP address:port" 형태로 보여준다.-o
: shows up PIDnslookup [DNS Name]
Loopback address, localhost address (such as 127.0.0.1) is used to send back the data to itself after connected to another server but wants to receive the packet in itself without other’s interruptions.
⇒ the packet never leaves the localhost, it loopbacks. whereas 0.0.0.0 is everywhere (listen on every available network interface, IPv4).
Difference