博客
关于我
强烈建议你试试无所不能的chatGPT,快点击我
安装cobbler
阅读量:5898 次
发布时间:2019-06-19

本文共 3412 字,大约阅读时间需要 11 分钟。

安装Django1.4

wget

rpm -ivf Django14-1.4.14-1.sdl6.noarch.rpm

安装命令

root@master ~]# yum install cobbler cobbler-web dhcp tftp-server pykickstart httpd -y
重启httpd
/etc/init.d/httpd restart
启动cobbler
/etc/init.d/cobblerd start
检查
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. 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.
5 : change 'disable' to 'no' in /etc/xinetd.d/rsync
6 : file /etc/xinetd.d/rsync does not exist
7 : debmirror package is not installed, it will be required to manage debian deployments and repositories
8 : The default password used by the sample templates for newly installed machines (default_password_crypted in /etc/cobbler/settings) is still set to 'cobbler' and should be changed, try: "openssl passwd -1 -salt 'random-phrase-here' 'your-password-here'" to generate new one
9 : fencing tools were not found, and are required to use the (optional) power management features. install cman or fence-agents to use them
解决报错
vi /etc/cobbler/settings
next_server: 10.0.0.8
server: 10.0.0.8
配置接管dhcp
manage_dhcp: 1
default_password_crypted: "$1$oldboy$fXF8f078vI9J/q9XyXA8e/"
生成密码的方法
openssl passwd -1 -salt 'oldboy' 'oldboy'
执行命令
cobbler get-loaders
修改配置
vi /etc/xinetd.d/rsync
disable = no
/etc/init.d/xinetd restart
配置dhcp
vim /etc/cobbler/dhcp.template
subnet 10.0.0.0 netmask 255.255.255.0 {
option routers 10.0.0.2;
option domain-name-servers 10.0.0.2;
option subnet-mask 255.255.255.0;
range dynamic-bootp 10.0.0.100 10.0.0.200;
刷新
cobbler sync

mount光盘

mount /dev/cdrom /mnt
导入iso
.# cobbler import --path=/mnt/ --name=CentOS-7-x86_64-DVD-1708 --arch=x86_64
cobbler import --path=/mnt/ --name=CentOS-6.5-x86_64 --arch=x86_64

会把镜像放到

/var/www/cobbler/ks_mirror

把my.cfg上传到一下目录

/var/lib/cobbler/kickstarts
修改配置文件
.# kickstarts]# cobbler profile edit --name=CentOS-7-DVD-1708-x86_64 --kickstart=/var/lib/cobbler/kickstarts/my.cfg
kickstarts]# cobbler profile edit --name=CentOS-6.5-x86_64 --kickstart=/var/lib/cobbler/kickstarts/my.cfg
修改内核参数
cobbler profile edit --name=CentOS-7-DVD-1708-x86_64 --kopts='net.ifnames=0 biosdevname=0'

同步

cobbler sync

修改cobbler配置文件

开启虚拟机就会自动安装
为某个网卡添加ip和主机名
cobbler system add --name=oldboy --mac=00:0C:29:BA:67:1C --profile=CentOS-6.5-x86_64 --ip-address=10.0.0.111 --subnet=255.255.255.0 --gateway=10.0.0.2 --interface=eht0 --static=1 --hostname=oldboy.example.com --name-servers="114.114.114.114 8.8.8.8"

修改安装时候的文字提示

vi /etc/cobbler/pxe/pxedefault.template

查看指定的PC

cobbler system list

转载于:https://blog.51cto.com/13491150/2051691

你可能感兴趣的文章
10 个顶尖的 Linux 开源人工智能工具
查看>>
传 Android N 或取消沿用多年的应用抽屉
查看>>
《PaaS程序设计》一2.4 PaaS:现代应用的虚拟工具
查看>>
Firefox 跟踪保护技术将页面加载时间减少 44%
查看>>
《嵌入式 Linux应用程序开发标准教程(第2版)》——2.3 Linux系统服务
查看>>
《Oracle高性能自动化运维》一一第2章 Oracle内存体系结构
查看>>
《SPSS 统计分析从入门到精通(第2版)》一第6章 非参数检验6.1 非参数检验简介...
查看>>
《Arduino实战》——1.3 设置你的工作环境
查看>>
阿里云开源容器技术Cabernets在阿里云上的最佳实践
查看>>
使用 Ansible 高效交付 Docker 容器
查看>>
《HTML5 开发实例大全》——1.2 在页面中输出一段文字
查看>>
十个鲜为人知的 Linux 命令 - Part 2
查看>>
RocksDB · 特性介绍 · HashLinkList 内存表
查看>>
OpenACC并行编程实战》—— 3.4 loop构件
查看>>
【Spark Summit East 2017】下一代存档:使用Hadoop进行存档、电子取证和监管
查看>>
一分钟了解互联网数据挖掘流程
查看>>
《C语言及程序设计》实践参考——乱玩数字
查看>>
Git for Windows v2.8.3 Release Notes
查看>>
android离线缓存技术
查看>>
分享两款强大的文本编辑器
查看>>