Retrieve router IP to a text file

douclind asked 1 year ago

I manage an XP pc (with XP PRO SP2) and a separate IP weather webcam 40 miles away that uploads weather info to our flying club website. The PC gets its connection via a DSL modem/wifi router with a dynamic IP. I port forward from the router to the webcam and to the PC for remote desktop.

So if the router gets a new wan IP I have to drive out to the field to find it out. The club isn't going to pay for a dynamic dns service. I think that would be ridiculous anyway. All I need is the IP that's sitting right there on the router.

My thought was to have a program running that would output the router's wan ip to a text file and have the weather software (which runs on the PC) routinely ftp it to our web host.

I thought I could use ping like so:
ping -r 1 flyjcrc.com>ip.txt
and have it periodically execute via a scheduler. Ping -r will output more than the router ip but that's no problem.

The wx software could upload ip.txt and I could access it whenever I needed it. But ping -r won't run on that PC for some reason. ping runs with no options but not ping -r. It just gives me 4 timeouts. I have no idea why. I'm not a networking guru.

So here I am on this forum hoping someone smarter than I am can help me figure something out. I either need a program that can output the IP or someone to help me figure why ping with the "r" option times out.

1 Answers
wimiadmin Staff answered 1 year ago

Thanks for your question douclind.

Not sure why ping -r isn't working. But we've got what you need.

Membership Options

Under the Silver options, you'll get our software that you can install on the remote machine. Anytime the IP changes, it'll email you with the new IP address. It's written in java so you'll need to have java installed and our software uses whatever email account you setup in the configuration. All for only $10 per year. 🙂

Know the answer? Login or sign up for an account to answer this question.
Sign Up