Objective: Become familiar with the router configuration and the copy commands available in the Cisco IOS.
Lab Equipment: Router 1 from the eRouters menu
Background Reading: Lab Primer Lesson 1: Introduction to the Cisco Router Command-Line Interface
1. Connect to Router 1, and enter privileged mode.
Router>enable
Router#
Lab Equipment: Router 1 from the eRouters menu
Background Reading: Lab Primer Lesson 1: Introduction to the Cisco Router Command-Line Interface
1. Connect to Router 1, and enter privileged mode.
Router>enable
Router#
2. Display the active configuration in memory. The currently active configuration script running on the router is referred to as the running-config in the router’s CLI. Note that privileged mode is required to display the active configuration. The running configuration script is not automatically saved on a Cisco router and will be lost in the event of power failure. The running configuration must be manually saved with the copy command.
Router#show running-config
![](https://i-blog.csdnimg.cn/blog_migrate/bb50282eb679e729ce9a4d3df5dec6f7.png)
3. Try to display the configuration stored in NVRAM (known as the startup-config). You have not saved the configuration, so there is not one to show.
Router#show startup-config
![](https://i-blog.csdnimg.cn/blog_migrate/907784487e80b3e68781c422330036ef.png)
4. Copy the current active configuration to NVRAM. The current active configuration is in RAM; it should be saved so that the router will still boot up with the configuration in the event of a power outage.
Router#copy running-config startup-config
![](https://i-blog.csdnimg.cn/blog_migrate/5e4ab79f89fdea3de6e9d069e5969054.png)
5. Now, show the configuration stored in NVRAM.
Router#show startup-config
![](https://i-blog.csdnimg.cn/blog_migrate/5deeaad7dc14d11b32f368794dd43358.png)
6. If you decide that you would like to configure the router from scratch, you can erase the startup configuration and reload the router. This will enable you to completely delete all configurations on the router so that you can start from scratch. Type the command that will delete the configuration file in NVRAM. When prompted, confirm that you do want to erase the NVRAM file system by pressing the Y key.
Router#erase startup-config
![](https://i-blog.csdnimg.cn/blog_migrate/7da82852e29f122ac68b5bd873fbd352.png)
7. Now, type the command to reload the router, and press the Y key when prompted to confirm the reload.
Router#reload
![](https://i-blog.csdnimg.cn/blog_migrate/e23917b411dd1ce75141c624cf736d55.png)
![](https://i-blog.csdnimg.cn/blog_migrate/89956711c71f8ce5189d9a52e2698acc.png)
8. After the router reboots, look at the startup configuration file again. Because you did not save it before you reloaded, there is nothing there.
Router>enable
Router#show startup-config
![](https://i-blog.csdnimg.cn/blog_migrate/cca7528cbfc81fbddf01f01d5aa8e997.png)
9. Now, change the host name of the router to Boson.
Router#config terminal
Router(config)#hostname Boson
Boson(config)#exit
Boson#
![](https://i-blog.csdnimg.cn/blog_migrate/f63d05eed5a895d5c5ddaff34e392e22.png)
10. Save your router configuration, and reload the router. Again, press the Y key when prompted to confirm the reload.
Boson#copy run start
Boson#reload
![](https://i-blog.csdnimg.cn/blog_migrate/a7edda38808c407993bcf304c484959b.png)
11. After the router reloads, the host name of Boson appears in the prompt. If you run the show startup-config command, nothing appears.
Boson>enable
Boson#show startup-config
![](https://i-blog.csdnimg.cn/blog_migrate/dd96d7b651eaaf57d5e22695c62172df.png)
******************************************************
本文转自redking51CTO博客,原文链接:http://blog.51cto.com/redking/71596
,如需转载请自行联系原作者