Configuring Junos OS on the EX2300
EX2300 Switch Default Configuration
Each EX Series switch is programmed with a factory-default configuration that contains the values set for each configuration parameter when a switch is shipped. The default configuration file for an EX2300 switch configures Ethernet switching and storm control on all interfaces, configures Power over Ethernet (PoE) on all interfaces of models that provide PoE, and enables the LLDP, LLDP-MED, and RSTP protocols and IGMP snooping.
When you commit changes to the configuration, a new configuration file is created that becomes the active configuration. You can always revert to the factory-default configuration—EX2300 switches do not have LCD panel, use the CLI commands to revert to the factory-default configuration. See Reverting to the Default Factory Configuration for the EX Series Switch.
The factory-default configuration file is different for different EX2300 switch models.
The number of interfaces in the default configuration file depends on the number of ports in the EX2300 switch.
The poe
statement does not appear for models without
PoE.
Uplink ports on EX2300 switches except EX2300-C switches are
listed as ge-0/1/0
to ge-0/1/3
and xe-0/1/0
to xe-0/1/3
. Uplink ports on EX2300-C switches as ge-0/1/0
to ge-0/1/1
and xe-0/1/0
to xe-0/1/1
.
The following is the factory-default configuration file for an EX2300 switch with 24 ports with PoE capability that runs Junos OS Release 18.2R3 or later.
system { auto-snapshot; phone-home { server https://redirect.juniper.net; rfc-compliant; } services { ssh; netconf { ssh; rfc-compliant; yang-compliant; } } } protocols { lldp { interface all; } lldp-med { interface all; } igmp-snooping { vlan default; } rstp { interface ge-0/0/0; interface ge-0/0/1; interface ge-0/0/2; interface ge-0/0/3; interface ge-0/0/4; interface ge-0/0/5; interface ge-0/0/6; interface ge-0/0/7; interface ge-0/0/8; interface ge-0/0/9; interface ge-0/0/10; interface ge-0/0/11; interface ge-0/0/12; interface ge-0/0/13; interface ge-0/0/14; interface ge-0/0/15; interface ge-0/0/16; interface ge-0/0/17; interface ge-0/0/18; interface ge-0/0/19; interface ge-0/0/20; interface ge-0/0/21; interface ge-0/0/22; interface ge-0/0/23; interface xe-0/1/0; interface xe-0/1/1; interface xe-0/1/2; interface xe-0/1/3; interface ge-0/1/0; interface ge-0/1/1; interface ge-0/1/2; interface ge-0/1/3; } } forwarding-options { storm-control-profiles default { all; } } poe { interface all; } interfaces { ## For phone-home connectivity to PHS enable dhcp on vme and irb. vme { unit 0 { family inet { dhcp; } } } irb { unit 0 { family inet { dhcp; } } } ge-0/0/0 { unit 0 { family ethernet-switching { storm-control default; } } } ge-0/0/1 { unit 0 { family ethernet-switching { storm-control default; } } } ge-0/0/2 { unit 0 { family ethernet-switching { storm-control default; } } } ge-0/0/3 { unit 0 { family ethernet-switching { storm-control default; } } } ge-0/0/4 { unit 0 { family ethernet-switching { storm-control default; } } } ge-0/0/5 { unit 0 { family ethernet-switching { storm-control default; } } } ge-0/0/6 { unit 0 { family ethernet-switching { storm-control default; } } } ge-0/0/7 { unit 0 { family ethernet-switching { storm-control default; } } } ge-0/0/8 { unit 0 { family ethernet-switching { storm-control default; } } } ge-0/0/9 { unit 0 { family ethernet-switching { storm-control default; } } } ge-0/0/10 { unit 0 { family ethernet-switching { storm-control default; } } } ge-0/0/11 { unit 0 { family ethernet-switching { storm-control default; } } } ge-0/0/12 { unit 0 { family ethernet-switching { storm-control default; } } } ge-0/0/13 { unit 0 { family ethernet-switching { storm-control default; } } } ge-0/0/14 { unit 0 { family ethernet-switching { storm-control default; } } } ge-0/0/15 { unit 0 { family ethernet-switching { storm-control default; } } } ge-0/0/16 { unit 0 { family ethernet-switching { storm-control default; } } } ge-0/0/17 { unit 0 { family ethernet-switching { storm-control default; } } } ge-0/0/18 { unit 0 { family ethernet-switching { storm-control default; } } } ge-0/0/19 { unit 0 { family ethernet-switching { storm-control default; } } } ge-0/0/20 { unit 0 { family ethernet-switching { storm-control default; } } } ge-0/0/21 { unit 0 { family ethernet-switching { storm-control default; } } } ge-0/0/22 { unit 0 { family ethernet-switching { storm-control default; } } } ge-0/0/23 { unit 0 { family ethernet-switching { storm-control default; } } } xe-0/1/0 { unit 0 { family ethernet-switching { storm-control default; } } } xe-0/1/1 { unit 0 { family ethernet-switching { storm-control default; } } } xe-0/1/2 { unit 0 { family ethernet-switching { storm-control default; } } } xe-0/1/3 { unit 0 { family ethernet-switching { storm-control default; } } } ge-0/1/0 { unit 0 { family ethernet-switching { storm-control default; } } } ge-0/1/1 { unit 0 { family ethernet-switching { storm-control default; } } } ge-0/1/2 { unit 0 { family ethernet-switching { storm-control default; } } } ge-0/1/3 { unit 0 { family ethernet-switching { storm-control default; } } } } groups { junos-defaults { protocols { igmp { interface me0.0 { disable; } interface vme.0 { disable; } } } } } system { commit { factory-settings { reset-chassis-lcd-menu; reset-virtual-chassis-configuration; } } } chassis { redundancy { graceful-switchover; } } vlans { default { vlan-id 1; l3-interface irb.0; } }
The following is the factory-default configuration file for an EX2300 switch with 24 ports with PoE capability that runs a version of Junos OS release earlier than 18.2R3.
system { auto-snapshot; syslog { user * { any emergency; } file messages { any notice; authorization info; } file interactive-commands { interactive-commands any; } } commit { factory-settings { reset-virtual-chassis-configuration; reset-chassis-lcd-menu; } } } interfaces { ge-0/0/0 { unit 0 { family ethernet-switching { storm-control default; } } } ge-0/0/1 { unit 0 { family ethernet-switching { storm-control default; } } } ge-0/0/2 { unit 0 { family ethernet-switching { storm-control default; } } } ge-0/0/3 { unit 0 { family ethernet-switching { storm-control default; } } } ge-0/0/4 { unit 0 { family ethernet-switching { storm-control default; } } } ge-0/0/5 { unit 0 { family ethernet-switching { storm-control default; } } } ge-0/0/6 { unit 0 { family ethernet-switching { storm-control default; } } } ge-0/0/7 { unit 0 { family ethernet-switching { storm-control default; } } } ge-0/0/8 { unit 0 { family ethernet-switching { storm-control default; } } } ge-0/0/9 { unit 0 { family ethernet-switching { storm-control default; } } } ge-0/0/10 { unit 0 { family ethernet-switching { storm-control default; } } } ge-0/0/11 { unit 0 { family ethernet-switching { storm-control default; } } } ge-0/0/12 { unit 0 { family ethernet-switching { storm-control default; } } } ge-0/0/13 { unit 0 { family ethernet-switching { storm-control default; } } } ge-0/0/14 { unit 0 { family ethernet-switching { storm-control default; } } } ge-0/0/15 { unit 0 { family ethernet-switching { storm-control default; } } } ge-0/0/16 { unit 0 { family ethernet-switching { storm-control default; } } } ge-0/0/17 { unit 0 { family ethernet-switching { storm-control default; } } } ge-0/0/18 { unit 0 { family ethernet-switching { storm-control default; } } } ge-0/0/19 { unit 0 { family ethernet-switching { storm-control default; } } } ge-0/0/20 { unit 0 { family ethernet-switching { storm-control default; } } } ge-0/0/21 { unit 0 { family ethernet-switching { storm-control default; } } } ge-0/0/22 { unit 0 { family ethernet-switching { storm-control default; } } } ge-0/0/23 { unit 0 { family ethernet-switching { storm-control default; } } } ge-0/1/0 { unit 0 { family ethernet-switching { storm-control default; } } } xe-0/1/0 { unit 0 { family ethernet-switching { storm-control default; } } } ge-0/1/1 { unit 0 { family ethernet-switching { storm-control default; } } } xe-0/1/1 { unit 0 { family ethernet-switching { storm-control default; } } } ge-0/1/2 { unit 0 { family ethernet-switching { storm-control default; } } } xe-0/1/2 { unit 0 { family ethernet-switching { storm-control default; } } } ge-0/1/3 { unit 0 { family ethernet-switching { storm-control default; } } } xe-0/1/3 { unit 0 { family ethernet-switching { storm-control default; } } } } forwarding-options { storm-control-profiles default { all; } } protocols { lldp { interface all; } lldp-med { interface all; } igmp-snooping { vlan default; } rstp { interface ge-0/0/0; interface ge-0/0/1; interface ge-0/0/2; interface ge-0/0/3; interface ge-0/0/4; interface ge-0/0/5; interface ge-0/0/6; interface ge-0/0/7; interface ge-0/0/8; interface ge-0/0/9; interface ge-0/0/10; interface ge-0/0/11; interface ge-0/0/12; interface ge-0/0/13; interface ge-0/0/14; interface ge-0/0/15; interface ge-0/0/16; interface ge-0/0/17; interface ge-0/0/18; interface ge-0/0/19; interface ge-0/0/20; interface ge-0/0/21; interface ge-0/0/22; interface ge-0/0/23; interface ge-0/1/0; interface xe-0/1/0; interface ge-0/1/1; interface xe-0/1/1; interface ge-0/1/2; interface xe-0/1/2; interface ge-0/1/3; interface xe-0/1/3; } } poe { interface all; }
See Also
Connecting and Configuring an EX Series Switch (CLI Procedure)
Using the CLI, set the following parameter values in the console server or PC:
Baud rate—9600
Flow control—None
Data—8
Parity—None
Stop bits—1
DCD state—Disregard
There are two ways to connect and configure an EX Series switch: one method is through the console by using the CLI and the other is by using the J-Web interface.
EX2200-24T-4G-DC switches do not support switch connection and configuration through the J-Web interface.
This topic describes the CLI procedure.
To run the ezsetup
script, the switch must
have the factory-default configuration as the active configuration.
If you have configured anything on the switch and want to run ezsetup
, revert to the factory-default configuration. See Reverting to the Default Factory Configuration for
the EX Series Switch.
To connect and configure the switch from the console by using the CLI:
You can now log in with the CLI or the J-Web interface to continue configuring the switch. If you use the J-Web interface to continue configuring the switch, the Web session is redirected to the new management IP address. If the connection cannot be made, the J-Web interface displays instructions for starting a J-Web session.
See Also
Connecting and Configuring an EX Series Switch (J-Web Procedure)
There are two ways to connect and configure an EX Series switch: one method is through the console by using the CLI and the other is by using the J-Web interface.
Starting in Junos OS Release 19.2R1, J-Web supports EX4650 switches.
This topic describes the J-Web procedure.
Before you begin the configuration, enable a DHCP client on the management PC that you will connect to the switch so that the PC can obtain an IP address dynamically.
To connect and configure the switch by using the J-Web interface:
You can now log in by using the CLI or the J-Web interface to continue configuring the switch.
If you use the J-Web interface to continue configuring the switch, the Web session is redirected to the new management IP address. If the connection cannot be made, the J-Web interface displays instructions for starting a J-Web session.
Reverting to the Default Factory Configuration for the EX Series Switch
With EX Series switches, if for any reason the current active configuration fails, you can revert to the factory-default configuration.
You can also roll back to a previous configuration, as described in Rolling Back Junos OS Configuration Changes, or revert to the rescue configuration, as described in Reverting to the Rescue Configuration for the EX Series Switch.
If you have lost the root password, it is not necessary to revert to the factory-default configuration to reset it. See Recovering the Root Password on Switches.
The factory-default configuration contains the basic configuration settings for the switch. This is the first configuration of the switch and it is loaded when the switch is first powered on. For the factory-default configuration file for your switch, see the hardware documentation for your switch.
You can run the EZsetup script to complete the initial configuration of the switch after reverting to the factory-default configuration. (The EZsetup script is available only on fixed configuration switches, it is not available on modular switches.) For information on completing the initial configuration using either the CLI or the J-Web interface, see Connecting and Configuring an EX Series Switch (CLI Procedure) or Connecting and Configuring an EX Series Switch (J-Web Procedure).
You can revert to the factory-default configuration by using the Menu
button to the right of the LCD panel on switches with LCD panel or by using the
request system zeroize
operational command or the load
factory-default
configuration command. (If your switch model does not have an LCD
panel, use these commands.) You can also use the load factory-default
command
to revert to the factory-default configuration file that contains all default settings
except the root password setting, which is retained.
These procedures are described in the following sections:
After resetting the factory default configuration either through the CLI or Factory Reset/Port mode button, the previous host name of the device is not reset. The host name can only be changed by configuring a new hostname or rebooting the device.
- Reverting to the EX Series Switch Factory-Default Configuration Using the request system zeroize Command
- Reverting to the EX Series Switch Factory-Default Configuration Using the load factory-default Command
- Reverting to the Factory-Default Configuration Using the EX Series Switch LCD Panel
- Reverting to the Factory-Default Configuration Using the Factory Reset/Mode button on EX2300, EX3400, and EX4300-48MP Switches
Reverting to the EX Series Switch Factory-Default Configuration Using the request system zeroize Command
The request system zeroize
command is a standard
Junos OS operational mode command that removes all configuration
information and resets all key values. The operation unlinks all user-created
data files, including customized configuration and log files, from
their directories. The switch then reboots and reverts to the factory-default
configuration.
To completely erase user-created data so that it is unrecoverable,
use the request system zeroize media
command.
Before issuing request system zeroize
, use the
request system snapshot
command to back up the files currently used to run the switch to a secondary device.
Using the zeroize command will destroy Junos and OAM partitions and the switch may not boot.
To recover from a failed software installation, see Recovering from a Failed Software Installation.
To revert to the factory-default configuration by using
the request system zeroize
command:
Reverting to the EX Series Switch Factory-Default Configuration Using the load factory-default Command
The load factory-default
command is a standard Junos OS
configuration command that replaces the current active configuration
with the factory-default configuration (except the root password setting,
which by default is not set but which you must set in order to commit
the new configuration in this procedure).
If you want to run the EZsetup script to complete the initial
configuration of the switch after you revert to the factory-default
configuration, do not use the load factory-default
command.
Instead do the reversion using either the LCD panel or the request
system zeroize
command. If you use the load factory-default
command to revert to the factory-default configuration, the configuration
for the root password is retained and the EZsetup script will not
run. (The EZsetup script is available only on fixed configuration
switches, it is not available on modular switches.)
The load factory-default
command by itself
is not supported on EX3300, EX4200, EX4500, and EX4550 switches configured
in a Virtual Chassis.
To revert to the factory-default configuration by using the load factory-default
command:
If you use this procedure, you must delete the system
commit factory settings, set the root password, and commit the configuration.
These steps are not required when you revert to the factory-default
configuration by using request system zeroize
. Also, the auto-image-upgrade
statement is not added to the configuration
when you use this procedure; it is added to the
configuration when you use request system zeroize
.
- [edit] user@switch#
load factory-default
- [edit] user@switch#
delete system commit factory-settings
- [edit] user@switch#
set system root-authentication plain-text-password
- [edit] user@switch#
commit
- Check the member ID and primary-role priority with the
show virtual-chassis
command and check to see whether there are remaining settings for uplink VCPs by using theshow virtual-chassis vc-port
command.
Reverting to the Factory-Default Configuration Using the EX Series Switch LCD Panel
To set the switch to the factory-default configuration, for EX Series switches, you can use the LCD panel and buttons on the front panel of the switch. If the EX Series switch model does not have an LCD panel, use one of the procedures described in the following sections.
To revert a member switch of a Virtual Chassis to the factory-default configuration, first disconnect the cables connected to the Virtual Chassis ports (VCPs) to avoid affecting Virtual Chassis configuration parameters (member ID, primary-role priority, and setting of VCP uplinks) on other members. See Disconnect a Fiber-Optic Cable, Disconnecting a Virtual Chassis Cable from an EX4200 Switch, or Disconnecting a Virtual Chassis Cable from an EX4500 Switch.
To revert to the factory-default configuration by using the LCD panel:
- Press the Menu button until you see MAINTENANCE MENU on the panel.
- Press the Enter button.
- Press Menu until you see FACTORY DEFAULT.
- Press Enter. The display says RESTORE DEFAULT?
- Press Enter. The screen flashes FACTORY DEFAULT IN PROGRESS and returns to the idle menu.
- Complete the initial configuration of the switch. See Connecting and Configuring an EX Series Switch (CLI Procedure) or Connecting and Configuring an EX Series Switch (J-Web Procedure).
Reverting to the Factory-Default Configuration Using the Factory Reset/Mode button on EX2300, EX3400, and EX4300-48MP Switches
To set the EX2300 switches except the EX2300-24MP and EX2300-48MP switches, EX2300-C switches, EX3400 switches, and EX4300-48MP switches to the factory-default configuration, use the Factory Reset/Mode button located on the far right side of the front panel.
To revert a member switch of a Virtual Chassis to the factory-default configuration, disconnect the cables connected to the VCPs to avoid affecting Virtual Chassis configuration parameters (member ID, primary-role priority, and setting of VCP uplinks) on other members (see Disconnect a Fiber-Optic Cable).
To revert to the factory-default configuration by using the Factory Reset/Mode button:
- Press the Factory Reset/Mode button for 10 seconds. The switch transitions into factory-default configuration, the console displays committing factory default configuration, and the Link/Activity LED on the RJ-45 network ports and the uplink ports is lit steadily in green color.
- Press the Factory Reset/Mode button for 10 more seconds. The switch transitions into initial setup mode, the console displays committing ezsetup config, and the Link/Activity LED on the RJ-45 network ports and the uplink ports blink in green color.
The Factory Reset/Mode button is enabled by default. You can disable the button using the CLI.
To disable the Factory Reset/Mode button, run the commands:
[edit] user@switch#
set chassis config-button no-clear
[edit] user@switch#
commit
To enable the Factory Reset/Mode button, run the commands:
[edit] user@switch#
delete chassis config-button no-clear
[edit] user@switch#
commit
Change History Table
Feature support is determined by the platform and release you are using. Use Feature Explorer to determine if a feature is supported on your platform.