quintanilha Posted October 6, 2020 Share Posted October 6, 2020 Boa tarde desculpe abrir este tópico. Mas aqui foi o único lugar que achei que alguém poderia me ajudar. Eu preciso listar todos os ips conectado ao meu servidor centos instalado com cpanel/whm, eu utiliza o seguinte comando : netstat -plan|grep :80|awk {‘print $5’}|cut -d: -f 1|sort|uniq -c|sort -nk 1 Mas depois que a cpanel lançou a atualização do painel o mesmo parou de funcionar, queria saber se alguém poderia me ajudar, desde já agradeço a todos. 0 Quote Link to comment Share on other sites More sharing options...
pluginscpanelwhm Posted October 6, 2020 Share Posted October 6, 2020 Olá, O que ocorre é um erro de sintaxe no seu comando Assim netstat -plan|grep :80|awk {‘print $5’}|cut -d: -f 1|sort|uniq -c|sort -nk 1 Vai dar isso awk: cmd. line:1: {‘print awk: cmd. line:1: ^ invalid char '�' in expression awk: cmd. line:1: {‘print awk: cmd. line:1: ^ syntax error E assim funciona netstat -plan|grep :80|awk '{print $5}'|cut -d: -f 1|sort|uniq -c|sort -nk 1 1 Quote Link to comment Share on other sites More sharing options...
quintanilha Posted October 8, 2020 Author Share Posted October 8, 2020 Meu amigo Muito obrigado pela sua ajuda, funcionou corretamente. Deus te abençoe! 0 Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.