当前位置: 首页 > news >正文

Dell-R730 【Pxe+dhcp+ftp+tftp+Kickstart+CentOs6.6】

IP:10.104.0.101

[root@localhost network-scripts]# cat ifcfg-em1

[root@localhost network-scripts]# iptables -F

[root@localhost network-scripts]# iptables -X

[root@localhost network-scripts]# service iptables stop

iptables:将链设置为政策 ACCEPT:filter                     [确定]

iptables:清除防火墙规则:                                      [确定]

iptables:正在卸载模块:                                         [确定]

[root@localhost network-scripts]# service iptables save

 

[root@localhost network-scripts]# vim /etc/sysconfig/selinux

[root@localhost network-scripts]#setenforce 0

setenforce: SELinux is disabled

[root@localhost network-scripts]# mkdir /media/cdrom

[root@localhost network-scripts]# mount /dev/cdrom /media/cdrom/

mount: block device /dev/sr0 is write-protected, mounting read-only read-only

[root@localhost network-scripts]# cd /etc/yum.repos.d/

[root@localhost yum.repos.d]# mv CentOS-Base.repo CentOS-Base.repo.bak

[root@localhost yum.repos.d]# vim CentOS-Media.repo

[root@localhost yum.repos.d]# yum -y install ftp tftp-server syslinux vsftpd xinetd dhcp

 

[root@localhost yum.repos.d]# mkdir /var/ftp/rhel6

[root@localhost yum.repos.d]# cp -rf /media/cdrom/* /var/ftp/rhel6/

[root@localhost yum.repos.d]# vim /etc/xinetd.d/tftp

 

[root@localhost yum.repos.d]# cd /media/cdrom/images/pxeboot/

[root@localhost pxeboot]# cp initrd.img vmlinuz /var/lib/tftpboot/

[root@localhost pxeboot]# cp /usr/share/syslinux/pxelinux.0 /var/lib/tftpboot/

[root@localhost pxeboot]# mkdir /var/lib/tftpboot/pxelinux.cfg

[root@localhost pxeboot]# vim /var/lib/tftpboot/pxelinux.cfg/default

 1 default auto
 2 
 3 prompt 0
 4 
 5 timeout 1
 6 
 7 label auto
 8 
 9         kernel vmlinuz
10 
11         append initrd=initrd.img ks=ftp://10.104.0.101/rhel6/ks.cfg devfs=nomount ramdisk_size=8192 ksdevice=em1 biosname=0
12 
13 label linux text
14 
15         kernel vmlinuz
16 
17         append text initrd=initrd.img devfs=nomount ramdisk_size=8192
18 
19 label linux rescue
20 
21         kernel vmlinuz
22 
23         append rescue  initrd=initrd.img devfs=nomount ramdisk_size=8192

 

 

[root@zuo pxeboot]# vim /etc/dhcp/dhcpd.conf

 1 subnet 10.104.0.0 netmask 255.255.255.0 {
 2 
 3         default-lease-time 21600;
 4 
 5         max-lease-time 43200;
 6 
 7         range 10.104.0.100 10.104.0.130;
 8 
 9         next-server 10.104.0.101;
10 
11         filename "pxelinux.0";
12 
13 }

 

[root@localhost pxeboot]# dhcpd

 

[root@localhost pxeboot]# service vsftpd restart

[root@localhost pxeboot]# chkconfig vsftpd on

[root@localhost pxeboot]# service xinetd restart

[root@localhost pxeboot]# chkconfig xinetd on

[root@localhost pxeboot]# service dhcpd restart

[root@localhost pxeboot]# chkconfig dhcpd on

[root@localhost pxeboot]# yum -y install system-config-kickstart

[root@localhost pxeboot]# system-config-kickstart

 

 

 

 

 

 

 

 

 

 

 

 

[root@localhost rhel6]# vim ks.cfg

install

# Use network installation

url --url="ftp://10.104.0.101/rhel6"

# Root password

rootpw --iscrypted $1$u0Tl6e4j$o3QI9JgfVdQU2o3pqDWlo/

# System authorization information

auth  --useshadow  --passalgo=md5

# Use graphical install

graphical

firstboot --disable

# System keyboard

keyboard us

# System language

lang en_US

# SELinux configuration

selinux --disabled

# Installation logging level

logging --level=info

reboot

# System timezone

timezone  Asia/Shanghai

# Network information

network  --bootproto=dhcp --device=em1 --onboot=on

# System bootloader configuration

bootloader --location=mbr --append="biosdevname=0"

# Clear the Master Boot Record

zerombr

# Partition clearing information

clearpart --all --initlabel

# Disk partitioning information

part /boot --fstype="ext4" --size=200

part swap --fstype="swap" --size=65536

part / --fstype="ext4" --size=51250

part /opt --fstype="ext4" --grow --size=1

%packages

@additional-devel

@backup-client

@base

@basic-desktop

@compat-libraries

@console-internet

@debugging

@desktop-debugging

@desktop-platform

@desktop-platform-devel

@development

@dial-up

@directory-client

@eclipse

@emacs

@fonts

@ftp-server

@general-desktop

@graphical-admin-tools

@graphics

@ha

@ha-management

@hardware-monitoring

@identity-management-server

@infiniband

@input-methods

@internet-applications

@internet-browser

@java-platform

@kde-desktop

@large-systems

@legacy-unix

@legacy-x

@mainframe-access

@mysql

@mysql-client

@network-file-system-client

@network-server

@network-tools

@nfs-file-server

@office-suite

@performance

@perl-runtime

@php

@postgresql

@postgresql-client

@print-client

@remote-desktop-clients

@resilient-storage

@ruby-runtime

@scalable-file-systems

@scientific

@security-tools

@server-platform

@server-platform-devel

@smart-card

@storage-client-fcoe

@storage-client-iscsi

@storage-client-multipath

@storage-server

@system-admin-tools

@system-management

@system-management-messaging-client

@system-management-snmp

@system-management-wbem

@technical-writing

@tex

@turbogears

@web-server

@web-servlet

@x11

ElectricFence

PyQt4-devel

SDL-devel

ant

babel

bzr

chrpath

cmake

compat-gcc-34

compat-gcc-34-c++

compat-gcc-34-g77

compat-openmpi

compat-openmpi-psm

crypto-utils

cups-devel

cvs-inetd

dejagnu

desktop-file-utils

e2fsprogs-devel

eclipse-mylyn-cdt

eclipse-mylyn-pde

eclipse-mylyn-trac

eclipse-mylyn-webtasks

eclipse-mylyn-wikitext

eclipse-subclipse-graph

expat-devel

expect

expect

freeglut-devel

fuse-devel

gcc-gnat

gcc-java

gcc-objc

gcc-objc++

glade3

gmp-devel

gnome-common

gnome-devel-docs

gnome-python2-desktop

gnutls-devel

gstreamer-plugins-base-devel

gtk2-devel-docs

hmaccalc

httpd-devel

hunspell-devel

imake

iptables-devel

java-1.8.0-openjdk-devel

jpackage-utils

junit

kdebase-devel

kdebase-workspace-devel

kdegraphics-devel

kdelibs-apidocs

kdelibs-devel

kdemultimedia-devel

kdenetwork-devel

kdepim-devel

kdepimlibs-devel

kdesdk

kdesdk-devel

kdewebdev

ksc

libXau-devel

libXaw-devel

libXinerama-devel

libXmu-devel

libXpm-devel

libXrandr-devel

libaio-devel

libblkid-devel

libbonobo-devel

libcap-devel

libdrm-devel

libgcrypt-devel

libglade2-devel

libgnomeui-devel

libgudev1-devel

libhugetlbfs-devel

libibverbs-devel

libnl-devel

libnl3-devel

libstdc++-docs

libtiff-devel

libtopology-devel

libudev-devel

libusb-devel

libuuid-devel

libxslt-devel

mercurial

mod_dav_svn

mod_revocator

mpfr-devel

nasm

net-snmp-devel

numactl-devel

openmotif-devel

papi-devel

pcre-devel

perl-Test-Pod

perl-Test-Pod-Coverage

perltidy

popt-devel

python-docs

qt-doc

rpmdevtools

rpmlint

sane-backends-devel

snappy-devel

startup-notification-devel

systemtap-sdt-devel

systemtap-server

tcl-devel

tcp_wrappers-devel

tk-devel

unique-devel

unixODBC-devel

xorg-x11-proto-devel

xz-devel

%end

转载于:https://www.cnblogs.com/zuolw/p/6288935.html

相关文章:

  • Bounce(弹走绵羊)lct裸题
  • MyBatis insert 返回主键的方法
  • dede数据库内容替换,去掉文章内容中的img标签
  • Android javaMail使用imap协议接收邮件
  • 缓存遇到的数据过滤与分页问题
  • 通过libVirt抓取kvm虚拟机监控指标数据
  • Eclipse+Pydev
  • TTL和RS232之间的详细对比
  • NSMutableArray崩溃信息
  • 艰困之道中学到的经验教训
  • 【JAVA秒会技术之随意切换数据库】Spring如何高效的配置多套数据源
  • 国外的搜索引擎,能查到好多资料
  • 基于nginx的负载均衡概述与实现
  • 总结2016,规划2017
  • GreenOpenPaint的实现(二)打开显示图片
  • [译]前端离线指南(上)
  • 345-反转字符串中的元音字母
  • HTML5新特性总结
  • Java多线程(4):使用线程池执行定时任务
  • Js基础知识(一) - 变量
  • js数组之filter
  • sublime配置文件
  • vue-cli3搭建项目
  • 安卓应用性能调试和优化经验分享
  • 分享几个不错的工具
  • 开放才能进步!Angular和Wijmo一起走过的日子
  • 责任链模式的两种实现
  • 国内开源镜像站点
  • 你学不懂C语言,是因为不懂编写C程序的7个步骤 ...
  • 选择阿里云数据库HBase版十大理由
  • #define MODIFY_REG(REG, CLEARMASK, SETMASK)
  • $NOIp2018$劝退记
  • (1)bark-ml
  • (17)Hive ——MR任务的map与reduce个数由什么决定?
  • (BFS)hdoj2377-Bus Pass
  • (淘宝无限适配)手机端rem布局详解(转载非原创)
  • (原創) 如何動態建立二維陣列(多維陣列)? (.NET) (C#)
  • (转)详解PHP处理密码的几种方式
  • .dwp和.webpart的区别
  • .NET 4.0中的泛型协变和反变
  • .NET Core 中的路径问题
  • .NET CORE使用Redis分布式锁续命(续期)问题
  • .NET Framework Client Profile - a Subset of the .NET Framework Redistribution
  • .NET建议使用的大小写命名原则
  • .net项目IIS、VS 附加进程调试
  • @selector(..)警告提示
  • [BZOJ5125]小Q的书架(决策单调性+分治DP+树状数组)
  • [C++]C++入门--引用
  • [CTF]2022美团CTF WEB WP
  • [datastore@cyberfear.com].Elbie、[thekeyishere@cock.li].Elbie勒索病毒数据怎么处理|数据解密恢复
  • [Django 0-1] Core.Checks 模块
  • [js]- 两个对象的合并(Object.assign)
  • [nlp] tokenizer
  • [oeasy]python001_先跑起来_python_三大系统选择_windows_mac_linux
  • [ThinkPHP]Arr返回1