zoukankan      html  css  js  c++  java
  • netstat命令

    虽然经常用这个命令,但总是对其中的参数作用不太清楚,记录下

    what are functions of netstat?

    netstat - Print network connections, routing tables, interface statistics, masquerade
    connections, and multicast memberships(大意就是打印网络连接。路由表。接口数据,伪装的连接和多播的成员关系)

    netstat的参数很多,记录下常用的

    -t #代表tcp

    -u #代表udp

    -l #show only listening sockets

    -a #show both listening and non-listening(for TCP this means established connections)

    -n #show numerical addressed instead of trying to determine symbolic host,port or user names

    -v #代表verbose

    -p #show the PID and name of the program to which each socket belongs

    -o #Include information related to networking timers

    -C #print routing information from the route cache

    -Z #If selinux enabled print selinx context

    -g #display multicast group membership information for IPV4 and IPV6

    -r #display the kernel routing tables

    -e #display other/more information

    咱们经常用的几个

    netstat -lntup |grep "mysqld"

    netstat -an|grep 22

    ------------------------------------------------------

    NOTE(可替代的其他命令展示)

    This program is obsolete. Replacement for netstat is ss. Replacement for netstat -r
    is ip route. Replacement for netstat -i is ip -s link. Replacement for netstat -g
    is ip maddr.

  • 相关阅读:
    bzoj1966:[AHOI2005]病毒检测
    bzoj2938:[Poi2000]病毒
    bzoj3172:[Tjoi2013]单词
    luoguP3808[模板]AC自动机(简单版)
    luoguP3796[模板]AC自动机(加强版)
    Java 基本类型、封装类型、常量池、基本运算
    Java 内存分配(转)
    Java 数组ArrayList语法
    Java的修饰、继承、接口、抽象类
    2019数模国赛有感
  • 原文地址:https://www.cnblogs.com/uglyliu/p/6084708.html
Copyright © 2011-2022 走看看