Here I am stating some basic description about netstat states
The socket has an established connection.
The socket is actively attempting to establish a connection.
A connection request has been received from the network.
The socket is closed, and the connection is shutting down.
Connection is closed, and the socket is waiting for a shutdown
from the remote end.
The socket is waiting after close to handle packets still in the
CLOSE The socket is not being used.
The remote end has shut down, waiting for the socket to close.
The remote end has shut down, and the socket is closed. Waiting
LISTEN The socket is listening for incoming connections. Such sockets
are not included in the output unless you specify the
–listening (-l) or –all (-a) option.
Both sockets are shut down but we still don’t have all our data
The state of the socket is unknown.