给设备使用密码加密
[yibo]user-interface console 0
[yibo-ui-console0]authentication-mode password
Please configure the login password (maximum length 16):yibo
使用用户名加密
[yibo]aaa
[yibo-aaa]local-user xx password cipher yy
Info: Add a new user.
调用
[yibo]user-interface console 0
[yibo-ui-console0]authentication-mode aaa
不同用户名不同权限
admin 最高权限
[yibo]aaa
[yibo-aaa]local-user admin privilege level 15 password cipher yibo
[yibo-aaa]local-user admin service-type terminal
[yibo-aaa]local-user guest service-type terminal
Info: Add a new user.
调用
[yibo]user-interface console 0
[yibo-ui-console0]authentication-mode aaa
针对密码设置权限
[yibo]user-interface console 0
[yibo-ui-console0]user privilege level 0
给接口配置IP地址
[wangcai]interface g0/0/0
[wangcai-GigabitEthernet0/0/0]ip address 192.168.1.1 24
[wangcai]interface g0/0/1
[wangcai-GigabitEthernet0/0/1]ip address 172.16.1.1/24
开启dhcp服务
[wangcai]dhcp enable
Info: The operation may take a few seconds. Please wait for a moment.done.
[wangcai]ip pool xx
Info: It's successful to create an IP address pool.
[wangcai-ip-pool-xx]network 192.168.1.0 mask 255.255.255.0
[wangcai-ip-pool-xx]gateway-list 192.168.1.1
[wangcai-ip-pool-xx]dns-list 8.8.8.8 114.114.114.114
[wangcai]dhcp enable
[wangcai]ip pool xx
[wangcai-ip-pool-xx]network 172.16.1.0 mask 255.255.255.0
Error:Please delete the network section first.
[wangcai-ip-pool-xx]gateway-list 172.16.1.1
Error:The network section should be within the subnet of the pool.
[wangcai-ip-pool-xx]dns-list 8.8.8.8 114.114.114.114
Info:Part of the domain-name-server IP has already exist.
调用
[wangcai]interface g0/0/1
[wangcai-GigabitEthernet0/0/1]dhcp select global
查看接口ip