-   Linux - Wireless Networking (
-   -   want to start script when wlan interface goes up (

nrsorte 03-23-2007 02:03 AM

want to start script when wlan interface goes up

I am writing a script to configure my wireless wlan settings. What should I do to automate it so that this script will run whenever wlan goes up. Please anyone guide me for this.

Thanks in advance.

saavik 03-24-2007 06:59 AM

Well I am not really sure what and when you want to run the script but maybe the search for ip-up.local could help.

In this script you can add things like mailing your actually ip.

If this does not help you may post some more infos.

jschiwal 03-24-2007 07:05 AM

Putting your distro in your profile will help get more accurate responses. Some distros use certain config files and scripts that may be a better fit toward a solution.

tommosimmo 03-24-2007 05:48 PM

Hi there,

Try editing/making your /etc/sysconfig/network-scripts/ifcfg-interfacename file to something like;

DEVICE=device name here
GATEWAY=ap's ip address here
ONBOOT=yes (if you want it to try and connect at boottime)
USERCTL=yes (Allows all users to start/stop the connection)
ESSID=The Ap's SSID here.
CHANNEL=<the default AP channel here>

BTW, What distro and hardware are you using?

Cheers, and good luck.

jschiwal 03-26-2007 03:45 AM

For SuSE, the same config scripts are in /etc/sysconfig/network/. Some distro's may not have anything similar and you need to produce a script with iwconfig commands. That's why knowing the distro helps, and a logical place for it is in the profile instead of having to repeat it on every post.

nrsorte 03-26-2007 07:24 AM


I have Linux-Pebble installed on my router boards and on them I want to run a script whenever my wlan goes up. After this in script I want to analyse wireless link status. Is it possible to do so on this Pebble? If so please could you guide me for the same.


All times are GMT -5. The time now is 09:53 AM.