创建MDC相当于构造了一台新的物理设备。创建后必须要启动MDC,MDC才能正常运行,相当于给设备上电启动。
执行mdc start命令后,MDC开始启动,并进入自动配置过程。请使用switchto mdc命令登录该MDC,确保该MDC的自动配置过程已经结束。如果网络中没有部署自动配置环境,请根据设备提示信息,使用<Ctrl+C>或<Ctrl+D>快捷键结束自动配置过程。关于自动配置的详细介绍请参见“基础配置指导”中的“自动配置”。
MDC创建并启动成功后,就可以当作一台独立设备使用了。如果用户当前已经登录了缺省MDC,可以通过以下方式来登录非缺省MDC,借用用户和缺省MDC之间的物理连接和会话连接来访问MDC。此时,命令行视图将从缺省MDC的系统视图切换到指定MDC的用户视图。
只有MDC处于active状态时,才允许使用该命令来登录MDC |
通过以上方式登录MDC后,可以给MDC的管理以太网接口配置IP地址,或者在MDC上创建VLAN接口并配置IP地址,并确保访问终端和MDC之间路由可达。这样,访问终端就可以直接使用Telnet或SSH等方式登录MDC了。
用户登录MDC后,可以在MDC的用户视图执行switchback或quit命令来退出登录。此时,命令视图将从当前MDC的用户视图返回到缺省MDC的系统视图。
S12510-X通过IRF(智能弹性架构)技术将多台设备虚拟成一台,而你提到的“把部分板卡逻辑成两台交换机”正是IRF的拆分场景,对应的操作其实是在IRF堆叠系统中,从主设备切换登录到成员设备(即逻辑上的另一台交换机)进行管理。
当你面对一台由多台物理设备(如两台S12510-X)组成的IRF堆叠系统时,它在外界看来就是一台逻辑交换机。要登录到其中的某台“物理交换机”(在IRF中称为“成员设备”)进行配置或查看信息,需要使用以下命令:
查看当前堆叠成员
首先登录到IRF系统(通常登录的是主设备Master),执行以下命令查看所有成员设备及其编号:
切换登录到指定成员设备
使用 switchto 命令,并指定目标设备的成员编号,即可从当前设备切换到该成员设备的命令行界面:
<H3C-Sysname> 变为 <H3C-Sysname_2>),表示你已经成功进入该成员设备的配置视图。返回主设备
在完成对该成员设备的操作后,你可以通过输入以下命令返回到主设备的命令行界面:
配置范围:通过 switchto 登录成员设备后,你在此进行的所有配置只会保存在该成员设备本地,而不会自动同步到主设备或其他成员。因此,你提到“把部分板卡逻辑成两台交换机”这个目标,正是通过将不同板卡规划到不同成员设备下,并在各自的设备上进行独立配置来实现的。
管理地址:在IRF系统中,通常只有一个全局的管理IP地址。切换设备后,该成员设备自身也必须配置一个管理IP地址,才能通过网络直接登录进行管理。switchto 命令是用于从IRF系统内部进行“跳转”的方法。
某公司有一台12500-F系列交换机,现要求将这台设备虚拟成三台独立的设备:MDC A,MDC B,MDC C,分给该公司的A、B、C三个不同部门用作接入公司网络的网关。使得各部门可以独享设备的表项资源,并且可以根据各部门的业务需求分配设备的磁盘空间、内存、CPU资源,未分配的使用设备缺省值。
图1-2 MDC典型配置组网图

(1) 创建并配置MDC A,供部门A使用。
# 创建MDC A。
<Device> system-view
[Device] mdc MDCA
Executing this command will create MDC MDCA ID 2 and empty folder /mdc/mdc2 in the root directory of the storage media. Continue? [Y/N]:y
MDC created successfully.
# 在缺省MDC中删除业务板2,并将该业务板分配给MDC A。
[Device-mdc-2-MDCA] mdc Admin
[Device-mdc-1-Admin] undo location slot 2
The configuration associated with the specified slot of MDC will be lost. Continue? [Y/N]:y
[Device-mdc-1-Admin] mdc MDCA
[Device-mdc-2-MDCA] location slot 2
# 为MDC A分配接口Ten-GigabitEthernet2/0/1~Ten-GigabitEthernet2/0/48。
[Device-mdc-2-MDCA] allocate interface ten-gigabitethernet 2/0/1 to ten-gigabitethernet 2/0/48
The configurations of the interfaces will be lost. Continue? [Y/N]:y
# 配置MDC A在主控板16和17上的磁盘使用上限均为40%。
[Device-mdc-2-MDCA] limit-resource disk slot 16 ratio 40
[Device-mdc-2-MDCA] limit-resource disk slot 17 ratio 40
# 启动MDC A。
[Device-mdc-2-MDCA] mdc start
It will take some time to start MDC...
MDC started successfully.
[Device-mdc-2-MDCA] quit
# 切换到MDC A,并按照提示信息键入CTRL_D进入MDC A的命令行界面进行配置。
[Device] switchto mdc MDCA
******************************************************************************
* Copyright (c) 2004-2014 Hangzhou H3C Tech. Co., Ltd. All rights reserved. *
* Without the owner's prior written consent, *
* no decompiling or reverse-engineering shall be allowed. *
******************************************************************************
Automatic configuration is running, press CTRL_D to break or press CTRL_B to
switch back to the default MDC.
<Device> system-view
# 将MDC A的名称修改为MDCA,以便和其它MDC区别。
[Device] sysname MDCA
# 配置MDC A 的网管口的IP地址、使能Telnet服务等基础配置,供用户远程登录MDC A。
[MDCA] interface M-GigabitEthernet 0/0/0
[MDCA-M-GigabitEthernet0/0/0] ip address 192.168.1.251 24
[MDCA-M-GigabitEthernet0/0/0] quit
[MDCA] telnet server enable
[MDCA] user-interface vty 0 63
[MDCA-line-vty0-63] authentication-mode none
[MDCA-line-vty0-63] user-role mdc-admin
# 从MDC A返回缺省MDC。
[MDCA-line-vty0-63] return
<MDCA> switchback
[Device]
(2) 创建并配置MDC B,供部门B使用。
# 创建MDC B。
[Device] mdc MDCB
Executing this command will create MDC MDCB ID 3 and empty folder /mdc/mdc3 in the root directory of the storage media. Continue? [Y/N]:y
MDC created successfully.
# 在缺省MDC中删除业务板4,并将该业务板分配给MDC B。
[Device-mdc-3-MDCB] mdc Admin
[Device-mdc-1-Admin] undo location slot 4
The configuration associated with the specified slot of MDC will be lost. Continue? [Y/N]:y
[Device-mdc-1-Admin] mdc MDCB
[Device-mdc-3-MDCB] location slot 4
# 为MDC B分配接口Ten-GigabitEthernet4/0/1~Ten-GigabitEthernet4/0/48。
[Device-mdc-3-MDCB] allocate interface ten-gigabitethernet 4/0/1 to ten-gigabitethernet 4/0/48
The configurations of the interfaces will be lost. Continue? [Y/N]:y
# 启动MDC B,并按照提示信息键入CTRL_D进入MDC B的命令行界面进行配置。
[Device-mdc-3-MDCB] mdc start
It will take some time to start MDC...
MDC started successfully.
[Device-mdc-3-MDCB] quit
# 切换到MDC B。
[Device] switchto mdc MDCB
******************************************************************************
* Copyright (c) 2004-2014 Hangzhou H3C Tech. Co., Ltd. All rights reserved. *
* Without the owner's prior written consent, *
* no decompiling or reverse-engineering shall be allowed. *
******************************************************************************
Automatic configuration is running, press CTRL_D to break or press CTRL_B to
switch back to the default MDC.
<Device> system-view
# 将MDC B的名称修改为MDCB,以便和其它MDC区别。
[Device] sysname MDCB
# 配置MDC B 的网管口的IP地址、使能Telnet服务等基础配置,供用户远程登录MDC B。
[MDCB] interface M-GigabitEthernet 0/0/0
[MDCB-M-GigabitEthernet0/0/0] ip address 192.168.2.252 24
[MDCB-M-GigabitEthernet0/0/0] quit
[MDCB] telnet server enable
[MDCB] user-interface vty 0 63
[MDCB-line-vty0-63] authentication-mode none
[MDCB-line-vty0-63] user-role mdc-admin
# 从MDC B返回缺省MDC。
[MDCB-line-vty0-63] return
<MDCB> switchback
[Device]
(3) 创建并配置MDC C,供部门C使用。
# 创建MDC C。
[Device] mdc MDCC
Executing this command will create MDC MDCC ID 4 and empty folder /mdc/mdc4 in the root directory of the storage media. Continue? [Y/N]:y
MDC created successfully.
# 在缺省MDC中删除业务板6,并将该业务板分配给MDC C。
[Device-mdc-4-MDCC] mdc Admin
[Device-mdc-1-Admin] undo location slot 6
The configuration associated with the specified slot of MDC will be lost. Continue? [Y/N]:y
[Device-mdc-1-Admin] mdc MDCC
[Device-mdc-4-MDCC] location slot 6
# 为MDC C分配接口Ten-GigabitEthernet6/0/1~Ten-GigabitEthernet6/0/48。
[Device-mdc-4-MDCC] allocate interface ten-gigabitethernet 6/0/1 to ten-gigabitethernet 6/0/48
The configurations of the interfaces will be lost. Continue? [Y/N]:y
# 配置MDC C的CPU权重为5,比MDC A和MDC B都低。
[Device-mdc-4-MDCC] limit-resource cpu weight 5
# 启动MDC C。
[Device-mdc-4-MDCC] mdc start
It will take some time to start MDC...
MDC started successfully.
[Device-mdc-4-MDCC] quit
# 切换到MDC C,并按照提示信息键入CTRL_D进入MDC C的命令行界面进行配置。
[Device] switchto mdc MDCC
******************************************************************************
* Copyright (c) 2004-2014 Hangzhou H3C Tech. Co., Ltd. All rights reserved. *
* Without the owner's prior written consent, *
* no decompiling or reverse-engineering shall be allowed. *
******************************************************************************
Automatic configuration is running, press CTRL_D to break or press CTRL_B to
switch back to the default MDC.
<Device> system-view
# 将MDC C的名称修改为MDCC,以便和其它MDC区别。
[Device] sysname MDCC
# 配置MDC C 的网管口的IP地址、使能Telnet服务等基础配置,供用户远程登录MDC C。
[MDCC] interface M-GigabitEthernet 0/0/0
[MDCC-M-GigabitEthernet0/0/0]ip address 192.168.3.253 24
[MDCC-M-GigabitEthernet0/0/0] quit
[MDCC] telnet server enable
[MDCC] user-interface vty 0 63
[MDCC-line-vty0-63] authentication-mode none
[MDCC-line-vty0-63] user-role mdc-admin
# 从MDC C返回缺省MDC。
[MDCC-line-vty0-63] return
<MDCC> switchback
[Device]
(1) 查看MDC是否存在并且运转正常。(此时,Device上应该有四台处于正常工作active状态的MDC)
<Device> display mdc
ID Name Status
----------------------------------
1 Admin active
2 MDCA active
3 MDCB active
4 MDCC active
(2) 模拟部门A的管理用户登录到MDC A,可以查看本设备的当前配置。
C:\> telnet 192.168.1.251
******************************************************************************
* Copyright (c) 2004-2014 Hangzhou H3C Tech. Co., Ltd. All rights reserved. *
* Without the owner's prior written consent, *
* no decompiling or reverse-engineering shall be allowed. *
******************************************************************************
<MDCA> display current-configuration
……配置文件信息略……
查看MDC是否存在并且运转正常。(此时,Device上应该有多台处于active状态的MDC) <Device> display mdc # 切换到MDC www。 [Device] switchto mdc www
查看MDC是否存在并且运转正常。(此时,Device上应该有多台处于active状态的MDC) <Device> display mdc # 切换到MDC www。 [Device] switchto mdc www
system-view
switchto mdc MDC名称
[H3C] switchto mdc MDC2
<MDC2>,表示已进入该逻辑交换机。switchback
<MDC2> switchback
[H3C]
display mdc
display current-configuration | include mdc
display mdc 详细信息
亲~登录后才可以操作哦!
确定你的邮箱还未认证,请认证邮箱或绑定手机后进行当前操作
举报
×
侵犯我的权益
×
侵犯了我企业的权益
×
抄袭了我的内容
×
原文链接或出处
诽谤我
×
对根叔社区有害的内容
×
不规范转载
×
举报说明