Netgear WG311v3 causes ndiswrapper socket deadlock

Bug #227033 reported by Alan Briolat
14
Affects Status Importance Assigned to Milestone
Linux
Invalid
Undecided
Unassigned
linux (Ubuntu)
Invalid
Undecided
Unassigned
ndiswrapper (Ubuntu)
Invalid
Medium
Unassigned

Bug Description

The occurrence of this bug is seemingly random, but happens to me on average once a day (but twice while writing this). Effectively, all of my TCP connections do nothing, and any new programs I start which use sockets in any way hang until I resolve the problem.

Solving the problem involves making NetworkManager stop the network connection (usually by telling it to reconnect). When I do this I get the following in dmesg:

[15824.027472] ndiswrapper (set_scan:1212): scanning failed (C0000001)
[15824.277080] ndiswrapper (set_essid:59): setting essid failed (C0000001)
[15825.861715] ndiswrapper (set_essid:59): setting essid failed (C0000001)
[15826.111890] ndiswrapper (set_essid:59): setting essid failed (C0000001)

However all of the processes that hung before catch up when I do this. To regain use of my wireless I have to reload the ndiswrapper module (rmmod ndiswrapper ; modprobe ndiswrapper). At this point, everything is back to normal.

I say that it's anything using sockets because most programs that are self-contained work fine when in this state, but things that fail to work tend to be using networking, or GNOME settings daemon (e.g. gnome-terminal, nautilus), or some other form of socket-based thing (I never knew sudo used sockets, but apparently it does!).

It took me quite a while to consider the networking to be the problem, but everything started working again when I killed the network connection. I'm thinking maybe this is some kind of deadlock somewhere to do with socket handling, which only gets resolves when a load of TCP connections get dropped. Unfortunately I'm not intimately familiar with the Linux kernel so I'm not sure where to look.

Uname: Linux iapetus 2.6.24-16-generic #1 SMP Thu Apr 10 13:23:42 UTC 2008 i686 GNU/Linux
Version: Ubuntu 2.6.24-16.30-generic
Using ndiswrapper with "Marvell Technology Group Ltd. 88w8335 [Libertas] 802.11b/g Wireless (rev 03)" device

Let me know what else is needed (I'll attach the usual dmesg and lspci info).

Revision history for this message
Alan Briolat (alan-codescape) wrote :
Revision history for this message
Alan Briolat (alan-codescape) wrote :
description: updated
Revision history for this message
Richard Seguin (sectech) wrote :

Thank you for taking the time to report this bug and helping to make Ubuntu better. Please answer these questions:

* Is this reproducible?
* If so, what specific steps should we take to recreate this bug?
* Is this a laptop or a desktop?
* Does this happen on a clean boot? (booting from scratch, not using resume/suspend)

I realize that you said it happens randomly so the first two questions may not apply... Sometimes it's an ACPI problem...
We'll get as much info as possible and with that information I'll try and find the right team to assign it to so it gets looked at quickly.

Revision history for this message
Richard Seguin (sectech) wrote :

Marked incomplete pending more information...

Changed in linux:
status: New → Incomplete
Revision history for this message
Alan Briolat (alan-codescape) wrote :

I haven't noticed any particular correlation between events and the bug occurring, so there are no steps I know of which will definitely reproduce this bug. I'll keep an eye out for any common factors.

This is a desktop machine, and as far as I can tell I've only had this problem since using wireless (in both Gutsy and Hardy).

Like I said, I still have use of the machine after "fixing" the problem, so let me know of any information I should gather the next time it happens that would help narrow it down.

Revision history for this message
Richard Seguin (sectech) wrote :

Thank you for your help

Revision history for this message
Jan Evert van Grootheest (j-e-van-grootheest) wrote :

Did you try the debug parameter of ndiswrapper?
Also the output of 'ndiswrapper -v' and 'ndiswrapper -l' would be interesting.

Also, your problem might have been fixed in ndiswrapper 1.51: http://sourceforge.net/project/shownotes.php?release_id=562382&group_id=93482
Perhaps somewhere you can find a package to test it...

Revision history for this message
Alan Briolat (alan-codescape) wrote :

I'll give the latest ndiswrapper a try and report back when I can tell if the bug still exists or not. Thanks =)

Revision history for this message
Alan Briolat (alan-codescape) wrote :

This bug should possibly be closed - I wanted to move to 64-bit, where a (possibly different) bug was causing a kernel panic for me (but definitely related to the wireless card), so I've bought a more Linux-compatible device, using neither ndiswrapper nor a Marvell chipset.

Revision history for this message
Richard Seguin (sectech) wrote :

Was the original issue fixed with the latest ndiswrapper? I don't want to close out a bug if it still remains...

Thanks,

Richard Seguin

Revision history for this message
Alan Briolat (alan-codescape) wrote :

The issue was not solved by any version of ndiswrapper (also, the latest in Hardy is newer than 1.52). I tried running ndiswrapper with a higher debug setting, but because of the seeming randomness of the bug, the log files filled and caused problems before the ndiswrapper bug manifested itself, so I still had no debug output from the actual breakage when it occurred.

Revision history for this message
Richard Seguin (sectech) wrote :

I'll leave the bug open for 30 days to see if anyone else has this problem.

Revision history for this message
didix (deiand) wrote :

Hi!
I'm writing this to say i DO have that exact same problem for couple of weeks now. It appeared after one of the regular updates. My wifi card is not Netgear ASIK, but it has a similar chip. It's built-in in my notebook. That's the lspci line concerning it:

00:0a.0 Ethernet controller: Marvell Technology Group Ltd. 88w8335 [Libertas] 802.11b/g Wireless (rev 43)

The kernel is: 2.6.24-19-generic
and "ndiswrapper -v" returns version 1.52.

Both are stock ubuntu packages. No tweaks. Don't close the bug as I think more ppl will show up experiencing it.

Thanks

Revision history for this message
habrys (adrian-habryka) wrote :

I have exact the same symptoms using the same wireless card: Netgear WG311v3 with ndiswrapper.

I experienced no problems at all on feisty and hardy using wired network. After moving my PC to another room, which forced me to buy and use a wireless card, this bug started to occur randomly once or twice a day. All the symptoms described by Alan are exactly the same on my machine (terminal, nautilus etc. cannot be started until I restart networking via Network Manager, then they catch up, error messages are the same etc.)

I also noticed, that having a samba share(s) mounted causes this strange "deadlock" to occur more often. I can see additional error messages in the output if dmesg | tail then:
[ 715.772180] CIFS VFS: Error 0xffffff90 on cifs_get_inode_info in lookup of \.Trash-1000
[ 725.749495] CIFS VFS: Error 0xffffff90 on cifs_get_inode_info in lookup of \.Trash-1000
[ 735.725806] CIFS VFS: Error 0xffffff90 on cifs_get_inode_info in lookup of \.Trash-1000
and so on...

But without samba shares mounted it happens as well, with only these error messages:
[ 1910.717822] ndiswrapper (set_scan:1212): scanning failed (C0000001)
[ 1910.967641] ndiswrapper (set_essid:59): setting essid failed (C0000001)
[ 1910.967650] ndiswrapper (set_infra_mode:149): getting operating mode to failed (C0000001)

On my laptop, which uses another wireless card with linux native driver I don't have any problems with networking.

Revision history for this message
Richard Seguin (sectech) wrote :

* Changing to confirmed as other reporters are having the same issue with the same hardware.
* Re-assigning to ndiswrapper.

Changed in linux:
importance: Undecided → Medium
status: Incomplete → Confirmed
Revision history for this message
Richard Seguin (sectech) wrote :

Just as a note for the recent reporters, could you please go through https://help.ubuntu.com/community/WifiDocs/WirelessTroubleShootingGuide and report back with what works/fails?

Thanks,

Richard Seguin

Revision history for this message
didix (deiand) wrote :

Having just gone through the troubleshooting guide - my problem is not in the DHCP / DNS area, nor driver area (since I can scan and this driver worked just fine up until a couple of weeks ago). Every time the connection drops dmesg outputs a line like this :

[ 4817.759121] ndiswrapper (set_scan:1212): scanning failed (C0000001)

I then either wait for nm-applet to reconnect or do a quick:

modprobe -r ndiswrapper
modprobe ndiswrapper

and everything works normal until next drop.
I hope I was helpful...

Thanks,
Deyan

Richard Seguin (sectech)
Changed in linux:
status: New → Invalid
Revision history for this message
Nicolas Piguet (npiguet) wrote :

Hello, I have exactly the same problem with exactly the same wireless card. It seems to happen randomly, but is triggered much faster if I use my connection heavily. For example, If I'm downloading a torrent it will deadlock in a few hours, but if the only thing I do is browse the internet it may take days before the deadlock happens.

I use Ubuntu Hardy AMD64 (with the proper 64 bit drivers for the WG311v3).

> ndiswrapper -v
utils version: '1.9', utils version needed by module: '1.9'
module details:
filename: /lib/modules/2.6.24-19-generic/ubuntu/misc/ndiswrapper/ndiswrapper.ko
version: 1.52
vermagic: 2.6.24-19-generic SMP mod_unload

> uname -a
Linux lotp-lanbox 2.6.24-19-generic #1 SMP Wed Jun 18 14:15:37 UTC 2008 x86_64 GNU/Linux

I use only packages from the official Ubuntu repos (backports disabled)

I'll try to run the wireless troubleshooting stuff when it breaks again

Revision history for this message
Richard Seguin (sectech) wrote :

didx: thank you for commenting on this issue but it seems the problem you are having is totally different then this issue, please create another bug report so we can take a look at your issue too.

Thanks,

Richard Seguin

Revision history for this message
Nicolas Piguet (npiguet) wrote :

So I tried following the WirelessTroubleShootingGuide that was provided, but it turns out that many of the commands will not run properly because when this bug occurs, sudo doesn't work anymore. Sudo probably opens some kind of socket to work its magic, and that makes it freeze when this bug appears. Also all commands that try to diagnose the problem by opening a connection to somewhere (and that includes DNS) lock up without providing any information and have to be forcefully killed.

And I can confirm that this bug really tends to happen when you do a lot of simultaneous opening/closing of connections (for example, when you download a torrent). I managed not to have any problems for more than a week by nothing more than browsing the web, but as soon as I started using Bittorrent this bug occured twice within a few hours.

Note that on the contrary to what didix says, modprobe -r ndiswrapper followed by modprobe ndiswrapper doesn't work and locks up too.

As to the questions asked in one of the top posts, the answers would be:

* Is this reproducible?
Yes, but not completely at will, trying to saturate the connection with a lot connection creation/destruction will make the bug appear much faster

* If so, what specific steps should we take to recreate this bug?
The best way I've found is to start any bittorrent on a popular torrent and wait a few ours. When the speed drops to zero, you can verify that all the applications that use a socket do not work anymore.

* Is this a laptop or a desktop?
I'm using a desktop.

* Does this happen on a clean boot? (booting from scratch, not using resume/suspend)
It happens from a clean boot.

Revision history for this message
Nicolas Piguet (npiguet) wrote :

Hmm... Interesting post on a fedora forum: http://forums.fedoraforum.org/archive/index.php/t-147494.html

According to one user, he had the same lockup problem with a wg311v2 card, and solved it using a 16k stack kernel (whatever that means... *shrugs*)

Revision history for this message
Kemble Wagner (oobe-trouble) wrote :

here is a thread i made in response to this bug report i didnt know how to reply to this bug report at first please get back to me and let me know if this fixes the issue as it did for me

Revision history for this message
Kemble Wagner (oobe-trouble) wrote :
Revision history for this message
Emilio (turl) wrote :

I have just tried your driver, doesn't solve my problem, I still can't connect to WPA-encrypted networks

Revision history for this message
Nicolas Piguet (npiguet) wrote :

I'm on the AMD64 architecture, so your driver cannot help me...

Revision history for this message
Kemble Wagner (oobe-trouble) wrote :

"I have just tried your driver, doesn't solve my problem, I still can't connect to WPA-encrypted networks" im only responding to the original topic this topic is not about WPA.

"I'm on the AMD64 architecture, so your driver cannot help me..." try finding newer amd64 drivers then

Revision history for this message
Kemble Wagner (oobe-trouble) wrote :

the netgear site says it has vista 64/32 drivers in this download

http://kbserver.netgear.com/release_notes/d103261.asp

i really cant help you with extraction there are progs that recognise some exe file
compression i installed in wine and copied the files from windows/inf however i dont think that will work if you want the amd 64 files anyway the solution is the same if you are experiencing the same probs as the original bug reporter

Revision history for this message
Kemble Wagner (oobe-trouble) wrote :

try this it came from a different site

here is the original link
http://www.encore-usa.com/product_download.php?region=us&bid=3

its a different brad with identical chipset

Revision history for this message
Kemble Wagner (oobe-trouble) wrote :

if that doesnt work try this one its the same sys file renamed using the netgear inf
im pretty sure that will work

Revision history for this message
Paul Watkins (6-launchpad-paulwatkins-co-uk) wrote :

I can confirm that I am having the identical issue as the above users.

I'm using:
Ubuntu 8.04
ndiswrapper 1.52
WG311v3

I agree with all the above comments regarding the recurrence of this bug. Dowloading torrents does seem to cause the issue to happen more readily. I've also noticed though that the signal strength seems to be quite low every time this happens.

I assume no one has found a solution to this yet?

Revision history for this message
Paul Watkins (6-launchpad-paulwatkins-co-uk) wrote :

Ignore my comment above re: signal strength

Revision history for this message
Kemble Wagner (oobe-trouble) wrote :

"I assume no one has found a solution to this yet?" did you read my post

Revision history for this message
Kemble Wagner (oobe-trouble) wrote :
Revision history for this message
Paul Watkins (6-launchpad-paulwatkins-co-uk) wrote :

Sorry, don't know how i missed that. I've installed the new driver so fingers crossed i won't be back...

Revision history for this message
Nicolas Piguet (npiguet) wrote : Re: [Bug 227033] Re: Netgear WG311v3 causes ndiswrapper socket deadlock

Please, be back anyway to let all of us know if it worked out for you or
not.

Paul Watkins wrote:
> Sorry, don't know how i missed that. I've installed the new driver so
> fingers crossed i won't be back...
>
>

Revision history for this message
Nicolas Piguet (npiguet) wrote :

Please come back anyway to let us know whether it worked or not. I personally haven't had time to try the solution (and I have another computer for torrenting...), but I'd love to know how it works out for you.

Revision history for this message
Nicolas Piguet (npiguet) wrote :

I tried both the drivers posted by Kemble Wagner and none of them worked properly. i got the following messages while trying to use them:

Aug 2 23:51:25 lotp-lanbox kernel: [ 1586.732790] ndiswrapper version 1.52 loaded (smp=yes, preempt=no)
Aug 2 23:51:25 lotp-lanbox loadndisdriver: loadndisdriver: load_driver(358): couldn't load driver netmw13c
Aug 2 23:51:25 lotp-lanbox kernel: [ 1586.741043] usbcore: registered new interface driver ndiswrapper

and

Aug 3 00:09:33 lotp-lanbox kernel: [ 2672.136910] ndiswrapper version 1.52 loaded (smp=yes, preempt=no)
Aug 3 00:09:33 lotp-lanbox loadndisdriver: loadndisdriver: load_driver(358): couldn't load driver wg311v3
Aug 3 00:09:33 lotp-lanbox kernel: [ 2672.146506] usbcore: registered new interface driver ndiswrapper

So I'm still stuck with the deadlocking driver.

Revision history for this message
Paul Watkins (6-launchpad-paulwatkins-co-uk) wrote :

The driver loads fine on mine. It seems to have solved the problem of the system hanging during normal internet use however I still have the issue where the system hangs after pressing the shutdown button on the desktop. The solution is either to press the power button on the pc itself or disable the wireless prior to shut down.

This driver is definitely an imporvement though.

Revision history for this message
Kemble Wagner (oobe-trouble) wrote :

you could always try ndiswrapper 1.53 compiled from source as thats what im using

Revision history for this message
Kemble Wagner (oobe-trouble) wrote :

also it just dawned on me you said i tried both the drivers even tough i posted 3 and 2 are 64 bit and you most likely didnt notice here is the link to the 32 bit http://ubuntuforums.org/showthread.php?t=861943

Revision history for this message
Nicolas Piguet (npiguet) wrote :

32 bits drivers cannot be used on 64 bit systems, as far I know.
Ndiswrapper will fail to load them.

Kemble Wagner wrote:
> also it just dawned on me you said i tried both the drivers even tough i
> posted 3 and 2 are 64 bit and you most likely didnt notice here is the
> link to the 32 bit http://ubuntuforums.org/showthread.php?t=861943
>
>

Revision history for this message
Kemble Wagner (oobe-trouble) wrote :

Oh sorry i thought you were using a 32bit system my mistake well im sorry but i have not had a chance to test the 64 bit drivers

Revision history for this message
Kemble Wagner (oobe-trouble) wrote :

i can tell you how to get the same 64 bit version drivers as im using in 32 bit i used wine to install the latest netgear drivers from the site and copyied the *.sys and *.inf files from fake windows c:\windows\inf directory that will definatly work i posted the 64 bit drivers from other sources i found on the net as im using 32bit still as its more compatable and stable

Revision history for this message
Richard Seguin (sectech) wrote :

Thank you for taking the time to report this bug and helping to make Ubuntu better. You reported this bug a while ago and there hasn't been any activity in it recently. We were wondering if this is still an issue for you. Can you try with the latest Ubuntu release? Thanks in advance.

Revision history for this message
martin_henry (mhd720) wrote :

I can confirm this problem occurs in 8.04 (32 bit) and 8.10 (64 bit), though I was using drivers posted by various walk-throughs which may not have had the latest. I have bookmarked and will return if I ever manage to solve the freezing issue.

Revision history for this message
Nicolas Piguet (npiguet) wrote :

I managed to fix that problem on 8.10 64 bits by using the drivers found on this page:
http://sites.google.com/site/subtlegems/netgear-wg311v3-ndis-driver-for-linux-amd64

Additionally, I'm using the Karmic packages for ndiswrapper-common and ndiswrapper-utils-1.9, which I downloaded from
http://packages.ubuntu.com/karmic/ndiswrapper-utils-1.9
http://packages.ubuntu.com/karmic/ndiswrapper-common

Now my lockups are gone, and I can use WPA.

Revision history for this message
Przemek K. (azrael) wrote :

This bug report is being closed due to your last comment regarding this being fixed with an update. For future reference you can manage the status of your own bugs by clicking on the current status in the yellow line and then choosing a new status in the revealed drop down box. You can learn more about bug statuses at https://wiki.ubuntu.com/Bugs/Status. Thank you again for taking the time to report this bug and helping to make Ubuntu better. Please submit any future bugs you may find.

Changed in linux:
status: New → Invalid
Changed in ndiswrapper (Ubuntu):
status: Confirmed → Invalid
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.