How to determine the WAN IP address of a DD-WRT router?

Post new topic   Reply to topic    DD-WRT Forum Index -> Advanced Networking
Author Message
Vaako
DD-WRT User


Joined: 10 Jun 2009
Posts: 370

PostPosted: Fri Oct 31, 2014 0:39    Post subject: How to determine the WAN IP address of a DD-WRT router? Reply with quote
Hi,

Can someone tell how to determine the WAN IP address of a DD-WRT router?

The modem is bridged and the router makes a PPPoE session.
This is how it's connected:

Modem LAN1 port <-> Router WAN port

I need to now what IP address is used on the WAN port of the router (not the public IP address).

I already tried these commands but gives me not the information I need:

iptables -L -n

ifconfig |grep "inet addr" |cut -d: -f2 |cut -d" " -f1

netstat

nvram get wan_ipaddr (gives me my public IP address)


Thanks in advance!

_________________
Regards,
Vaako

1x Netgear R7800 Nighthawk - firmware not decided yet !!!!
1x Netgear R7000 Nighthawk r36410
1x Ubiquiti RouterStation Pro DD-WRT r23204 std (12/24/13)
1x Asus RT-N16 SVN revision 20675 NEWD-2 K2.6
1x Linksys E4200 v3.0 r34777 mega (01/31/18 )
1x Buffalo WZR-HP-G300NH B0 B0 Gargoyle FW
1x Linksys WRT600N v1.1 (Bricked)
1x Linksys WRT54GL v1.1 (DD-WRT 26446)
1x Linksys WRT54GS v2.2 (DD-WRT 26446)
1x Linksys RVS4000 (stock fw)
3x D-Link DWL-7100AP (openWRT)
2x TP-Link TL-WA801ND (Bridge mode) 100mW TX-Power
Asus WL-520GU SVN 16403M NEWD-2 Eko std-nokaid
4x Fonera with Gargoyle FW
Sponsor
Per Yngve Berg
DD-WRT Guru


Joined: 13 Aug 2013
Posts: 6865
Location: Romerike, Norway

PostPosted: Sat Nov 01, 2014 14:44    Post subject: Reply with quote
http://www.dd-wrt.com/wiki/index.php/Access_To_Modem_Configuration
Vaako
DD-WRT User


Joined: 10 Jun 2009
Posts: 370

PostPosted: Sat Nov 01, 2014 17:21    Post subject: Reply with quote
Yes I know, this is for access your modem in front of the router.
And I use it also in my home setup but that is not the information what I'm looking for.

What I need is how to determine the IP address of the router WAN port that is connected to the modem.

There must be a IP address on that WAN port otherwise a connection is not possible, I just like to now that IP address.

_________________
Regards,
Vaako

1x Netgear R7800 Nighthawk - firmware not decided yet !!!!
1x Netgear R7000 Nighthawk r36410
1x Ubiquiti RouterStation Pro DD-WRT r23204 std (12/24/13)
1x Asus RT-N16 SVN revision 20675 NEWD-2 K2.6
1x Linksys E4200 v3.0 r34777 mega (01/31/18 )
1x Buffalo WZR-HP-G300NH B0 B0 Gargoyle FW
1x Linksys WRT600N v1.1 (Bricked)
1x Linksys WRT54GL v1.1 (DD-WRT 26446)
1x Linksys WRT54GS v2.2 (DD-WRT 26446)
1x Linksys RVS4000 (stock fw)
3x D-Link DWL-7100AP (openWRT)
2x TP-Link TL-WA801ND (Bridge mode) 100mW TX-Power
Asus WL-520GU SVN 16403M NEWD-2 Eko std-nokaid
4x Fonera with Gargoyle FW
Per Yngve Berg
DD-WRT Guru


Joined: 13 Aug 2013
Posts: 6865
Location: Romerike, Norway

PostPosted: Sat Nov 01, 2014 17:51    Post subject: Reply with quote
What about "ifconfig vlan2"?
Vaako
DD-WRT User


Joined: 10 Jun 2009
Posts: 370

PostPosted: Sun Nov 02, 2014 14:38    Post subject: Reply with quote
Per Yngve Berg wrote:
What about "ifconfig vlan2"?


I only can see it's MAC address but no IP address.

Quote:
root@Router:~# ifconfig vlan2
vlan2 Link encap:Ethernet HWaddr 00:24:01:xx:xx:xx
UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
RX packets:35103547 errors:0 dropped:0 overruns:0 frame:0
TX packets:28049364 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:0
RX bytes:41726976255 (38.8 GiB) TX bytes:3140290771 (2.9 GiB)

_________________
Regards,
Vaako

1x Netgear R7800 Nighthawk - firmware not decided yet !!!!
1x Netgear R7000 Nighthawk r36410
1x Ubiquiti RouterStation Pro DD-WRT r23204 std (12/24/13)
1x Asus RT-N16 SVN revision 20675 NEWD-2 K2.6
1x Linksys E4200 v3.0 r34777 mega (01/31/18 )
1x Buffalo WZR-HP-G300NH B0 B0 Gargoyle FW
1x Linksys WRT600N v1.1 (Bricked)
1x Linksys WRT54GL v1.1 (DD-WRT 26446)
1x Linksys WRT54GS v2.2 (DD-WRT 26446)
1x Linksys RVS4000 (stock fw)
3x D-Link DWL-7100AP (openWRT)
2x TP-Link TL-WA801ND (Bridge mode) 100mW TX-Power
Asus WL-520GU SVN 16403M NEWD-2 Eko std-nokaid
4x Fonera with Gargoyle FW
Vaako
DD-WRT User


Joined: 10 Jun 2009
Posts: 370

PostPosted: Wed Nov 05, 2014 19:28    Post subject: Reply with quote
Where are the specialists when you need them Confused
_________________
Regards,
Vaako

1x Netgear R7800 Nighthawk - firmware not decided yet !!!!
1x Netgear R7000 Nighthawk r36410
1x Ubiquiti RouterStation Pro DD-WRT r23204 std (12/24/13)
1x Asus RT-N16 SVN revision 20675 NEWD-2 K2.6
1x Linksys E4200 v3.0 r34777 mega (01/31/18 )
1x Buffalo WZR-HP-G300NH B0 B0 Gargoyle FW
1x Linksys WRT600N v1.1 (Bricked)
1x Linksys WRT54GL v1.1 (DD-WRT 26446)
1x Linksys WRT54GS v2.2 (DD-WRT 26446)
1x Linksys RVS4000 (stock fw)
3x D-Link DWL-7100AP (openWRT)
2x TP-Link TL-WA801ND (Bridge mode) 100mW TX-Power
Asus WL-520GU SVN 16403M NEWD-2 Eko std-nokaid
4x Fonera with Gargoyle FW
Vaako
DD-WRT User


Joined: 10 Jun 2009
Posts: 370

PostPosted: Thu Nov 13, 2014 17:43    Post subject: Reply with quote
Anuone?? Rolling Eyes
_________________
Regards,
Vaako

1x Netgear R7800 Nighthawk - firmware not decided yet !!!!
1x Netgear R7000 Nighthawk r36410
1x Ubiquiti RouterStation Pro DD-WRT r23204 std (12/24/13)
1x Asus RT-N16 SVN revision 20675 NEWD-2 K2.6
1x Linksys E4200 v3.0 r34777 mega (01/31/18 )
1x Buffalo WZR-HP-G300NH B0 B0 Gargoyle FW
1x Linksys WRT600N v1.1 (Bricked)
1x Linksys WRT54GL v1.1 (DD-WRT 26446)
1x Linksys WRT54GS v2.2 (DD-WRT 26446)
1x Linksys RVS4000 (stock fw)
3x D-Link DWL-7100AP (openWRT)
2x TP-Link TL-WA801ND (Bridge mode) 100mW TX-Power
Asus WL-520GU SVN 16403M NEWD-2 Eko std-nokaid
4x Fonera with Gargoyle FW
tatsuya46
DD-WRT Guru


Joined: 03 Jan 2010
Posts: 7568
Location: YWG, Canada

PostPosted: Thu Nov 13, 2014 18:09    Post subject: Reply with quote
top right "wan ip address"..?
_________________
LATEST FIRMWARE(S)

BrainSlayer wrote:
we just do it since we do not like any restrictions enforced by stupid cocaine snorting managers

[x86_64] Haswell i3-4150/QCA9984/QCA9882 ------> r55797 std
[QUALCOMM] DIR-862L --------------------------------> r55797 std
▲ ACTIVE / INACTIVE ▼
[QUALCOMM] WNDR4300 v1 --------------------------> r50485 std
[BROADCOM] DIR-860L A1 ----------------------------> r50485 std


Sigh.. why do i exist anyway.. | I love you Anthony.. never forget that.. my other 99% that ill never see again..

Vaako
DD-WRT User


Joined: 10 Jun 2009
Posts: 370

PostPosted: Fri Nov 14, 2014 3:16    Post subject: Reply with quote
tatsuya46 wrote:
top right "wan ip address"..?


Where at the top right, I dont understand?
I cant see any IP address you mention.

_________________
Regards,
Vaako

1x Netgear R7800 Nighthawk - firmware not decided yet !!!!
1x Netgear R7000 Nighthawk r36410
1x Ubiquiti RouterStation Pro DD-WRT r23204 std (12/24/13)
1x Asus RT-N16 SVN revision 20675 NEWD-2 K2.6
1x Linksys E4200 v3.0 r34777 mega (01/31/18 )
1x Buffalo WZR-HP-G300NH B0 B0 Gargoyle FW
1x Linksys WRT600N v1.1 (Bricked)
1x Linksys WRT54GL v1.1 (DD-WRT 26446)
1x Linksys WRT54GS v2.2 (DD-WRT 26446)
1x Linksys RVS4000 (stock fw)
3x D-Link DWL-7100AP (openWRT)
2x TP-Link TL-WA801ND (Bridge mode) 100mW TX-Power
Asus WL-520GU SVN 16403M NEWD-2 Eko std-nokaid
4x Fonera with Gargoyle FW
Per Yngve Berg
DD-WRT Guru


Joined: 13 Aug 2013
Posts: 6865
Location: Romerike, Norway

PostPosted: Fri Nov 14, 2014 6:30    Post subject: Reply with quote
I don't think the interface have an ip.

You can dump the traffic on the interface with tcpdump

http://manpages.ubuntu.com/manpages/natty/man8/tcpdump.8.html
Vaako
DD-WRT User


Joined: 10 Jun 2009
Posts: 370

PostPosted: Fri Nov 14, 2014 21:46    Post subject: Reply with quote
Per Yngve Berg wrote:
I don't think the interface have an ip.


How can it not have an IP ???
Then it would not be posible to communicate between the modem and router!

The modem is in Bridge-mode and can be accessed via IP but I dont remember the IP anymore and at the moment it is not an option to reset the modem and re-configurate it but that way I would have know the modem's IP address since it is a statis address that is being used.

The router is configurated to make the PPPoE session and I used in the past startup and firewall script to access the modem behind the router:
http://www.dd-wrt.com/wiki/index.php/Access_To_Modem_Configuration

I only can wait till it's possible to power off the modem and reset re-configurate again then my problem is solved.

Anyway I thought there was a way to determine the router's WAN port IP adress but no one seems to know.

_________________
Regards,
Vaako

1x Netgear R7800 Nighthawk - firmware not decided yet !!!!
1x Netgear R7000 Nighthawk r36410
1x Ubiquiti RouterStation Pro DD-WRT r23204 std (12/24/13)
1x Asus RT-N16 SVN revision 20675 NEWD-2 K2.6
1x Linksys E4200 v3.0 r34777 mega (01/31/18 )
1x Buffalo WZR-HP-G300NH B0 B0 Gargoyle FW
1x Linksys WRT600N v1.1 (Bricked)
1x Linksys WRT54GL v1.1 (DD-WRT 26446)
1x Linksys WRT54GS v2.2 (DD-WRT 26446)
1x Linksys RVS4000 (stock fw)
3x D-Link DWL-7100AP (openWRT)
2x TP-Link TL-WA801ND (Bridge mode) 100mW TX-Power
Asus WL-520GU SVN 16403M NEWD-2 Eko std-nokaid
4x Fonera with Gargoyle FW
wa2ise
DD-WRT Novice


Joined: 30 Sep 2014
Posts: 15

PostPosted: Sat Nov 15, 2014 4:37    Post subject: Reply with quote
If you can get to your router via http on the LAN side (your PC connected to a LAN port of your router), it should be on the "system information" web page. This is the first page you see when you http to your router.
In Firefox, do 192.168.1.81 (or whatever the IP address of your router on the LAN side is), and the "system information" page should show. The WAN IP is in the "Router" box. At least in version of the Firmware: DD-WRT v24-sp2 (08/12/10) mini.
Vaako
DD-WRT User


Joined: 10 Jun 2009
Posts: 370

PostPosted: Sat Nov 15, 2014 12:15    Post subject: Reply with quote
wa2ise wrote:
If you can get to your router via http on the LAN side (your PC connected to a LAN port of your router), it should be on the "system information" web page. This is the first page you see when you http to your router.
In Firefox, do 192.168.1.81 (or whatever the IP address of your router on the LAN side is), and the "system information" page should show. The WAN IP is in the "Router" box. At least in version of the Firmware: DD-WRT v24-sp2 (08/12/10) mini.


Yes I now and thats the problem, it only displays the public IP address and not the router's physical WAN IP address.

_________________
Regards,
Vaako

1x Netgear R7800 Nighthawk - firmware not decided yet !!!!
1x Netgear R7000 Nighthawk r36410
1x Ubiquiti RouterStation Pro DD-WRT r23204 std (12/24/13)
1x Asus RT-N16 SVN revision 20675 NEWD-2 K2.6
1x Linksys E4200 v3.0 r34777 mega (01/31/18 )
1x Buffalo WZR-HP-G300NH B0 B0 Gargoyle FW
1x Linksys WRT600N v1.1 (Bricked)
1x Linksys WRT54GL v1.1 (DD-WRT 26446)
1x Linksys WRT54GS v2.2 (DD-WRT 26446)
1x Linksys RVS4000 (stock fw)
3x D-Link DWL-7100AP (openWRT)
2x TP-Link TL-WA801ND (Bridge mode) 100mW TX-Power
Asus WL-520GU SVN 16403M NEWD-2 Eko std-nokaid
4x Fonera with Gargoyle FW
Per Yngve Berg
DD-WRT Guru


Joined: 13 Aug 2013
Posts: 6865
Location: Romerike, Norway

PostPosted: Sat Nov 15, 2014 16:27    Post subject: Reply with quote
Can't you connect a PC configured for DHCP to the modem and see what gateway it gets?
Vaako
DD-WRT User


Joined: 10 Jun 2009
Posts: 370

PostPosted: Sat Nov 15, 2014 16:35    Post subject: Reply with quote
Per Yngve Berg wrote:
Can't you connect a PC configured for DHCP to the modem and see what gateway it gets?


No, since the modem is configurated Bridge-mode it has a static IP address and DHCP is disabled.
Therefore I need to now what subnet it is in to connect a PC/Laptop also setup with static IP address.

At the moment I can not interupt the internet connection to do some tests.

_________________
Regards,
Vaako

1x Netgear R7800 Nighthawk - firmware not decided yet !!!!
1x Netgear R7000 Nighthawk r36410
1x Ubiquiti RouterStation Pro DD-WRT r23204 std (12/24/13)
1x Asus RT-N16 SVN revision 20675 NEWD-2 K2.6
1x Linksys E4200 v3.0 r34777 mega (01/31/18 )
1x Buffalo WZR-HP-G300NH B0 B0 Gargoyle FW
1x Linksys WRT600N v1.1 (Bricked)
1x Linksys WRT54GL v1.1 (DD-WRT 26446)
1x Linksys WRT54GS v2.2 (DD-WRT 26446)
1x Linksys RVS4000 (stock fw)
3x D-Link DWL-7100AP (openWRT)
2x TP-Link TL-WA801ND (Bridge mode) 100mW TX-Power
Asus WL-520GU SVN 16403M NEWD-2 Eko std-nokaid
4x Fonera with Gargoyle FW
Display posts from previous:    Page 1 of 1
Post new topic   Reply to topic    DD-WRT Forum Index -> Advanced Networking 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 cannot attach files in this forum
You cannot download files in this forum