📜 ⬆️ ⬇️

Installing Wireless DLink AirPlus XtremeG DWL G520 on Debian Linux

In fact, this is a continuation of the previous post about setting up a home server.

Dug Google, - everywhere they write about the problems with the DWL G520 +, but nowhere do they write about how to install the G520.

Considering that I found this card in the bins of the motherland ™, I had to work with what is +)
')
As a result, empirically:

lspci # pci
>>...
>>02:06.0 Ethernet controller: Atheros Communications Inc. Atheros AR5001X+ Wireless Network Adapter (rev 01)


..., I learned that this card is on a chipset (?) Atheros AR5001X +, and then I got to the MadWIFI website

The rest was already like a fairy tale

apt-get install wireless-tools
uname -r
apt-cache search 2.6.18-6-amd64 # ,
apt-get install linux-headers-2.6.18-6-amd64 # make, make , .
cd /tmp
wget downloads.sourceforge.net/madwifi/madwifi-0.9.4.tar.gz
gunzip madwifi-0.9.4.tar.gz
tar -xvf madwifi-0.9.4.tar
cd madwifi-0.9.4
make
make install
modprobe ath_pci


In Google, people write that one “modprobe ath_pci” is not enough - after the restart, they say, it will not work
I tried to reboot -
skazkinserver:~# iwconfig
lo no wireless extensions.

eth1 no wireless extensions.

eth0 no wireless extensions.

wifi0 no wireless extensions.

ath0 IEEE 802.11b ESSID:""
Mode:Managed Channel:0 Access Point: Not-Associated
Bit Rate:0 kb/s Tx-Power:0 dBm Sensitivity=1/1
Retry:off RTS thr:off Fragment thr:off
Encryption key:off
Power Management:off
Link Quality=0/70 Signal level=-256 dBm Noise level=-256 dBm
Rx invalid nwid:0 Rx invalid crypt:0 Rx invalid frag:0
Tx excessive retries:0 Invalid misc:0 Missed beacon:0

sit0 no wireless extensions.



It seems to be working.

I start setting up - I need it so that with any restart or something else if it happens - my debian clings to wifi like a drowning man in a life ring, so to speak. Given that the Wi-Fi spot requires WPA2 authorization from me.

I went to Google, as a result of the following:

Explanations: wifispot is the name of my point, passprase is the password for wpa2

apt-get install wpasupplicant
wpa_passprase wifispot passphrase > /etc/default/wpa_supplicant.conf
mcedit /etc/network/interfaces


In the last I inserted the following:

iface ath0 inet static
address 192.168.1.15 # ip,
netmask 255.255.255.0
network 192.168.1.0
broadcast 192.168.1.255
gateway 192.168.1.1
wireless-essid wifispot


after which you can test the performance:

wpa_supplicant -iath0 -c/etc/default/wpa_supplicant.conf -Dmadwifi -B
# ( (-B))

ifup ath0
#


I didn’t think how to stuff it adequately into autoload - this resulted in the following script:
(for some reason it does not stop, but it will start successfully)
mcedit /etc/init.d/wireless_up
##### :
#!/bin/sh

test -f /sbin/wpa_supplicant || exit 0

case "$1" in
start)

wpa_supplicant -iath0 -c/etc/default/wpa_supplicant.conf -Dmadwifi -B
ifup ath0
;;
stop)
0
pkill -f wpa
ifdown ath0
;;
restart) ifdown ath0
pkill -f wpa
0
wpa_supplicant -iath0 -c/etc/default/wpa_supplicant.conf -Dmadwifi -B
ifup ath00
;;
*) echo "Usage: /etc/init.d/wireless_up {start|stop|restart}"
exit 2
;;
esac
exit 0

##### -
update-rc.d -f wireless_up defaults

#####

reboot



Uh, well, it seems to work! To test the restart, turn off the lace - and - Oh, no! Does not work!

After a lot of digging (as soon as I cut off the lace - the wireless stops working) it helped -

mcedit /etc/network/interfaces
auto lo eth1 ath0 auto lo ath0


I reboot without a lace - it works! =)

Source: https://habr.com/ru/post/46051/


All Articles