- 论坛徽章:
- 0
|
本帖最后由 lydongkill 于 2010-06-03 14:50 编辑
[root@sctest init.d]# vi /etc/dhcpd.conf
#
# DHCP Server Configuration file.
# see /usr/share/doc/dhcp*/dhcpd.conf.sample
#
ddns-update-style interim;
ignore client-updates;
default-lease-time 21600;
max-lease-time 43200;
#
# DHCP Server Configuration file.
# see /usr/share/doc/dhcp*/dhcpd.conf.sample
#
ddns-update-style interim;
ignore client-updates;
default-lease-time 21600;
max-lease-time 43200;
subnet 192.168.0.0 netmask 255.255.255.0 {
range dynamic-bootp 192.168.0.10 192.168.0.200;
option subnet-mask 255.255.255.0;
option time-offset -18000;
}
option space PXE;
option PXE.mtftp-ip code 1 = ip-address;
option PXE.mtftp-cport code 2 = unsigned integer 16;
option PXE.mtftp-sport code 3 = unsigned integer 16;
option PXE.mtftp-tmout code 4 = unsigned integer 8;
option PXE.mtftp-delay code 5 = unsigned integer 8;
option PXE.discovery-control code 6 = unsigned integer 8;
option PXE.discovery-mcast-addr code 7 = ip-address;
class "pxeclients" {
match if substring (option vendor-class-identifier, 0, 9) = "PXEClient";
option vendor-class-identifier "PXEClient";
vendor-option-space PXE;
option PXE.mtftp-ip 0.0.0.0;
filename "pxelinux.0";
next-server 192.168.0.138;
}
[root@sctest pxelinux.cfg]# vi default
default local
prompt 1
timeout 600
label local
localboot 0
label text
kernel vmlinuz
append netmask=255.255.255.0 gateway=192.168.0.1 ksdevice=eth1 initrd=initrd.img nofb text ks=http://192.168.0.138/ks.cfg
~
[root@sctest html]# vi ks.cfg
# Kickstart file automatically generated by anaconda.
install
text
#reboot
lang en_US.UTF-8
keyboard us
timezone Asia/Shanghai
key --skip
firstboot --disable
selinux --disabled
firewall --disabled
#network --device eth0 --bootproto dhcp
authconfig --enableshadow --enablemd5
bootloader --location=mbr --driveorder=hda,sda --append="rhgb quiet"
rootpw --iscrypted $1$sc49Qg3B$hjJtNbFr3CVq89gw79Hby1
url --url=http://192.168.0.138/cds20/
# The following is the partition information you requested
# Note that any partitions you deleted are not expressed
# here so unless you clear all partitions first, this is
# not guaranteed to work
zerombr
"ks.cfg" 207L, 4050C
# Kickstart file automatically generated by anaconda.
install
text
#reboot
lang en_US.UTF-8
keyboard us
timezone Asia/Shanghai
key --skip
firstboot --disable
selinux --disabled
firewall --disabled
#network --device eth0 --bootproto dhcp
authconfig --enableshadow --enablemd5
bootloader --location=mbr --driveorder=hda,sda --append="rhgb quiet"
rootpw --iscrypted $1$sc49Qg3B$hjJtNbFr3CVq89gw79Hby1
url --url=http://192.168.0.138/cds20/
# The following is the partition information you requested
# Note that any partitions you deleted are not expressed
# here so unless you clear all partitions first, this is
# not guaranteed to work
zerombr
clearpart --drives=hda,sda --initlabel
part /boot --fstype="ext3" --size=250 --ondisk=hda
part / --fstype="ext3" --size=1 --ondisk=hda --grow
part /arroyo/db --fstype="ext3" --size=50000 --ondisk=sda
part /home --fstype="ext3" --size=30000 --ondisk=sda
part /var --fstype="ext3" --size=10000 --ondisk=sda
part swap --size=8192 --ondisk=sda
part /arroyo --fstype="ext3" --size=1 --ondisk=sda --grow
%packages
@core
@base
device-mapper-multipath
-nss-tools
-nss_db
-acpid
-nss_ldap
-rhn-check
-pam_pkcs11
-readahead
-krb5-workstation
-ksh
-lftp
unzip
-crash
-aspell-en
-stunnel
-words
-apmd
-coolkey
-dhclient
-aspell
-numactl
-mgetty
-fbset
-man-pages
-vconfig
-dump
-dosfstools
-mdadm
-libaio
ftp
-rsync
-nano
-finger
-irqbalance
-autofs
-sendmail
-rdate
-conman
wget
-symlinks
-pcmciautils
-yum
-yum-updatesd
-redhat-lsb
-pam_ccreds
-mlocate
-pam_smb
-sos
-mtools
-pkinit-nss
-gpm
zip
-microcode_ctl
-cpuspeed
-dhcpv6_client
-NetworkManager
-mozldap
tcpdump
-specspo
-iptstate
-rsh
-setuptool
-nfs-utils
-pinfo
-ipsec-tools
-sysreport
-rp-pppoe
-unix2dos
-svrcore
-mtr
-mkbootdisk
-tree
-yum-rhn-plugin
-OpenIPMI
-pam_krb5
-irda-utils
-pam_passwdqc
-amtu
-rng-utils
sudo
-ypbind
-jwhois
-rhn-setup
-rdist
-pax
-nc
which
-smartmontools
-ccid
tcsh
-yum-security
-anacron
-m2crypto
telnet
-dos2unix
-setarch
-eject
-bluez-utils
-logwatch
-usbutils
-gnupg
time
-talk
perl
strace
ntp
gdb
binutils
%post
#
# Now install the software
#
mknod /dev/calypso c 234 0
chmod 666 /dev/calypso
rm -f /etc/rc*/*sendmail
rm -f /etc/rc*/*irqbalance
echo "blacklist e1000" >> /etc/modprobe.d/blacklist
groupadd -g 503 isa
groupadd -g 504 bss
groupadd -g 505 db
groupadd -g 506 oss
groupadd -g 508 msa
groupadd -g 510 asmrpt
groupadd -g 511 aimmgr
useradd -u 503 -g 503 -G isa -d /home/isa -s /bin/tcsh -c "ISA Acct" -p `openssl passwd -crypt calypso` isa
useradd -u 504 -g 504 -G bss -d /home/bss -s /bin/bash -c "BSS Acct" -p `openssl passwd -crypt calypso` bss
useradd -u 505 -g 505 -G db -d /home/db -s /bin/bash -c "DB Acct" -p `openssl passwd -crypt calypso` db
useradd -u 506 -g 506 -G oss -d /home/oss -s /bin/bash -c "OSS Acct" -p `openssl passwd -crypt calypso` oss
useradd -u 508 -g 508 -G msa -d /opt/msa -s /bin/bash -c "MSA Acct" -p `openssl passwd -crypt calypso` msa
useradd -u 510 -g 510 -G asmrpt -d /arroyo/asmrpt -s /bin/bash -c "ASM FTP Acct" -p `openssl passwd -crypt asmrpt` asmrpt
useradd -u 511 -g 511 -G aimmgr -d /arroyo/asmrpt/adi -s /bin/bash -c "AIM FTP Acct" -p `openssl passwd -crypt aim123` aimmgr
mkdir /home/stats
mkdir /arroyo/log
mkdir /arroyo/archive
mkdir /arroyo/archive/arroyo_log
mkdir /arroyo/archive/isa_log
mkdir /arroyo/image
mkdir /arroyo/test
mkdir /mnt/cdrom
chmod 755 /home/isa
chmod 777 /arroyo/log
chown isa:isa /arroyo/db
chown isa:isa /arroyo/archive/isa_log
cd /
wget http://192.168.0.138/overlay/CDS-TV-2.2.1.iso -o /tmp/cds-iso_get.out
cd /root
wget http://192.168.0.138/overlay/INST.SH -o /tmp/cds-iso_get.out
chmod 700 cdsinstall
## Need to install Kernel/Cserver Here.
#/mnt/cdrom/inst.sh common
#rm -rf /mnt/cdrom/*
#Above 2 cmds are broken so just do the basics
#cd /mnt/cdrom
#cp *.tgz /
#cd /
#tar xvfz common-base.tgz
#rm -rf /mnt/cdrom/*
[root@sctest xinetd.d]# vi tftp
# default: off
# description: The tftp server serves files using the trivial file transfer \
# protocol. The tftp protocol is often used to boot diskless \
# workstations, download configuration files to network-aware printers, \
# and to start the installation process for some operating systems.
service tftp
{
socket_type = dgram
protocol = udp
wait = yes
user = root
server = /usr/sbin/in.tftpd
server_args = -s /tftpboot
disable = no
per_source = 11
cps = 100 2
flags = IPv4
} |
|