当前位置:网站首页>Basic configuration commands of cisco switches (what is the save command of Huawei switches)
Basic configuration commands of cisco switches (what is the save command of Huawei switches)
2022-08-01 10:11:00 【Full stack programmer webmaster】
大家好,又见面了,我是你们的朋友全栈君.
一、调试命令
思科:
Switch#show run Displays all configuration commands
Switch#show ip inter brief Displays the status of all interfaces
Switch#show vlan brief 显示所有VLAN的信息
Switch#show version 显示版本信息
华为:
[Quidway]dis cur Displays all configuration commands
[Quidway]display interfaces Displays the status of all interfaces
[Quidway]display vlan all 显示所有VLAN的信息
[Quidway]display version 显示版本信息
二、接口配置命令
思科:
Switch(config)#interface f0/1 进入接口视图
Switch(config-if)#no shut This command brings up the interface
Switch(config-if)#description to server01 端口描述
Switch(config-if)#ip add 192.168.0.100 255.255.255.0 设置接口IP
华为:
[Quidway]interface e0/1 进入接口视图
[Quidway]undo shutdown This command brings up the interface
[Quidway]description to server02 端口描述
[Quidway]ip add 192.168.0.102 255.255.255.0 设置接口IP
三、VLAN配置命令:
思科:
建立和删除VLAN
Switch# vlan database
Switch(vlan)# vlan 20 name test20
Switch(vlan)# no vlan 20
Switch(vlan)# exit
将端口分配给一个VLAN
Switch(config)# interface f0/1
Switch(config-if)# switchport mode access
Switch(config-if)# switchport access vlan 20
设置VLAN TRUNK
Switch(config)# interface f0/24
Switch(config-if)# switchport mode trunk
Switch(config-if)#switchport trunk allow vlan {ID|All}
Switch(config-if)# switchport trunk encapsulation dot1q
华为:
建立和删除VLAN
[Quidway]vlan 30
[Quidway]undo vlan 30
将端口分配给一个VLAN
[Quidway]int ethernet0/1
[Quidway-Ethernet0/1]port access vlan 30( port default vlan 30)
或[Quidway]vlan 30
[Quidway-vlan3]port ethernet 0/1 在VLAN中增加端口
[Quidway-vlan3]port ethernet 0/1 to ethernet 0/4 在VLANAdd multiple consecutive ports to the
设置VLAN TRUNK
[Quidway]int e0/24
[Quidway-Ethernet0/24] port link-type trunk
[Quidway-Ethernet0/24]port trunk permit vlan {
ID|All}
四、端口镜像配置
思科:
配置镜像源端口
Switch(config)#monitor session 1 source interface gigabitEthernet 0/2 - 5 rx
The last parameter of the above command:
both Monitor bidirectional data,默认为both
rx 接收
tx 发送
配置镜像目的端口
Switch(config)#monitor session 1 destination interface gigabitEthernet 0/6
删除镜像端口
Switch(config)#no monitor session 1
华为:
将端口E0/2Configured to monitor the port
[Quidway]monitor-port Ethernet 0/2
端口E0/1配置为镜像端口
[Quidway]port mirror Ethernet 0/1
Or directly configure the monitoring port and mirroring port
[Quidway]port mirror Ethernet 0/1 observing-port Ethernet 0/2
删除镜像[Quidway]undo monitor-port
五、Set up secure remote access
Cisco Settingsvty安全访问:
R1(config)# access-list 1 permit 192.168.0.5
R1(config)# line vty 0 4
R1(config)# access-class 1 in
华为设置vty安全访问:
[Quidway]acl number 2000
rule 1 permit source 172.168.0.150 0
rule 2 deny
[Quidway]user-interface vty 0 4
acl 2000 inbound
六、NTP配置
思科:
Cisco6509#show clock 显示时间
Cisco6509#clock set 14:00:00 30 Sep 2011 设置时间
Cisco6509(config)#ntp server 202.198.0.102 Settings are synchronized with other time servers
Cisco6509(config)#clock timezone beijing +8 设置时区
华为:
[Quidway]dis clock 显示时间
[Quidway]clock datetime 23:30:00 2011/11/16 设置时间
[Quidway]ntp-service unicast-server 202.198.0.102 Settings are synchronized with other time servers
[Quidway]clock timezone E8 add 08:00:00 设置时区
七、静态路由配置
思科:
ip route <目的网段> <目的网段掩码><下一跳>
Cisco6509# ip route 0.0.0.0 0.0.0.0 10.1.1.2 静态路由
Cisco6509#ip route 0.0.0.0 0.0.0.0 192.168.0.1 150 The administrative distance of the floating static route is 150
华为:
[Quidway] ip route-static 0.0.0.0 0.0.0.0 10.65.1.2
[Quidway]ip route-static 0.0.0.0 0.0.0.0 192.168.0.1 preference 150
发布者:全栈程序员栈长,转载请注明出处:https://javaforall.cn/126979.html原文链接:https://javaforall.cn
边栏推荐
- STM32个人笔记-嵌入式C语言优化
- 【cartographer ros】十: 延时和误差分析
- ClickHouse入门介绍与其特性
- What are the common API security flaws?
- How I secured 70,000 ETH and won a 6 million bug bounty
- MacOS下postgresql(pgsql)数据库密码为什么不需要填写或可以乱填写
- 小程序毕设作品之微信美食菜谱小程序毕业设计成品(4)开题报告
- scrapy爬虫框架的使用
- Cross-domain network resource file download
- URL.createObjectURL、URL.revokeObjectURL、Uint8Array、Blob使用详解
猜你喜欢
Three chess (C language implementation)
C#/VB.NET 将PPT或PPTX转换为图像
2022年中盘点 | 产品打底,科技背书,广汽集团阔步向前
How to implement deep copy in js?
C language game - minesweeper
Meeting OA (Upcoming Meetings & All Meetings)
The use of scrapy crawler framework
[Software Architecture Mode] The difference between MVVM mode and MVC mode
Custom Types - Enums, Unions
opencv创建窗口—cv.namedWindow()
随机推荐
微信公众号授权登录后报redirect_uri参数错误的问题
[Cloud Residency Co-Creation] Huawei Cloud Global Scheduling Technology and Practice of Distributed Technology
gc的意义和触发条件
Py之yellowbrick:yellowbrick的简介、安装、使用方法之详细攻略
Introduction and application of pointers
世界第4疯狂的科学家,在103岁生日那天去世了
可视化——Superset安装与部署
Google Earth Engine APP——15行代码搞定一个inspector高程监测APP
Introduction and application of heap memory (including examples)
Cross-domain network resource file download
MFC实现交通图导航系统
C#/VB.NET 将PPT或PPTX转换为图像
我是如何保护 70000 ETH 并赢得 600 万漏洞赏金的
STM32 Personal Notes - Embedded C Language Optimization
Explain / Desc 执行计划分析
将Servlet项目改为SSM项目
rpm和yum
CTFshow,命令执行:web32
SkiaSharp 之 WPF 自绘 五环弹动球(案例版)
How to Steal $100 Million from the Perfect Smart Contract