You are not logged in.
Ever since I switched from FreeBSD to Arch, I've been wondering why wireless networking is such a hazzle in Arch compared to FreeBSD.
In FreeBSD I would let my wpa_supplicant.conf contain something like this:
network={
ssid="home_ssid"
psk="some_passphrase"
}
network={
ssid="friend_ssid"
psk="some_passphrase"
}
network={
ssid="work_ssid"
psk="some_passphrase"
}
In /etc/rc.conf I would simply put ifconfig_wlan0="WPA DHCP" and I would be done. I could take my laptop and move it between different access points and FreeBSD would automagically switch between them (is that what's called roaming?).
Why is it not as simple as that in Arch? As far as I can tell I need netcfg or a similar "wrapper" around wpa_supplicant.conf to do the same thing. Is there something I have misunderstood?
Offline
what if you go somewhere and you need to use wep, I take it you need to change rc.conf (not a freebsd user so I do not know) with netcfg this is not needed, just make the new profile.
Netcfg is an extremely powerful network tool with huge possibilities not limited to wpa, wep ppp including mobile/cell phone modems and others are available too
Wifi-select is worth installing for connecting to networks on the fly that you may not want to keep a config for, i.e in a cafe or other free networks.
example configs
WPA
CONNECTION='wireless'
DESCRIPTION='A simple WPA encrypted wireless connection'
INTERFACE='wlan0'
SECURITY='wpa'
ESSID='MyNetwork'
KEY='WirelessKey'
IP='dhcp'
WEP
CONNECTION='wireless'
DESCRIPTION='A simple WEP encrypted wireless connection'
INTERFACE='wlan0'
SECURITY='wep'
ESSID='MyNetwork'
KEY='1234567890'
IP='dhcp
PPP
CONNECTION='ppp'
INTERFACE='ignore'
PEER='provider'
PPP_TIMEOUT=10
Offline
Hmm, I set up my wpa_supplicant.conf in a similar way, but I just call wpa_supplicant directly rather than using a wrapper.
sudo wpa_supplicant -Dwext -iwlan0 -c/etc/wpa_supplicant.conf -B
sudo dhcpcd wlan0
That'll get me internet, though I've not tried roaming so I can't speak with any authority on that front. I have recently put together a little wpa_sup daemon that handles the above for me on boot now to streamline things a little bit.
Offline
gazj - WEP is not a problem, it can be configured though wpa_supplicant.conf. If you need to use different IPs I don't know what you'll do though.
delcake - Where do you put those lines? In rc.local?
Edit: Oh, you made a daemon.
Last edited by Lars Stokholm (2010-05-17 17:11:08)
Offline
Ah, I see I didn't know wpa_supplicant could do wep. As you can see netcfg is a wrapper for several networking possibilites.
Maybe this is more what you are looking for http://bbs.archlinux.org/viewtopic.php?id=59004 [+]
Still does not sound as simple as the freebsd method you mention
Offline
Actually, what delcake says doesn't sound too different from what can be done in FreeBSD. I just followed the wiki when I first set up Arch and here netcfg was suggested.
Offline
you could use autowifi from aur . you just just set up wpa_supplicant.conf for roaming (like you are used to from bsd) and have the autowifi daemon running .if you want a gui you can use wpa_gui or wpa_cli in a terminal.
works wonderfull
Offline
Yup, I pretty much just gutted the network daemon and set up some simple lines to get wpa_supplicant and dhcpd up and running.
Here's what I came up with:
## wpa_sup [plain_text]
#!/bin/bash
. /etc/rc.conf
. /etc/rc.d/functions
case "$1" in
start)
if ! ck_daemon wpa_sup; then
echo "WPA Supplicant is already running. Try 'wpa_sup restart'"
exit
fi
stat_busy "Starting WPA Supplicant"
error=0
/usr/sbin/wpa_supplicant -Dwext -iwlan0 -c/etc/wpa_supplicant.conf -B || error=1
/usr/sbin/dhcpcd -q wlan0 || error=1
if [ $error -eq 0 ]; then
add_daemon wpa_sup
stat_done
else
stat_fail
fi
;;
stop)
#if ck_daemon wpa_sup; then
# echo "WPA Supplicant is not running. Try 'wpa_sup start'"
# exit
#fi
stat_busy "Stopping Network"
rm_daemon wpa_sup
error=0
killall wpa_supplicant || error=1
killall dhcpcd || error=1
if [ $error -eq 0 ]; then
stat_done
else
stat_fail
fi
;;
restart)
$0 stop
/bin/sleep 2
$0 start
;;
*)
echo "usage: $0 {start|stop|restart}"
esac
# vim: set ts=2 noet:
Yeah, probably fairly ugly but it gets the job done for my simple use-case.
Last edited by delcake (2010-05-17 17:59:22)
Offline