Click to See Complete Forum and Search --> : Changing IP address...


Locke
09-23-2001, 06:33 AM
K, got an odd question for you peoples. :D

I am on a cable connection, using dhcpcd to set my IP address. I want to catch when my IP address changes (it doesn't often, but when it does...) so i can excute a script that will upload the new IP to my web server. This way, I can find my computer no matter where I am.

Are there flags that linux throws when it detects an IP change, or would this be a job for cron?

If it were a job for cron, what is the env variable for the IP address?

Thanks in advance for any help!

YaRness
09-23-2001, 08:07 AM
there are scripts that will manage this for you.

if *I* are trying to figure out how to do it, i'd prolly download one of those scripts and see how it works.

i dunno the names of any, but i'm sure a search on google.com including the words "dynamic", "ip", and "dns" would do the trick.

atually, maybe a few more words (http://www.google.com/search?q=dynamic+ip+dns+script+update) might help.

slacker_x
09-23-2001, 05:41 PM
another option is using a service like dyndns and then running a client to update the IP for you. I use one called ipcheck I believe.

ipcheck.py

(python script)