Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

there is no "-H" option for RedHat EL6 #57

Closed
almedinvisionary opened this issue Jan 29, 2019 · 2 comments
Closed

there is no "-H" option for RedHat EL6 #57

almedinvisionary opened this issue Jan 29, 2019 · 2 comments

Comments

@almedinvisionary
Copy link

I need to run the following command to create a list of IP addresses connected to the server, along with their total number of connections.
ss -Hntu | awk '{print $6}' | sort | uniq -c | sort -nr

We receive the following error:

ss: invalid option -- 'H'
Usage: ss [ OPTIONS ]
       ss [ OPTIONS ] [ FILTER ]
   -h, --help           this message
   -V, --version        output version information
   -n, --numeric        don't resolve service names
   -r, --resolve       resolve host names
   -a, --all            display all sockets
   -l, --listening      display listening sockets
   -o, --options       show timer information
   -e, --extended      show detailed socket information
   -m, --memory        show socket memory usage
   -p, --processes      show process using socket
   -i, --info           show internal TCP information
   -s, --summary        show socket usage summary

   -4, --ipv4          display only IP version 4 sockets
   -6, --ipv6          display only IP version 6 sockets
   -0, --packet display PACKET sockets
   -t, --tcp            display only TCP sockets
   -u, --udp            display only UDP sockets
   -d, --dccp           display only DCCP sockets
   -w, --raw            display only RAW sockets
   -x, --unix           display only Unix domain sockets
   -f, --family=FAMILY display sockets of type FAMILY

   -A, --query=QUERY, --socket=QUERY
       QUERY := {all|inet|tcp|udp|raw|unix|packet|netlink}[,QUERY]

   -D, --diag=FILE      Dump raw information about TCP sockets to FILE
   -F, --filter=FILE   read filter information from FILE
       FILTER := [ state TCP-STATE ] [ EXPRESSION ]

Is there a known workaround?

@jgmdev
Copy link
Owner

jgmdev commented Jan 30, 2019

Remove the -H flag or use netstat while using head to skip the output heading.

@jgmdev
Copy link
Owner

jgmdev commented Feb 1, 2019

Fixed by pull request #58

@jgmdev jgmdev closed this as completed Feb 1, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants