Network Monitoring with Ethereal
We all hope that our networks simply do what they are supposed to do, but often that is not the case. Two systems that should talk to each other don't; a network becomes saturated with traffic for no apparent reason; you need to know what some non-Linux device is doing. In these and other networking situations, Ethereal may be the tool that saves the day.
A few years ago I set up a a wireless link for a project. It was relatively slow--a real data throughput of around 300Kbps--but it easily should have handled the system's traffic. It should have, but in reality, the network seemed saturated much of the time. On paper, everything was fine. The link capacity was significantly more than the traffic--but that was on paper.
The switch talking to the master radio did have a lot of blinking lights, but watching blinking lights to measure traffic is about as accurate as using your tongue as a battery tester. Starting up Ethereal, however, quickly identified the problem. A whole bunch of computers running some other operating system were sending broadcast packets over the network for such exciting events as a computer being turned on or the paper supply in a printer becoming low.
Once I had the problem identified, it was easy to correct. I simply moved the radio traffic to a subnet away from the chatty operating system, and performance was fine.
Ethereal's man page offers this synopsis of what the program does: "Interactively browse network traffic". My use of Ethereal described above occurred in real time, but Ethereal uses the same file format as tcpdump. Therefore, you can use Ethereal to analyze an old dump file. Besides this libpcap format, Ethereal can read many other dump formats, including those from capture tools used on other operating systems--even the chatty ones.
As with virtually all protocol analyzers, Ethereal shows you a summary line for a packet and a hex dump. It also gives you the ability to drill down through the protocol tree. In addition, you can define filters to select and display specifically the data you are interested in. In short, Ethereal offers quite a few command-line options. Unless you want to plant Ethereal in a script, though, it is easier to set it up interactively to do what you want.
A word of warning: if you are monitoring live traffic for a system other than the one Ethereal is running on, make sure you are connecting to it at a point where you can see the traffic. Ethereal sets your local Ethernet interface to promiscuous mode, which means it sees all the traffic. If, however, your system is connected to an Ethernet switch, only the traffic for your system appears and is analyzed. You may need to "splice in" to the place you want to monitor using a hub.
Besides basic monitoring, Ethereal offers a lot of analyzing options. In my example at the start of this article, I could have used a filter to pull out the expected traffic. For example, adding tcp.port != 80 to the filter window and clicking the Apply button would have excluded any port 80 (HTTP) traffic from the display.
The Colorize Display option is handy as well. Select Colorize Display from the Display menu, and Ethereal guides you through the setup. The steps are simple:
You name your new entry and enter an expression. For example, ip.addr == 126.96.36.199 would select any packets whose "from" or "to" IP address is equal to 188.8.131.52. Don't worry, you don't have to memorize all of these choices; the Add Expression button offers a list of all the options.
Select a background color for the new rule.
Select a foreground color for the new rule.
Click Save if you want Ethereal to remember your rules.
That's all there is to it. If you are displaying in real time, you will see the packets appear in color immediately. If you don't like a rule, simply go back and edit it in the same menu.
Copyright (c) 2004, Dean Wilson. Originally published in Linux Gazette issue 98. Copyright (c) 2004, Specialized Systems Consultants, Inc.
Dean Wilson is a system administrator and occasional updater of his Web pages.
Free Webinar: Hadoop
How to Build an Optimal Hadoop Cluster to Store and Maintain Unlimited Amounts of Data Using Microservers
Realizing the promise of Apache® Hadoop® requires the effective deployment of compute, memory, storage and networking to achieve optimal results. With its flexibility and multitude of options, it is easy to over or under provision the server infrastructure, resulting in poor performance and high TCO. Join us for an in depth, technical discussion with industry experts from leading Hadoop and server companies who will provide insights into the key considerations for designing and deploying an optimal Hadoop cluster.
Some of key questions to be discussed are:
- What is the “typical” Hadoop cluster and what should be installed on the different machine types?
- Why should you consider the typical workload patterns when making your hardware decisions?
- Are all microservers created equal for Hadoop deployments?
- How do I plan for expansion if I require more compute, memory, storage or networking?
|Dynamic DNS—an Object Lesson in Problem Solving||May 21, 2013|
|Using Salt Stack and Vagrant for Drupal Development||May 20, 2013|
|Making Linux and Android Get Along (It's Not as Hard as It Sounds)||May 16, 2013|
|Drupal Is a Framework: Why Everyone Needs to Understand This||May 15, 2013|
|Home, My Backup Data Center||May 13, 2013|
|Non-Linux FOSS: Seashore||May 10, 2013|
- RSS Feeds
- Making Linux and Android Get Along (It's Not as Hard as It Sounds)
- Using Salt Stack and Vagrant for Drupal Development
- Dynamic DNS—an Object Lesson in Problem Solving
- New Products
- Validate an E-Mail Address with PHP, the Right Way
- Drupal Is a Framework: Why Everyone Needs to Understand This
- A Topic for Discussion - Open Source Feature-Richness?
- Download the Free Red Hat White Paper "Using an Open Source Framework to Catch the Bad Guy"
- Tech Tip: Really Simple HTTP Server with Python
3 min 30 sec ago
- Keeping track of IP address
1 hour 54 min ago
- Roll your own dynamic dns
7 hours 7 min ago
- Please correct the URL for Salt Stack's web site
10 hours 19 min ago
- Android is Linux -- why no better inter-operation
12 hours 34 min ago
- Connecting Android device to desktop Linux via USB
13 hours 3 min ago
- Find new cell phone and tablet pc
14 hours 1 min ago
15 hours 30 min ago
- Automatically updating Guest Additions
16 hours 38 min ago
- I like your topic on android
17 hours 25 min ago