centos8 已经发布了GA版本,迫不及待的想尝鲜了,然后现实总是那么残酷,一直安装失败,具体安装步骤如下:

假设cobbler已配置完成。

1、下载centos8 iso镜像

wget http://mirrors.aliyun.com/centos/8.0.1905/isos/x86_64/CentOS-8-x86_64-1905-dvd1.iso

2、挂载

$ mount -o loop CentOS-8-x86_64-1905-dvd1.iso /mnt/
$ cd /mnt/
$ cp -r * /iso/centos8.0/
$ cd /iso/centos8.0/
  AppStream BaseOS EFI images isolinux media.repo TRANS.TBL

3、配置kickstart文件

$ cat /var/lib/cobbler/kickstarts/centos8.0.ks

#version=RHEL8

# System authorization information

auth --enableshadow --passalgo=sha512

# System bootloader configuration

bootloader --location=mbr --boot-drive=sda

# Partition clearing information

clearpart --all --initlabel

# Use text mode install

#text
graphical # Firewall configuration firewall --disabled # Run the Setup Agent on first boot firstboot --disable ignoredisk --only-use=sda # System keyboard keyboard --vckeymap=us --xlayouts='us' # System language lang en_US.UTF-8 # Use network installation url --url=$tree # If any cobbler repo definitions were referenced in the kickstart profile, include them here. $yum_repo_stanza # Network information $SNIPPET('network_config') # Reboot after installation reboot #Root password rootpw --iscrypted $default_password_crypted # SELinux configuration selinux --disabled # Do not configure the X Window System skipx # System timezone timezone --utc Asia/Shanghai # Install OS instead of upgrade install # Clear the Master Boot Record zerombr # Allow anaconda to partition the system as needed #autopart part /boot --fstype="xfs" --ondisk=sda --size=500
part swap --fstype="swap" --ondisk=sda --size=2048
part / --fstype="xfs" --ondisk=sda --size=1 --grow
part biosboot --fstype="BIOS Boot" --ondisk=sda --size=2 %pre $SNIPPET('log_ks_pre') $SNIPPET('kickstart_start') $SNIPPET('pre_install_network_config') # Enable installation monitoring $SNIPPET('pre_anamon') %end %packages @^minimal-environment
@standard %end

4、cobbler 导入

$ cobbler import --name=centos8.0 --path=/iso/centos8.0 --kickstart=/var/lib/cobbler/kickstarts/centos8.0.ks --arch=x86_64

发现报错,报错如下:

No signature matched

$ cobbler import --name=centos8.0 --path=/iso/centos8.0 --kickstart=/var/lib/cobbler/kickstarts/centos8.0.ks
task started: 2019-10-16_074659_import
task started (id=Media import, time=Wed Oct 16 07:46:59 2019)
No signature matched in /var/www/cobbler/ks_mirror/centos8.0
!!! TASK FAILED !!!

解决:

$ cobbler signature update
task started: 2019-10-16_074829_sigupdate
task started (id=Updating Signatures, time=Wed Oct 16 07:48:29 2019)
Successfully got file from https://cobbler.github.io/signatures/2.8.x/latest.json
*** TASK COMPLETE ***

5、装机

然后装机过程中报错了,截图未报错,报错信息是:报错的界面是配置"Installation Source",报错为:"Error setting up base repository",反复测试依然有问题,不知道怎么设置,没办法,只能从iso那块下手了,检查iso文件内容。

6、iso配置

iso中有AppStream和BaseOS两个目录,目录中都有Packages目录和repodata目录,将BaseOS中的 BaseOS/repodata/586a8e96ad3b73414e5c6ae94a5e4f128a087fcb0ca9837674573a8d6cac4a9c-comps-BaseOS.x86_64.xml 拷贝到 BaseOS 同级目录下,并将 AppStream/Packages 下的auth*包文件全部拷贝到BaseOS/Packages 下,然后使用 createrepo -g 586a8e96ad3b73414e5c6ae94a5e4f128a087fcb0ca9837674573a8d6cac4a9c-comps-BaseOS.x86_64.xml . 创建repodata目录。

$ cd /iso/centos8.0/
$ ls
AppStream BaseOS EFI images isolinux media.repo TRANS.TBL
$ cp AppStream/Packages/auth* BaseOS/Packages/
$ cp BaseOS/repodata/586a8e96ad3b73414e5c6ae94a5e4f128a087fcb0ca9837674573a8d6cac4a9c-comps-BaseOS.x86_64.xml ./ $ ls
586a8e96ad3b73414e5c6ae94a5e4f128a087fcb0ca9837674573a8d6cac4a9c-comps-BaseOS.x86_64.xml AppStream BaseOS EFI images isolinux media.repo TRANS.TBL $ createrepo -g 586a8e96ad3b73414e5c6ae94a5e4f128a087fcb0ca9837674573a8d6cac4a9c-comps-BaseOS.x86_64.xml .
Spawning worker 0 with 167 pkgs
Spawning worker 39 with 166 pkgs
Workers Finished
Saving Primary metadata
Saving file lists metadata
Saving other metadata
Generating sqlite DBs
Sqlite DBs complete $ rm -rf AppStream/repodata BaseOS/repodata

重新使用cobbler import,再使用最小化安装。

当然我配置的可能哪里出了问题,导致出现了"Error setting up base repository"报错,如果哪位大神解决了这个问题,欢迎评论区告知一声。

  

最新文章

  1. centos tar压缩与解压缩命令大全
  2. 关于近段时间论坛型APP 的一段舍弃
  3. time 模块
  4. mysql substring_index substring left right方法
  5. java提高篇---Iterator
  6. jquery在线教程
  7. ThinkPHP下隐藏index.php以及URL伪静态
  8. linux(边压缩边传输边解压)
  9. windows 2003 域控制器(AD)的常规命令行操作以及修复
  10. Chapter 2 Open Book——30
  11. Centos 6.5 安装python3.6
  12. [总结] 第二类Stirling数
  13. YOLOv1
  14. linux tomcat jvm调优
  15. JAVA迭代器学习--在JAVA中实现线性表的迭代器
  16. Flutter基础用法解析
  17. Java-Maven(八):配置远程中央仓库的各种方法
  18. stdlib.h
  19. 局域网代理通过wget下载
  20. C# HttpWebRequest 笔记

热门文章

  1. 【LeetCode】1114. Print in Order 解题报告(C++)
  2. 【LeetCode】89. Gray Code 解题报告(Python & C++)
  3. 【LeetCode】840. Magic Squares In Grid 解题报告(Python)
  4. 第五个知识点 复杂性为NP类是什么意思
  5. Feign动态调用,结合Ribbon
  6. Window/Linux下Mysql的安装步骤
  7. 【VUE】VUE使用常见问题搜集
  8. .net core中Grpc使用报错:The response ended prematurely.
  9. cpuinfo基本参数讲解
  10. CAD快速入门--绝望