Atmospherian
April 10th, 2009, 03:38 PM
When i use gnome, i can connect to my wireless networks at home and at work (both use WEP) with no problems. I recently switched to using wmii and no longer have access to the network applet in gnome.
I have been trying to connect to networks via the command line but have not had much success.
Here is a script i am using to connect to a network:
#!/bin/sh
sudo ifconfig wlan0 down
sudo dhclient -r wlan0
sudo ifconfig wlan0 up
sudo iwconfig wlan0 essid "$1"
sudo iwconfig wlan0 key $2
sudo iwconfig wlan0 key open
sudo iwconfig wlan0 mode Managed
sudo dhclient wlan0
This appears to make a connection, but the dhclient never picks up an IP.
DHCPDISCOVER on wlan0 to 255.255.255.255 port 67 interval 3, 7, 14, 15, etc.
What does the network manager app in gnome do behinds the scenes that i am not doing on the command line? What do i need to add/change/remove from my script to make it work?
btw, my wireless card is a RTL8187.
Thanks
I have been trying to connect to networks via the command line but have not had much success.
Here is a script i am using to connect to a network:
#!/bin/sh
sudo ifconfig wlan0 down
sudo dhclient -r wlan0
sudo ifconfig wlan0 up
sudo iwconfig wlan0 essid "$1"
sudo iwconfig wlan0 key $2
sudo iwconfig wlan0 key open
sudo iwconfig wlan0 mode Managed
sudo dhclient wlan0
This appears to make a connection, but the dhclient never picks up an IP.
DHCPDISCOVER on wlan0 to 255.255.255.255 port 67 interval 3, 7, 14, 15, etc.
What does the network manager app in gnome do behinds the scenes that i am not doing on the command line? What do i need to add/change/remove from my script to make it work?
btw, my wireless card is a RTL8187.
Thanks