当前位置:网站首页>在ENSP中配置DHCP服务器
在ENSP中配置DHCP服务器
2022-08-08 06:24:00 【捍胃者】

配置如图所示:
首先将实验拆分为设备加密以及配置dhcp
方便起见我们首先将设备改名为dhcp,代码如下:
<Huawei>system-view
[Huawei]sysname dhcp其次进入三a(即3A认证:验证用户的身份与可使用的网络服务,认证Authentication,授权Authorization,计费Accounting)对不同用户名设置不同的权限,admin用户名设置最高权限level15,guest用户名设置最低权限level0,最后接口调用,设置完成,代码如下:
[dhcp]aaa
[dhcp-aaa]local-user admin privilege level 15 password cipher admin
[dhcp-aaa]local-user admin service-type terminal
[dhcp-aaa]local-user guest privilege level 0 password cipher guest
Info: Add a new user.
[dhcp-aaa]local-user guest service-type terminal
[dhcp-aaa]quit
[dhcp]user-interface console 0
[dhcp-ui-console0]au
[dhcp-ui-console0]authentication-mode aaa然后,我们进入配置dhcp的第二阶段:
首先对路由器配置两个端口ip(因为有g0/0/0端口和g0/0/1端口),代码如下:
[dhcp]interface g0/0/0
[dhcp-GigabitEthernet0/0/0]ip address 192.168.1.1 24
[dhcp]interface g0/0/1
[dhcp-GigabitEthernet0/0/1]ip address 172.16.1.1 24接下来我会对每段配置代码加上注释,具体如下:
[dhcp]dhcp enable 【首先开启dhcp服务】
[dhcp]ip pool 11 【创建一个名为11的池子用于存放网段,可以理解为抽奖池需要放入奖品抽奖】
[dhcp-ip-pool-11]network 192.168.1.0 mask 255.255.255.0 【向持重放入网段用于调用ip,就是将奖品放入奖池中等待抽奖】
[dhcp-ip-pool-11]gateway-list 192.168.1.1 【加上对网络关口的配置,即与前面接口g0/0/0的ip一致】
[dhcp-ip-pool-11]dns-list 8.8.8.8 114.114.114.114 【由于服务器需要对域名进行解析为ip,因此要加上域名解析服务器;8.8.8.8是GOOGLE公司提供的DNS,114.114.114.114是国内移动、电信和联通通用的DNS】
【最后就是调用啦】
[dhcp]interface g0/0/0 【对g0/0/0接口下方,所以要进入g0/0/0接口】
[dhcp-GigabitEthernet0/0/0]dhcp select global 【调用全局的地址池】
【此接口同样的操作,不再赘述】
[dhcp]dhcp enable
[dhcp]ip pool 22
[dhcp-ip-pool-22]network 172.16.1.0 mask 255.255.255.0
[dhcp-ip-pool-22]gateway-list 172.16.1.1
[dhcp-ip-pool-22]dns-list 8.8.8.8 114.114.114.114
[dhcp]interface g0/0/1
[dhcp-GigabitEthernet0/0/1]dhcp select global
最后就是进入pc终端看看是否有拿到ip,以下还要进行几步简单的操作:
1.将ipv4静态改为DHCP,点击应用

2.在命令行中输入:ipconfig

最后可见我们的终端成功地拿到了ip!!!
四台终端重复这样的操作,检查一下是否都拿到ip


ok,好的,到此处我们的dhcp服务器算是搭建成功啦!
这是本人第一次写CSDN,欢迎各位大佬指正,也欢迎各位小伙伴们一起学习交流,如果觉得有用的话,还请点个赞哦~~
边栏推荐
- In 2022 China children's food market scale and development trend
- CV代码细节总结(一)
- 业务架构图是什么?
- [BSidesCF 2020] Had a bad day1
- Lightning Sixteen Whip
- 冰箱压缩机市场现状研究分析与发展前景预测
- 神经网络二分类问题范例,神经网络解决分类问题
- Industry Research: Analysis of the Status and Prospects of the Pension Insurance Market in 2022
- hyperledger-fabric documention official documentation
- 多神经网络模型联合训练,神经网络模型怎么训练
猜你喜欢

关系抽取论文阅读笔记

栈的实例应用

Lamp analysis: LED lamps are expected to reach $45.9 billion in 2028

P20 美颜相机的实现——基础铺垫2

关于剪枝对象的分类(weights剪枝、神经元剪枝、filters剪枝、layers剪枝、channel剪枝、对channel分组剪枝、Stripe剪枝)

【嵌入式Linux】SQLite数据库

CUDA10 installs a version of tensorflow that supports gpu

RCNN目标检测原文理解

Analysis of the status quo of the chemical industry: the polyolefin market consumption is nearly 200 million tons

hyperledger-fabric documention official documentation
随机推荐
设备行业研究报告:激光打印机市场现状及未来发展趋势
COSMIC: COmmonSense knowledge for eMotion Identification in Conversations
关系抽取论文阅读笔记
P21 美颜相机的实现——提速,重绘,撤回
@Autowired和@Resource区别
七.Redis 持久化之 AOF
九.Redis 集群(cluster 模式)
Error日志 ERROR: Failed building wheel for jsonnet
《Filter Pruning using Hierarchical Group Sparse》ICPR2020论文详解
MongoDB中的聚合-管道
四. Redis 事务、锁机制秒杀
3.SQL底层执行原理
基于深度学习的关系抽取
mycmsms target drone wp
在Mysql的 left/right join 添加where条件
Market Research: In-depth Analysis and Development Prospect Report of Metal Furniture Industry in 2022
TextCNN实现imdb数据集情感分类任务
P04 并发小球V1 V2.1
fpga卷积神经网络加速器,FPGA卷积神经网络综述
Part 10:iOS的数据持久化(2),Sqlite,CoreData