PXE高效批量网络装机(1)

● tftp.service - Tftp Server
Loaded: loaded (/usr/lib/systemd/system/tftp.service; indirect; vendor preset: disabled)
Active: active (running) since 一 2024-05-06 11:45:21 CST; 2min 50s ago
Docs: man:in.tftpd
Main PID: 3268 (in.tftpd)
Tasks: 1
CGroup: /system.slice/tftp.service
└─3268 /usr/sbin/in.tftpd -s /var/lib/tftpboot

5月 06 11:45:21 l3 systemd[1]:


![](https://img-blog.csdnimg.cn/direct/8d95117e17194439abdd798da3bd7669.png)


### 完成 dhcp服务和启动


##### 安装dhcp



[root@l3 xinetd.d]# yum install -y dhcp
已加载插件:fastestmirror, langpacks
Loading mirror speeds from cached hostfile
正在解决依赖关系
–> 正在检查事务
—> 软件包 dhcp.x86_64.12.4.2.5-83.el7.centos.1 将被 安装
–> 解决依赖关系完成

依赖关系解决

==============================================================================
Package 架构 版本 源 大小

正在安装:
dhcp x86_64 12:4.2.5-83.el7.centos.1 local 515 k

事务概要

安装 1 软件包

总下载量:515 k
安装大小:1.4 M
Downloading packages:
Running transaction check
Running transaction test
Transaction test succeeded
Running transaction
正在安装 : 12:dhcp-4.2.5-83.el7.centos.1.x86_64 1/1
验证中 : 12:dhcp-4.2.5-83.el7.centos.1.x86_64 1/1

已安装:
dhcp.x86_64 12:4.2.5-83.el7.centos.1

完毕!
[root@l3 xinetd.d]#


#### 配置文件 dhcp



[root@l3 xinetd.d]# cd /usr/share/doc/dhcp-4.2.5/
[root@l3 dhcp-4.2.5]# ls
dhcpd6.conf.example dhcpd.conf.example ldap
[root@l3 dhcp-4.2.5]# \cp -f dhcpd.conf.example /etc/dhcp/dhcpd.conf
[root@l3 dhcp-4.2.5]# cd /etc/dhcp/
[root@l3 dhcp]# ls
dhclient.d dhclient-exit-hooks.d dhcpd6.conf dhcpd.conf scripts
[root@l3 dhcp]#



[root@l3 dhcp]# vim dhcpd.conf


![](https://img-blog.csdnimg.cn/direct/ce01aaf5d9cb41fa88a1b32b9487c99d.png)



#### 另开一个页面安装引导程序



[root@l3 ~]#
[root@l3 ~]# yum install -y syslinux
已加载插件:fastestmirror, langpacks
Loading mirror speeds from cached hostfile
正在解决依赖关系
–> 正在检查事务
—> 软件包 syslinux.x86_64.0.4.05-15.el7 将被 安装
–> 解决依赖关系完成

依赖关系解决

==============================================================================
Package 架构 版本 源 大小

正在安装:
syslinux x86_64 4.05-15.el7 local 990 k

事务概要

安装 1 软件包

总下载量:990 k
安装大小:2.3 M
Downloading packages:
Running transaction check
Running transaction test
Transaction test succeeded
Running transaction
正在安装 : syslinux-4.05-15.el7.x86_64 1/1
验证中 : syslinux-4.05-15.el7.x86_64 1/1

已安装:
syslinux.x86_64 0:4.05-15.el7

完毕!
[root@l3 ~]#


![](https://img-blog.csdnimg.cn/direct/66a9b1df009b4a0b8b1cf1edf9ca5b8b.png)




[root@l3 ~]# cd /usr/share/syslinux/

[root@l3 syslinux]# ls
altmbr.bin ethersel.c32 isohdpfx.bin mbr_c.bin sanboot.c32
altmbr_c.bin gfxboot.c32 isohdpfx_c.bin mbr_f.bin sdi.c32
altmbr_f.bin gptmbr.bin isohdpfx_f.bin memdisk sysdump.c32
cat.c32 gptmbr_c.bin isohdppx.bin memdump.com syslinux64.exe
chain.c32 gptmbr_f.bin isohdppx_c.bin meminfo.c32 syslinux.com
cmd.c32 gpxecmd.c32 isohdppx_f.bin menu.c32 syslinux.exe
config.c32 gpxelinux.0 isolinux.bin pcitest.c32 ver.com
cpuid.c32 gpxelinuxk.0 isolinux-debug.bin pmload.c32 vesainfo.c32
cpuidtest.c32 hdt.c32 kbdmap.c32 poweroff.com vesamenu.c32
diag host.c32 linux.c32 pwd.c32 vpdtest.c32
disk.c32 ifcpu64.c32 ls.c32 pxechain.com whichsys.c32
dmitest.c32 ifcpu.c32 lua.c32 pxelinux.0 zzjson.c32
dosutil ifplop.c32 mboot.c32 reboot.c32
elf.c32 int18.com mbr.bin rosh.c32
[root@l3 syslinux]#


![](https://img-blog.csdnimg.cn/direct/4cbbf5a4db944a2ea3e25bf00ed09cf2.png)



![](https://img-blog.csdnimg.cn/direct/d2ce8e1e36934c5685aedeb49ee1e0d5.png)


#### 


![](https://img-blog.csdnimg.cn/direct/e4a736f43fa64b14a3f44cc018a33850.png)


####  启动



[root@l3 ~]# systemctl enable dhcpd --now



[root@l3 ~]# systemctl status dhcpd
● dhcpd.service - DHCPv4 Server Daemon
Loaded: loaded (/usr/lib/systemd/system/dhcpd.service; enabled; vendor preset: disabled)
Active: active (running) since 一 2024-05-06 13:30:38 CST; 5min ago
Docs: man:dhcpd(8)
man:dhcpd.conf(5)
Main PID: 60763 (dhcpd)
Status: “Dispatching packets…”
Tasks: 1
CGroup: /system.slice/dhcpd.service
└─60763 /usr/sbin/dhcpd -f -cf /etc/dhcp/dhcpd.conf -user dhcpd -…

5月 06 13:30:38 l3 dhcpd[60763]: No subnet declaration for virbr0 (192.16…).
5月 06 13:30:38 l3 dhcpd[60763]: ** Ignoring requests on virbr0. If this…at
5月 06 13:30:38 l3 dhcpd[60763]: you want, please write a subnet decla…on
5月 06 13:30:38 l3 dhcpd[60763]: in your dhcpd.conf file for the netwo…nt
5月 06 13:30:38 l3 dhcpd[60763]: to which interface virbr0 is attached. **
5月 06 13:30:38 l3 dhcpd[60763]:
5月 06 13:30:38 l3 dhcpd[60763]: Listening on LPF/ens33/00:0c:29:c9:0b:e0…24
5月 06 13:30:38 l3 dhcpd[60763]: Sending on LPF/ens33/00:0c:29:c9:0b:e0…24
5月 06 13:30:38 l3 dhcpd[60763]: Sending on Socket/fallback/fallback-net
5月 06 13:30:38 l3 systemd[1]: Started DHCPv4 Server Daemon.
Hint: Some lines were ellipsized, use -l to show in full.
[root@l3 ~]#


另一个页面



[root@l3 syslinux]# cp pxelinux.0 /var/lib/tftpboot/
[root@l3 syslinux]# ls /var/lib/tftpboot/
pxelinux.0
[root@l3 syslinux]#
[root@l3 syslinux]# cd /mnt/
[root@l3 mnt]# ls
CentOS_BuildTag GPL LiveOS RPM-GPG-KEY-CentOS-7
EFI images Packages RPM-GPG-KEY-CentOS-Testing-7
EULA isolinux repodata TRANS.TBL
[root@l3 mnt]# cd images/
[root@l3 images]# ls
efiboot.img pxeboot TRANS.TBL
[root@l3 images]# cd pxeboot
[root@l3 pxeboot]# ls
initrd.img TRANS.TBL vmlinuz
[root@l3 pxeboot]#



[root@l3 pxeboot]#
[root@l3 pxeboot]# cp vmlinuz initrd.img /var/lib/tftpboot/
[root@l3 pxeboot]# ls /var/lib/tftpboot/
initrd.img pxelinux.0 vmlinuz
[root@l3 pxeboot]#


切换页面


#### 安装软件vsftpd



[root@l3 dhcp]# yum install -y vsftpd
已加载插件:fastestmirror, langpacks
Loading mirror speeds from cached hostfile
正在解决依赖关系
–> 正在检查事务
—> 软件包 vsftpd.x86_64.0.3.0.2-29.el7_9 将被 安装
–> 解决依赖关系完成

依赖关系解决

===============================================================================
Package 架构 版本 源 大小

正在安装:
vsftpd x86_64 3.0.2-29.el7_9 local 173 k

事务概要

安装 1 软件包

总下载量:173 k
安装大小:353 k
Downloading packages:
Running transaction check
Running transaction test
Transaction test succeeded
Running transaction
正在安装 : vsftpd-3.0.2-29.el7_9.x86_64 1/1
验证中 : vsftpd-3.0.2-29.el7_9.x86_64 1/1

已安装:
vsftpd.x86_64 0:3.0.2-29.el7_9

完毕!
[root@l3 dhcp]#



[root@l3 dhcp]# systemctl enable --now vsftpd
Created symlink from /etc/systemd/system/multi-user.target.wants/vsftpd.service to /usr/lib/systemd/system/vsftpd.service.
[root@l3 dhcp]#



[root@l3 dhcp]# cd /var/ftp
[root@l3 ftp]# mkdir centos7
[root@l3 ftp]# ls /mnt
CentOS_BuildTag GPL LiveOS RPM-GPG-KEY-CentOS-7
EFI images Packages RPM-GPG-KEY-CentOS-Testing-7
EULA isolinux repodata TRANS.TBL
[root@l3 ftp]# mount /dev/sr0 /var/ftp/centos7/
mount: /dev/sr0 写保护,将以只读方式挂载
[root@l3 ftp]#
[root@l3 ftp]# cd /var/ftp/centos7/
[root@l3 centos7]# ls
CentOS_BuildTag GPL LiveOS RPM-GPG-KEY-CentOS-7
EFI images Packages RPM-GPG-KEY-CentOS-Testing-7
EULA isolinux repodata TRANS.TBL
[root@l3 centos7]#

[root@l3 centos7]# cd /var/lib/tftpboot/
[root@l3 tftpboot]# ls
initrd.img pxelinux.0 vmlinuz
[root@l3 tftpboot]# mkdir pxelinux.cfg
[root@l3 tftpboot]# ls
initrd.img pxelinux.0 pxelinux.cfg vmlinuz
[root@l3 tftpboot]# cd pxelinux.cfg
[root@l3 pxelinux.cfg]# touch default
[root@l3 pxelinux.cfg]# ls
default
[root@l3 pxelinux.cfg]#



[root@l3 pxelinux.cfg]# vim default



default auto
prompt 1

label auto
kernel vmlinuz
append initrd=initrd.img method=ftp://192.168.217.30/centos7

label text
kernel vmlinuz
append initrd=initrd.img method=ftp://192.168.217.30/centos7

label rescue
kernel vmlinuz
append initrd=initrd.img method=ftp://192.168.217.30/centos7


![](https://img-blog.csdnimg.cn/direct/fa50e3e85e92430ca770b19a83e21515.png)



[root@l3 pxelinux.cfg]# cd …
[root@l3 tftpboot]#



[root@l3 tftpboot]# pwd
/var/lib/tftpboot
[root@l3 tftpboot]# ls -R
.:
initrd.img pxelinux.0 pxelinux.cfg vmlinuz

./pxelinux.cfg:
default
[root@l3 tftpboot]#



[root@l3 tftpboot]#
[root@l3 tftpboot]# systemctl status tftp xinetd
● tftp.service - Tftp Server
Loaded: loaded (/usr/lib/systemd/system/tftp.service; indirect; vendor preset: disabled)
Active: inactive (dead) since 一 2024-05-06 12:00:21 CST; 2h 57min ago
Docs: man:in.tftpd
Main PID: 3268 (code=exited, status=0/SUCCESS)

5月 06 11:45:21 l3 systemd[1]: Started Tftp Server.

● xinetd.service - Xinetd A Powerful Replacement For Inetd
Loaded: loaded (/usr/lib/systemd/system/xinetd.service; enabled; vendor preset: enabled)
Active: active (running) since 一 2024-05-06 11:45:04 CST; 3h 13min ago
Main PID: 3244 (xinetd)
Tasks: 1
CGroup: /system.slice/xinetd.service
└─3244 /usr/sbin/xinetd -stayalive -pidfile /var/run/xinetd.pid

5月 06 11:45:04 l3 xinetd[3244]: removing discard
5月 06 11:45:04 l3 xinetd[3244]: removing discard
5月 06 11:45:04 l3 xinetd[3244]: removing echo
5月 06 11:45:04 l3 xinetd[3244]: removing echo
5月 06 11:45:04 l3 xinetd[3244]: removing tcpmux
5月 06 11:45:04 l3 xinetd[3244]: removing time
5月 06 11:45:04 l3 xinetd[3244]: removing time
5月 06 11:45:04 l3 xinetd[3244]: Service tftp has socket_type dgram, but …it
5月 06 11:45:04 l3 xinetd[3244]: xinetd Version 2.3.15 started with libwr…n.
5月 06 11:45:04 l3 xinetd[3244]: Started working: 0 available services
Hint: Some lines were ellipsized, use -l to show in full.
[root@l3 tftpboot]#



[root@l3 tftpboot]# systemctl restart tftp xinetd
[root@l3 tftpboot]# systemctl status tftp xinetd
● tftp.service - Tftp Server
Loaded: loaded (/usr/lib/systemd/system/tftp.service; indirect; vendor preset: disabled)
Active: active (running) since 一 2024-05-06 14:59:49 CST; 19s ago
Docs: man:in.tftpd
Main PID: 61785 (in.tftpd)
Tasks: 1
CGroup: /system.slice/tftp.service
└─61785 /usr/sbin/in.tftpd -s /var/lib/tftpboot

5月 06 14:59:49 l3 systemd[1]: Started Tftp Server.

● xinetd.service - Xinetd A Powerful Replacement For Inetd
Loaded: loaded (/usr/lib/systemd/system/xinetd.service; enabled; vendor preset: enabled)
Active: active (running) since 一 2024-05-06 14:59:49 CST; 19s ago
Process: 61787 ExecStart=/usr/sbin/xinetd -stayalive -pidfile /var/run/xinetd.pid $EXTRAOPTIONS (code=exited, status=0/SUCCESS)
Main PID: 61788 (xinetd)
Tasks: 1
CGroup: /system.slice/xinetd.service
└─61788 /usr/sbin/xinetd -stayalive -pidfile /var/run/xinetd.pid

5月 06 14:59:49 l3 xinetd[61788]: removing discard
5月 06 14:59:49 l3 xinetd[61788]: removing discard
5月 06 14:59:49 l3 xinetd[61788]: removing echo



[root@l3 tftpboot]# systemctl status dhcpd
● dhcpd.service - DHCPv4 Server Daemon
Loaded: loaded (/usr/lib/systemd/system/dhcpd.service; enabled; vendor preset: disabled)
Active: active (running) since 一 2024-05-06 13:30:38 CST; 1h 30min ago
Docs: man:dhcpd(8)
man:dhcpd.conf(5)
Main PID: 60763 (dhcpd)
Status: “Dispatching packets…”
Tasks: 1
CGroup: /system.slice/dhcpd.service
└─60763 /usr/sbin/dhcpd -f -cf /etc/dhcp/dhcpd.conf -user dhcpd -…

5月 06 13:30:38 l3 dhcpd[60763]: No subnet declaration for virbr0 (192.16…).
5月 06 13:30:38 l3 dhcpd[60763]: ** Ignoring requests on virbr0. If this…at
5月 06 13:30:38 l3 dhcpd[60763]: you want, please write a subnet decla…on
5月 06 13:30:38 l3 dhcpd[60763]: in your dhcpd.conf file for the netwo…nt
5月 06 13:30:38 l3 dhcpd[60763]: to which interface virbr0 is attached. **
5月 06 13:30:38 l3 dhcpd[60763]:
5月 06 13:30:38 l3 dhcpd[60763]: Listening on LPF/ens33/00:0c:29:c9:0b:e0…24
5月 06 13:30:38 l3 dhcpd[60763]: Sending on LPF/ens33/00:0c:29:c9:0b:e0…24
5月 06 13:30:38 l3 dhcpd[60763]: Sending on Socket/fallback/fallback-net
5月 06 13:30:38 l3 systemd[1]: Started DHCPv4 Server Daemon.
Hint: Some lines were ellipsized, use -l to show in full.
[root@l3 tftpboot]#


#### 三个服务准备好,接下来准备四个文件



[root@l3 tftpboot]# cd /var/lib/tftpboot/
[root@l3 tftpboot]# pwd
/var/lib/tftpboot
[root@l3 tftpboot]# ls
initrd.img pxelinux.0 pxelinux.cfg vmlinuz
[root@l3 tftpboot]#


### 全部准备好之后,开始测试


### 半自动化


![](https://img-blog.csdnimg.cn/direct/9e9090d155754fea93779d18506761c2.png)


![](https://img-blog.csdnimg.cn/direct/19b3b9892d47497391f2ad5fd9c8c009.png) ![](https://img-blog.csdnimg.cn/direct/d383365b9792456083a5748306c0a68b.png)


![](https://img-blog.csdnimg.cn/direct/4cb85817cf2b409fa6711cb804754a3e.png)


![](https://img-blog.csdnimg.cn/direct/7a64ce8ef42447b2b2779ebc6369e364.png) ![](https://img-blog.csdnimg.cn/direct/49db3ad0a78b457d94ec0b4963ede037.png)


![](https://img-blog.csdnimg.cn/direct/db3362bff4cd4b40827af6f97c64bfd4.png)![](https://img-blog.csdnimg.cn/direct/c55119554e7b4733aff759a854c69189.png) ![](https://img-blog.csdnimg.cn/direct/80209f1b8eb44fee98e39542e21b5515.png)


![](https://img-blog.csdnimg.cn/direct/b8d9bb1df1e94d6bb6cd046264ac5aca.png)


#### boot:auto 或者 直接回车


![](https://img-blog.csdnimg.cn/direct/1455b017c201494b92185b4c6f7f4639.png) ![](https://img-blog.csdnimg.cn/direct/642bf04d167c4ecb9905aaa391fa3743.png)


 ![](https://img-blog.csdnimg.cn/direct/8d67b087cbd74407b05b2414596c4b7a.png)


![](https://img-blog.csdnimg.cn/direct/a54bdde9a82b47e98e6e62ab183cfb71.png)![](https://img-blog.csdnimg.cn/direct/fef77e20dd34456eb50029082813f8b8.png)![](https://img-blog.csdnimg.cn/direct/03c8a32fd1d24f5d9191118513472194.png) ![](https://img-blog.csdnimg.cn/direct/41da206970cf400da2e35796e252b426.png)


![](https://img-blog.csdnimg.cn/direct/ff8c674fe7fe445a8719443f6aaf2377.png) ![](https://img-blog.csdnimg.cn/direct/a7d769a31ca34697a456b0da97729360.png)


![](https://img-blog.csdnimg.cn/direct/4ef035a902ed479fa0b07e01529ef500.png)


### 




---


### 全自动化


#### 全部部署完毕之后,新建虚拟机


![](https://img-blog.csdnimg.cn/direct/3b5d02166e334528abf06442eec545da.png)


**新建虚拟机步骤和上边一样**


#### 在开机之前


![](https://img-blog.csdnimg.cn/direct/083450dcbd094712936cb413bf67bf4f.png)



![](https://img-blog.csdnimg.cn/direct/adeec2750f24427d84dbaeedb08ca3e1.png)


![](https://img-blog.csdnimg.cn/direct/ddb5e76ffba54d5ebca50e6ad7e4cdd4.png) ![](https://img-blog.csdnimg.cn/direct/efa9724e3f3849e3b4ca66f6e8321a61.png)


![](https://img-blog.csdnimg.cn/direct/f1b6de20ecfb4a5db86b18b141d56157.png) ![](https://img-blog.csdnimg.cn/direct/ccc70b274ef84b289533c84df2946c13.png)


####  配置和之前一样,如果不想一步步配置



[root@l3 tftpboot]# yum install -y system-config-kickstart.noarch
已加载插件:fastestmirror, langpacks
Loading mirror speeds from cached hostfile
正在解决依赖关系
–> 正在检查事务
—> 软件包 system-config-kickstart.noarch.0.2.9.7-1.el7 将被 安装
–> 正在处理依赖关系 system-config-keyboard >= 1.3.1,它被软件包 system-config-kickstart-2.9.7-1.el7.noarch 需要
–> 正在处理依赖关系 system-config-language,它被软件包 system-config-kickstart-2.9.7-1.el7.noarch 需要
–> 正在处理依赖关系 system-config-date,它被软件包 system-config-kickstart-2.9.7-1.el7.noarch 需要
–> 正在检查事务
—> 软件包 system-config-date.noarch.0.1.10.6-3.el7.centos 将被 安装
–> 正在处理依赖关系 system-config-date-docs,它被软件包 system-config-date-1.10.6-3.el7.centos.noarch 需要
–> 正在处理依赖关系 gnome-python2-canvas,它被软件包 system-config-date-1.10.6-3.el7.centos.noarch 需要
—> 软件包 system-config-keyboard.noarch.0.1.4.0-5.el7 将被 安装
–> 正在处理依赖关系 system-config-keyboard-base = 1.4.0-5.el7,它被软件包 system-config-keyboard-1.4.0-5.el7.noarch 需要
—> 软件包 system-config-language.noarch.0.1.4.0-9.el7 将被 安装
–> 正在处理依赖关系 usermode-gtk,它被软件包 system-config-language-1.4.0-9.el7.noarch 需要
–> 正在检查事务
—> 软件包 gnome-python2-canvas.x86_64.0.2.28.1-14.el7 将被 安装
–> 正在处理依赖关系 gnome-python2(x86-64) = 2.28.1-14.el7,它被软件包 gnome-python2-canvas-2.28.1-14.el7.x86_64 需要
–> 正在处理依赖关系 libgnomecanvas(x86-64) >= 2.8.0,它被软件包 gnome-python2-canvas-2.28.1-14.el7.x86_64 需要
–> 正在处理依赖关系 libgnomecanvas-2.so.0()(64bit),它被软件包 gnome-python2-canvas-2.28.1-14.el7.x86_64 需要
–> 正在处理依赖关系 libart_lgpl_2.so.2()(64bit),它被软件包 gnome-python2-canvas-2.28.1-14.el7.x86_64 需要
—> 软件包 system-config-date-docs.noarch.0.1.0.11-4.el7 将被 安装
–> 正在处理依赖关系 rarian-compat,它被软件包 system-config-date-docs-1.0.11-4.el7.noarch 需要
—> 软件包 system-config-keyboard-base.noarch.0.1.4.0-5.el7 将被 安装
—> 软件包 usermode-gtk.x86_64.0.1.111-6.el7 将被 安装
–> 正在检查事务
—> 软件包 gnome-python2.x86_64.0.2.28.1-14.el7 将被 安装
—> 软件包 libart_lgpl.x86_64.0.2.3.21-10.el7 将被 安装
—> 软件包 libgnomecanvas.x86_64.0.2.30.3-8.el7 将被 安装
—> 软件包 rarian-compat.x86_64.0.0.8.1-11.el7 将被 安装
–> 正在处理依赖关系 rarian = 0.8.1-11.el7,它被软件包 rarian-compat-0.8.1-11.el7.x86_64 需要
–> 正在处理依赖关系 rarian,它被软件包 rarian-compat-0.8.1-11.el7.x86_64 需要
–> 正在处理依赖关系 librarian.so.0()(64bit),它被软件包 rarian-compat-0.8.1-11.el7.x86_64 需要
–> 正在检查事务
—> 软件包 rarian.x86_64.0.0.8.1-11.el7 将被 安装
–> 解决依赖关系完成

依赖关系解决

=============================================================================


在服务端 


![](https://img-blog.csdnimg.cn/direct/9d4dd531edb447419f0f06522ebd327d.png)


###### 或者 输入命令 ,也可以自动弹出



[root@l3 ~]# system-config-kickstart


![](https://img-blog.csdnimg.cn/direct/95721aaf8d5c47b896fb15eec0116b27.png)


![](https://img-blog.csdnimg.cn/direct/f128ed1941094968959ae868bdf4b4cc.png)


![](https://img-blog.csdnimg.cn/direct/c5d29b6dd0d64fa4ad04c7338b009554.png) ![](https://img-blog.csdnimg.cn/direct/7bc431615aee48478a080fb187074784.png)


![](https://img-blog.csdnimg.cn/direct/e4f30ff7fe454a25bf60951a912baf84.png) ![](https://img-blog.csdnimg.cn/direct/2cb62c85db6741d89cfcdaae6373a70e.png)


#### 安装方法


##### 


###### 引导装载程序选项


###### 分区信息


![](https://img-blog.csdnimg.cn/direct/5b9c26aa51fd402da8aefc89664492bd.png)![](https://img-blog.csdnimg.cn/direct/33e640a0d5de4ecbb5784efb49888f81.png) 


![](https://img-blog.csdnimg.cn/direct/bab462ee8d214f9293d1802286cda12f.png)



![](https://img-blog.csdnimg.cn/direct/9a72f1a3558f4b18b37909b2365f8496.png)


###### 网络配置


![](https://img-blog.csdnimg.cn/direct/0bebae99a9d748cb96a28ab702042f20.png)


######  防火墙配置


![](https://img-blog.csdnimg.cn/direct/363caa4a7971457abfec826ba62fa77c.png)


###### 安装后脚本


这里我们添加yum


![](https://img-blog.csdnimg.cn/direct/61dbe09bed81479282a0a0e96d948087.png)



mkdir /etc/yum.repos.d/repo.bak
mv /etc/yum.repos.d/*.repo /etc/yum.repos.d/repo.bak
echo [local]
name=local
baseurl=ftp://192.168.217.30/centos7
enabled=1
gpgcheck=0 > /etc/yum.repos.d/local.repo


 ![](https://img-blog.csdnimg.cn/direct/baaa43b945d74da382b146792daef55b.png)


######  保存好,自动生成


 ![](https://img-blog.csdnimg.cn/direct/23b52f3e5de14f528984c18758fa1db4.png)



[root@l3 ~]# vim ks.cfg


![](https://img-blog.csdnimg.cn/direct/f7ba428794ec498a95aa7429b1b55f61.png)


###### 软件包配置


###### 开另一个服务端窗口



[root@l3 pxeboot]# cd
[root@l3 ~]# ls
anaconda-ks.cfg ks.cfg 模板 图片 下载 桌面
initial-setup-ks.cfg 公共 视频 文档 音乐
[root@l3 ~]# vim anaconda-ks.cfg


![](https://img-blog.csdnimg.cn/direct/c09dce1eedfd418f93ff0f2bb2ea85a8.png)


复制出来



%packages
@^gnome-desktop-environment
@base
@core
@desktop-debugging
@development
@dial-up
@directory-client
@fonts
@gnome-desktop
@guest-agents
@guest-desktop-agents
@input-methods
@internet-browser
@java-platform
@multimedia
@network-file-system-client
@networkmanager-submodules
@print-client
@x11
chrony
kexec-tools

%end


插入窗口1  (vim ks.cfg)


![](https://img-blog.csdnimg.cn/direct/7cd6b7f499b24e59b029e906fd1aab22.png)


 如果想要最小化安装


![](https://img-blog.csdnimg.cn/direct/b97f93c8ead644169e7cb346a79a95ec.png)



[root@l3 tftpboot]# cd
[root@l3 ~]#
[root@l3 ~]# ls
anaconda-ks.cfg ks.cfg 模板 图片 下载 桌面
initial-setup-ks.cfg 公共 视频 文档 音乐
[root@l3 ~]# cp ks.cfg /var/ftp/
[root@l3 ~]# cd /var/ftp/
[root@l3 ftp]# ls
centos7 ks.cfg pub
[root@l3 ftp]#

## 最后

**自我介绍一下,小编13年上海交大毕业,曾经在小公司待过,也去过华为、OPPO等大厂,18年进入阿里一直到现在。**

**深知大多数网络安全工程师,想要提升技能,往往是自己摸索成长,但自己不成体系的自学效果低效又漫长,而且极易碰到天花板技术停滞不前!**

**因此收集整理了一份《2024年网络安全全套学习资料》,初衷也很简单,就是希望能够帮助到想自学提升又不知道该从何学起的朋友。**

![img](https://img-blog.csdnimg.cn/img_convert/581c1bb4e79f45cce8cb642ef4b2ffb9.png)

![img](https://img-blog.csdnimg.cn/img_convert/8681972a54c21fb9daaabd3384b3e9ad.png)

![img](https://img-blog.csdnimg.cn/img_convert/93a30434b349fe01e405874133498841.png)

![img](https://img-blog.csdnimg.cn/img_convert/bc21ac0600cedf6f3b319e2ab6fdca76.png)

![img](https://img-blog.csdnimg.cn/img_convert/26167b84a577a0d6fa4f236fc571ed1f.png)

 

**既有适合小白学习的零基础资料,也有适合3年以上经验的小伙伴深入学习提升的进阶课程,基本涵盖了95%以上网络安全知识点!真正的体系化!**

[**如果你觉得这些内容对你有帮助,需要这份全套学习资料的朋友可以戳我获取!!**](https://bbs.csdn.net/topics/618653875)

**由于文件比较大,这里只是将部分目录截图出来,每个节点里面都包含大厂面经、学习笔记、源码讲义、实战项目、讲解视频,并且会持续更新!**

g  公共    视频  文档  音乐
[root@l3 ~]# cp ks.cfg /var/ftp/
[root@l3 ~]# cd /var/ftp/
[root@l3 ftp]# ls
centos7  ks.cfg  pub
[root@l3 ftp]# 


最后

自我介绍一下,小编13年上海交大毕业,曾经在小公司待过,也去过华为、OPPO等大厂,18年进入阿里一直到现在。

深知大多数网络安全工程师,想要提升技能,往往是自己摸索成长,但自己不成体系的自学效果低效又漫长,而且极易碰到天花板技术停滞不前!

因此收集整理了一份《2024年网络安全全套学习资料》,初衷也很简单,就是希望能够帮助到想自学提升又不知道该从何学起的朋友。

[外链图片转存中…(img-1D9sJcc0-1715539228636)]

[外链图片转存中…(img-d6ooegVv-1715539228637)]

[外链图片转存中…(img-FnWBUXFJ-1715539228637)]

[外链图片转存中…(img-Y4t9ZK2a-1715539228637)]

[外链图片转存中…(img-XotC1X39-1715539228637)]

既有适合小白学习的零基础资料,也有适合3年以上经验的小伙伴深入学习提升的进阶课程,基本涵盖了95%以上网络安全知识点!真正的体系化!

如果你觉得这些内容对你有帮助,需要这份全套学习资料的朋友可以戳我获取!!

由于文件比较大,这里只是将部分目录截图出来,每个节点里面都包含大厂面经、学习笔记、源码讲义、实战项目、讲解视频,并且会持续更新!

  • 23
    点赞
  • 20
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值