This Guide will explain how to install Vserver in Fedora and then How to Install MyPLC in Vserver
Step 1 : Install Fedora 12 without GUI (do not Install Any X11 packages Because in GUI mode vserver not Installing Properly)
Option 1 :
Download Fedora Net Install ISO and Install while Installing Choose Minimal as Installation Option Because It is Not Going to Install Any GUI Component.
Download Link for Fedora 12 Net Install ISO
Option 2:
Download Fedora 12 DVD and while Installing Choose Minimal as Installation Option Because It is Not Going to Install Any GUI Component, And Coustamize packages and remove all GUI packages and Multimedia Packages and all Applications which contain GUI.
Download Link for Fedora 12 DVD
Goto Step 2 If you Installed Fedora With Out GUI
Step 2:
Stop SELINUX
Check this http://linux-problem-solver.blogspot.in/2012/09/disabling-selinux-in-fedora.html
Step 3:
Stop IPTable ( Firewall )
Check this http://linux-problem-solver.blogspot.in/2012/09/disable-or-turnoff-iptables-firewall-in.html
Step 4:
If you did not restart system after step2, step3 then restart your System now.
Step 5:
Add Vserver repo
[root@xyz~]# cd /etc/yum.repos.d/
[root@xyz yum.repos.d]# vim vserver.repo
#Add Only One based on 32 bit or 64 bit
#for 32 bit Fedora
#Add Following Lines to vserever.repo
#for 64 bit Fedora
#Add Following Lines to vserever.repo
For 64 bit System
[root@xyz svn-build]# ./vtest-init-vserver.sh -f f12 -d onelab -p linux64 vtest64 http://ftp-stud.hs-esslingen.de/pub/Mirrors/archive.fedoraproject.org/fedora/linux/releases/12/Everything/x86_64/os/Packages/ -- --interface eth0:138.96.255.221 --hostname vnode01.inria.fr &> vtest64.log&
Step 1 : Install Fedora 12 without GUI (do not Install Any X11 packages Because in GUI mode vserver not Installing Properly)
Option 1 :
Download Fedora Net Install ISO and Install while Installing Choose Minimal as Installation Option Because It is Not Going to Install Any GUI Component.
Download Link for Fedora 12 Net Install ISO
Option 2:
Download Fedora 12 DVD and while Installing Choose Minimal as Installation Option Because It is Not Going to Install Any GUI Component, And Coustamize packages and remove all GUI packages and Multimedia Packages and all Applications which contain GUI.
Download Link for Fedora 12 DVD
Goto Step 2 If you Installed Fedora With Out GUI
Step 2:
Stop SELINUX
Check this http://linux-problem-solver.blogspot.in/2012/09/disabling-selinux-in-fedora.html
Step 3:
Stop IPTable ( Firewall )
Check this http://linux-problem-solver.blogspot.in/2012/09/disable-or-turnoff-iptables-firewall-in.html
Step 4:
If you did not restart system after step2, step3 then restart your System now.
Step 5:
Add Vserver repo
[root@xyz~]# cd /etc/yum.repos.d/
[root@xyz yum.repos.d]# vim vserver.repo
#Add Only One based on 32 bit or 64 bit
#for 32 bit Fedora
#Add Following Lines to vserever.repo
[vserver]
name=Linux-VServer related packages for Fedora $releasever - $basearch
baseurl=http://build.onelab.eu/vserver/f12/i686
gpgcheck=0
#gpgkey=http://build.onelab.eu/conf/keys/RPM-ONELAB-GPG-KEY
#for 64 bit Fedora
#Add Following Lines to vserever.repo
[vserver]
name=Linux-VServer related packages for Fedora $releasever - $basearch
baseurl=http://build.onelab.eu/vserver/f12/x86_64/
gpgcheck=0
#gpgkey=http://build.onelab.eu/conf/keys/RPM-ONELAB-GPG-KEY
Step 6:
Add this Line : exclude=kernel* util-vserver* yum in fedora.repo the location is before
[fedora-debuginfo] line Like below
[root@xyz~]# cd /etc/yum.repos.d/
[root@xyz yum.repos.d]# vim fedora.repo
[root@xyz yum.repos.d]# vim fedora.repo
[fedora]
...
...
...
exclude=kernel* util-vserver* yum
[fedora-debuginfo]
...
...
Step 7:
Add this Line : exclude=kernel* util-vserver* yum in fedora-update.repo the location is before
[fedora-debuginfo] line Like below
[root@xyz~]# cd /etc/yum.repos.d/
[root@xyz yum.repos.d]# vim fedora.repo
[root@xyz yum.repos.d]# vim fedora.repo
[fedora]
...
...
...
exclude=kernel* util-vserver* yum
[fedora-debuginfo]
...
...
Step 8:
yum install kernel
It will Install Kernel like kernel-2.6.32.11-162.vs2.3.0.36.29.4.fc12.i686 [this kernel will support Vserver with out any Problem)
step 9:
Open Grub file and set timeout to 10 seconds or any value And Default to 0 because it
will select latest installed kernal as default kernel
[root@xyz~]# vi /etc/grub.conf
.....
.....
default=0
timeout=10
....
....
Restart So System will boot into Newly Installed Kernel
Check which kernel is selected by typing uname -a in terminal
[root@xyz~]# uname -a
Linux center.cmmacs.ernet.in 2.6.32.11-162.vs2.3.0.36.29.4.fc12.i686 #1 SMP Thu Dec 2 19:34:22 CET 2010 i686 i686 i386 GNU/Linux
Step 10:
Install kernel-firmware version which is related to our installed kernel
For 32 bit
[root@xyz~]# rpm -U --force http://build.onelab.eu/vserver/f12/i686/kernel-firmware-2.6.32.11-162.vs2.3.0.36.29.4.fc12.i686.rpm
for 64 bit
[root@xyz~]# rpm -U --force http://build.onelab.eu/vserver/f12/x86_64/kernel-firmware-2.6.32.11-162.vs2.3.0.36.29.4.fc12.x86_64.rpm
Step 11:
Install yum which support chroot
[root@xyz~]# rpm -qa | grep yum
yum-utils-1.1.26-1.fc12.noarch
yum-3.2.28-5.fc12.noarch
yum-metadata-parser-1.1.2-14.fc12.i686
yum-utils-1.1.26-1.fc12.noarch
yum-3.2.28-5.fc12.noarch
yum-metadata-parser-1.1.2-14.fc12.i686
#Remove yum
[root@xyz~]# rpm -e --nodeps yum-3.2.28-5.fc12.noarch
Success, Now
For 32 bit
[root@xyz~]# rpm -ivh http://build.onelab.eu/vserver/f12/i686/yum-3.2.25-2chroot.noarch.rpm
For 64 bit
[root@xyz~]# rpm -ivh http://build.onelab.eu/vserver/f12/x86_64/yum-3.2.25-2chroot.noarch.rpm
Step 11:
Install Necessary Packages
[root@xyz~]# yum install util-vserver util-vserver-build
[root@xyz~]# yum install subversion
[root@xyz~]# yum install httpd
[root@xyz~]# yum install createrepo
[root@xyz~]# yum install qemu
[root@xyz~]# yum install bridge-utils
[root@xyz~]# yum install emacs
[root@xyz~]# yum install ntp
Step 12:
Download Necessary Files to Setup Vserver Properly
[root@xyz~]# cd
[root@xyz~]# svn co http://svn.planet-lab.org/svn/build/trunk svn-build
If SVN showning unknown host error set proxy for SVN like below
[root@xyz~]# vi /etc/subversion/servers
Edit the file Like below
[Global]
http-proxy-host=my.proxy.com
http-proxy-port=3128
Step 13:
Copy Distribution files to /etc/vservers/.distributions
[root@xyz~]# cd
[root@xyz~]# cd svn-build
[root@xyz svn-build]# cd mirroring
[root@xyz mirroring]# cp -r * /etc/vservers/.distributions
Step 14:
Initializing Vserver Distributions
[root@xyz mirroring]# sh mirror.sh -a
[root@xyz mirroring]# sh mirror.sh init
Step 15: Verifying the setup
Going to install Fedora 12 in Vserver
Go to /etc/vservers/.distributions
[root@xyz~]# cd /etc/vservers/.distributions
[root@xyz .distributions]# ls
centos5 f10 f12 f13 f7 f8 fc1 fc2 fc3 fc4 fc5 fc6 rh9 suse91
[root@xyz .distributions]# cd f12
[root@xyz f12]# cd yum.repos.d/
[root@xyz yum.repos.d]# ls
building.repo building.repo.in
IF building.repo not there then
[root@xyz yum.repos.d]# cp building.repo.in building.repo
Step 16: Adding MYPLC repository to Vserver repository
Going to install MyPLC in Vserver of Fedora 12
[root@xyz~]# cd /etc/vservers/.distributions/f12/yum.repos.d
#Note to create vserver Successfully we need to change gpgcheck=1 to gpgcheck=0 in .repo file
[root@xyz yum.repos.d]# vim building.repo
[fedora]
name=Fedora 12 - $basearch
baseurl=http://ftp-stud.hs-esslingen.de/pub/Mirrors/archive.fedoraproject.org/fedora/linux/releases/12/Everything/$basearch/os/
enabled=1
metadata_expire=7d
gpgcheck=0
gpgkey=http://mirror.onelab.eu/keys/RPM-GPG-KEY-fedora-12-primary
[updates]
name=Fedora 12 - $basearch - Updates
baseurl=http://ftp-stud.hs-esslingen.de/pub/Mirrors/archive.fedoraproject.org/fedora/linux/updates/12/$basearch/
enabled=1
metadata_expire=7d
gpgcheck=0
gpgkey=http://mirror.onelab.eu/keys/RPM-GPG-KEY-fedora-12-primary
Add MYPLC Repository location in building.repo file
[root@xyz yum.repos.d]# vim building.repo
[fedora]
...
...
...
#For 32 bit
[myplc]
name= MyPLC
baseurl=http://build.onelab.eu/5.0/rc32/onelab--5.0-rc32-f12-32/RPMS/
enabled=1
gpgcheck=0
#For 64 bit
[myplc]
name= MyPLC
baseurl=http://build.onelab.eu/5.0/rc32/onelab--5.0-rc32-f12-64/RPMS/
enabled=1
gpgcheck=0
Step 17:
Some times while creating Vserver we get error /proc/uptime can not be accessed
to Avoid this before creating Vserver Start vprocunhide script
[root@xyz~]# cd /etc/init.d/
[root@xyz init.d]# ./vprocunhide start
Step 18:
Create Vserver
[root@xyz svn-build]# cd ~/svn-build
For 32 bit System
[root@xyz svn-build]# ./vtest-init-vserver.sh -f f12 -d onelab -p linux32 vtest32 http://ftp-stud.hs-esslingen.de/pub/Mirrors/archive.fedoraproject.org/fedora/linux/releases/12/Everything/i386/os/Packages/ -- --interface eth0:138.96.255.221 --hostname vnode01.inria.fr &> vtest32.log&
For 64 bit System
Check RPM packages location connecting or not other wise change location, currently
http://ftp-stud.hs-esslingen.de/pub/Mirrors/archive.fedoraproject.org/fedora/linux/releases/12/Everything/i386/os/Packages/ link is working properly
Step 19:
Start Vserver and Install MYPLC
[root@xyz~]# vserver vtest32 start
[root@xyz~]# vserver vtest32 enter
[vtest32 ] /# yum install plc
Install myplc
[vtest32 ] /# yum install myplc
make myplc start at system startup
[vtest32 ] /# chkconfig plc on
Start MYPLC if you done all steps correctly then you will see text like below
[vtest32 ] /# service plc start
PLC: Generating network files: [ OK ]
PLC: Generating SSL certificates for: PLC: WWW: PLC: API: P[ OK ]:
PLC: Generating GPG keys: [ OK ]
PLC: Generating SSH keys: [ OK ]
PLC: Starting web server: PLC: Setting PHP timezone to GMT:[ OK ]
PLC: Starting PostgreSQL server: [ OK ]
PLC: Configuring the API: [ OK ]
PLC: Bootstrapping the database: PLC: - 101-up-leases.sql (dbdumped): PLC: - 102-up-isvalid.sql (dbdumped): PLC: - 103-up-extensions.sql (dbdumped): PLC: - 104-up-noderole.sql (dbdumped): PLC: - 105-up-timespent.sq[ OK ]ped):
PLC: Starting DNS server: PLC: Configuring resolv.conf: [ OK ]
PLC: Creating BootCD variants: [ OK ]
PLC: Rebuilding Boot CD: [ OK ]
[ OK ]
PLC: Signing and indexing node packages: [ OK ]
[vtest32 ] /# yum install myplc
make myplc start at system startup
[vtest32 ] /# chkconfig plc on
Start MYPLC if you done all steps correctly then you will see text like below
[vtest32 ] /# service plc start
PLC: Generating network files: [ OK ]
PLC: Generating SSL certificates for: PLC: WWW: PLC: API: P[ OK ]:
PLC: Generating GPG keys: [ OK ]
PLC: Generating SSH keys: [ OK ]
PLC: Starting web server: PLC: Setting PHP timezone to GMT:[ OK ]
PLC: Starting PostgreSQL server: [ OK ]
PLC: Configuring the API: [ OK ]
PLC: Bootstrapping the database: PLC: - 101-up-leases.sql (dbdumped): PLC: - 102-up-isvalid.sql (dbdumped): PLC: - 103-up-extensions.sql (dbdumped): PLC: - 104-up-noderole.sql (dbdumped): PLC: - 105-up-timespent.sq[ OK ]ped):
PLC: Starting DNS server: PLC: Configuring resolv.conf: [ OK ]
PLC: Creating BootCD variants: [ OK ]
PLC: Rebuilding Boot CD: [ OK ]
[ OK ]
PLC: Signing and indexing node packages: [ OK ]
MyPLC Installation Completed
No comments:
Post a Comment