Вы находитесь на странице: 1из 5

11/13/2016

RootofLinux!:ConfiguringPXEBootserveronRHEL6/CentOS6
1

More NextBlog

CreateBlog

RootofLinux!
BasictoAdvanceManagementandAdministrationonLinux
Home
SEARCHTHISBLOG

MONDAY,8APRIL2013

Search

ConfiguringPXEBootserveronRHEL6/CentOS6

JBOSSEAP6.XCONFIGURATION

ClickHereforJBossEAP
HOWTO'S

ClickHereHowTo's
SERVERSCONFIGURATION

ClickHereforServers
Configuration

Step1:FirstSetthestaticIPaddress
#vim/etc/sysconfig/networkscripts/ifcfgeth0
BOOTPROTO=static
IPADDR=192.168.0.254
NETMASK=255.255.255.0
GATEWAY=192.168.0.254
DNS1=192.168.0.254
:wq(saveandexit)
NowRestartthenetworkservice
#servicenetworkrestart
#chkconfignetworkon
Step2:InserttheRHEL6dvdintoDVDROMandmountit.
#mount/dev/sr0/mnt/
NowyouneedtoconfigureYUMservertoinstallpackages,sousethe
followingsteptoconfigureYUMserver.formoreinformationabout
packagemanagement,pleasevisitmypreviousblog.
#cd/mnt/Packages/
#rpmivhvsftpd<tab>
#rpmivhdeltarpm<tab>
#rpmivhpythondeltarpm<tab>
#rpmivhcreaterepo<tab>
Note:deltarpm,pythondeltarpmbotharedependenciesofcreaterepo
package.
NowcopyentireRHEL6dvdinto/var/ftp/pub/rhel6/dvd
Note:beforecopyingRHEL6DVD,firstinsurethat,youhaveenough
diskspacein/var/ftp/pubornot.
#mkdirp/var/ftp/pub/rhel6/dvd
#cprvf/mnt/*/var/ftp/pub/rhel6/dvd
Nowcreatearepofileforyumserver
#cd/etc/yum.repos.d/
#rmrf*
#vimyum.repo
[server]
name=PXEserver
baseurl=file:///var/ftp/pub/rhel6/dvd
enabled=1
gpgcheck=0
:wq(saveandexit)
NowCreatelocalrepositoryforYUMserver

http://sureshchandra.blogspot.in/2013/04/configuringpxebootserveronrhel6.html

1/5

11/13/2016

RootofLinux!:ConfiguringPXEBootserveronRHEL6/CentOS6
#createrepov/var/ftp/pub/rhel6/dvd
Setp3:Nowinstallhttpd,andkickstart,packagesusingyumserver
#yuminstallhttpdsystemconfigkickstarty
Nowcreateasoftlinkof/var/ftp/pub/into/var/www/html/directory,
sothatyoucanaccessthisrepositoryandinstallationtreeusingFTP
andHTTPprotocol.
#lns/var/ftp/pub//var/www/html/
NowfixyourSELinuxsecuritycontextbyusing"restorecon"command
#restoreconR/var/www/html/
#restoreconR/var/ftp/pub/
Nowrestartyourservicesof"vsftpd"and"httpd"
#servicevsftpdrestart
#chkconfigvsftpdon
#servicehttpdrestart
#chkconfighttpdon
Step4:NowcreateakickstartfileforunattendinstallationforRHEL
6andsaveinto/var/ftp/pub/withthenameofworkstation.cfg
Step5:Nowinstallsyslinux,xinetd,tftpserver,dhcpusingyum
#yuminstallsyslinuxxinetdtftpserverdhcpy
Nowcreatea"pxelinux.cfg"directoryin/var/lib/tftpboot/directory
#mkdir/var/lib/tftpboot/pxelinux.cfg

Nowcopy"pxelinux.0"filefrom/usr/share/syslinux/pxelinux.0to/var/lib/tftpboot/directory

#cp/usr/share/syslinux/pxelinux.0/var/lib/tftpboot/

Nowenableyourtftpserver,becausedefaultisdisable.andstartthetftpserver.

#vim/etc/xinetd.d/tftp
Disable=no
#servicexinetdrestart
chkconfigxinetdon

Step6:ConfigureDHCP

Firstcopythedhcpd.conf.samplefileinto/etc/dhcp/dhcpd.conf

#cp/usr/share/doc/dhcp4.1.1/dhcpd.conf.sample/etc/dhcp/dhcpd.conf

NowEditdhcpd.conffileaccordingtoyournetwork
#vim/etc/dhcp/dhcpd.conf

http://sureshchandra.blogspot.in/2013/04/configuringpxebootserveronrhel6.html

2/5

11/13/2016

RootofLinux!:ConfiguringPXEBootserveronRHEL6/CentOS6
Allowbooting;
Allowbootp;
authoritative;
#Thisistheverybasicsubnetdeclaration.
subnet192.168.0.0netmask255.255.255.0{
range192.168.0.1192.168.0.50;
optionrouters192.168.0.254;
optiondomainname"example.com";
optiondomainnameservers192.168.0.254;
defaultleasetime21600;
maxleasetime43200;

#PXEclientIPrange
rangedynamicbootp192.168.0.51192.168.0.100;
filename"pxelinux.0";
nextserver192.168.0.254;
}

:wq(saveandexit)

#servicedhcpdrestart
#chkconfigdhcpdon

Step7:NowcopythefollowingfilesfromRHEL6DVDinto/var/lib/tftpboot/directory

#cd/var/ftp/pub/rhel6/dvd/images/pxeboot/
#cpvmlinuz/var/lib/tftpboot/
#cpinitrd.img/var/lib/tftpboot/
#cp/usr/share/syslinux/menu.c32/var/lib/tftpboot/

#cd/var/ftp/pub/rhel6/dvd/isolinux/
#cprvf*/var/lib/tftpboot/

Nowyouneedtocreateabootmenu

#vim/var/lib/tftpboot/pxelinux.cfg/default
defaultvesamenu.c32
#prompt1
timeout600
displayboot.msg

http://sureshchandra.blogspot.in/2013/04/configuringpxebootserveronrhel6.html

3/5

11/13/2016

RootofLinux!:ConfiguringPXEBootserveronRHEL6/CentOS6

menubackgroundsplash.jpg
menutitleWelcometotheRHEL6PXEInstallation!
labellocal
menulabelbootfrom^localdrive
menudefault
localboot0xffff

labelws
menulabelInstallRHEL6^workstation
kernelvmlinuz

appendbiosdevname=0ksdevice=linkload_ramdisk=1initrd=initrd.imgnetworkks=http://192.168.0.254/pu

:wq(saveandexit)

NowbootyourclientmachineusingPXEandenjoy................!
PostedbySureshChandraat08:07
+1 Recommend this on Google

4comments:
AshutoshMaurya 23January2014at06:16
SirplzdescribeHowtoSettingUpAMultibootPXEInstallServerOncennos....
Reply
Replies
SURESHCHANDRA 23January2014at06:19
PleasedescribeyourQuestion?

AshutoshMaurya 23January2014at07:40
sir,
IwanttosetupaPXEserverforMultipleLinuxDistributionsonCentos...
ForExample..Centos,Fedora,Ubuntu...
Plzhelp...
Reply

AshutoshMaurya 23January2014at07:39
Thiscommenthasbeenremovedbytheauthor.
Reply

http://sureshchandra.blogspot.in/2013/04/configuringpxebootserveronrhel6.html

4/5

11/13/2016

RootofLinux!:ConfiguringPXEBootserveronRHEL6/CentOS6

Enteryourcomment...

Commentas:

Publish

Unknown(Google)

Signout

Notifyme

Preview

NewerPost

Home

OlderPost

Subscribeto:PostComments(Atom)

PictureWindowtemplate.PoweredbyBlogger.

http://sureshchandra.blogspot.in/2013/04/configuringpxebootserveronrhel6.html

5/5

Вам также может понравиться