熱搜:win11繞過硬件限制安裝 一鍵重裝Win10系統(tǒng) 最干凈的u盤啟動(dòng)盤 真正純凈版的win7系統(tǒng)
時(shí)間:2015-02-07 17:03:23 作者:qipeng 來源:系統(tǒng)之家 1. 掃描二維碼隨時(shí)看資訊 2. 請使用手機(jī)瀏覽器訪問: https://m.xitongzhijia.net/xtjc/20150207/37599.html 手機(jī)查看 評論 反饋
Install Method:安裝源
HTTP Server:安裝源的IP
HTTP Directory:目錄
Boot Loader Options:引導(dǎo)選項(xiàng)
Install new boot loader安裝新的bootloader,下面是使用舊的。
Use GRUB password:GRUB要不要加密。
Install boot loader on Master Boot Record(MBR)
將bootloader裝入MBR中
Install boot loasder on first sector of the boot partition
將bootloader裝入某一個(gè)分區(qū)中引導(dǎo)。
kernel parameters:crashkernel=auto rhgb quiet使用靜默模式。
Partition Information定義分區(qū)
Network Configuration網(wǎng)絡(luò)配置
Authentication認(rèn)證,默認(rèn)sha512就可以
pre
post這里不用指定#!/bin/bash
4,保存kickstart配置文件。
文件默認(rèn)保存名字為ks.cfg
5,檢查ks.cfg配置文件的錯(cuò)誤。
# ksvalidator 2ks.cfg
kscfg配置文件詳解:
命令段:
#platform=x86, AMD64, 或 Intel EM64T
#version=DEVEL
# Firewall configuration
firewall --disabled禁用防火墻
# Install OS instead of upgrade
install默認(rèn)動(dòng)作是安裝
# Use network installation
url --url=“ftp://1.0.0.12/centos/”使用FTP安裝源
repo --name=“CentOS” --baseurl=“ftp://1.0.0.12/centos”
# Root password
rootpw --iscrypted $1$dpCtQEn6$pC3UGFPZEJJ5nVftiaScq0
# System authorization information
auth --useshadow --passalgo=sha512
# Use text mode install
text使用文本安裝方式
# System keyboard
keyboard us使用美式英語鍵盤
# System language
lang zh_CN設(shè)置默認(rèn)語言
# SELinux configuration
selinux --disabled禁用SELINUX
# Do not configure the X Window System
skipx
# Installation logging level
logging --level=info
# Reboot after installation
reboot安裝完成時(shí)的動(dòng)作
# System timezone
timezone Asia/Shanghai
# Network information
network --bootproto=static --device=eth0 --ip=1.0.0.7 --netmask=255.0.0.0 --onboot=on
# System bootloader configuration
bootloader --append=“crashkernel=auto rhgb quiet” --location=mbr --driveorder=“sda”
# Clear the Master Boot Record
zerombr
# Partition clearing information
clearpart --all --initlabel清空磁盤分區(qū)
# Disk partitioning information磁盤分區(qū)
part /boot --asprimary --fstype=“ext4” --ondisk=sda --size=100
part / --asprimary --fstype=“ext4” --ondisk=sda --size=20480
part swap --asprimary --fstype=“swap” --ondisk=sda --size=500
腳本段:
%post
touch /tmp/abc.txt
%end
軟件包段:
%packages
@base
@basic-desktop
@chinese-support
@core
@debugging
@desktop-debugging
@desktop-platform
@desktop-platform-devel
@development
@directory-client
@fonts
使用引導(dǎo)光盤引導(dǎo)后的選擇:
點(diǎn)擊兩次“ESC”鍵,進(jìn)入命令行模式,然后
linux ip=1.0.0.7 netmask=255.0.0.0 ks=ftp://1.0.0.12/pub/ks.cfg
ftp安裝源自動(dòng)安裝linux詳細(xì)步驟:
1,制作引導(dǎo)光盤:
# mount /dev/cdrom /media/cdrom/
# mkdir /root/myboot
# cp /media/cdrom/isolinux/ /root/myboot/isolinux
# cd /root/myboot/isolinux
# chmod +w 。/*
# chmod +x vmlinuz
# mkisofs -R -J -T -v -no-emul-boot -boot-load-size 4 -boot-info-table -V “MageEdu Testing Image” (-V跟光盤標(biāo)簽) -b isolinux/isolinux.bin (明確指定isolinux.bin的存放位置) -c isolinux/boot.cat (指定boot.cat的位置) -o /tmp/boot.iso (指定輸出位置) /root/myboot/ (指定輸入源)
2,制作ftp安裝源
# yum install vsfptd
# service vsftpd start
# mkdir /var/ftp/CentOS
# mount /media/cdrom /var/ftp/CentOS,
3,將制作好的ks.cfg文件放到ftp目錄
# cp /root/ks.cfg /var/ftp/pub
4,將前面的boot.iso掛載到目標(biāo)主機(jī)的光驅(qū),啟動(dòng)后兩次“ESC”鍵,然后就輸入:
linux ip=1.0.0.7 netmask=255.0.0.0 ks=ftp://1.0.0.12/pub/ks.cfg
5,自動(dòng)安裝啟動(dòng)
上面就是Linux全自動(dòng)安裝的方法介紹了,本文通過編譯腳本實(shí)現(xiàn)Linux系統(tǒng)全自動(dòng)化安裝,需要安裝anaconda,編譯完anaconda后啟動(dòng)即可。
發(fā)表評論
共0條
評論就這些咯,讓大家也知道你的獨(dú)特見解
立即評論以上留言僅代表用戶個(gè)人觀點(diǎn),不代表系統(tǒng)之家立場