Global configuration mode is the Cisco IOS CLI mode for changing device-wide settings and entering more specific configuration modes. Enter it from privileged EXEC mode with configure terminal; the prompt changes to hostname(config)#. section 5.2.2 section 5.5
Use these commands to operate safely in the mode:
- hostname R1 changes the device name immediately, and no hostname R1 removes that configuration. section 5.2.2
- Use exit to return to privileged EXEC mode from global configuration mode; use end, Ctrl-C, or Ctrl-Z from configuration modes. section 5.2.2
- Run EXEC commands from configuration mode with do, such as do show clock; show clock alone is rejected there. section 5.2.2
- Use context-sensitive help, Tab completion, and unique abbreviated commands such as conf t to work efficiently. section 5.2.4
Changing a hostname
Router# configure terminal Router(config)# hostname R1 R1(config)# The prompt immediately reflects the new hostname, helping identify the device during network work. section 5.2.2
R1(config)# show clock #1
^ #1
% Invalid input detected at '^' marker. #1
R1(config)# do show clock #2
*03:06:22.892 UTC Fri Feb 10 2023 #2
#1 Show commands don’t work in global configuration mode.
#2 Uses do to execute the command in global configuration mode
Compare an invalid show command with do show clock to see how global configuration mode accesses EXEC operations. section 5.2.2
