Loading... # dnsmasq TFTP 与网络启动 # 一、TFTP 协议原理 TFTP(Trivial File Transfer Protocol)是一个简单文件传输协议,主要用于网络启动场景。 ## 1. TFTP 配置 ```bash # 启用 TFTP enable-tftp tftp-root=/var/tftpboot # 安全模式 tftp-secure tftp-max=50 ``` # 二、PXE 启动配置 ## 1. PXE 配置 ```bash # PXE 提示 pxe-prompt="Press F8 for menu", 5 # PXE 服务 pxe-service=x86PC, "Install Linux", pxelinux pxe-service=x86PC, "Boot from local disk", 0 ``` ## 2. 引导菜单配置 ```bash # /srv/tftp/pxelinux.cfg/default DEFAULT linux LABEL linux KERNEL vmlinuz APPEND initrd=initrd.img ip=dhcp LABEL local LOCALBOOT 0 ``` # 三、实战案例 ## 1. PXE 批量装机 ```bash # 完整 PXE 配置 enable-tftp tftp-root=/srv/tftp dhcp-range=192.168.1.100,192.168.1.200,12h pxe-prompt="Install System", 10 pxe-service=x86PC, "Install Ubuntu", ubuntu-installer ``` ## 2. 多系统启动环境 ```bash # 多启动选项 pxe-service=x86PC, "Ubuntu 22.04", ubuntu22 pxe-service=x86PC, "CentOS 8", centos8 pxe-service=x86PC, "Windows PE", winpe pxe-service=x86PC, "Local Disk", 0 ``` *** **标签**:dnsmasq、TFTP、PXE 最后修改:2026 年 01 月 30 日 © 允许规范转载 赞 如果觉得我的文章对你有用,请随意赞赏