Windows 7 Gateway DNS Variable

Post new topic   Reply to topic    DD-WRT Forum Index -> General Questions
Author Message
gatorback
DD-WRT User


Joined: 04 Feb 2007
Posts: 426
Location: Fountain of Youth

PostPosted: Sat Jul 25, 2015 17:30    Post subject: Windows 7 Gateway DNS Variable Reply with quote
My Win7 laptop access several different dd-wrt routers that are at various sites around town. Each time I need to access a particular gateway, I must find the LAN IP of the gateway and type this into the web browser.

In an ideal world, the LAN IP would be put into a variable:

Code:
set "ip="
for /f "tokens=1-2 delims=:" %%a in ('ipconfig^|find "Default"') do if not defined ip set ip=%%b
ping %ip%


This .bat file finds the IP address and stores it in a variable.

Is there a clever way to assign the LAN gateway IP to a local DNS variable=mygateway?

My Google search was unsuccessful, but I am hopeful that someone clever has already done this. Thanks in advance for either links to the solution or actionable examples.

_________________
My Routers | RT-N16 Wiki | TMO Cellspot Wiki
Peacock Flashing | Wireless N Conf | Linking Routers |
DD-WRT Wiki | DD-WRT Builds | Broadcom FAQ| QoS| OTRW
Sponsor
Display posts from previous:    Page 1 of 1
Post new topic   Reply to topic    DD-WRT Forum Index -> General Questions All times are GMT

Navigation

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You can attach files in this forum
You can download files in this forum