Bug 14241 - r8169 Promiscuous mode on network slows the network down
Summary: r8169 Promiscuous mode on network slows the network down
Status: CLOSED OBSOLETE
Alias: None
Product: Networking
Classification: Unclassified
Component: IPV4 (show other bugs)
Hardware: All Linux
: P1 high
Assignee: Stephen Hemminger
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2009-09-26 23:34 UTC by Mudit Wahal
Modified: 2012-06-13 17:13 UTC (History)
4 users (show)

See Also:
Kernel Version: 2.6.31
Subsystem:
Regression: Yes
Bisected commit-id:


Attachments

Description Mudit Wahal 2009-09-26 23:34:38 UTC
Hi,

I have been running 2.6.22.14 kernel for about 2+ years on a pentium D 925, 1GB DDR2 system. I have a realtek 8169 gigabit onboard network controller on a ubuntu distribution. I wanted to try kvm but it didn't run because the kvm-intel module of 2.6.22 kernel is way too old. So, I upgraded to 2.6.28 (and later to 2.6.31 to eliminate 2.6.28 issues) to try that kernel. The kvm did work with 2.6.28. I had to put the ethernet in bridge mode so that the kvm guest OS gets the same IP address from my subnet. As a side effect when putting in bridge mode, the ethernet interface also enters promiscuous mode. I made changes in /etc/network/interface file as per ubuntu kvm wiki page to add a bridge interface and add the eth0 to the bridge port.

Anyway, I noticed that certain network related tasks were taking too long. I stream video my server using UPnP to my UPnP client. The UPnP client had trouble streaming over a gigabit network inside my home. I was watching a x264 720p movie yesterday and it was freezing on almost each frame. This is all with 2.6.28 (and later upgraded to 2.6.31 latest kernel). If I downgrade back to 2.6.22 kernel, I dont have any issues streaming even a 20Mbps movie.

I've a 6Mbps DSL line at home. I run some scripts during the day to get stocks quotes from yahoo. That involves about issues 100 or so wget requests. On a 2.6.22 kernel, that takes about 2-3 mins to complete. On a 2.6.31 kernel it takes about 45-50 mins.

Since I didnt change the /etc/network/interfaces file , so when 2.6.22 loads, the ethernet still enters into promiscuous mode. I can run iftop and see that its watching other traffic on my network.

So, my conclusion is that there is something drastically change in the ethernet driver when it runs in promiscuous mode between 2.6.22 and 2.6.28 (or 31) which is making it run excruciatingly slow. I'm open to all suggestions for making any changes to my system. I'm willing to offer whatever information is needed from my system if someone is willing to take a look at it. I do need kvm but not the expense of a sloooow network.

Thanks for reading so far.
Comment 1 Francois Romieu 2009-09-28 20:40:29 UTC
Mudit, the comments in http://bugzilla.kernel.org/show_bug.cgi?id=11757 apply :
please narrow it down and send a complete dmesg.

-- 
Ueimor
Comment 2 Andrew Morton 2009-09-30 22:48:09 UTC
(In reply to comment #0)

> So, my conclusion is that there is something drastically change in the
> ethernet
> driver when it runs in promiscuous mode between 2.6.22 and 2.6.28 (or 31)
> which
> is making it run excruciatingly slow.

I marked this as a regression.
Comment 3 Mudit Wahal 2009-10-01 03:11:12 UTC
I'd like to take this bug back. I think something else is going and I need to narrow it down. I tried running same wget script (calls wget about 300 times) without the promiscuous mode and the results are still the same about 30-40mins.

If I run a speedtest from a mozilla browser, I get a consistent speed of 5.5Mbps.
Also, the responsiveness of 2.6.28 and 2.6.31.1 kernel seems very sluggish over vnc inside my LAN compared to 2.6.22.

Then I tried a Linksys 10/100 network card instead of my onboard realtek 8169. I get exact same results - means 300 wgets taking about 40-50mins. So, I don't know if the problem is with networking or some general scheduler issue. I need to narrow down by running some task 300 times which does number crunching in a loop on a 2.6.22 and a 2.6.31.1 kernel. It may be some other issue related to scheduler or something else. I compiled both 2.6.28 and 2.6.31.1 from source using make menuconfig and accepting most of the default options. I want to eliminate networking first. Unfortunately this server is in production network, I will not be able to try it till saturday morning.

Thanks

Mudit

Note You need to log in before you can comment on or make changes to this bug.