cobbler简介
看到百度这句话的时候我心里突然觉得压力好大啊啊啊,感觉饭碗不保,赶紧学习了一下
曾经使用PXE批量安装系统,但是PXE存在一个缺陷,即只能安装单一的操作系统。但是在实际环境中,不同功能的服务器需要部署不同的环境,而cobbler正好满足了这一需求。cobbler基于python开发,是对PXE的二次封装,且提供了CLI和Web的管理形式,使得操作和管理更加简便。cobbler的实现与PXE类似,也需要tftp,httpd,dhcp这些服务。使用yum即可完成cobbler的安装,在安装的同时也会自动安装tftp和httpd服务,dhcp服务需要自行安装。
准备工作:
Cobbler实验主机环境:
OS: Redhat 7.2 x86_64bit
IP: 192.168.1.4
防火墙关闭,SELinux处于disabled状态
为了安装Cobbler所需要的一系列软件,首先配置一下yum源,贴上本人的
#自己挂的镜像
[lockey]
name=lockey rhel72
baseurl=http://192.168.1.4/iso72
gpcheck=0
#epel网络源
[good]
name=ailiyun
baseurl=http://mirrors.aliyun.com/epel/7/x86_64/
enabled=1
gpgcheck=0
#网络yum源
[centos]
name=cobbler
baseurl=http://mirrors.aliyun.com/centos/7/os/x86_64/
enabled=1
gpgcheck=0
1. cobbler安装和基本配置
[root@lockey4 ~]# yum install cobbler cobbler-web pykickstart debmirror
这里也有一个el7的RPM包可以用也可以不用cobbler-2.8.1-2.el7.x86_64.rpm
启动cobbler
[root@lockey4 ~]# systemctl start cobblerd.service
[root@lockey4 ~]# cobbler check
1 : The 'server' field in /etc/cobbler/settings must be set to something other than localhost, or kickstarting features will not work. This should be a resolvable hostname or IP for the boot server as reachable by all machines that will use it.
2 : For PXE to be functional, the 'next_server' field in /etc/cobbler/settings must be set to something other than 127.0.0.1, and should match the IP of the boot server on the PXE network.
3 : change 'disable' to 'no' in /etc/xinetd.d/tftp
4 : 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. F