# [SOLVED] Wieless doesn't connect

## Ishiki

On my router I've setup WPA.

And...  /etc/init.d/net.wlan0 restart gives me:

```
net.wlan0         | * Bringing down interface wlan0 

net.wlan0         | *   Stopping wpa_cli on wlan0 ...                                        [ ok ] 

net.wlan0         | *   Stopping wpa_supplicant on wlan0 ...                                 [ ok ] 

net.wlan0         | * Bringing up interface wlan0 

net.wlan0         | *   Starting wpa_supplicant on wlan0 ... 

net.wlan0         |ioctl[SIOCSIWMODE]: Resource temporarily unavailable 

net.wlan0         |ioctl[SIOCGIWRANGE]: Resource temporarily unavailable 

net.wlan0         |ioctl[SIOCSIWAUTH]: Resource temporarily unavailable 

net.wlan0         |WEXT auth param 7 value 0x1 - ioctl[SIOCSIWENCODEEXT]: Resource temporarily unavailable 

net.wlan0         |ioctl[SIOCSIWENCODEEXT]: Resource temporarily unavailable 

net.wlan0         |ioctl[SIOCSIWENCODEEXT]: Resource temporarily unavailable 

net.wlan0         |ioctl[SIOCSIWENCODEEXT]: Resource temporarily unavailable 

net.wlan0         |ioctl[SIOCSIWAUTH]: Resource temporarily unavailable 

net.wlan0         |WEXT auth param 4 value 0x0 - ioctl[SIOCSIWAUTH]: Resource temporarily unavailable                                                                                                 [ ok ]an0         |WEXT auth param 5 value 0x1 - 

net.wlan0         | *   Starting wpa_cli on wlan0 ...                                        [ ok ] 

net.wlan0         | *   Backgrounding ... ... 

net.wlan0         | * WARNING: net.wlan0 has started, but is inactive 
```

wpa_supplicant -Dwext -iwlan0 -c/etc/wpa_supplicant/wpa_supplicant.conf :

```
CTRL-EVENT-DISCONNECTED - Disconnect event - remove keys
```

/etc/conf.d/net 

```
modules=("wpa_supplicant") 

wpa_supplicant_wlan0="-Dwext" 
```

/etc/wpa_supplicant/wpa_supplicant.conf 

```
ctrl_interface=/var/run/wpa_supplicant 

ctrl_interface_group=0 

ap_scan=1 

network={ 

  ssid="MyNetSsid" 

#  scan_ssid=1 

proto=WPA 

key_mgmt=WPA-PSK 

 psk="MyPass" 

  pairwise=TKIP 

  group=TKIP CCMP WEP104 

  priority=2 

} 
```

in wpa_gui I can see my network, but connection can't be established.

lsmod shows ipw3945, ieee80211, ieee80211_crypt_tkip, ieee80211_crypt_ccmp, ieee80211_crypt_wep

Windows machines can connect to the AP without any problems.

On them, I've setup security type: WPA-PERSONAL, cryptography: TKIP, set the password, and it works.

What can I do ... ?Last edited by Ishiki on Wed Oct 03, 2007 6:54 pm; edited 1 time in total

----------

## Abraxas

Try re-emerging wireless-tools.  Have you upgraded kernels or wireless drivers recently?

----------

## Ishiki

I've tried reinstalling wpa_supplicant and wireless-tools, even tried using madwifi, and ipw drivers... didn't work.

I don't use wireless tools, cause my AP is WPA-secured.

Kernel and drivers - maybe they were upgraded, but I try to make WiFi work just for 2 days.

Before I didn't have access do wireless network.

When wpa_supplicant is run with -d option (debuging), then I can see my network, even it's SSID is scanned... but can't connect.

----------

## Psycho Dad

Which version of ipw3945 do you have? 1.2.2 cant connect to hidden Wlans here (1.2.0 can).

And why do you have wlan0? Normally the ipw3945-driver uses ethx

Did you emerge the iwlwifi driver too, it makes wlan0 (but does not work stable for me)?

You have to choose one driver.

My wpa_supplicant.conf with ipw3945-1.2.2, not hidden AP and WPA TKIP looks like this:

```
ctrl_interface=/var/run/wpa_supplicant

ctrl_interface_group=wheel

update_config=0

ap_scan=1

fast_reauth=1

network={

  ssid="censored"

  scan_ssid=1

  proto=WPA

  key_mgmt=WPA-PSK

  psk="secret"

  pairwise=TKIP

  group=TKIP

  priority=5

```

----------

## Abraxas

 *Ishiki wrote:*   

> I've tried reinstalling wpa_supplicant and wireless-tools, even tried using madwifi, and ipw drivers... didn't work.
> 
> I don't use wireless tools, cause my AP is WPA-secured.
> 
> Kernel and drivers - maybe they were upgraded, but I try to make WiFi work just for 2 days.
> ...

 

You say you don't use wireless tools but you have this option set: 

```
wpa_supplicant_wlan0="-Dwext"
```

Which i believe means you are telling wpa_supplicant to use wireless tools to connect.

----------

## Ishiki

 *Abraxas wrote:*   

> You say you don't use wireless tools but you have this option set:
> 
> ```
> wpa_supplicant_wlan0="-Dwext"
> ```
> ...

  -Dwext is the kind of driver which is used by wpa_supplicant. Wext means that it supports most of wifi cards that have 'wireless extensions'.

 *Psycho Dad wrote:*   

> 1.2.2 cant connect to hidden Wlans here (1.2.0 can).
> 
> And why do you have wlan0? Normally the ipw3945-driver uses ethx 

  And that was it ! I've changed router's setting to not hide SSID, and now everything works, like a charm.

I have wlan0, because sometimes I use eht0 (usb cable modem) and I have eth1 also. So to eliminate interferences with interface names, i've put some udev options to do the work.

Thank You.

----------

## Abraxas

 *Ishiki wrote:*   

>  *Abraxas wrote:*   You say you don't use wireless tools but you have this option set:
> 
> ```
> wpa_supplicant_wlan0="-Dwext"
> ```
> ...

 

Exactly.  WIreless tools are userspace tools to manipulate wireless extensions based drivers.  So when you specify Dwext you are specifying that wpa_supplicant connects using wireless extensions.  The messages that looks like the following is from wireless tools:

```
net.wlan0         |ioctl[SIOCSIWENCODEEXT]: Resource temporarily unavailable

net.wlan0         |ioctl[SIOCSIWENCODEEXT]: Resource temporarily unavailable

net.wlan0         |ioctl[SIOCSIWENCODEEXT]: Resource temporarily unavailable

net.wlan0         |ioctl[SIOCSIWAUTH]: Resource temporarily unavailable 
```

That's why I suggest re-emerging wireless tools.  Sometimes there is a mismatch between the kernel wireless extensions version and the wireless tools package and that causes all kinds of errors.

----------

## jekyll

 *Psycho Dad wrote:*   

> Which version of ipw3945 do you have? 1.2.2 cant connect to hidden Wlans here (1.2.0 can).
> 
> 

 

Why does 1.2.2 not connect to hidden wlans?  I can get it to connect, as long as I issue the command

```
iwconfig eth1 essid <realssid>
```

I find it quite annoying to have to enter it every time I boot.  The other problem I have is that if I try and mask version 1.2.2, portage somehow ignores that I've masked it in package.mask.

-jekyll

----------

## Psycho Dad

Masking works here

```
echo =net-wireless/ipw3945-1.2.2 >> /etc/portage/package.mask
```

----------

## Psycho Dad

And 

```
iwconfig eth1 essid <realssid>
```

works here too, I put it in /etc/conf.d/net, so I don´t have to enter it manually after booting.

Thank you!

----------

## thecooptoo

there is a WPA network that the only way ive been able to connect is with ap_scan =1 regardless of anything else inthe config

----------

## jekyll

 *jekyll wrote:*   

>  *Psycho Dad wrote:*   Which version of ipw3945 do you have? 1.2.2 cant connect to hidden Wlans here (1.2.0 can).
> 
>  
> 
> Why does 1.2.2 not connect to hidden wlans?  I can get it to connect, as long as I issue the command
> ...

 

I found the reason for my problem.  I had ipw3945 in package.unmask, as well as =net-wireless/ipw3945-1.2.2 in package.mask.  When I removed ipw3945 from package.unmask, it worked correctly and allowed me to mask ipw3945-1.2.2.

-jekyll

----------

## _Stevie_

hello all,

i have the same problem with the connection to a network.

as it seems i cant connect to any network until enter sudo iwconfig essid <anyletters!>.

after i entered this command wicd can connect to my network.

it doesnt matter if the essid i enter exists or not. this command seems to trigger

some sort of hardware-reset since turning my wlan off and on with my hardware-trigger

has the same effect.

as far as i read, the solution is to enter the command in /etc/conf.d/net.

is that right or is there already another solution? (didnt understand that mask and unmask).

best,

stevie

----------

