ITPub博客

首页 > 自动化运维 > > cobbler安装

cobbler安装

作者:badb0y 时间:2019-08-15 02:12:05 0 删除 编辑
centos7
yum install epel-* -y
yum -y install httpd dhcp tftp python-ctypes cobbler  xinetd cobbler-web

systemctl enable httpd
systemctl enable cobblerd
systemctl start httpd
systemctl start cobblerd

运行检测
cobbler check

下载启动文件
cobbler get-loaders

启用并启动rsyncd
systemctl enable rsyncd 
systemctl start rsyncd

安装pykickstart
yum install pykickstart -y

生成root默认密码
openssl passwd -1 -salt '123' '123'
$1$bjfh$FnywzAEV.cpqS2tpA3GLi0

vi /etc/cobbler/settings
...
101 default_password_crypted: "$1$bjfh$FnywzAEV.cpqS2tpA3GLi0"
242 manage_dhcp: 1
272 next_server: 192.168.2.3
384 server: 192.168.2.3

vi /etc/xinetd.d/tftp
...
14         disable                 = no

systemctl restart cobblerd
cobbler check

配置dhcp
manage_dhcp: 1
vi /etc/cobbler/dhcp.template
...
21 subnet 192.168.2.0 netmask 255.255.255.0 {
     22      option routers             192.168.2.2;
     23      option domain-name-servers 192.168.2.198;
     24      option subnet-mask         255.255.255.0;
     25      range dynamic-bootp        192.168.2.240 192.168.2.254;
     26      default-lease-time         21600;
     27      max-lease-time             43200;
     28      next-server                $next_server;

systemctl restart cobblerd
cobbler sync
排除错误,直到通过

修改默认界面
cat /var/lib/tftpboot/pxelinux.cfg/default

导入镜像
cd /opt
mount -o loop CentOS-7-x86_64-Minimal-1810.iso /mnt
cobbler import --path=/mnt --name=Centos-7.6-x86_64 --arch=x86_64 
umount /mnt
mount -o loop CentOS-6.10-x86_64-minimal.iso /mnt
cobbler import --path=/mnt --name=Centos-6.10-x86_64 --arch=x86_64 
cobbler list
cobbler report

来自 “ ITPUB博客 ” ,链接:https://blog.itpub.net/405749/viewspace-3133293/ ,如需转载,请注明出处,否则将追究法律责任。

下一篇: kickstart安装使用
请登录后发表评论 登录
全部评论

注册时间:2014-08-15

  • 博文量
    5
  • 访问量
    31397