
Tất cả các hướng dẫn bên dưới sẽ được thực hiện trên Router R0
- Chuyển sang chế độ cấu hình cho router với lệnh configure terminal
Router#configure terminal
Enter configuration commands, one per line. End with CNTL/Z.
Router(config)#
- Đặt Banner cho Router với lệnh banner motd
Router(config)#banner motd #Enter TEXT message. End with the character '#'.Chao mung den voi hocict.edu.vn#Router(config)#
Trong đó dấu # báo kết thúc lời chào.
- Đặt Hostname cho Router với lệnh hostname
Mặc định Router sẽ có tên là Router và theo sau nó là dấu > nếu trong chế độ User Mode, dấu # nếu trong chế độ Previlege Mode. Để gán tên cho router ta sử dụng thông qua lệnh hostname.
Router(config)#hostname R0R0(config)#
- Đặt password cho Router khi chuyển sang chế độ Privilege
Mặc định khi chuyển sang chế độ Previlege Mode sẽ không yêu cầu mật khẩu, ta có thể cài đặt yêu cầu mật khẩu khi chuyển từ chế độ User Mode sang chế độ Previlege Mode.
R0(config)#enable password 123R0(config)#Với lệnh enable password thì mật khẩu sẽ đọc được trong khi ta xem lại cấu hình của router thông qua lệnh show running-configR0#show running-config
Building configuration...
Current configuration : 757 bytes
!
version 12.4
no service timestamps log datetime msec
no service timestamps debug datetime msec
no service password-encryption
!
hostname R0
!
!
!
enable password 123
!
!
!
!
!
!
no ip cef
no ipv6 cef
--More--
Nếu không muốn hiển thị mật khẩu trong khi xem lại cấu hình của router thì ta có thể cấu hình với lệnh enable secretR0(config)#enable secret 456R0(config)#R0#show running-config
Building configuration...
Current configuration : 784 bytes
!
version 12.4
no service timestamps log datetime msec
no service timestamps debug datetime msec
no service password-encryption
!
hostname R0
!
!
!
enable secret 5 $1$mERr$DqFv/bNKU3CFm5jwSLasx/
!
!
!
!
!
!
no ip cef
no ipv6 cef
--More--
- Đặt password cho Router khi cấu hình qua console
Mật khẩu này sẽ được yêu cầu khi ta cấu hình router qua cổng console
R0(config)#line console 0R0(config-line)#password hocictR0(config-line)#login
- Đặt password cho Route khi kết nối qua Telnet
Mật khẩu này sẽ được yêu cầu khi ta telnet vào router
Cấu hình địa chỉ IP cho interfacesR0(config)#line vty 0 4R0(config-line)#password hocictR0(config-line)#login
R0(config)#int s0/0/0 //chọn cổng serial 0/0/0R0(config-if)#ip address 192.168.3.5 255.255.255.252 //đặt địa chỉ IPR0(config-if)#clock rate 64000 //qui định tốc độ cho đầu cái DCER0(config-if)#no shut //chuyển sang trạng thái hoạt độngR0(config)#int fa0/0R0(config-if)#ip add 192.168.2.254 255.255.255.0R0(config-if)#no shutR0(config)#int fa0/1R0(config-if)#ip add 192.168.1.254 255.255.255.0R0(config-if)#no shut