5

How can I see how much network traffic each thread is doing in Linux?

Any information would be useful. (bytes transferred, # of accepts, etc)

1

2 Answers 2

3

You could try ntop.

After installing it, based on what distribution you're using, you will have to start the ntop service. Most probably it will look something like this (check your distro's documentation for proper ntop service starting):

service ntop start

After you successfully started the ntop service, you will be able to access ntop's web interface through your web browser:

http://localhost:3000/

Keep in mind that 3000 is the default port for ntop. If you changed it, you will have to change it in your browser as well. If you installed ntop on a remote machine, instead of "localhost", you will have to enter the proper IP/hostname.

After that, ntop usage is pretty straightforward. Go through its web interface and find the information you need. The web interface itself looks like this:

enter image description here
Source

enter image description here Source

2
  • Whilst this may theoretically answer the question, it would be preferable to include the essential parts of the answer here, and provide the link for reference. Also you link is dead. Jul 28, 2012 at 23:42
  • What I was trying to do was prevent link only answers. Your edit only makes this worse. Please take a look at this meta question and answer on how to recommend software without it being link only. Jul 29, 2012 at 16:33
1

There are several applications that can show you a "top"-like list of network traffic for a particular process or thread.

These are the two I've found most useful:

  1. nethogs

    enter image description here

  2. iftop

    enter image description here

5
  • Please explain further how this is useful to the question at hand. You should beware, that linking only answers are typically deleted. Jul 28, 2012 at 18:30
  • And how would you improve this after 2 years? Seriously. The guy asked for network monitor software, I answered, someone else answered the same way 'ntop' ... I still don't see what's wrong here. All 3 programs (2 linked by me, the 3rd from the accepted answer) can do what the question asks for. Jul 28, 2012 at 19:02
  • I recommend looking at this answer on meta. What we're trying to do is improve answer, from being link only to super awesome ones. If you have any more questions, feel free to contact me in the Ask a Mod or Root Access chat rooms. Jul 28, 2012 at 23:42
  • I hope this version is good enough. If not, feel free to delete it. Jul 29, 2012 at 10:41
  • @PatkosCsaba: Screenshots often go a long way :) Jul 29, 2012 at 16:29

You must log in to answer this question.

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