您好,欢迎访问三七文档
当前位置:首页 > 商业/管理/HR > 信息化管理 > Cisco-Nexus-N5K-简要配置
CiscoN5k-01配置脚本说明v1//1设定设备名称hostnameN5K-01//2设定账户权限usernameadminpasswordciscorolenetwork-adminusernameciscopasswordciscorolepriv-15注:Cisco取消了enablepassword设定。//4设定feature,很多特性默认是关闭的featurefex启用扩展n2k设备功能featuretelnet启用telnet到远程设备功能featureinterface-vlan启用SVI功能featurevrrp启用VRRP虚拟网关功能featuredhcp启用DHCPSnooping功能,IPSourceGuard//5定义FEX扩展设备fex101定义一个FEX号码为101,类似定义vlanfex102interfaceEthernet1/1switchportmodefex-fabric设定端口属性为FEX连接属性fexassociate101设定连接的fex号码,在连接成功后,以E101/1/X表示扩展端口noshutinterfaceEthernet1/2switchportmodefex-fabricfexassociate102noshut//6设定捆绑端口inte1/31-32将e1/31-32口进行捆绑。channel-group1modeon设定捆包号1,模式强制switchportswitchportmodetrunknoshut//7设定port-channelintpo1捆绑号1switchportswitchporttrunkencapsulationdot1qNexusTrunk协议只支持dot1q,可以不写这一条switchportmodetrunkswitchporttrunkallowedvlanall设定允许通过的vlanid。默认所有noshut//8创建vlanvlan10创建vlan10stateactive状态启用noshut//9生成树配置spanning-treemoderapid-pvst启用快速pvst,spanning-treevlan1,10priority4096设定pvst的优先级,确保n5k-01为root,优先级高值越小spanning-treevlan1,10priority4096//10设定SVI端口和vrrpinterfacevlan10ipaddress192.168.10.253255.255.255.0noshutvrrp10VRRP号和vlan号保持一致address192.168.10.254浮动地址preempt设定抢占模式priority110设定优先级noshutinterfacevlan1ipaddress192.168.1.253255.255.255.0noshutvrrp1address192.168.1.254preemptpriority110noshut//11设定管理地址(带外管理)interfacemgmt0默认管理接口ipaddress1.1.1.1/8//12设置SNMP字符串snmp-servercommunityABCDROsnmp-servercommunityABCDRW//13设定vty连接控制ipaccess-listVTY_ACCESS10permitip192.168.10.00.0.0.255any允许192.168.250.0/2420permitipanyany允许所有(测试用)linevtyexec-timeout5telnet登入后闲置超时时间ipaccess-classVTY_ACCESSin将控制列表引用到vty端口,限制登录网段。lineconexec-timeout20//14noipdomain-lookup不做域名检查
本文标题:Cisco-Nexus-N5K-简要配置
链接地址:https://www.777doc.com/doc-5752526 .html