1 : change 'disable' to 'no' in /etc/xinetd.d/tftp2 : Some network boot-loaders are missing from /var/lib/cobbler/loaders, you may run'cobbler get-loaders' to download them, or, if you only want to handle x86/x86_64 netbooting, you may ensure that you have installed a *recent* version of the syslinux package installed and can ignore this message entirely. Files in this directory, should you want to support all architectures, should include pxelinux.0, menu.c32, elilo.efi, and yaboot. The 'cobbler get-loaders' command is the easiest way to resolve these requirements. #可以忽略(确保系统已经安装pxelinux)3 : enable and start rsyncd.service with systemctl
4 : comment out'dists' on /etc/debmirror.conf for proper debian support5 : comment out'arches' on /etc/debmirror.conf for proper debian support6 : fencing tools were not found, and are required to use the (optional) power management features. install cman or fence-agents to use them #可以忽略
#报错1问题解决 cat << EOF | tee /etc/xinetd.d/tftp service tftp { socket_type = dgram protocol = udp wait = yes user = root server = /usr/sbin/in.tftpd server_args = -s /var/lib/tftpboot disable = no per_source = 11 cps = 100 2 flags = IPv4 } EOF #报错3问题解决 systemctl enable --now rsyncd.service #报错4、5问题解决 sed -i 's|@dists=.*|# @dists=|' /etc/debmirror.conf sed -i 's|@arches=.*|# @arches=|' /etc/debmirror.conf
Cobbler 首次同步
#再次运行检查
cobbler check
1 : Some network boot-loaders are missing from /var/lib/cobbler/loaders, you may run'cobbler get-loaders' to download them, or, if you only want to handle x86/x86_64 netbooting, you may ensure that you have installed a *recent* version of the syslinux package installed and can ignore this message entirely. Files in this directory, should you want to support all architectures, should include pxelinux.0, menu.c32, elilo.efi, and yaboot. The 'cobbler get-loaders' command is the easiest way to resolve these requirements.2 : fencing tools were not found, and are required to use the (optional) power management features. install cman or fence-agents to use them
vim /var/lib/cobbler/snippets/late_apt_repo_config
cat >/etc/apt/sources.list<<EOF
deb http://mirrors.aliyun.com/ubuntu/ bionic main restricted universe multiverse
deb http://mirrors.aliyun.com/ubuntu/ bionic-security main restricted universe multiverse
deb http://mirrors.aliyun.com/ubuntu/ bionic-updates main restricted universe multiverse
deb http://mirrors.aliyun.com/ubuntu/ bionic-proposed main restricted universe multiverse
deb http://mirrors.aliyun.com/ubuntu/ bionic-backports main restricted universe multiverse
EOF
允许 root 用户 SSH 登录
sed -i 's|.*PermitRootLogin.*|PermitRootLogin yes|g' /etc/ssh/sshd_config && service ssh start
安装Ubuntu系统之后执行的脚本模板文件
vim /var/lib/cobbler/scripts/preseed_late_default
$SNIPPET('post_run_deb')
Cobbler 配置启动菜单
客户端配置
服务端配置 BIOS 启动菜单
修改启动菜单配置文件
vim /etc/cobbler/pxe/pxedefault.template
#LABEL local# MENU LABEL (local)# MENU DEFAULT# LOCALBOOT -1