3

What tool can I use to figure out what process is using the network over a certain time frame and how much data was transferred?

I can tell the data is transferred over a 5 minute period. Could be a backup. Is the process the right thing to be looking for?

3 Answers 3

3

You can use nethogs to exactly to that.

sudo yum -y install nethogs

To run nethogs:

sudo nethogs

To monitor your network you could also use iftop to monitor during your transfer, you'll see hosts you're communicating with. current, peak, cummulative transfer rates. You however won't be able to see which process.

sudo yum -y install iftop

If it says you don't have the permissions run it with sudo.

sudo iftop

To run iftop on a specific interface:

sudo iftop -i eth0

5
  • The question was what processes are using the network. iftop shows bandwidth by interface, but I don't think it show it by process. Mar 1, 2014 at 0:40
  • You are right, but now I remember of nethogs which can do that. I'll edit my post. Mar 1, 2014 at 0:46
  • Great thanks. I was looking to monitor the process because of the time the transfer happens. But iftop will sort the issue for me also, Ill just have to stay up. Unless there is some way to capture the output? Mar 2, 2014 at 22:59
  • Check that out: stackoverflow.com/questions/20702980/… Mar 3, 2014 at 0:22
  • But these don't tell each process which server is communicating to...
    – Emanuele
    Mar 8, 2014 at 16:24
4

nethogs shows network usage by process, sorted by highest usage first.

2

You can use nettop, shows not only usage by process, but even which hostnames you send/receive data, and the split between TCP/UDP traffic. Additionally supports all IPv4 and IPv6 traffic (TCP/UDP only though).

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .