LinuxQuestions.org
Welcome to the most active Linux Forum on the web.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Networking > Linux - Wireless Networking
User Name
Password
Linux - Wireless Networking This forum is for the discussion of wireless networking in Linux.

Notices

Reply
 
LinkBack Search this Thread
Old 08-19-2005, 11:59 PM   #1
djzanni
Member
 
Registered: Dec 2003
Location: Washington, DC
Distribution: Ubuntu 7.04
Posts: 73

Rep: Reputation: 15
ndiswrapper no longer working on mandrake after change of router


I'm a linux wireless noob and I've spent countless hours trying to connect to a wireless router using ndiswrapper. But I can't quite figure it out, so I hope y'all can show me the way. It used to work on a previous router, but I've moved now and am using a neighbor's router with a new essid... and now it no longer works (on my linux side... my windows 2k side works).

When I install ndiswrapper-0.9-1mdk.i586.rpm everything seems to work fine. I modprobe ndiswrapper and everything seems to work, I do lsmod and ndiswrapper is listed.

I do ndiswrapper -l and I get

Code:
Installed ndis drivers:
mrv8k51 hardware present
I do ndiswrapper -m and I get:

Code:
modprobe config already contains alias directive
At this point, the ifconfig wlan0 command gives me:

Code:
wlan0     Link encap:Ethernet  HWaddr 00:0F:3D:4B:7F:93
          BROADCAST MULTICAST  MTU:1500  Metric:1
          RX packets:0 errors:0 dropped:0 overruns:0 frame:0
          TX packets:0 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:1000
          RX bytes:0 (0.0 b)  TX bytes:0 (0.0 b)
          Interrupt:5 Memory:e4010000-e401ffff

Thus, up to here everything seems fine (right?)

Then I go to the mandrake control center to add a “new connection”. I choose “wireless connection”, and I get an option to choose “wlan0” which I do indeed choose. The next screen asks whether I want “Automatic IP (BOOTP/DHCP)” or to do it manually. I know the router is set up for DHCP so I choose the automatic IP. On the next screen I select all available options and use the ESSID for the DHCP host name:
Code:
X Assign host name from DHCP address
DHCP host name: WLAN
X Track network card ID
X Network hotplugging
X Start at boot
The next screen gives asks me for some of the router settings. I leave the key field blank since the router's encryption is turned off:
Code:
Operating mode: Managed
Network name (ESSID): WLAN
Encryption Key:
[Should I be doing something other than “Managed” ?]

I leave the next screen blank:
Code:
RTS/CTS:
Fragmentation:
And I choose “steves_place” on the next screen for the host name:
Code:
Host name (optional): steves_place
I also leave the next screen blank:

Code:
Zeroconf host name:
It then asks me if I want to restart the network. I say yes. At this point there seems to be two reactions:

1) Sometimes (rarely) it says that the network restarted and that I should reboot. When I do reboot, of course, it hangs on the “bringing up wlan0 interface” and I have to reboot again and go into interactive startup and suppress the wlan0 (otherwise I can't boot up).

2) The usual response is that the machine freezes. Nevertheless when I do reboot it hangs on the wlan0 interface as described above.

Assuming the machine hasn't frozen. At this point if I go to the “manage connections” part of the control center and I click on the “wireless” tab, I see only two fields are filled:
Code:
Operating made: Managed
Network name (ESSID): WLAN
Network ID:
Operating Frequency:
Sensitivity Threshold:
Bitrate (in b/s):
Encryption key:
RTS/CTS:
Fragmentation:
Iwconfig command extra arguments:
Iwspy command extra arguments:
Iwpriv command extra arguments:
I know the ESSID is WLAN because that's what appears when I look at it from my windows side. In fact, here is the pertinent information that the router (a Belkin cable/dsl gateway router) displays:

LAN Settings
LAN/WLAN MAC: 00-30-BD-C4-7E-DE
IP Address: 192.168.2.1
Subnet Mask: 255.255.255.0
DHCP server: Enabled

Internet Settings
WAN MAC address: 00-30-BD-C4-7E-DF
Connection type: DYNAMIC
Subnet Mask: 255.255.248.0
Wan IP: 68.100.131.6
Default gateway: 68.100.128.1
DNS Address: 68.100.16.30

Features
NAT: Enabled
Firewall Settings: Enabled
SSID: WLAN
Encryption: Disable

Also – in case it helps – after I have set things up this way, my ifcfg-wlan0 file reads:
Code:
DEVICE=wlan0
BOOTPROTO=dhcp
ONBOOT=yes
HWADDR=00:0f:3d:4b:7f:93
METRIC=10
MII_NOT_SUPPORTED=no
WIRELESS_MODE=Managed
WIRELESS_ESSID=WLAN
DHCP_HOSTNAME=WLAN
NEEDHOSTNAME=yes
If it matters, I have the kernel source installed, and there is a link to it from /lib/modules/2.6.8.1-12mdk/build.

My kernel version is 2.6.8.1-12mdk.

I have a dual boot with windows 2K and the wireless connection works fine there.

It used this same ndiswrapper setup with a different router and it worked fine, but I've moved and am now using a neighbor's router.

One very last thing. I ran across a mention in linuxquestions.org about the driver that I'm using. It says that this particular driver “may need iwpriv wlan0 ndis_reset when changing essid.” I am changing my essid from what is was before I moved, so maybe this is the problem? I don't know how to use iwpriv, however.

Any help would be much appreciated. Thanks.

~daveZ
 
Old 08-22-2005, 10:11 AM   #2
djzanni
Member
 
Registered: Dec 2003
Location: Washington, DC
Distribution: Ubuntu 7.04
Posts: 73

Original Poster
Rep: Reputation: 15
I see that since there are no replies so I'm guessing I've stumped y'all ;) So after some more fiddeling I've got a little more info.

When I modprobe ndiswrapper and then dmesg, I get:

Code:
ndiswrapper version 0.8 loaded
ndiswrapper adding mrv8k51.sys
wlan%d: setting essid failed (C0010015)
ndiswrapper: Unable to set empty essid
ndiswrapper: Unable to set packet filter (C00000BB)
wlan0: ndiswrapper ethernet device 00:0f:3d:4b:7f:93 using driver mrv8k51.sys
Something here that might be wrong is that the dmesg says that I've got ndiswrapper version 0.8 loaded, but the rpm I installed was ndiswrapper-0.9-1mdk.i586.rpm. Something going on here? [Interestingly, when I uninstall ndiswrapper-0.9-1mdk.i586.rpm and install a more recent rpm -- ndiswrapper-1.0-1.mdk10.1.thac.i586.rpm -- and then dmesg, I *STILL* get "ndiswrapper version 0.8 loaded". Maybe this is the problem?]

Then when I iwconfig, I get:

Code:
lo        no wireless extensions.

eth1      no wireless extensions.

sit0      no wireless extensions.

wlan0     IEEE 802.11b  ESSID:""
          Mode:Managed  Channel:0  Access Point: FF:FF:FF:FF:FF:FF
          Bit Rate:54Mb/s   Sensitivity=-200 dBm
          RTS thr:2346 B   Fragment thr:2346 B
          Encryption key:off
          Power Management:off
          Link Quality:100/100  Signal level:-76 dBm  Noise level:-256 dBm
          Rx invalid nwid:0  Rx invalid crypt:0  Rx invalid frag:0
          Tx excessive retries:0  Invalid misc:1   Missed beacon:0
now I make an ifcfg-wlan0 file in /etc/sysconfig/networking/ . In the file is:
Code:
DEVICE=wlan0
BOOTPROTO=dhcp
onBOOT=no
MODE=Managed
ESSID=WLAN
and I make a link to it called ifcfg-wlan0 in /etc/sysconfig/network-scripts/

Then when I try ifup wlan0, the light on my d-link dwl g510 starts flashing away, but the computer nevertheless freezes up. I can't type anything else in the console and I have to force a reboot. Is my ifcfg-wlan0 file written wrong?

Interestingly, if instead I change the ESSID in the ifcfg-wlan0 file from WLAN to "any", and then try ifup wlan0, I get:
Code:
Error for wireless request "Set ESSID" (8B1A) :
    SET failed on device wlan0 ; Invalid argument.

Determining IP information for wlan0... failed.
The LED on my wireless card does *not* flash while this is happening.

Thanks for your help.

~daveZ
 
Old 08-22-2005, 02:45 PM   #3
djzanni
Member
 
Registered: Dec 2003
Location: Washington, DC
Distribution: Ubuntu 7.04
Posts: 73

Original Poster
Rep: Reputation: 15
figured it out!

OK. I've gotten it working. In case this is any help to anyone in the future I will describe how I did it.

I was frustrated and though I prefer doing things through rpms I decided to compile ndiswrapper instead. First I uninstalled (urpme in mandrake) ndiswrapper, then I followed the instructions for uninstalling on the ndiswrapper website, getting rid of all the remnants of previous versions.

Then I basically just followed the instructions for installing from source. This included building the headers for the kernel source. To do this I cd'd into /usr/src/linux-<version> and just did "make menuconfig" and then saved the configuration without changing anything. Then I did "make dep" and "make clean".

I compiled and installed the rest exactly how is says in the instructions.

make distclean
make
make install

I then checked to make sure that my driver was still there "ndiswrapper -l". I was and it said hardware was present. Then ran "modprobe ndiswrapper" to insert the module. This, however, gave me an error. I checked dmesg and it said to check the system log. When I checked the system log (/var/log/syslog in mandrake), it said that it had tried all the drivers I had but none worked. This got me to thinking that I did, after all, have the wrong driver, even though this exact same driver worked with my other router. So I downloaded a new driver from the d-link website and installed it into ndiswrapper ("ndiswrapper -i mydriver.inf") and then I modprobed again. This time it worked!! I then made sure that I had a proper ifcfg-wlan0 file in /etc/sysconfig/networking/ and that I had a link to it in /etc/sysconfig/network-scripts.

I then ran ifup wlan0. It didn't work, but I then changed the essid in the ifcfg-wlan0 file to "WLAN" from "any". I guess my wireless card doesn't pick up just any signal. The WLAN essid worked. Yihaa!!!

~daveZ
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are Off
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
After UID change can no longer ftp meshking Linux - General 4 07-13-2004 02:44 AM
Mandrake Linux 9.2 Download Collection no longer working - annoying me! Alexanda G Mandriva 0 06-12-2004 09:49 PM
Previously working vnc... no longer working marsonist Linux - Networking 1 01-21-2004 07:34 AM
no longer get network access beyond router monkeyman2000 Linux - Networking 13 12-11-2003 07:47 PM
Installed router, dial-up Internet no longer works. (MDK 9.1) mcarter Linux - Networking 1 09-01-2003 03:18 PM


All times are GMT -5. The time now is 02:21 PM.

Main Menu
 
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
identi.ca: @linuxquestions
Facebook: @linuxquestions
Open Source Consulting | Domain Registration