Juniper EX Switch Ops: Initial Setup and Key Commands - 夜莺博客

Juniper EX Switch Ops: Initial Setup and Key Commands

Juniper EX switches behave differently from Cisco gear in several ways that surprise newcomers: there is no "enable" mode, configuration is commit-based, the default root login drops you into the shell rather than the CLI, and Virtual Chassis is a different concept from stacking. This article compiles the practical operations notes from an EX series field wiki — initial setup, everyday interface/VLAN/STP commands, Virtual Chassis essentials, and OSPF/AAA tuning tips — so you can manage EX switches confidently.

Basics: Defaults and Initial Setup

  • Default credentials: username root with no password (drops into the shell, not the CLI).
  • Default management IP: via DHCPv4.
  • Serial: RS-232 over RJ45, 115200 baud, 8 data bits, no parity, 1 stop bit, no flow control.
  • Native VLAN: 0, aka default.

System Housekeeping

request system storage cleanup          # clean up old files
set system arp aging-timer 300          # 5 min — match MAC timeout, avoid flooding
set system internet-options path-mtu-discovery   # lets BGP use larger packets

On ARP aging: the default 20 minutes on routers can cause flooding when the router tries to forward traffic but the MAC entry has timed out; 5 minutes matches the switch MAC address timeout.

VLAN and STP Quick Reference

set vlans sales vlan-id 10                      # create VLAN
set interfaces ge-0/0/1 unit 0 family ethernet-switching interface-mode access
set interfaces ge-0/0/1 unit 0 family ethernet-switching vlan members sales
show vlans interface <interface>                # verify
show spanning-tree interface                    # STP status

Note: on modern ELS switches (EX2300/EX3400 and all QFX), port-mode was renamed to interface-mode.

Virtual Chassis Essentials

Virtual Chassis (VC) connects multiple switches into a ring and manages them as one logical device, simplifying loop prevention (no STP needed inside the VC) and improving fault tolerance. With a preprovisioned config, mastership priority is assigned automatically based on the selected role. Each member shows up as a separate FPC; the master's MST LED is solid green, the backup's blinks green. Alarms for a member appear only on the master and the member itself.

Routing and AAA Tips

  • OSPF: set router ID, define areas, mark interface lo0.0 passive, and use interface-type p2p on point-to-point links for fast recovery on short breakages.
  • AAA: no enable mode; use authentication-order [ radius ] and login classes with permissions. Locally defined users are unnecessary when RADIUS/TACACS is configured.
  • Config archival: use system archival with transfer-on-commit for automatic backups.

For more Junos operations content, see our Junos EX flapped interface identification guide, the Junos SRX LAN troubleshooting article, and the multi-vendor CLI cheat sheet.

原文链接:https://wiki.hon.one/networking/juniper-ex