Wireless networking in Gentoo

This is a work in progress
Fire up dhcp on the wireless interface: dhcpcd eth1
(that should create the device also kinda thing)

The init script (/etc/init.d/wireless)

#!/sbin/runscript
# Copyright 1999-2005 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2

depend() {
before net.eth0
}

start() {
#! /bin/sh
# wifi: wpa_supplicant init
echo " * [Wifi]: Enabling WPA supplicant..."
if [ -x /sbin/wpa_supplicant ]; then
wpa_supplicant -B -i eth1 -c /etc/wpa_supplicant.conf -D ipw -w -dd
dhcpcd eth1
fi
}

stop() {
echo "Stop doesn't work yet!"
}

restart() {
echo "Restart doesn't work yet!"
}

rc-update add wireless default

Then we configure /etc/wpa_supplicant.conf


#CONFIG_CTRL_IFACE=y
ctrl_interface=/var/run/wpa_supplicant

network={
ssid="home"
scan_ssid=1
proto=WPA
key_mgmt=WPA-PSK
psk="somepass"
}

Then hope for the best I guess!

Leave a Reply

Your email address will not be published. Required fields are marked *