
juniper交换机配置指南.doc
11页juniper交换机配置指南开机后:login: rootLast login: Fri Jan 17 22:21:55 on ttyd0--- JUNOS 7.2R3.3 built 2002-03-23 02:44:36 UTCTerminal type? [vt100]
开启系统ftp服务命令:set system services ftp说明:系统默认是没有打开ftp功能的,只有打开ftp服务之后才能从网络上ftp到路由器配置SNMPset snmp community
[edit]user@host # show interfacesge-0/0/16 {unit 0 {family ethernet-switching;}}配置物理端口三层接口EX交换机物理接口可以支持三层路由接口功能,直接可以在接口上配置三层地址[edit]root@host# set interfaces ge-0/0/17 unit 0 family inet address192.168.20.1/24配置VLAN初始化配置时候,所有端口属于default VLAN,default vlan 的默认ID是0user@host# set interfaces name unit 0 family ethernet-switching port-mode access#配置端口的access模式,默认端口就是access模式user@host#set vlans vlan-name vlan-id number#配置VLAN分配vlan IDEX支持2种方式来配置access接口分配到VLAN,采用其中一种就可以实现端口VLAN的划分方式一:user@host#set vlans vlan-name interface interface_name直接在VLAN中添加多个物理端口方式二:或是在物理接口下:user@host#set interfaces interface-name unit 0 family ethernet-switching vlan membersvlan-name or vlan-id#添加端口到特定VLANuser@host# show vlans vlan-name detail#查看VLAN信息Example:root@host> editEntering configuration mode[edit]root@host# set vlans sales vlan-id 100[edit]root@host# set vlans sales interface ge-0/0/1#或者可以如下配置,实现相同的配置效果[edit]root@host# set interfaces ge-0/0/1 unit 0 family ethernet-switchingvlan members sales配置Vlan trunk配置端口作trunk端口,支持802.1Q的标准封装。
user@host# set interfaces name unit 0 family ethernet-switching port-mode trunk#配置端口的VLAN模式为trunk模式user@host# set interfaces name unit 0 family ethernet-switching vlan membersall|number#配置trunk端口的允许通过的VLAN,9.1版本目前不支持vlan-range,预期在9.2版本支持Example:root@host> editEntering configuration mode[edit]root@host#showinterfaces {ge-0/0/3 {unit 0 {family ethernet-switching {port-mode trunk;vlan {members [ orange blue ];}}}}ge-0/0/4 {unit 0 {family ethernet-switching {port-mode trunk;vlan {members [ 100 200 ];}}}}}配置 native-vlan-idEX在trunk端口下支持native-vlan 的配置:root@host> editEntering configuration mode[edit]root@host# set interface ge-0/0/8 unit 0 family Ethernet-switchnative-vlan-id purple[edit]root@host#show interfacege-0/0/8 {unit 0 {family ethernet-switching {port-mode trunk;vlan {members [ orange blue purple ];}native-vlan-id purple;}} 静态路由协议手工添加到路由表下一跳必须有效所以的配置在routing-options 级别Syntax:[edit]routing-options {static {defaults {static-options;}route destination-prefix {next-hop next-hop;qualified-next-hop address {metric metric;preference preference;}static-options;}}}Example:[edit]user@host# showrouting-options {static {route 0.0.0.0/0 next-hop 192.168.0.1;}}OSPF单区域[edit]user@host# set protocols ospf area 0 interface ge-0/0/0[edit]user@h。












