I want that, whenever pppd connects to the internet, a certain window applet (wmWeather) to be automatically executed (to appear
on my screen). My script /etc/ppp/ip-up.local is executed (I checked this using the "touch /tmp/hello", which does what is
suppose to do), but the applet does not appear on the screen.
Here is the script:
/etc/ppp/ip-up.local
--------------------------[start]
#!/bin/bash
/usr/X11R6/bin/wmWeather -station KTTN
touch /tmp/hello
exit 0
--------------------------[end]
Now, I know that /etc/ppp/ip-up (which calls /etc/ppp/ip-up.local):
1. runs as a root,
2. changes the PATH,
3. sets the standard input, output and error for all commands inside to /dev/null,
but i don't see how any of these will explain why the line executing wmWeather in /etc/ppp/ip-up.local, which is for sure is
executed, does not pop-up the applet on the screen.
Leads that did not get me anywhere:
1. /etc/ppp/ip-up.local runs ok, when called from a command line.
2. I looked inside the source code of the applet, and all commands have complete paths (so a changed PATH shouldn't be a problem).
3. The following lines from man pppd regarding ip-up did not get me anywhere either.
/etc/ppp/ip-up
A program or script which is executed when the link is available
for sending and receiving IP packets (that is, IPCP has come
up). It is executed with the parameters
interface-name tty-device speed local-IP-address remote-IP-address ipparam
Any leads are gratefully appreciated.
baudolino
clueless as always