[root@192 kris]# ifup wlan0
Determining IP information for wlan0.../sbin/ifup: line 427: 3760 Terminated $DHCP_CLIENT $DHCP_ARGS
done.
/sbin/ifup: line 427: 3839 Hangup /etc/init.d/tmdns reload >/dev/null 2>&1
[root@192 kris]# iwconfig wlan0
wlan0 IEEE 802.11g ESSID:""
Mode:Managed Frequency:2.437GHz Access Point: 00:00:00:00:00:00
Bit Rate:54Mb/s
Encryption key

ff
Link Quality:0/100 Signal level:-73 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
Notice all my encryption and essid are reset.
And here's the process to get it up and running again. For some reason it didn't set the key the first time. No clue why.
[root@192 kris]# iwconfig wlan0 key open xxxxxxxxxx
[root@192 kris]# iwconfig wlan0 essid xxxxxxxx
[root@192 kris]# iwconfig wlan0
wlan0 IEEE 802.11g ESSID:"xxxxxxxx"
Mode:Managed Frequency:2.437GHz Access Point: 00:00:00:00:00:00
Bit Rate:54Mb/s
Encryption key

ff
Link Quality:0/100 Signal level:-68 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
[root@192 kris]# iwconfig wlan0 key open xxxxxxxxxx
[root@192 kris]# iwconfig wlan0 essid xxxxxxxx
[root@192 kris]# iwconfig wlan0
wlan0 IEEE 802.11g ESSID:"xxxxxxxx"
Mode:Managed Frequency:2.437GHz Access Point: 00:0D:88:B7:01:F6
Bit Rate:54Mb/s
Encryption key:xxx-xxx-xxxx Security mode

pen
Link Quality:0/100 Signal level:-69 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
[root@192 kris]# ifconfig wlan0 up
[root@192 kris]# ifconfig wlan0
wlan0 Link encap:Ethernet HWaddr 00:0D:88:57:47:41
inet addr:192.168.0.102 Bcast:192.168.0.255 Mask:255.255.255.0
inet6 addr: fe80::20d:88ff:fe57:4741/64 Scope:Link
UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
RX packets:569 errors:0 dropped:0 overruns:0 frame:0
TX packets:227 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:1000
RX bytes:257225 (251.1 Kb) TX bytes:35707 (34.8 Kb)
Interrupt:10 Memory:cffe0000-cffeffff
[root@192 kris]#
I can't figure out why it won't take the key settings sometimes. The output is the same on my laptop, except the ifup wlan0 gives me the link not present error. And the ifconfig shows zero for transmit packets and bytes. It does show packets received.
NOTE: running ifconfig wlan0 up is not necessary. I just went to the store, came back, and the connection was down again. All values in iwconfig had been reset. So I typed them back in, DIDN'T do an ifconfig wlan0 up, and the connection is established again. I think my iwconfig prog is haunted.