eNSP常用命令资料

整理文档很辛苦,赏杯茶钱您下走!

免费阅读已结束,点击下载阅读编辑剩下 ...

阅读已结束,您可以下载文档离线阅读编辑

资源描述

3、acl命令格式:基本/高级ACL支持:acl[ipv6]acl-number{inbound|outbound}undoacl[ipv6]acl-number{inbound|outbound}二层ACL支持:aclacl-numberinboundundoaclacl-numberinbound功能:acl命令用来引用访问控制列表(ACL),2000~2999:基本ACL编号;3000~3999:高级ACL编号;4000~4999:二层ACL编号。应用实例:Sysnamesystem-view[Sysname]aclnumber2001[Sysname-acl-basic-2001]rulepermitsource192.168.1.260Sysnamesystem-view[Sysname]aclnumber3001[Sysname-acl-adv-3001]rulepermittcpdestination192.168.1.4104、DHCP命令格式:(1)配置基于接口地址池的DHCP[R1]dhcpenable开启DHCP功能[R1-GigabitEthernet0/0/2]dhcpselectinterface开启接口的DHCP服务功能[R1-GigabitEthernet0/0/2]dhcpserverleaseday2配置IP地址租用有效期限为2天,默认为1天,超过租期后该地址将会重新分配[R1-GigabitEthernet0/0/2]dhcpserverexcluded-ip-address192.168.3.251192.168.3.253配置不参与自动分配的IP地址[R1-GigabitEthernet0/0/2]dhcpserverdns-list8.8.8.8指定接口地址池下的DNS服务器(2)配置基于全局地址池的DHCP[R2]dhcpenable开启DHCP功能[R2]ippoolhuawei1创建一个全局地址池,地址池名称为huawei1[R3-ip-pool-huawei1]network192.168.4.0动态分配的地址范围192.168.4.0,如果不指定掩码,则默认使用自然掩码[R3-ip-pool-huawei1]leaseday2全局地址池下的地址租期[R3-ip-pool-huawei1]gateway-list192.168.4.254配置DHCP客户端的网关地址[R3-ip-pool-huawei1]excluded-ip-address192.168.4.250192.168.4.253[R3-ip-pool-huawei1]dns-list8.8.8.8[R3]interfaceGigabitEthernet0/0/0[R3-GigabitEthernet0/0/0]dhcpselectglobal开启接口DHCP功能,指定接口采用全局地址池为客户端分配IP地址5、Eth-Trunk命令格式:[S1]interfaceEth-Trunk1配置链路聚合,创建Eth-Trunk1[S1-Eth-Trunk1]modemanualload-balance指定为手工负载分担模式[S1]interfaceGigabitEthernet0/0/1[S1-GigabitEthernet0/0/1]eth-trunk1加入到Eth-Trunk1接口[S1]interfaceGigabitEthernet0/0/2[S1-GigabitEthernet0/0/2]eth-trunk1加入到Eth-Trunk1接口6、GVRP命令格式:[S1]gvrp在交换机上启用GVRP[S1]interfaceGigabitEthernet0/0/1[S1-GigabitEthernet0/0/1]gvrp在接口上启用GVRP[S3]interfaceGigabitEthernet0/0/1[S3-GigabitEthernet0/0/1]gvrpregistrationfixed在接口下将GVRP的注册模式修改为Fixed模式[S2]interfaceGigabitEthernet0/0/1[S2-GigabitEthernet0/0/1]gvrpregistrationforbidden在接口下将GVRP的注册模式修改为Forbidden模式7、IPV6命令格式:[R1]ipv6全局开启IPv6功能[R1]intg0/0/0[R1-GigabitEthernet0/0/0]ipv6enable接口下开启IPv6功能[R1-GigabitEthernet0/0/0]ipv6addressautolink-local接口上配置自动生成链路本地地址[r1-GigabitEthernet0/0/0]ipv6address2001:3:fd::64eui-64配置EUI-64地址[R1]intg0/0/0[R1-GigabitEthernet0/0/0]ipv6enable接口下开启IPv6功能[r1-GigabitEthernet0/0/0]ipv6add2031:0:130f::164在接口上手工静态配置全球单播地址8、NAT命令格式:[R1]intg0/0/0[R1-GigabitEthernet0/0/0]natstaticglobal202.169.10.5inside172.16.1.1静态NAT[r1]intg0/0/1[r1-GigabitEthernet0/0/1]natserverprotocoltcpglobalcurrent-interface使用当前接口IP作NAT映射[R1]nataddress-group1202.169.10.50202.169.10.60配置NAT地址池[R1]acl2001[R1-acl-basic-2001]rule5permitsource172.16.1.00.0.0.255配置访问控制列表[R1]intg0/0/0[R1-GigabitEthernet0/0/0]natoutbound2001address-group1配置NATOutbound[R1]acl2001[R1-acl-basic-2001]rule5permitsource172.16.1.00.0.0.255[R1]intg0/0/0[R1-GigabitEthernet0/0/0]natoutbound2001配置NATEasy–IP,使用接口的IP地址作为NAT9、OSPF命令格式:[Huawei]ospf11代表进程号,如果没有注明,则默认为进程1[Huawei-ospf-1]area0区域ID,配置为区域0[Huawei-ospf-1-area-0.0.0.0]network1.1.1.00.0.0.255精确区配所通告的网段10、PAP,CHAP命令格式:R1]interfaceSerial1/0/0[R1-Serial1/0/0]pppauthentication-modepap配置PPP的PAP认证,配置本端的PPP协议验证方式为PAP[R2]interfaceSerial1/0/0[R2-Serial1/0/0]ppppaplocal-userhuaweipasswordcipherhello配置发送账户huawei密码hello到认证方[R1]interfaceSerial1/0/0[R1-Serial1/0/0]pppauthentication-modechap配置PPP的CHAP认证,配置本端的PPP协议验证方式为CHAP[R1]aaa[R1-aaa]local-userhuaweipasswordcipherhello[R1-aaa]local-userR1service-typeppp新建对端被认证方所使用的用户名为huawei密码为hello[R2]interfaceSerial1/0/0[R2-Serial1/0/0]pppchapuserhuawei[R2-Serial1/0/0]pppchappasswordcipherhello进入接口模式下配置发送账户huawei密码hello到认证方11、RIP命令格式:[R1]rip使用RIP命令开启协议进程,默认进程号是1[R1-rip-1]network10.0.0.0配置通告的网段[R1-rip-1]version2配置RIP运行的版本为214、STP命令格式:[S1]stpenable交换机启用STP[S1]stpmodestp将交换机的STP模式更改为普通生成树STP[S1]stppriority0配置S1为根交换机[S2]stppriority4096配置S2根网桥优先级为4096[S1]stpregion-configuration配置MSTP,进入MST域视图[S1-mst-region]region-namehuawei配置MST域名[S1-mst-region]revision-level1配置MSTP的修订级别为1[S1-mst-region]instance1vlan10指定VLAN10映射到MSTI1[S1-mst-region]instance2vlan20指定VLAN20映射到MSTI2[S1-mst-region]activeregion-configuration激活MST域配置15、Telnet命令格式:[Huawei]user-interfacevty04进入VTY0到4接口[Huawei-ui-vty0-4]authentication-modepasswordPleaseconfiguretheloginpassword(maximumlength16):Huawei配置TELNET密码为huawei[Huawei-ui-vty0-4]userprivilegelevel1用户级别为1(监控级)16、VRRP命令格式:[R2]interfaceEthernet1/0/1[R2-Ethernet1/0/1]vrrpvrid1virtual-ip172.16.1.254创建VRRP备份组,备份组号为1,虚拟IP为172.16.1.254[R2-Ethernet1/0/1]vrrpvrid1priority120配置优先级为120[R2]interfaceEthernet1/0/1[R2-Ethernet1/0/1]vrrpvrid2preempt-modedisable配置虚拟组2中的抢占模式为非抢占方式,默认为抢占模式[R2]interfaceEthernet1/0/1[R2-Ethernet1/0/1]vrrpvrid1trackinterfaceGigabitEthernet0/0/0reduced50配置监视上行接口,如此接口断掉,裁减优先级50[R3]interfaceEthernet1/0/1[R3-Ethernet1/0/1]vrrpvrid1authentication-modemd5huawei对VRRP虚拟组1配置接口认证,认证方式为MD5,密码为huawei17、帧中继命令格式:[r1]ints1/0/0[r1-Serial1/0/0]ipaddress10.0.123.1255.255.255.0配置IP地址与子网掩码[r1-Serial1/0/0]link-protocolfr使用动态映射,配置链路层协议为FR[r1-Serial1/0/0]frinarp运行帧中继逆向地址解析功能自动生成地址映射表,默认开启18、单臂路由命令格式:[R1]interfaceGigabitEthernet0/0/1.1[R1-GigabitEthernet0/0/1.1]ipaddress192.168.1.254255.255.255.0[R1-GigabitEthernet0/0/1.1]dot1qterminationvid10配置子接口对一层tag报文的终结功能,VI

1 / 13
下载文档,编辑使用

©2015-2020 m.777doc.com 三七文档.

备案号:鲁ICP备2024069028号-1 客服联系 QQ:2149211541

×
保存成功