Apply Command on CISCO Router/Switch

Command

Apply

Use

This command applies any changes to the VLAN database but doesn’t exit the VLAN database. In fact, the exit command is a macro that runs the applycommand before exiting.

Syntax

Swtich(vlan)#apply

Example

In the below example we will enter the VLAN database, configure VLAN 99 and exit without using the exit or the apply command. Looking at show vlan brief afterwards, we see that VLAN99 was not created.

Cat1#vlan database
% Warning: It is recommended to configure VLAN from config mode,
as VLAN database mode is being deprecated. Please consult user
documentation for configuring VTP/VLAN in config mode.

Cat1(vlan)#vlan 99
VLAN 99 added:
Name: VLAN0099
Cat1(vlan)#^Z
Cat1#
02:36:15: %SYS-5-CONFIG_I: Configured from console by console
Cat1#show vlan br

VLAN Name Status Ports
—- ——————————– ——— ——————————-
1 default active Fa0/1, Fa0/2, Fa0/3, Fa0/4
Fa0/5, Fa0/6, Fa0/7, Fa0/8
Fa0/9, Fa0/10, Fa0/11, Fa0/12
Fa0/13, Fa0/14, Fa0/15, Fa0/16
Fa0/17, Fa0/18, Gi0/2
1002 fddi-default act/unsup
1003 token-ring-default act/unsup
1004 fddinet-default act/unsup
1005 trnet-default act/unsup

This time we will use the exit command after creating vlan 99. Now we see the vlan was properly created.

Cat1#vlan database
% Warning: It is recommended to configure VLAN from config mode,
as VLAN database mode is being deprecated. Please consult user
documentation for configuring VTP/VLAN in config mode.

Cat1(vlan)#vlan 99
VLAN 99 added:
Name: VLAN0099
Cat1(vlan)#apply
APPLY completed.
Cat1(vlan)#^Z
Cat1#
Cat1#show vlan

VLAN Name Status Ports
—- ——————————– ——— ——————————-
1 default active Fa0/1, Fa0/2, Fa0/3, Fa0/4
Fa0/5, Fa0/6, Fa0/7, Fa0/8
Fa0/9, Fa0/10, Fa0/11, Fa0/12
Fa0/13, Fa0/14, Fa0/15, Fa0/16
Fa0/17, Fa0/18, Gi0/2
99 VLAN0099 active
1002 fddi-default act/unsup
1003 token-ring-default act/unsup
1004 fddinet-default act/unsup
1005 trnet-default act/unsup
Subscribe
Notify of
guest

0 Comments
Inline Feedbacks
View all comments
0
Would love your thoughts, please comment.x
()
x