Huawei eNSP- default routing configuration

Experimental topology

Here Insert Picture Description

lab environment

企业网和公网之间的通信
pc1(192.168.10.10/24)
pc2(192.168.10.20/24)

1, the router R1 Configuration

<Huawei>sys    ##进入系统视图模式
Enter system view, return user view with Ctrl+Z.
[Huawei]sys R1  ##修改名字
[R1]int g0/0/1    ##进入接口
[R1-GigabitEthernet0/0/1]ip add 192.168.10.1 24   ##配置ip地址
[R1-GigabitEthernet0/0/1]undo shut      ##开启物理接口
[R1-GigabitEthernet0/0/1]int g0/0/0
[R1-GigabitEthernet0/0/0]ip add 12.0.0.1 30
[R1-GigabitEthernet0/0/0]undo shutdown 
[R1-GigabitEthernet0/0/0]q   ##退出接口
[R1]ip route-static 0.0.0.0 0.0.0.0 12.0.0.2   ##配置默认路由

2, the router R2 Configuration

<Huawei>sys    ##系统视图模式
Enter system view, return user view with Ctrl+Z.
[Huawei]sys R2   ##修改名字
[R2]int g0/0/0   ##进入接口
[R2-GigabitEthernet0/0/0]ip add 12.0.0.2 30  ##配置ip地址
[R2-GigabitEthernet0/0/0]undo shutdown     ##开启物理接口
[R2-GigabitEthernet0/0/0]int loo 0        ##进入回环网卡
[R2-LoopBack0]ip add 2.2.2.2 32        ##设置地址  方便测试
[R2-LoopBack0]q
[R2]ip route-static 192.168.10.0 24 12.0.0.1   ##设置静态路由

3, configuration pc machine ip address

Here Insert Picture Description
Here Insert Picture Description

4, using the pc can communicate see ping2.2.2.2

Here Insert Picture Description
Here Insert Picture Description

thanks for reading!

Guess you like

Origin blog.51cto.com/14080162/2448974