Testuję na GNS (na bazie c3745-advipservicesk9-mz.124-25) mechanizm NAT-a w następującej konfiguracji:
W pierwszym podejściu chciałbym NAT-ować cały ruch wychodzący z FastEthernet0/0 (192.168.1.0/24) w stronę dowolnego tunelu.interface Loopback0
ip address 10.5.5.1 255.255.255.255
ip virtual-reassembly
!
interface Tunnel1
ip unnumbered Loopback0
ip nat outside
ip pim sparse-dense-mode
keepalive 5 5
tunnel source FastEthernet0/1
tunnel destination 10.5.7.1
!
interface Tunnel2
ip unnumbered Loopback0
ip nat outside
ip pim sparse-dense-mode
keepalive 5 5
tunnel source FastEthernet0/1
tunnel destination 10.5.8.1
!
interface Tunnel3
ip unnumbered Loopback0
ip nat outside
ip pim sparse-dense-mode
keepalive 5 5
tunnel source FastEthernet0/1
tunnel destination 10.5.9.1
!
interface FastEthernet0/0
ip address 192.168.1.1 255.255.255.0
ip pim sparse-dense-mode
ip nat inside
!
interface FastEthernet0/1
ip address 10.5.20.1 255.255.255.252
!
router eigrp 1
passive-interface Loopback0
network 10.5.5.1 0.0.0.0
no auto-summary
!
ip route 0.0.0.0 0.0.0.0 10.5.20.2
!
!
ip pim autorp listener
ip nat inside source list 1 interface Loopback0 overload
!
access-list 1 permit 192.168.1.0 0.0.0.255
Niestety przy klasycznej konfiguracji nie udało mi się zaobserwować działania NATa - tzn. IP nadawcy pozostawało niezmienione (192.168.1.0/24).
Dodam, że robiłem też testy z tylko jednym tunelem i wpisem "ip nat inside source list 1 interface tunnel1 overload" oraz dodawałem "ip nat outside" do loopback0, niestety nic nie pomagało.
Zastanawiam się, czy popełniłem jakiś błąd, czy to raczej ograniczenie tego, że tunel ma adres typu unnumbered?