Ubuntu 8.04 Hardy Heron USB and Ndiswrapper Fixes

Tonight was a fun night.

I upgraded my desktop at work to Ubuntu 8.04. It worked just fine.

So today I upgraded my laptop to 8.04 as well. Not so good.

Upon first boot into the new system, I was greeted with this:

“BUG: soft lockup – CPU#0 stuck for 11s!”

After much research, I discovered that ndiswrapper, the software that allows the use of Windows NDIS network drivers for wireless cards to run under Linux, may be at fault. I booted into the old kernel that the upgrade left behind, and ran these commands in a terminal window. Note that you will need your Windows drivers handy before you do this, because this nukes the currently installed driver! You will also need another network connection, such as a wired connection.

sudo apt-get remove ndisgtk ndiswrapper-common ndiswrapper-utils-1.9
sudo rm -rf /etc/ndiswrapper
sudo apt-get install ndisgtk ndiswrapper-common ndiswrapper-utils-1.9
sudo shutdown -r now

First, this removes ndisgtk, ndiswrapper-common and ndiswrapper-utils-1.9. Then we remove the configuration directory for ndiswrapper, and then we re-install the packages we removed. Finally, we reboot.

Log back in and go to System > Administration > Windows Wireless Drivers and re-add your Windows driver. Reboot, and your system will actually boot, and your wireless card will work. Note that the Windows Wireless Drivers screen is slow to come up, so be patient.

With that done, I thought I might try a different driver with ndiswrapper, just to see if there was a performance difference, and having left my USB drive at home, I decided to use my Sandisk Sansa E250v2 MP3 player as a USB drive. I plugged it into my desktop, which had a copy of the new driver, and waited.

The player never mounted. Looking in syslog, I got this:

usb 4-3: new high speed USB device using ehci_hcd and address 2
ehci_hcd 0000:00:1d.7: port 3 reset error -110
hub 4-0:1.0: hub_port_status failed (err = -32)

Not good. I thought it might be a buggy hub in the desktop, so I tried plugging the player into my laptop, with the same results. This is Bad. It means this won’t work with my server at home either, because it got upgraded too, and Tony without music is Bitchy Tony.

After more research, I found out that the way the kernel deals with USB 2.0 devices changed a bit, and some devices, such as my player, don’t work so well with the shiny! new! improved! way of things. The fix is to put the following line just before “exit 0” in /etc/rc.local:

echo 1 > /sys/module/usbcore/parameters/old_scheme_first

Of course, /etc/rc.local needs to be edited using root privileges. In addition, for the change to take effect immediately, open up a terminal, type “sudo su -“, put in your password, type the line above into the terminal, and hit Ctrl-D until the terminal closes. Otherwise, you will need to reboot for the change to take effect.

I will post more of my adventures with Ubuntu 8.04 later. Until then, enjoy!

This entry was posted in Computing, Uncategorized. Bookmark the permalink.