losing ESSID

Hey guys, facing a weird issue - hoping someone might be able to help.

The wireless network on my laptop is configured with a static IP address. (not using nm)

When i take the laptop out of the range (or i power the router down) the essid is becoming "off/any".

When i'm back in range the connection is not reestablished and to re-enable the connection i gotta reconfigure the essid "iwconfig wlan0 essid <essid name>"

Anyone knows how to avoid that and make the essid stick unless i want to change it manually?

What is your system?

its a ubuntu 10.10

You may need to disable the autoconfiguration GUI thing, that may be taking over despite you controlling it from commandline.

Can't find what is this GUI thing that is taking over!
drives me crazy... i've been looking for an answer for days!

Anyone?

I played around with the ifup ifdown (i even completely deleted them)
There should be a way to map it somehow to connect to my "preferred" essid.

but i can't find it!

:wall:

Have you added the requisite information to /etc/network/interfaces?

Yes my interfaces file:

auto wlan0
iface wlan0 inet static
wireless-essid MYESSID
address 192.168.168.102
netmask 255.255.255.0
gateway 192.168.168.1