task 4.9 NAT

Rack1R4(config)#route-map POLICY permit 10
Rack1R4(config-route-map)# match ip add 100
Rack1R4(config-route-map)#set interface loopback 0
% route-map:can not set interface.
% Use P2P interfaces for set interface clause

How can I get lo0 be the course interface?

Comments

  • Can you please send your config on int lo0 ? [*-)]

  • And why the lab Do`s and dont`s says: "do not use any static routers, default routers, default networks, or policy routing..."

     

     

  • I also get same output - Any Idea's

    RSRack2R5(config-route-map)#set interface loopback0       
    %Warning:Use P2P interface for routemap
                    set interface clause

  • it works now

    It appears the notification doest stop the interface been applied to the router map policy

     

    RSRack2R5#show route-map POLICY
    route-map POLICY, permit, sequence 10
      Match clauses:
        ip address (access-lists): 100
      Set clauses:
        interface Loopback0
      Policy routing matches: 0 packets, 0 bytes
    RSRack2R5#config t
    Enter configuration commands, one per line.  End with CNTL/Z.
    RSRack2R5(config)#ip lo
    RSRack2R5(config)#ip local po
    RSRack2R5(config)#ip local pol
    RSRack2R5(config)#ip local policy ro
    RSRack2R5(config)#ip local policy route-map POLICY
    RSRack2R5(config)#
    RSRack2R5#ping 144.2.78.7 source f0/1
    *Aug 31 10:07:24.160: %SYS-5-CONFIG_I: Configured from console by console
    RSRack2R5#ping 144.2.78.7 source f0/1

    Type escape sequence to abort.
    Sending 5, 100-byte ICMP Echos to 144.2.78.7, timeout is 2 seconds:
    Packet sent with a source address of 144.2.55.5
    !!!!!
    Success rate is 100 percent (5/5), round-trip min/avg/max = 4/7/12 ms
    RSRack2R5#
    *Aug 31 10:07:26.696: NAT: creating portlist proto 1 globaladdr 150.2.5.5
    *Aug 31 10:07:26.696: NAT: [0] Allocated Port for 144.2.55.5 -> 150.2.5.5: wanted 29 got 29
    *Aug 31 10:07:26.696: NAT: i: icmp (144.2.55.5, 29) -> (144.2.78.7, 29) [240]    
    *Aug 31 10:07:26.696: NAT: s=144.2.55.5->150.2.5.5, d=144.2.78.7 [240]
    *Aug 31 10:07:26.704: NAT: i: icmp (144.2.55.5, 29) -> (144.2.78.7, 29) [241]    
    *Aug 31 10:07:26.704: NAT: s=144.2.55.5->150.2.5.5, d=144.2.78.7 [241]
    *Aug 31 10:07:26.708: NAT: i: icmp (144.2.55.5, 29) -> (144.2.78.7, 29) [242]    
    *Aug 31 10:07:26.708: NAT: s=144.2.55.5->150.2.5.5, d=144.2.78.7 [242]
    RSRack2R5#
    *Aug 31 10:07:26.716: NAT: i: icmp (144.2.55.5, 29) -> (144.2.78.7, 29) [243]    
    *Aug 31 10:07:26.716: NAT: s=144.2.55.5->150.2.5.5, d=144.2.78.7 [243]
    *Aug 31 10:07:26.728: NAT: i: icmp (144.2.55.5, 29) -> (144.2.78.7, 29) [244]    
    *Aug 31 10:07:26.728: NAT: s=144.2.55.5->150.2.5.5, d=144.2.78.7 [244]
    RSRack2R5#

  • Mine doesnt seem to be working...I keep getting that message as well, but my interface is not being applied in the set statement like the previous posters.  I heard this works in older code, but not the newer stuff like 12.4.  Is this the case?  I tried a workaround using the nvi, and ip nat enable, but couldnt get that to work either. 

  • You could also use "set ip next-hop" instead of "set interface." Just specfy a dummy address that would be on the same network as the Loopback0 interface, such as 150.X.5.55.

  • Agree, isn't this policy routing?

     


  • What a waste of time... I tried over a hour (before looking for the answer) to do this without policy routing as it was restricted in Do’s and Don’ts!

  • I was really sure this was going to work


    int s0/0/0.1 
    ip nat enable

    int fa0/1 
    ip nat enable

    ip nat pool MYPOOL 144.2.15.6 144.2.15.10 prefix-length 24 

    ip nat source list 1 pool MYPOOL

    access-list 1 permit ip 144.2.55.0 0.0.0.255

    But it didn't because local generated traffic won't apply to nat, so funny because with ip nat inside and ip nat outside this works fine but its a resctriction, so it doesn't even work with ip nat outside on the loopback. The WB uses PBR... that is not allowed... one trashed hour.

    Anyway just another experience.

Sign In or Register to comment.