nephix.wordpress.com


Wireless LAN im FRZ mit Linux

Posted in Howto, IT by nephix on the 2. April 2008

Zunächst sollte überprüft werden ob bereits wpa_supplicant installiert ist, oder nicht. Falls dies nicht der Fall sein sollte ist es unter Debian mit einem einfachen

# aptitude install wpasupplicant

als root erledigt. Besitzt ihr einen anderen Packetmanager, sucht ein ähnliches Paket in dem Repository von eurer Distribution. Wahlweise könnt ich auch den Source laden, Link hier. Jetzt erstellen wir uns eine wpa_supplicant.conf mit folgendem Inhalt:

ctrl_interface=/var/run/wpa_supplicant
ctrl_interface_group=0
eapol_version=1
ap_scan=1
fast_reauth=1

network= {
ssid=”eduroam”
key_mgmt=WPA-EAP
proto=WPA
pairwise=TKIP
group=TKIP
eap=TTLS
anonymous_identity=”anonymous@tu-dresden.de”
identity=”sXXXXXXX@tu-dresden.de”
password=”*******”
ca_cert=”/etc/wpa_supplicant/TUD-CACert.pem”
phase2=”auth=PAP”
priority=2
}

und speichern es unter /etc/wpa_supplicant/wpa_supplicant.conf. Um sich Erfolgreich zu verbinden bitte identity und password editieren. Wie zu erkennen wird noch ein TUD-CACert.pem Zertifikat benötigt, welches wir hier finden. Dieses speichern wir wie im Configfile angegeben Pfad in /etc/wpa_supplicant/TUD-CACert.pem. Zum verbinden kann dieses kleine Script verwendet werden: wpasupplicant.sh
(Danke an dieser Stelle zur xaitax für seine Hilfe ;) )

Speichert dieses Script in /sbin/wlanfrz ab und führt

# chmod +x /sbin/wlanfrz

als root aus. Weiterhin solltet ihr noch das Device wlan0 mit eurem W-LAN Device auf dem System anpassen. Wenn man nun in FRZ Nähe ist kann man sich bequem als root mit

# wlanfrz start

zum AP connecten.

Quellen
[1] offizielle Anleitung des Fakultätrechenzentrums

SD Karten Hotplug [engl]

Posted in Howto, IT by nephix on the 1. April 2008

-=[ Howto auto hotplug SD Cards ]=-

1st Step:

Detect your Cardreader via typing

# lspci | grep SD

You will get an output like that:

03:01.1 SD Host controller: Ricoh Co Ltd R5C822 SD/SDIO/MMC/MS/MSPro Host Adapter

2nd Step:

Next you login as root and type

# setpci -s 3:01.1 4c.b=0×02

whereas 3:01.1 you had to change with the output of step one.

3rd Step:

Test it, insert a SD card! If it doesn’t work, try something else. ;)
If you’re interested in auto hotplug your SD Cards at boot time follow the next step,
else you’re done here.

4th Step:

Be sure, you’re root and create new file in /etc/init.d/

# touch /etc/init.d/cardreader

Now …

# vim /etc/init.d/cardreader

and insert

#!/bin/bash

setpci -s nn:nn.n 4c.b=0×02

exit 0

and save with [esc]:wq

Now change permission of created file

# chmod 777 /etc/init.d/cardreader

Change to dir /etc/init.d/

# cd /etc/init.d/

On most distributions you can use `chkconfig`

# chkconfig -a cardreader

On gentoo

# rc-update add cardreader default

On Debian link the script to some /etc/rc* with ln -s

Done!