1.系统名称命名 hostname F1-SW012.系统钟配置clock timezone beijing 83.用户角色ssh和限源登录配置ip access-list standard denglu-acl10 permit host x.x.x.xexitrole audit-admindescription audit adminexitrole network-admindescription network adminexitrole network-operatordescription network operatorexitrole security-admindescription security adminexitlocal-user admin class managerservice-type sshprivilege 15password 7 123456exitline vty 0 4access-class denglu-acl inprotocol input sshlogin localexitip ssh serverssh server prefer-key diffie-hellman-group-exchange-sha256 diffie-hellman-group-exchange-sha1 diffie-hellman-group14-sha1ssh server perfer-stoc-hmac hmac-sha2-256ssh server perfer-identity-key ssh-rsa4.交换机逐流转发配置ip load-sharing per-flowipv6 load-sharing per-flow5.802.1X配置aaa server group radius radius1server x.x.x.x acct-port 1813 auth-port 1812 key 7 123exitdomain systemaaa authentication dot1x radius-group radius1aaa authentication login localaaa authorization login localaaa accounting dot1x start-stop radius-group radius1exit6.环路检测配置loopback-detection enableint gi 0/7shutdownswitchport access vlan 20spanning-tree bpdu guard enablespanning-tree portfast edgeport enableloopback-detection enable7.vlan和接口access和trunk配置vlan 10,19-20,100,1108.lldp配置lldp runint gi 0/7shutdownswitchport access vlan 20spanning-tree bpdu guard enablespanning-tree portfast edgeport enableloopback-detection enableexitint gi 0/8switchport access vlan 20spanning-tree bpdu guard enablespanning-tree portfast edgeport enableloopback-detection enableexitint gi 0/16switchport mode trunkswitchport trunk allowed vlan add 1,10-11switchport trunk pvid vlan 1loopback-detection enableexit9.静态链路聚合配置link-aggregation 1 manualint ten 0/25duplex fulllink-aggregation 1 manualexitint ten 0/26duplex fulllink-aggregation 1 manualexitint link-aggregation1switchport mode trunkswitchport trunk allowed vlan add 1,10-11switchport trunk pvid vlan 10no telnet server enable端口范围配置int range gi 0/7-10switchport mode trunkswitchport trunk allowed vlan add 1,10-1110.vlan虚接口和地址、路由配置int vlan 10ip ad x.x.x.x 255.255.255.0exitip route 0.0.0.0 0.0.0.0 x.x.x.x或者ip default-gateway x.x.x.x11.snmp和限源配置ip access-list standard snmp-acl10 permit host x.x.x.xexitsnmp-server startsnmp-server view default 1.2 includesnmp-server view default 1.0.8802 includesnmp-server view default 1.1.2 includesnmp-server view default 1.3.111 includesnmp-server view default 1.3.6.1 includesnmp-server group 1 v3 authpriv read default notify defaultsnmp-server user admin 1 v3 auth sha password 7 123 encrypt des password 7 456 snmp-acl12.端口隔离配置isolate group 1interface gi 0/1 bothinterface gi 0/2 bothinterface gi 0/3 bothexit13.保存配置wirtecopy runnning-config startup-config重启设备生效14.重启设备reload15.enable与进入配置视图MPenableMP#MP#config terminal16.enabel密码配置enable password 123XX17.dhcp配置service dhcpip dhcp excluded-addess 192.168.10.1 192.168.10.100ip dhcp poolnetwork 192.168.10.0 255.255.255.0default-router 192.168.10.1option 43 hex 800478C0280C18.STP配置spanning-tree mode mstpspanning-tree priority 4096int range gi 0/7-10spanning-tree portfast19.流量优先级标记class-map match-any VOIPmatch dscp efprority percent 8020.端口限速int range gi 0/7-10rate-limit in 1000000 1500000rate-limit out 1000000 150000021.配置归档管理archive configpatch flash:/config-archivemaximum 1022.日志发送logging host X.X.X.Xlogging trap informationallogging source-interface vlan 1023.设备诊断与网络通信检测show tech-support flash:/diagnostic.logping 8.8.8.8 source vlan 10traceroute 8.8.8.8 source vlan 1025.清除限制性地址clear mac-address-table restricted static26.设备查看命令show runshow run int g0/0/1show ip int bshow interface ethernet statusshow mac-address-tableshow ip dhcp bindingshow loggingshow vlanshow vlan 10show mac-address-table
迈普交换机配置学习
发布时间:2026/6/13 11:10:58
1.系统名称命名 hostname F1-SW012.系统钟配置clock timezone beijing 83.用户角色ssh和限源登录配置ip access-list standard denglu-acl10 permit host x.x.x.xexitrole audit-admindescription audit adminexitrole network-admindescription network adminexitrole network-operatordescription network operatorexitrole security-admindescription security adminexitlocal-user admin class managerservice-type sshprivilege 15password 7 123456exitline vty 0 4access-class denglu-acl inprotocol input sshlogin localexitip ssh serverssh server prefer-key diffie-hellman-group-exchange-sha256 diffie-hellman-group-exchange-sha1 diffie-hellman-group14-sha1ssh server perfer-stoc-hmac hmac-sha2-256ssh server perfer-identity-key ssh-rsa4.交换机逐流转发配置ip load-sharing per-flowipv6 load-sharing per-flow5.802.1X配置aaa server group radius radius1server x.x.x.x acct-port 1813 auth-port 1812 key 7 123exitdomain systemaaa authentication dot1x radius-group radius1aaa authentication login localaaa authorization login localaaa accounting dot1x start-stop radius-group radius1exit6.环路检测配置loopback-detection enableint gi 0/7shutdownswitchport access vlan 20spanning-tree bpdu guard enablespanning-tree portfast edgeport enableloopback-detection enable7.vlan和接口access和trunk配置vlan 10,19-20,100,1108.lldp配置lldp runint gi 0/7shutdownswitchport access vlan 20spanning-tree bpdu guard enablespanning-tree portfast edgeport enableloopback-detection enableexitint gi 0/8switchport access vlan 20spanning-tree bpdu guard enablespanning-tree portfast edgeport enableloopback-detection enableexitint gi 0/16switchport mode trunkswitchport trunk allowed vlan add 1,10-11switchport trunk pvid vlan 1loopback-detection enableexit9.静态链路聚合配置link-aggregation 1 manualint ten 0/25duplex fulllink-aggregation 1 manualexitint ten 0/26duplex fulllink-aggregation 1 manualexitint link-aggregation1switchport mode trunkswitchport trunk allowed vlan add 1,10-11switchport trunk pvid vlan 10no telnet server enable端口范围配置int range gi 0/7-10switchport mode trunkswitchport trunk allowed vlan add 1,10-1110.vlan虚接口和地址、路由配置int vlan 10ip ad x.x.x.x 255.255.255.0exitip route 0.0.0.0 0.0.0.0 x.x.x.x或者ip default-gateway x.x.x.x11.snmp和限源配置ip access-list standard snmp-acl10 permit host x.x.x.xexitsnmp-server startsnmp-server view default 1.2 includesnmp-server view default 1.0.8802 includesnmp-server view default 1.1.2 includesnmp-server view default 1.3.111 includesnmp-server view default 1.3.6.1 includesnmp-server group 1 v3 authpriv read default notify defaultsnmp-server user admin 1 v3 auth sha password 7 123 encrypt des password 7 456 snmp-acl12.端口隔离配置isolate group 1interface gi 0/1 bothinterface gi 0/2 bothinterface gi 0/3 bothexit13.保存配置wirtecopy runnning-config startup-config重启设备生效14.重启设备reload15.enable与进入配置视图MPenableMP#MP#config terminal16.enabel密码配置enable password 123XX17.dhcp配置service dhcpip dhcp excluded-addess 192.168.10.1 192.168.10.100ip dhcp poolnetwork 192.168.10.0 255.255.255.0default-router 192.168.10.1option 43 hex 800478C0280C18.STP配置spanning-tree mode mstpspanning-tree priority 4096int range gi 0/7-10spanning-tree portfast19.流量优先级标记class-map match-any VOIPmatch dscp efprority percent 8020.端口限速int range gi 0/7-10rate-limit in 1000000 1500000rate-limit out 1000000 150000021.配置归档管理archive configpatch flash:/config-archivemaximum 1022.日志发送logging host X.X.X.Xlogging trap informationallogging source-interface vlan 1023.设备诊断与网络通信检测show tech-support flash:/diagnostic.logping 8.8.8.8 source vlan 10traceroute 8.8.8.8 source vlan 1025.清除限制性地址clear mac-address-table restricted static26.设备查看命令show runshow run int g0/0/1show ip int bshow interface ethernet statusshow mac-address-tableshow ip dhcp bindingshow loggingshow vlanshow vlan 10show mac-address-table