# Unstable wifi connection (only in gentoo)

## motu

Hi everybody,

I have a problem with my wifi device,  more detailed: with the connection.

I recently decided to give gentoo a try, but my connection breaks much too often.

Well that's really annoying if you want to download some packages for installation.

Just some background information:

Wireless network is using WPA-PSK/TKIP/DHCP

Connecting with wpa_supplicant and dhcpcd works

Connecting via vista works fine (it's on the same machine)

I'm currently using the gentoo liveCD (2008.0  2.6.24r5)

I have already done some research at google/gentoo forum

The wifi dongle:

D-Link dwl-g122 rev.B1 (Driver: rt2500usb)

Connection Quality:

On vistas scale ~50%

iwconfig: ~27/100

Current workaround:

kill dhcpcd

restart wpa_supplicant

restart dhcpcd

I'm sorry that I can't post some log files, since I'm not familiar enough with linux system (I'm a ubuntuGUIuser).

It would be nice if you can help me.

----------

## NeddySeagoon

motu,

Welcome to Gentoo

I use an rt73 unencrypted, using the kernel driver.

The 2.6.24 kernel driver would not start reliably but was OK when it got going and 2.6.25 has been solid.

 have just got 2.6.26 but not tested it yet.

Are you using ndiswrapper or the kernel driver?

Try /sbin/iwconfig wlan0 you should get something like

```
$ /sbin/iwconfig wlan0

wlan0     IEEE 802.11g  ESSID:"RadioNet"  

          Mode:Managed  Frequency:2.417 GHz  Access Point: 00:06:25:4B:4E:C3   

          Bit Rate=54 Mb/s   Tx-Power=27 dBm   

          Retry min limit:7   RTS thr:off   Fragment thr=2352 B   

          Link Quality=93/100  Signal level=-42 dBm  

          Rx invalid nwid:0  Rx invalid crypt:0  Rx invalid frag:0

          Tx excessive retries:0  Invalid misc:0   Missed beacon:0
```

The important things are 

```
Tx-Power=27 dBm
```

higher is better, the max you can set is jusrisdiction dependant,

and 

```
  Link Quality=93/100  Signal level=-42 dBm  
```

The signal level is the received power, less negative is better.

/sbin/iwconfig wlan0 txpower 20dBm sets the Transmit Power to 20 dBm.  Try setting various (higher) transmit powers than you have at the moment.

This can be added to the startup when you know what works

----------

## motu

Hi,

to the question, I|m using the kernel-module-driver.

I've tried to change the txpower setting.

 *Quote:*   

> livecd gentoo # uname -r 
> 
> 2.6.24-gentoo-r5
> 
> livecd gentoo # iwconfig wlan0
> ...

 

Hope it's better when I'm in an installed system.

Have a nice day

----------

## NeddySeagoon

motu,

The 2.6.25 kernel driver is better than 2.6.24.

Your 

```
Signal level=-96 dBm
```

is very low, its close to the limit for working at all but the link is still going

```
Bit Rate=54 Mb/s
```

as fast as it can. Normally, it falls back to lower speeds.

----------

