yuedingwangji 发表于 2015-4-21 22:04:26

大神帮我看下为什么这条静态映射没作用,route-map!

公司有一台服务器 192.168.0.47 ,现在需要发布到外网,现在做静态映射, ip nat inside source static 192.168.0.47 192.168.11.81 ,然后外网PING的时候,是可以PING通192.168.11.81 这个IP的,内网PING81的时候也是可以ping的,查过相关的资料,这样内网按理是ping不通 81 这个网段的,因为NAT回流,小弟技术有效,还没学到哪里,现在最多NA+一点, 我发现一个规律,无论你把那个地址映射出去,映射出去的IP地址,在内网都是可以通的,比方说,我原来这个192.168.11.0/24 这个网段是没有192.168.11.85 这个IP的,原本在路由器上是ping不通这个IP的,但是我现在通过一条命令 ip nat inside source static 192.168.0.47 192.168.11.85,我就能在内网ping通这个IP,跟踪路由的跳数是一,也就是说他去192.168.11.85,都不需要走路由,而且得到的回复是来自192.168.11.85的回复, 现在情况就是无论映射到那个IP,外网都能PING通,却不能访问指定的端口,如23,22, 8080 等等, 顺带请教一个为什么静态映射就不需要ACL, 下面上一下配置,小弟可能描述语言不是很精准,语言不对的地方,见谅!

   如果有哪位大神,知道为什么,愿意为懵晕的我解答的话,万分感谢    QQ125557082 ,希望你不介意多一个朋友
配置如下,因为是公司路由器,所以把相关的密码和证书去掉了。。。
   


Building configuration...

Current configuration : 6197 bytes
!
! Last configuration change at 07:55:37 UTC Tue Apr 21 2015
version 15.2
service timestamps debug datetime msec
service timestamps log datetime msec
service password-encryption
!
hostname cwgs-bgw-RT-1
!
boot-start-marker
boot-end-marker
!
!
logging buffered 51200 warnings
enable secret
enable password
!
no aaa new-model
!
ip cef
!
!
!
!
!
!
ip domain name yourdomain.com
no ipv6 cef
multilink bundle-name authenticated
!
!
!
subject-name cn=IOS-Self-Signed-Certificate-3756962253
!
!


      quit
license udi pid CISCO2921/K9 sn FGL171211TS
!
!
!
!
csdb tcp synwait-time 30
csdb tcp idle-time 3600
csdb tcp finwait-time 5
csdb tcp reassembly max-memory 1024
csdb tcp reassembly max-queue-length 16
csdb udp idle-time 30
csdb icmp idle-time 10
csdb session max-session 65535
!
!
!
!
interface Loopback1
no ip address
!
interface Embedded-Service-Engine0/0
no ip address
shutdown
!
interface GigabitEthernet0/0
description $ETH-LAN$$ETH-SW-LAUNCH$$INTF-INFO-GE 0/0$
ip address 10.1.1.1 255.255.255.0
shutdown
duplex auto
speed auto
!
interface GigabitEthernet0/0.1
encapsulation dot1Q 10
ip address 192.168.10.1 255.255.255.0
!
interface GigabitEthernet0/0.2
encapsulation dot1Q 20
ip address 192.168.0.250 255.255.255.0
ip nat inside
ip virtual-reassembly in
!
interface GigabitEthernet0/1
ip address 192.168.11.8 255.255.255.0
ip nat outside
ip virtual-reassembly in
duplex auto
speed auto
!
interface GigabitEthernet0/2
ip address 10.0.0.11 255.255.255.248
ip nat inside
ip virtual-reassembly in
duplex auto
speed auto
!
interface Serial0/0/0
no ip address
clock rate 2000000
!
interface Serial0/0/0.1
!
interface FastEthernet0/1/0
no ip address
!
interface FastEthernet0/1/1
no ip address
!
interface FastEthernet0/1/2
no ip address
!
interface FastEthernet0/1/3
no ip address
!
interface Vlan1
no ip address
!
ip forward-protocol nd
!
ip http server
ip http access-class 23
ip http authentication local
ip http secure-server
ip http timeout-policy idle 60 life 86400 requests 10000
!
ip nat inside source route-map internal interface GigabitEthernet0/1 overload
ip nat inside source static 192.168.0.47 192.168.11.81
ip route 0.0.0.0 0.0.0.0 192.168.11.1
ip route 192.168.0.0 255.255.255.0 GigabitEthernet0/2
!
access-list 1 permit 192.168.0.0 0.0.0.255
access-list 23 permit 10.10.10.0 0.0.0.7
access-list 24 permit 192.168.11.0 0.0.0.255
!
route-map internal permit 10
match ip address 1
!
!
!
control-plane

yuedingwangji 发表于 2015-4-22 19:15:58

为什么没有一个人回复的

Dennis. 发表于 2015-4-23 10:45:43

你加我QQ:393581839,我给你远程,有些地方配置不合适。
页: [1]
查看完整版本: 大神帮我看下为什么这条静态映射没作用,route-map!