192.168.1.1 255.255.255.0 //设置端口ip
dns-server 61.177.7.1 //配置dns服务器
exit
end
disable
可以通过 ip helper-address指定 DHCP中继代理
interface FastEthernet0/1
ip address 192.168.1.1 255.255.255.0
ip helper-address 192.168.10.2 \\配置DHCP中继代理,DHCP
六、配置NAT
命令
en
config t //全局模式
interface f0/0
ip address 192.168.1.1 255.255.255.0
ip nat inside //内部端口
no shu
exit
interface f0/1
ip address 192.168.10.1 255.255.255.0
ip nat outside //外部端口
no shu
exit
access-list 1 permit any //设置一个可访问列表
ip nat pool gr-nat-pool 192.168.10.3 192.168.10.254 netmask 255.255.255.0 //设置分配池
ip nat inside resource list 1 pool gr-nat-pool overload
show ip nat traslations
clear ip nat traslation *
七、其它
sh running-config //显示当前运行配置
sh startup-config //显示开机配置
sh ip route //显示路由
sh nat traslations //显示nat当前情况