0

I have a conky script that includes the tcp_monitor, but it shows all the localhost connections, too. (::1 and 127.0.0.1)

I cannot split the display by port numbers, as most conky configs do, so I need to filter out localhost.

Are there any ideas?

1

Having just received the 'Tumbleweed' badge for this question, I think I will answer it with an alternate configuration in case it helps someone:

${execp netstat -upant | grep "tcp\|udp" | grep -v "127.0.0.1\|::1" | awk '{split($4, a, ":"); print "%s %s\n", a[1], a[2] }' }

From this starting place, I can grep for different states, different IPs, etc. It's not as good as tcp_monitor and it eats more resources, but it works for my needs.

Your Answer

By clicking "Post Your Answer", you acknowledge that you have read our updated terms of service, privacy policy and cookie policy, and that your continued use of the website is subject to these policies.

Not the answer you're looking for? Browse other questions tagged or ask your own question.