167
display diff startup-configuration { configfile file-name-d | current-configuration }
Views
Any view
Predefined user roles
network-admin
network-operator
Parameters
configfile file-name-s: Specifies the source configuration file for comparison.
configfile file-name-d: Specifies the target configuration file for comparison.
current-configuration: Specifies the running configuration. In the display diff
current-configuration command, this keyword specifies the source configuration for comparison. In
the display diff configfile file-name-s and display diff startup-configuration commands, this
keyword specifies the target configuration.
startup-configuration: Specifies the next-startup configuration. In the display diff
startup-configuration command, this keyword specifies the source configuration for comparison. In
the display diff configfile file-name-s and display diff current-configuration commands, this
keyword specifies the target configuration.
Examples
# Display the differences between startup.cfg and test.cfg.
<Sysname> display diff configfile startup.cfg configfile test.cfg
--- flash:/startup.cfg
+++ flash:/test.cfg
@@ -17,7 +17,9 @@
#
vlan 200
#
-vlan 300
+vlan 400
+#
+vlan 500
#
<Sysname>
The output shows that VLAN 200 is contained in both configurations, VLAN 400 and VLAN 500 are
contained only in test.cfg, and VLAN 300 is contained only in startup.cfg.
# Display the differences between the running configuration and the next-startup configuration.
<Sysname> display diff current-configuration startup-configuration
--- Current configuration
+++ Startup configuration
@@ -17,9 +17,7 @@
#
vlan 200
#
-vlan 400
-#
-vlan 500
+vlan 300