Apply the following configuration on the first/master switch in your stack.
Define and modify a new virtual-chassis
set virtual-chassis preprovisioned
set virtual-chassis no-split-detection
set virtual chassis member 0 serial-number <serial-number> role routing-engine
set virtual chassis member 1 serial-number <serial-number> role routing-engine
Commit the new VC and exit configure
mode
commit
Request the port(s) of your choosing to be used as VC ports to connect your switch(es)
request virtual-chassis vc-port set pic-slot 0 port 30
request virtual-chassis vc-port set pic-slot 0 port 31
Apply the following configuration on any preceding switches in your stack.
Request the port(s) of your choosing to be used as VC ports to connect your switch(es)
request virtual-chassis vc-port set pic-slot 0 port 30
request virtual-chassis vc-port set pic-slot 0 port 31
At this point, you should be able to connect your switches together using the VC ports from each switch setup is the latter steps. The backup switch(es) will automatically become part of the stack once connected.
To verify the successful creation of your VC, run the following command. You should see the serial numbers of both devices and which one is Master (with the remainders being Backups)
show virtual-chassis
We will now configure each physical switch with its own management IP address with an additional, floating, IP address that will be the primary address used to manage the stack.
All configuration should be applied via the Master switch.
Remove the non-floating em0
interface
delete interface em0
Configuration Groups
will be used to define each stack member's hostname and management IP address information. The “member” number is in reference to the member number assigned to each switch's serial number in step 1; defining the VC.
set groups member0 when member member0
set groups member0 system host-name <physical-switch-hostname>
set groups member0 interfaces em0 unit 0 family inet address 192.168.55.201/24 master-only <-- this is the floating IP
set groups member0 interfaces em0 unit 0 family inet address 192.168.55.202/24
set groups member1 when member member1
set groups member1 system host-name <physical-switch-hostname>
set groups member1 interfaces em0 unit 0 family inet address 192.168.55.201/24 master-only <-- this is the floating IP
set groups member1 interfaces em0 unit 0 family inet address 192.168.55.203/24
Tell the stack to apply the latter groups
set apply-groups member0
set apply-groups member1
Set commit synchronization to ensure all switches in the stack always have the most recent configuration
set system commit synchronize
Set graceful-switchover
to enable the stack to change Master device without any interruption
set chassis redundancy graceful-switchover
Commit your changes to finalize the VC's IP configuration.
commit
Login to the 1st/master switch in your stack.
To verify your stack is functioning as expected, start by inspecting the VC
show virtual-chassis
Request a new session with the second switch in the stack
request session member 1
Request that switch 2 take over as the master
request chassis routing-engine master acquire
Show the VC again. You should see that switch 2 is now the master
show virtual-chassis
You can now run the latter process again to move master status back to switch 1.