交换机配置操作手册.docx

上传人:b****4 文档编号:12146269 上传时间:2023-04-17 格式:DOCX 页数:13 大小:30.29KB
下载 相关 举报
交换机配置操作手册.docx_第1页
第1页 / 共13页
交换机配置操作手册.docx_第2页
第2页 / 共13页
交换机配置操作手册.docx_第3页
第3页 / 共13页
交换机配置操作手册.docx_第4页
第4页 / 共13页
交换机配置操作手册.docx_第5页
第5页 / 共13页
点击查看更多>>
下载资源
资源描述

交换机配置操作手册.docx

《交换机配置操作手册.docx》由会员分享,可在线阅读,更多相关《交换机配置操作手册.docx(13页珍藏版)》请在冰豆网上搜索。

交换机配置操作手册.docx

交换机配置操作手册

1.总体概述3

2.软件操作4

2.1.通过Console线缆连接Juniper设备4

2.2.设备启动5

2.3.设备重启5

2.4.JUNOS升级5

2.5.密码恢复6

3.JUNOSCLI模式8

4.Juniper设备的基本配置9

5.EX路由交换机初始配置向导EZSETUP11

6.端口配置11

7.VLAN配置12

8.VLAN路由端口(RVI)的配置13

9.路由配置14

1.总体概述

本文档为JuniperNetworks,Inc.编写。

用于说明JuniperEX基本命令配置。

更多的信息请参考下面的网站:

2.软件操作

JUNOS软件是专门为互联网设计的第一种路由交换操作系统。

它运行在Juniper网络公司的所有T-系列、M-系列和J-系列路由器和EX系列路由交换机上,而且目前正被部署在全球最大、增长最迅速的网络中。

Junos使用FreeBSD内核,模块化的设计,提供卓越的故障恢复能力并确保能够简单地集成IPv6、MPLS等新功能。

JUNOS软件提供的全套具有工业强度的路由协议、灵活的策略语言,可以高效地扩展以支持很大数量的网络接口和路由。

基于标准的JUNOS软件可以支持互联网路由协议,同时控制路由器、交换机及其接口并实现对各种规模的网络的系统管理。

简便易用的界面使您可以配置路由协议和接口属性、监控路由、检测并排除协议和网络连接故障。

本节将描述JUNOS的一些应急操作,这些操作都会影响设备的正常功能,操作时请谨慎使用:

⏹动

2.1.通过Console线缆连接Juniper设备

使用下面的步骤连接路由器的Console接口:

1.准备好Juniper设备自带的Console线缆(如果没有的话,请准备两个DB9-RJ45转接头和一条RJ45-RJ45反转线)

2.将Console线缆的DB9插头一头插到PC或者笔记本电脑的COM口上,另外一端插到Juniper设备的CONSOLE口上。

3.打开计算机中的终端软件工具。

例如:

CRT或者Windows自带的超级终端。

设置如下:

⏹端口:

选择第二步中Console线缆插入到PC上的端口,通常为COM1或者COM2

⏹波特率:

9600

⏹数据位:

8位

⏹停止位:

1位

⏹流控:

4.打开配置到的CRT或者超级终端,按“Enter”键,屏幕出现登陆的提示符,即连接成功。

如果没有显示,请检查线缆或者终端的配置是否正确。

如果出现任何现场无法解决的问题,请寻求JuniperTAC的帮助,参阅。

2.2.设备启动

加电启动Juniper设备。

系统第一次启动建议通过Console端口登陆。

启动完成后,看看到login提示符,输入用户名为root,缺省密码是空。

进入系统后输入cli命令进入Junoscommandlineinterface,可以进行设备调试。

如下例:

login:

root

Password:

Terminaltype?

[vt100]y

root%cli

root>

2.3.设备重启

Juniper设备重启必须按照下面的步骤进行操作:

1.用console设备连接到Juniper设备的CONSOLE端口上。

2.使用具有足够权限的用户名和密码登陆CLI命令行界面。

3.在提示符下输入下面的命令:

user@host>requestsystemreboot

4.等待console设备的输出,确认Juniper设备软件已经重新启动。

2.4.JUNOS升级

Juniper设备JUNOS软件升级必须按照下面的步骤进行操作:

1.用console设备连接到Juniper设备的CONSOLE端口上。

2.下载新的JUNOS软件,放置到FTP服务器上。

3.将新的JUNOS软件复制到Juniper设备上,使用下面的命令:

4.user@host>filecopyftp:

//username:

passwordfilename/var/tmp/filename

5.升级前,执行下面的命令备份旧的软件及设定:

user@host>requestsystemsnapshot

6.安装新的JUNOS软件:

user@host>requestsystemsoftwareaddsourcereboot

其中source参数为通过上一步骤保存在系统中的文件,如:

2.5.密码恢复

如果Juniper设备的Root密码丢失,而且没有其他的超级用户权限,那么就需要执行密码恢复,该操作需要中断Juniper设备的正常功能。

要进行密码恢复,请按照下面操作进行:

1.重新启动Juniper设备。

2.在启动过程中,console上出现下面的提示的时候,按任意键中断正常启动方式,然后再进入单用户状态:

Hit[Enter]tobootimmediately,oranyotherkeyforcommandprompt.

Booting[kernel]in9seconds...

okboot–s

3.执行密码恢复:

在以下提示文字后输入recovery

Enterfullpathnameofshellor'recovery'forrootpasswordrecoveryorRETURNfor/bin/sh:

recovery

NOTE:

OnceintheCLI,youwillneedtoenterconfigurationmodeusing

NOTE:

the'configure'commandtomakeanyrequiredchanges.Forexample,

NOTE:

toresettherootpassword,type:

NOTE:

configure

NOTE:

setsystemroot-authenticationplain-text-password

NOTE:

(enterthenewpasswordwhenasked)

NOTE:

commit

NOTE:

exit

NOTE:

exit

NOTE:

WhenyouexittheCLI,youwillbeaskedifyouwanttoreboot

NOTE:

thesystem

StartingCLI...

root>

4.进入配置模式,删除root密码:

root>configure

Enteringconfigurationmode

[edit]

root#deletesystemroot-authentication

root@router#commit

commitcomplete

[edit]

root@router#exit

Exitingconfigurationmode

root@kenny>exit

Rebootthesystem?

[y/n]y

Terminated

5.重新启动后,配置新的root密码。

Juniper设备恢复正常。

3.

JUNOSCLI模式

设备启动,登录进入系统后输入cli,即可进入JUNOSCLI模式,可进行设备调试。

JUNOSCLI有两种模式:

用户模式和配置模式,区分方法是他们的提示符不一样:

用户模式

user@host>#用户模式

在用户模式下可以显示路由器的配置、端口状态、路由信息等,它的提示符是>号。

登录后输入cli即进入路由器的用户模式:

host(ttyp6)

login:

root

Password:

---JUNOS9.1R1.8built2007-07-0700:

49:

05UTC

root@host%cli

root@host>

配置模式

user@host##配置模式

通过在用户模式使用edit命令进入配置模式,它的提示符是#号:

root@host>edit

Enteringconfigurationmode

[edit]

root@host#

配置生效和保存

Juniper设备配置保存可以有两种方式:

命令直接生效和保存:

用命令commit生效和保存配置

root@host#commit

commitcomplete

[edit]

root@host#

需要确认的命令生效和保存:

分两步完成,用命令commitconfirm保存配置后,不在固定时间(缺省为10分钟)内用commit命令确认,则系统自动回退原有配置,请注意:

root@host#commitconfirmed

commitconfirmedwillbeautomaticallyrolledbackin10minutesunlessconfirmed

commitcomplete

#commitconfirmedwillberolledbackin10minutes

[edit]

root@host#commit

commitcomplete

[edit]

root@host#

4.Juniper设备的基本配置

配置路由器设备名

user@host#setsystemhostnamehostname#配置设备名

root@host>edit

Enteringconfigurationmode

[edit]

root@host#setsystemhost-nameDEMO

[edit]

root@DEMO#commit

配置路由器Telnet服务

user@host#setsystemservicestelnet#配置telnet服务

root@host#setsystemservicestelnet?

Possiblecompletions:

<[Enter]>Executethiscommand

connection-limitMaximumnumberofallowedconnections(1..250)

rate-limitMaximumnumberofconnectionsperminute(1..250)

|Pipethroughacommand

[edit]

root@host#setsystemservicestelnet

[edit]

root@host#commit

配置路由器FTP服务

user@host#setsystemservicesftp#配置FTP服务

root@host#setsystemservicesftp?

Possiblecompletions:

<[Enter]>Executethiscommand

connection-limitMaximumnumberofallowedconnections(1..250)

rate-limitMaximumnumberofconnectionsperminute(1..250)

|Pipethroughacommand

[edit]

root@host#setsystemservicesftp

[edit]

root@host#commit

配置DNS服务器

user@host#setsystemname-serverdns-address#配置模式

通过在用户模式使用edit命令进入配置模式:

root@host#

[edit]

root@host#commit

5.

EX路由交换机初始配置向导EZSETUP

在第一次登录系统后,直接输入ezsetup命令进入初始配置向导,在此向导中,顺序输入:

∙系统名称hostname

∙系统密码

∙是否启用Telnet服务

∙是否启用SSH服务

∙交换机管理模式:

带外/带内

∙用缺省VLAN"default"管理

∙缺省VLAN的地址和网关

∙系统时间和日期

∙系统时区

∙保存配置

即可方便完成路由交换机初始配置

6.端口配置

配置物理端口

user@host#setinterfacege-slot/pic/portdescriptiondescription

#配置端口描述

user@host#setinterfacege-slot/pic/portmtumtu-number

#配置端口MTU

user@host#setinterfacege-slot/pic/portspeedport-speed

#配置端口速率

user@host#setinterfacege-slot/pic/portduplexport-duplex

#配置端口双工

root@host>edit

Enteringconfigurationmode

[edit]

root@host#setinterfacesge-3/0/0description“to_BJ-4200-1”

[edit]

root@host#setinterfacesge-3/0/0mtu1400

[edit]

root@host#setinterfacesge-3/0/0speed1000

[edit]

root@host#setinterfacesge-3/0/0duplexfull

[edit]

root@host#commit

7.VLAN配置

配置VLAN

user@host#setinterfacesnameunit0familyethernet-switchingport-modeaccess|trunk

#配置端口的VLAN模式(trunk或access)

user@host#setinterfacesnameunit0familyethernet-switchingvlanmembersall|number

#配置trunk端口的允许通过的VLAN

user@host#setvlansvlan-namevlan-idnumber

#配置VLAN

user@host#setvlansvlan-nameinterfaceinterface_name

或是:

user@host#setinterfacesinterface-nameunit0familyethernet-switchingvlanmembersvlan-nameorvlan-id

#添加端口到特定VLAN

user@host#showvlansvlan-namedetail

#查看VLAN信息

root@host>edit

Enteringconfigurationmode

[edit]

root@host#setvlanssalesvlan-id100

[edit]

root@host#setvlanssalesinterfacege-0/0/1

#or

[edit]

root@host#setinterfacesge-0/0/1unit0familyethernet-switchingvlanmemberssales

[edit]

root@host#commit

8.VLAN路由端口(RVI)的配置

配置VLAN路由端口

user@host#setinterfacesvlanunitnumberfamilyinetaddress

#配置RVI端口和地址

user@host#setvlansvlan_namel3-interfacevlan.unit-number

#绑定RVI端口到某个VLAN

user@host#showvlans

user@host#showinterfaceterse

user@host#showEthernet-switchinginterface

#查看VLAN和端口信息

root@host>edit

Enteringconfigurationmode

[edit]

root@host#

[edit]

root@host#setvlanssalesl3-interfacevlan.100

[edit]

root@host#commit

9.路由配置

配置静态路由

user@host#setrouting-optionsstaticroutenetwork/masknext-hopaddress

#配置静态路由

root@host>edit

Enteringconfigurationmode

[edit]

root@host#

[edit]

root@host#commit

配置静态路由

user@host#setrouting-optionsstaticroutenetwork/masknext-hopaddress

#配置静态路由

root@host>edit

Enteringconfigurationmode

[edit]

root@host#

[edit]

root@host#commit

展开阅读全文
相关资源
猜你喜欢
相关搜索

当前位置:首页 > 工程科技 > 能源化工

copyright@ 2008-2022 冰豆网网站版权所有

经营许可证编号:鄂ICP备2022015515号-1