尝试使用 ATT Uverse 和 IP Passthrough 设置静态 IP 块到华硕路由器

Attempting to setup static IP block with ATT Uverse and IP Passthrough to ASUS router

我正在尝试完成以下设置:

NVG599 <>华硕RT-AC88U <>静态设备

我有一个 Ubuntu 服务器 运行 Apache,它已配置为使用内部地址 192.x.x.x 以及其中一个静态 IP 地址。我知道 Apache 正在 运行 / 监听 / 工作。如果我浏览到内部地址,我会得到默认的 Apache 页面。 Ubuntu 防火墙被禁用。我实际上有一个指向此 IP 地址“http://thelavender.net

的域设置

通常 ATT RG 会处理第二个子网/静态 IP 块。我无法弄清楚的是华硕现在基本上接管了所有路由职责,将如何处理这些问题。

ATT RG 中有一个级联路由器选项,我看到有人在谈论使用它。这个对吗?

编辑

回想起来,我觉得1:1 NAT才是我真正需要的吧?

编辑 2
我尝试使用类似这样的东西:

#!/bin/sh
#
# to restore this configuration, it needs to be saved to /jffs/scripts/nat-start
# on the router.
#
ifconfig eth0:0 WanIP1 netmask 255.255.255.248 up
iptables -t nat -A PREROUTING -i eth0 -d WanIP1 -j DNAT --to-destination     192.168.1.10
iptables -t nat -I POSTROUTING -s 192.168.1.10 -j SNAT --to WanIP1
#
ifconfig eth0:1 WanIP2 netmask 255.255.255.248 up
iptables -t nat -A PREROUTING -i eth0 -d WanIP2 -j DNAT --to-destination     192.168.1.11
iptables -t nat -I POSTROUTING -s 192.168.1.11 -j SNAT --to WanIP2
#
ifconfig eth0:2 WanIP3 netmask 255.255.255.248 up
iptables -t nat -A PREROUTING -i eth0 -d WanIP3 -j DNAT --to-destination 192.168.1.12
iptables -t nat -I POSTROUTING -s 192.168.1.12 -j SNAT --to WanIP3
#
# Port forwards, in case the webui doesn't work, but i think it will.  uncomment below if needed.
# iptables -A FORWARD -p tcp --dport 80 -d 192.168.1.10 -j ACCEPT

我只尝试了第一组并将其放入 nat-start 脚本中让 Merlin 获取。当我这样做并重新启动路由器时,它拒绝从 RG 获取 WAN IP。

如有任何帮助,我们将不胜感激。

编辑

投了反对票,但没有解释原因。

NVG599局域网地址:192.168.0.254 / 255.255.255.0

RT-AC88U 广域网地址:192.168.0.1 / 255.255.255.0 RT-AC88U 局域网地址:192.168.1.1 / 255.255.255.0

NVG599 级联路由器:已启用 级联路由器地址:192.168.0.1 网络地址:107.218.164.224 子网掩码:255.255.255.248

服务器:192.168.1.10 和 107.218.164.225

路由器的启动脚本:

#!/bin/sh
#
# tell it where to find the server

ip ro add 107.218.164.225/32 via 192.168.1.10
iptables -I POSTROUTING -t nat -s 107.218.164.225/32 -j RETURN

#
# servers 2-N go here
......
#
# catch-all for everything else on the LAN
#
# this will double-NAT everything and will end up using the NVG's dynamic IP which is outside of the static IP block
##iptables -A POSTROUTING -t nat -o eth0 -j SNAT --to 192.168.0.1
#
# this uses one of the public IPs
iptables -A POSTROUTING -t nat -o eth0 -j SNAT --to 107.218.164.230

如果需要,还有服务器脚本

#!/bin/sh
#
ifconfig eth0:1 107.218.164.225/29
ip ro repl default via 192.168.1.1 src 107.218.164.225