sync-peers destination

To add a peer switch to a switch profile, use the sync-peers destination command. To remove a peer from the switch profile, use the no form of this command.

sync-peers destination ipv4-address

no sync-peers destination ipv4-address

Syntax Description

destination
Specifies the destination IPv4 address of the peer switch.
ipv4-address
Destination IPv4 address of the peer switch in the format A . B . C . D .

Command Default

None

Command Modes

Switch profile configuration mode

Command History

Release
Modification
5.0(2)N1(1)
This command was introduced.

Usage Guidelines

Use this command to add the peer switch that will be included in the synchronization. You must have the IPv4 address of the peer switch. You can ensure that configuration synchronization is enabled on the peer switch by using the config sync command.

After you add a peer to a switch profile, you can add commands to the switch profile.

Peers maintain a configuration revision of their local configuration as well as the revision. After a network outage, when connectivity is established between the peer switches and the peers are reachable, each peer determines if any configuration in the switch needs to be synchronized with the other peer. Changed configurations will then be synchronized between the peers.

When you remove a peer from the switch profile, all configuration information about the peer is deleted from the local switch.

Examples

This example shows how to add a peer switch with IPv4 address 192.168.1.37 to a switch profile named s5010 on switch 1 of the peer:

Peer A

switch# config sync
Enter configuration commands, one per line. End with CNTL/Z.
switch(config-sync)# switch-profile s5010
Switch-Profile started, Profile ID is 1
switch(config-sync-sp)# sync-peers destination 192.168.1.37
switch(config-sync-sp)#
 

This example shows how to add a peer switch with IPv4 address 192.168.120.3 to a switch profile named s5010 on switch 2 of the peer:

Peer B

switch# config sync
Enter configuration commands, one per line. End with CNTL/Z.
switch(config-sync)# switch-profile s5010
Switch-Profile started, Profile ID is 1
switch(config-sync-sp)# sync-peers destination 192.168.120.3
switch(config-sync-sp)#
 

This example shows how to delete a peer with IPv4 address 192.168.1.37 from a switch profile named s5010 on switch 1 of the peer:

Peer A

switch# config sync
Enter configuration commands, one per line. End with CNTL/Z.
switch(config-sync)# switch-profile s5010
switch(config-sync-sp)# no sync-peers destination 192.168.1.37
switch(config-sync-sp)#
 

Related Commands

Command
Description
command
Adds, modifies, or removes commands from a switch profile.
copy running-config startup-config
Copies the running configuration to the startup configuration.
import
Imports the commands from the running configuration to the switch profile.
show switch-profile
Displays the switch profile created on the switch and its configuration revision.
show switch-profile status
Displays the switch profile status.
switch-profile
Configures a switch profile.