Occasionally, I need to see the network traffic by process (program). For example, I want to see what programs are generating network traffic. Some programs, like Google Updater and Microsoft Update, install themselves and run in the background without my knowledge. Or maybe I'm seeing a lot of network traffic when there should be none. I then need to know what process is generating the traffic so I can shut it down.
The command to find this information (from the Terminal) is:
lsof -n -P -i +c 50
If you want a GUI to show this info to you, download WaterRoof (an ipfw configuration program) and click "Net Processes"