能PING到路由器网关,但PING不通DNS

作者:思科培训 来源:来自网络 发布时间:10-01-11

学员提问:

正在调试一个思科R2800路由器 将G0/0口设置成内网,G0/1设置成外网 设置完IP后 能PING到路由器网关 但PING不通DNS

这是配置

Current configuration : 2961 bytes
!
version 12.4
service timestamps debug datetime msec
service timestamps log datetime msec
no service password-encryption
!
hostname R2800
!
boot-start-marker
boot-end-marker
!
logging buffered 51200 warnings
enable secret 5 $1$iC0o$vqbF7aix4.OVbah5AtqNB.
enable password cisco
!
no aaa new-model
!
!
ip cef
!
!
!
ip cef
!
!
ip domain name yourdomain.com
multilink bundle-name authenticated
!
!
!
archive
log config
hidekeys
!
!
!
!
!
interface GigabitEthernet0/0
ip address 192.168.1.254 255.255.255.0
ip nat inside
ip virtual-reassembly
duplex auto
speed 100
!
interface GigabitEthernet0/1
ip address 60.21.215.224 255.255.255.128
ip nat outside
ip virtual-reassembly
duplex auto
speed 100
!
ip forward-protocol nd
ip route 0.0.0.0 0.0.0.0 GigabitEthernet0/1 60.21.215.129
!
!
ip http server
ip http access-class 23
ip http authentication local
ip http timeout-policy idle 60 life 86400 requests 10000
ip nat inside source list 5 interface GigabitEthernet0/0 overload
!
access-list 5 permit any
!
!
control-plane
!
-----------------------------------------------------------------------
^C
!
line con 0
password cisco
login
line aux 0
line vty 0 4
access-class 23 in
privilege level 15
password guojian
login
transport input telnet
line vty 5 15
access-class 23 in
privilege level 15
login local
transport input telnet
!
scheduler allocate 20000 1000
!
end


捷盈讲师及学员解答:

NAT配置错了,仔细检查一下。还有路由也配置错了。