2 votes

signification de la sortie de netstat

Je cours netstat -a | grep ftp le résultat est

tcp        0      0 *:ftp                   *:*                     LISTEN

Quelle est la signification de ces zéros et étoiles ?

6voto

Avinash Raj Points 72686

La sortie de netstat la commande serait comme,

Proto Recv-Q Send-Q Local Address           Foreign Address         State

Les explications du format ci-dessus sont présentées ci-dessous.

Desde man netstat ,

   Proto
       The protocol (tcp, udp, raw) used by the socket.

   Recv-Q
       The  count  of  bytes  not copied by the user program connected to this
       socket.

   Send-Q
       The count of bytes not acknowledged by the remote host.

   Local Address
       Address and port number of the local end of  the  socket.   Unless  the
       --numeric  (-n)  option is specified, the socket address is resolved to
       its canonical host name (FQDN), and the port number is translated  into
       the corresponding service name.

   Foreign Address
       Address  and port number of the remote end of the socket.  Analogous to
       "Local Address."

   State
       The state of the socket. Since there are no states in raw mode and usu
       ally  no  states  used  in UDP, this column may be left blank.Normally
   this can be one of several values:

   ESTABLISHED
          The socket has an established connection.

   SYN_SENT
          The socket is actively attempting to establish a connection.

   SYN_RECV
          A connection request has been received from the network.

   FIN_WAIT1
          The socket is closed, and the connection is shutting down.

   FIN_WAIT2
          Connection is closed, and the socket is waiting for  a  shutdown
          from the remote end.

   TIME_WAIT
          The socket is waiting after close to handle packets still in the
          network.

   CLOSE  The socket is not being used.

   CLOSE_WAIT
          The remote end has shut down, waiting for the socket to close.

   LAST_ACK
          The remote end has shut down, and the socket is closed.  Waiting
          for acknowledgement.

   LISTEN The  socket is listening for incoming connections.  Such sockets
          are not included in the output unless you specify the  --listen
          ing (-l) or --all (-a) option.

Votre exemple :

tcp        0      0 *:ftp                   *:*                     LISTEN
  • 0 - nombre d'octets zéro

  • *:* - L'adresse étrangère doit avoir le format suivant : (n'importe quoi : n'importe quoi). Pas de mention d'une adresse particulière.

SistemesEz.com

SystemesEZ est une communauté de sysadmins où vous pouvez résoudre vos problèmes et vos doutes. Vous pouvez consulter les questions des autres sysadmins, poser vos propres questions ou résoudre celles des autres.

Powered by:

X