• manikant singh

    manikant singh

    1 year ago
    Hi Guys, Can some tell what number represents what protocol in "listening_ports" table. For example here protocols value is 6. what does it mean? TCP/UDP or any other protocol if any. Here state "ESTABLISHED" suggest TCP connection. But I would to know if protocol number can be mapped to protocol name. Can anyone please either give reference to a document or list its type.
      "family": 2,
      "fd": 3,
      "local_address": "",
      "local_port": 22,
      "net_namespace": 4026531957,
      "path": "",
      "pid": 29831,
      "protocol": 6,
      "remote_address": "",
      "remote_port": 42266,
      "socket": 32357509,
      "state": "ESTABLISHED"
    Thanks for your help.
  • sundsta


    1 year ago
  • CptOfEvilMinions


    1 year ago
    select REPLACE(REPLACE(protocol,17,'UDP'),6,"TCP") from listening_ports WHERE protocol !=0 LIMIT 50;

    Replaces 6 with
    and 17 with