[BSCI]配置IOS dhcp服务

 
1
 
 
R1底层配置
r1(config)#int f0/0
r1(config-if)#ip ad 192.168.1.1 255.255.255.0
r1(config-if)#no sh
r1(config-if)#exi
R1配置DHCP服务
定义地址池名字
r1(config)#ip dhcp pool VLAN100
定义网段
r1(dhcp-config)#network 192.168.1.0 /24  
定义默认网关
r1(dhcp-config)#default-router 192.168.1.254
定义dns服务器地址
r1(dhcp-config)#dns-server 218.30.19.40
定义域名服务器地址
r1(dhcp-config)#domain-name cisco.com
定义租期不限制
r1(dhcp-config)#lease inf
r1(dhcp-config)#exi
定义分配排除地址
r1(config)#ip dhcp excluded-address 192.168.1.254
打开R2和R3与R1互联的接口并开启dhcp
r2(config)#int f0/0
r2(config-if)#ip ad dhcp
r2(config-if)#no sh
得到获得ip消息
*Sep 14 13:54:06.431: %DHCP-6-ADDRESS_ASSIGN: Interface FastEthernet0/0 assigned DHCP address 192.168.1.2, mask 255.255.255.0, hostname r2
r3(config)#int f0/0
r3(config-if)#ip ad dhcp
r3(config-if)#no sh
*Sep 14 13:54:28.999: %DHCP-6-ADDRESS_ASSIGN: Interface FastEthernet0/0 assigned DHCP address 192.168.1.3, mask 255.255.255.0, hostname r3
在R1上查看现象
r1#sh ip dhcp pool VLAN100
Pool VLAN100 :
Utilization mark (high/low)    : 100 / 0
Subnet size (first/next)       : 0 / 0
Total addresses                : 254
Leased addresses               : 2
Pending event                  : none
1 subnet is currently in the pool :
Current index        IP address range                    Leased addresses
192.168.1.4          192.168.1.1      - 192.168.1.254     2
r1#sh ip dh bin
Bindings from all pools not associated with VRF:
IP address          Client-ID/              Lease expiration        Type
                    Hardware address/
                    User name
192.168.1.2         0063.6973.636f.2d63.    Infinite                Automatic
                    6139.322e.3064.6538.
                    2e30.3030.302d.4661.
                    302f.30
192.168.1.3         0063.6973.636f.2d63.    Infinite                Automatic
                    6139.332e.3066.3930.
                    2e30.3030.302d.4661.
                    302f.30

你可能感兴趣的:(ios,服务,DHCP,休闲,BSCI)