Tampilkan postingan dengan label Installing. Tampilkan semua postingan
Tampilkan postingan dengan label Installing. Tampilkan semua postingan

Minggu, 24 Juli 2011

Installing Lighttpd With PHP5 And MySQL Support On CentOS 5.6

Lighttpd is a secure, fast, standards-compliant web server designed for speed-critical environments. This tutorial shows how you can install Lighttpd on a CentOS 5.6 server with PHP5 support (through FastCGI) and MySQL support.

Comments (0)Add Comment
You must be logged in to post a comment. Please register if you do not have an account yet.
busy

View the original article here

Rabu, 06 Juli 2011

Installing Lighttpd With PHP5 And MySQL Support On Ubuntu 11.04

Lighttpd is a secure, fast, standards-compliant web server designed for speed-critical environments. This tutorial shows how you can install Lighttpd on an Ubuntu 11.04 server with PHP5 support (through FastCGI) and MySQL support.


View the original article here

Selasa, 05 Juli 2011

Installing Nginx With PHP5 (And PHP-FPM) And MySQL Support On Ubuntu 11.04

Nginx (pronounced "engine x") is a free, open-source, high-performance HTTP server. Nginx is known for its stability, rich feature set, simple configuration, and low resource consumption. This tutorial shows how you can install Nginx on an Ubuntu 11.04 server with PHP5 support (through PHP-FPM) and MySQL support.


View the original article here

Senin, 23 Mei 2011

Installing Apache2 With PHP5 And MySQL Support On Ubuntu 11.04 (LAMP)

LAMP is short for Linux, Apache, MySQL, PHP. This tutorial shows how you can install an Apache2 webserver on an Ubuntu 11.04 server with PHP5 support (mod_php) and MySQL support.


Read more at HowtoForge


View the original article here

Sabtu, 30 April 2011

Installing Zimbra Collaboration Suite 7 On CentOS 5.x (64Bit)

This article explains how to install Zimbra Collaboration Suite 7 (ZCS) on CentOS 5.x (64Bit). Prepared by Rafael Marangoni, from BRLink Suporte Linux Team.


Zimbra is a collaboration suite very widely used in the world. Users can share folders, contacts, schedules and other things, using a very rich web interface. Click here to know more about it.


One important note is that we're using CentOS 5 64bits, that is not oficially supported by Zimbra team (only RHEL and SUSE are). But CentOS works fine with Zimbra.


First, we need to configure the DNS entry that is pointing to the server. In this case, we're using the hostname zimbratest.example.com


Then, we need to configure the hostname in the Linux box.

vi /etc/sysconfig/network

NETWORKING=yesNETWORKING_IPV6=noHOSTNAME=zimbratest.example.comvi /etc/hosts

127.0.0.1 localhost.localdomain localhost10.0.0.234 zimbratest.example.com zimbratest

Next, we need to install some packages:

yum install -y sysstat perl sudo sqlite


I suggest that you reboot the Linux box at this point, to apply all the configs.


First, we need to download the tarball from Zimbra's website. Click here.

mkdir /download
cd /download
wget http://files2.zimbra.com/downloads/7.0.1_GA/zcs-7.0.1_GA_3105.RHEL5_64.20110304210645.tgz


Initiate the installer:

tar -zxvf zcs-7.0.1_GA_3105.RHEL5_64.20110304210645.tgz
cd zcs-7.0.1_GA_3105.RHEL5_64.20110304210645
./install.sh --platform-override


PS: The Zimbra installation script checks if the distro is RHEL. To ignore that and install on CentOS, you must use "--platform-override".


The installation script is a wizard. For almost all the options, we'll select the default option. These are the questions:


If you leave the question in blank, it will select the default option.


First, we need to agree with the license terms.

Do you agree with the terms of the software license agreement? [N] y


Now, Zimbra will check all the prerequisites. If anything is not found, stop the Wizard and install it with yum.


If everything is ok, the script will ask what are the packages that we want to install. Just select the default options.


Select the packages to install
Install zimbra-ldap [Y]
Install zimbra-logger [Y]
Install zimbra-mta [Y]
Install zimbra-snmp [Y]
Install zimbra-store [Y]
Install zimbra-apache [Y]
Install zimbra-spell [Y]
Install zimbra-memcached [N]
Install zimbra-proxy [N]


Afterwards, the script asks you if you want to override the platform. You say "yes", of course.



You appear to be installing packages on a platform different
than the platform for which they were built.


This platform is CentOS5_64
Packages found: RHEL5_64
This may or may not work.


Using packages for a platform in which they were not designed for
may result in an installation that is NOT usable. Your support
options may be limited if you choose to continue.


Install anyway? [N] y
The system will be modified. Continue? [N] y


Now, we need to wait the installation procedures.


When all the packages are installed, a menu will be displayed with some config options. We only need to set the admin password.
To do that, we need to press 3.

Main menu


   1) Common Configuration:
2) zimbra-ldap:                             Enabled
3) zimbra-store:                            Enabled
+Create Admin User:                    yes
+Admin user to create:                 admin@zimbratest.example.com
******* +Admin Password                        UNSET
+Anti-virus quarantine user:           virus-quarantine.kzpbrsgbx7@zimbratest.example.com
+Enable automated spam training:       yes
+Spam training user:                   spam.sd5fsqtdzi@zimbratest.example.com
+Non-spam(Ham) training user:          ham.2qun60wc4@zimbratest.example.com
+SMTP host:                            zimbratest.example.com
+Web server HTTP port:                 80
+Web server HTTPS port:                443
+Web server mode:                      http
+IMAP server port:                     143
+IMAP server SSL port:                 993
+POP server port:                      110
+POP server SSL port:                  995
+Use spell check server:               yes
+Spell server URL:                     http://zimbratest.example.com:7780/aspell.php
+Configure for use with mail proxy:    FALSE
+Configure for use with web proxy:     FALSE
+Enable version update checks:         TRUE
+Enable version update notifications:  TRUE
+Version update notification email:    admin@zimbratest.example.com
+Version update source email:          admin@zimbratest.example.com


   4) zimbra-mta:                              Enabled
5) zimbra-snmp:                             Enabled
6) zimbra-logger:                           Enabled
7) zimbra-spell:                            Enabled
8) Default Class of Service Configuration:
r) Start servers after configuration        yes
s) Save config to file
x) Expand menu
q) Quit


Address unconfigured (**) items  (? - help) 3


Followed by 4. And type the admin password.

Store configuration


   1) Status:                                  Enabled
2) Create Admin User:                       yes
3) Admin user to create:                    admin@zimbratest.example.com
** 4) Admin Password                           UNSET
5) Anti-virus quarantine user:              virus-quarantine.kzpbrsgbx7@zimbratest.example.com
6) Enable automated spam training:          yes
7) Spam training user:                      spam.sd5fsqtdzi@zimbratest.example.com
8) Non-spam(Ham) training user:             ham.2qun60wc4@zimbratest.example.com
9) SMTP host:                               zimbratest.example.com
10) Web server HTTP port:                    80
11) Web server HTTPS port:                   443
12) Web server mode:                         http
13) IMAP server port:                        143
14) IMAP server SSL port:                    993
15) POP server port:                         110
16) POP server SSL port:                     995
17) Use spell check server:                  yes
18) Spell server URL:                        http://zimbratest.example.com:7780/aspell.php
19) Configure for use with mail proxy:       FALSE
20) Configure for use with web proxy:        FALSE
21) Enable version update checks:            TRUE
22) Enable version update notifications:     TRUE
23) Version update notification email:       admin@zimbratest.example.com
24) Version update source email:             admin@zimbratest.example.com


Select, or 'r' for previous menu [r] 4


Password for admin@zimbratest.example.com (min 6 characters): [7M_lgfdx3B] secret


Then press r to return to the main menu.

Store configuration


   1) Status:                                  Enabled
2) Create Admin User:                       yes
3) Admin user to create:                    admin@zimbratest.example.com
4) Admin Password                           set
5) Anti-virus quarantine user:              virus-quarantine.kzpbrsgbx7@zimbratest.example.com
6) Enable automated spam training:          yes
7) Spam training user:                      spam.sd5fsqtdzi@zimbratest.example.com
8) Non-spam(Ham) training user:             ham.2qun60wc4@zimbratest.example.com
9) SMTP host:                               zimbratest.example.com
10) Web server HTTP port:                    80
11) Web server HTTPS port:                   443
12) Web server mode:                         http
13) IMAP server port:                        143
14) IMAP server SSL port:                    993
15) POP server port:                         110
16) POP server SSL port:                     995
17) Use spell check server:                  yes
18) Spell server URL:                        http://zimbratest.example.com:7780/aspell.php
19) Configure for use with mail proxy:       FALSE
20) Configure for use with web proxy:        FALSE
21) Enable version update checks:            TRUE
22) Enable version update notifications:     TRUE
23) Version update notification email:       admin@zimbratest.example.com
24) Version update source email:             admin@zimbratest.example.com


Select, or 'r' for previous menu [r] r


And press a to apply the config. Afterwards, save the configuration data.

Main menu


   1) Common Configuration:
2) zimbra-ldap:                             Enabled
3) zimbra-store:                            Enabled
4) zimbra-mta:                              Enabled
5) zimbra-snmp:                             Enabled
6) zimbra-logger:                           Enabled
7) zimbra-spell:                            Enabled
8) Default Class of Service Configuration:
r) Start servers after configuration        yes
s) Save config to file
x) Expand menu
q) Quit


*** CONFIGURATION COMPLETE - press 'a' to apply
Select from menu, or press 'a' to apply config (? - help) a
Save configuration data to a file? [Yes]
Save config in file: [/opt/zimbra/config.11722]
Saving config in /opt/zimbra/config.11722...done.
The system will be modified - continue? [No] y


We need to wait the end of the process.

Operations logged to /tmp/zmsetup.04042011-131235.log
Setting local config values...done.
Setting up CA...done.
Deploying CA to /opt/zimbra/conf/ca ...done.
Creating SSL certificate...done.
Installing mailboxd SSL certificates...done.
Initializing ldap...done.
Setting replication password...done.
Setting Postfix password...done.
Setting amavis password...done.
Setting nginx password...done.
Creating server entry for zimbratest.example.com...done.
Saving CA in ldap ...done.
Saving SSL Certificate in ldap ...done.
Setting spell check URL...done.
Setting service ports on zimbratest.example.com...done.
Adding zimbratest.example.com to zimbraMailHostPool in default COS...done.
Installing webclient skins...
steel...done.
twilight...done.
pebble...done.
bare...done.
lemongrass...done.
beach...done.
sand...done.
sky...done.
carbon...done.
smoke...done.
lavender...done.
tree...done.
waves...done.
lake...done.
oasis...done.
bones...done.
hotrod...done.
Finished installing webclient skins.
Setting zimbraFeatureTasksEnabled=TRUE...done.
Setting zimbraFeatureBriefcasesEnabled=TRUE...done.
Setting MTA auth host...done.
Setting TimeZone Preference...done.
Initializing mta config...done.
Setting services on zimbratest.example.com...done.
Creating domain zimbratest.example.com...done.
Setting default domain name...done.
Creating domain zimbratest.example.com...already exists.
Creating admin account admin@zimbratest.example.com...done.
Creating root alias...done.
Creating postmaster alias...done.
Creating user spam.sd5fsqtdzi@zimbratest.example.com...done.
Creating user ham.2qun60wc4@zimbratest.example.com...done.
Creating user virus-quarantine.kzpbrsgbx7@zimbratest.example.com...done.
Setting spam training and Anti-virus quarantine accounts...done.
Initializing store sql database...done.
Setting zimbraSmtpHostname for zimbratest.example.com...done.
Configuring SNMP...done.
Checking for default IM conference room...not present.
Initializing default IM conference room...done.
Setting up syslog.conf...done.


You have the option of notifying Zimbra of your installation.
This helps us to track the uptake of the Zimbra Collaboration Suite.
The only information that will be transmitted is:
The VERSION of zcs installed (7.0.1_GA_3105_CentOS5_64)
The ADMIN EMAIL ADDRESS created (admin@zimbratest.example.com)


Notify Zimbra of your installation? [Yes] no
Notification skipped
Starting servers...done.
Installing common zimlets...
com_zimbra_bulkprovision...done.
com_zimbra_phone...done.
com_zimbra_attachmail...done.
com_zimbra_linkedin...done.
com_zimbra_srchhighlighter...done.
com_zimbra_attachcontacts...done.
com_zimbra_adminversioncheck...done.
com_zimbra_url...done.
com_zimbra_cert_manager...done.
com_zimbra_date...done.
com_zimbra_email...done.
com_zimbra_webex...done.
com_zimbra_dnd...done.
com_zimbra_social...done.
Finished installing common zimlets.
Restarting mailboxd...done.
Setting up zimbra crontab...done.


Moving /tmp/zmsetup.04042011-131235.log to /opt/zimbra/log


Configuration complete - press return to exit


First, we need to access the admin console:

https://zimbratest.example.com:7071


or directly by IP:

https://10.0.0.234:7071


PS: You will need to accept the SSL cert.


 

To log in, the user is admin and the password used in the installation script.


Use the admin console to configure the server.


To use the webclient, just point your browser to:

http://zimbratest.example.com


or directly by IP:

http://10.0.0.234


Zimbra Docs: http://www.zimbra.com/support/documentation/



View the original article here

Installing Lighttpd With PHP5 And MySQL Support On OpenSUSE 11.4

Lighttpd is a secure, fast, standards-compliant web server designed for speed-critical environments. This tutorial shows how you can install Lighttpd on an OpenSUSE 11.4 server with PHP5 support (through FastCGI) and MySQL support.


I do not issue any guarantee that this will work for you!


In this tutorial I use the hostname server1.example.com with the IP address 192.168.0.100. These settings might differ for you, so you have to replace them where appropriate.


First we install MySQL 5 like this:

yast2 -i mysql mysql-client mysql-community-server


Then we create the system startup links for MySQL (so that MySQL starts automatically whenever the system boots) and start the MySQL server:

chkconfig -f --add mysql
/etc/init.d/mysql start


To secure the MySQL installation, run:

mysql_secure_installation


Now you will be asked several questions:


server1:~ # mysql_secure_installation


NOTE: RUNNING ALL PARTS OF THIS SCRIPT IS RECOMMENDED FOR ALL MySQL
SERVERS IN PRODUCTION USE!  PLEASE READ EACH STEP CAREFULLY!


In order to log into MySQL to secure it, we'll need the current
password for the root user.  If you've just installed MySQL, and
you haven't set the root password yet, the password will be blank,
so you should just press enter here.


Enter current password for root (enter for none): <-- ENTER
OK, successfully used password, moving on...


Setting the root password ensures that nobody can log into the MySQL
root user without the proper authorisation.


Set root password? [Y/n] <-- Y
New password: <-- fill in your desired MySQL root password
Re-enter new password: <-- confirm that password
Password updated successfully!
Reloading privilege tables..
... Success!


By default, a MySQL installation has an anonymous user, allowing anyone
to log into MySQL without having to have a user account created for
them.  This is intended only for testing, and to make the installation
go a bit smoother.  You should remove them before moving into a
production environment.


Remove anonymous users? [Y/n] <-- Y
 ... Success!


Normally, root should only be allowed to connect from 'localhost'.  This
ensures that someone cannot guess at the root password from the network.


Disallow root login remotely? [Y/n] <-- Y
 ... Success!


By default, MySQL comes with a database named 'test' that anyone can
access.  This is also intended only for testing, and should be removed
before moving into a production environment.


Remove test database and access to it? [Y/n] <-- Y
 - Dropping test database...
... Success!
- Removing privileges on test database...
... Success!


Reloading the privilege tables will ensure that all changes made so far
will take effect immediately.


Reload privilege tables now? [Y/n] <-- Y
 ... Success!


Cleaning up...


All done!  If you've completed all of the above steps, your MySQL
installation should now be secure.


Thanks for using MySQL!


server1:~ #


Now your MySQL setup should be secured.


Lighttpd is available as an OpenSUSE package, therefore we can install it like this:

yast2 -i lighttpd


Then we create the system startup links for Lighttpd (so that Lighttpd starts automatically whenever the system boots) and start it:

chkconfig -f --add lighttpd
/etc/init.d/lighttpd start


Now direct your browser to http://192.168.0.100, and you should see that Lighttpd delivers a page (well, it's a 404 page because there's no index file in Lighttpd's document root, but at least this means that Lighttpd is working ok):


Lighttpd's default document root is /srv/www/htdocs on OpenSUSE, and the configuration file is /etc/lighttpd/lighttpd.conf.

We can make PHP5 work in Lighttpd through FastCGI. There's a FastCGI package for PHP5 available on OpenSUSE, php5-fastcgi, which we install like this:

yast2 -i php5-fastcgi

Installing Lighttpd With PHP5 And MySQL Support On OpenSUSE 11.4 - Page 2

View the original article here

Jumat, 29 April 2011

Installing Cherokee With PHP5 And MySQL Support On Debian Squeeze

Cherokee is a very fast, flexible and easy to configure Web Server. It supports the widespread technologies nowadays: FastCGI, SCGI, PHP, CGI, TLS and SSL encrypted connections, virtual hosts, authentication, on the fly encoding, load balancing, Apache compatible log files, and much more. This tutorial shows how you can install Cherokee on a Debian Squeeze server with PHP5 support (through FastCGI) and MySQL support.


I do not issue any guarantee that this will work for you!


In this tutorial I use the hostname server1.example.com with the IP address 192.168.0.100. These settings might differ for you, so you have to replace them where appropriate.


First we install MySQL 5 like this:

apt-get install mysql-server mysql-client


You will be asked to provide a password for the MySQL root user - this password is valid for the user root@localhost as well as root@server1.example.com, so we don't have to specify a MySQL root password manually later on:


New password for the MySQL "root" user: <-- yourrootsqlpassword
Repeat password for the MySQL "root" user: <-- yourrootsqlpassword


Cherokee is available as a Debian package, therefore we can install it like this:

apt-get install cherokee


Now direct your browser to http://192.168.0.100, and you should see the Cherokee placeholder page:


 Click to enlarge

Cherokee can be configured through a web-based control panel which we can start as follows:

cherokee-admin -b


(By default cherokee-admin binds only to 127.0.0.1 (localhost), which means you can only connect to it from the same system. With the -b parameter you can specify the network address to listen to. If no IP is provided, it will bind to all interfaces.)


Output should be similar to this one:

root@server1:~# cherokee-admin -b


Login:
User:              admin
One-time Password: 1Kkcc58atG8DNIM7


Web Interface:
URL:               http://localhost:9090/


[11/04/2011 12:14:18.622] (error) rrd_tools.c:120 - Could not find the rrdtool binary.
Cherokee Web Server 1.0.8 (Jan 11 2011): Listening on port ALL:9090, TLS
disabled, IPv6 enabled, using epoll, 4096 fds system limit, max. 2041
connections, caching I/O, single thread


You need the username and password to log into the web interface which can be found on http://192.168.0.100:9090/:


This is how the web interface looks:  

To stop cherokee-admin, type CTRL+C on the shell.


We can make PHP5 work in Cherokee through FastCGI. Fortunately, Debian provides a FastCGI-enabled PHP5 package which we install like this:

apt-get install php5-cgi


We must modify /etc/php5/cgi/php.ini and uncomment the line cgi.fix_pathinfo=1:

vi /etc/php5/cgi/php.ini

[...]; cgi.fix_pathinfo provides *real* PATH_INFO/PATH_TRANSLATED support for CGI. PHP's; previous behaviour was to set PATH_TRANSLATED to SCRIPT_FILENAME, and to not grok; what PATH_INFO is. For more information on PATH_INFO, see the cgi specs. Setting; this to 1 will cause PHP CGI to fix its paths to conform to the spec. A setting; of zero causes PHP to behave as before. Default is 1. You should fix your scripts; to use SCRIPT_FILENAME rather than PATH_TRANSLATED.; http://php.net/cgi.fix-pathinfocgi.fix_pathinfo=1[...]

Then we restart Cherokee:

/etc/init.d/cherokee restart

Installing Cherokee With PHP5 And MySQL Support On Debian Squeeze - Page 2

View the original article here

Kamis, 28 April 2011

Installing And Using OpenVZ On CentOS 5.6

In this HowTo I will describe how to prepare a CentOS 5.6 server for OpenVZ. With OpenVZ you can create multiple Virtual Private Servers (VPS) on the same hardware, similar to Xen and the Linux Vserver project. OpenVZ is the open-source branch of Virtuozzo, a commercial virtualization solution used by many providers that offer virtual servers. The OpenVZ kernel patch is licensed under the GPL license, and the user-level tools are under the QPL license.


This howto is meant as a practical guide; it does not cover the theoretical backgrounds. They are treated in a lot of other documents in the web.


This document comes without warranty of any kind! I want to say that this is not the only way of setting up such a system. There are many ways of achieving this goal but this is the way I take. I do not issue any guarantee that this will work for you!


In order to install OpenVZ, we need to add the OpenVZ repository to yum:

cd /etc/yum.repos.d
wget http://download.openvz.org/openvz.repo
rpm --import http://download.openvz.org/RPM-GPG-Key-OpenVZ


The repository contains a few different OpenVZ kernels (you can find more details about them here: http://wiki.openvz.org/Kernel_flavors). The command

yum search ovzkernel


shows you the available kernels:

[root@server1 yum.repos.d]# yum search ovzkernel
...
ovzkernel.i686 : Virtuozzo Linux kernel (the core of the Linux operating system)
ovzkernel.x86_64 : Virtuozzo Linux kernel (the core of the Linux operating system)
ovzkernel-PAE.i686 : The Linux kernel compiled for PAE capable machines.
ovzkernel-PAE-debug.i686 : The Linux PAE kernel compiled with debug config
ovzkernel-PAE-devel.i686 : Development package for building kernel modules to match the PAE kernel.
ovzkernel-debug.i686 : The Linux kernel compiled with debug config
ovzkernel-debug.x86_64 : The Linux kernel compiled with debug config
ovzkernel-devel.i686 : Development package for building kernel modules to match the kernel.
ovzkernel-devel.x86_64 : Development package for building kernel modules to match the kernel.
ovzkernel-ent.i686 : The Linux kernel compiled for huge mem capable machines.
ovzkernel-ent-debug.i686 : The Linux ent kernel compiled with debug config
ovzkernel-ent-devel.i686 : Development package for building kernel modules to match the ent kernel.
ovzkernel-xen.i686 : The Linux kernel compiled for Xen VM operations
ovzkernel-xen.x86_64 : The Linux kernel compiled for Xen VM operations
ovzkernel-xen-devel.i686 : Development package for building kernel modules to match the kernel.
ovzkernel-xen-devel.x86_64 : Development package for building kernel modules to match the kernel.
[root@server1 yum.repos.d]#


Pick one of them and install it as follows:

yum install ovzkernel


This should automatically update the GRUB bootloader as well. Anyway, we should open /boot/grub/menu.lst; the first kernel stanza should now contain the new OpenVZ kernel. The title of that kernel just reads "CentOS". I think it's a good idea to change that title and add something with "OpenVZ" to it so that you know that it's the OpenVZ kernel. Also make sure that the value of default is 0 so that the first kernel (the OpenVZ kernel) is booted automatically instead of the default CentOS kernel.

vi /boot/grub/menu.lst

# grub.conf generated by anaconda## Note that you do not have to rerun grub after making changes to this file# NOTICE: You have a /boot partition. This means that# all kernel and initrd paths are relative to /boot/, eg.# root (hd0,0)# kernel /vmlinuz-version ro root=/dev/VolGroup00/LogVol00# initrd /initrd-version.img#boot=/dev/sdadefault=0timeout=5splashimage=(hd0,0)/grub/splash.xpm.gzhiddenmenutitle CentOS OpenVZ (2.6.18-238.5.1.el5.028stab085.5) root (hd0,0) kernel /vmlinuz-2.6.18-238.5.1.el5.028stab085.5 ro root=/dev/VolGroup00/LogVol00 initrd /initrd-2.6.18-238.5.1.el5.028stab085.5.imgtitle CentOS (2.6.18-238.el5) root (hd0,0) kernel /vmlinuz-2.6.18-238.el5 ro root=/dev/VolGroup00/LogVol00 initrd /initrd-2.6.18-238.el5.img

Now we install some OpenVZ user tools:

yum install vzctl vzquota


Open /etc/sysctl.conf and make sure that you have the following settings in it:

vi /etc/sysctl.conf

[...]net.ipv4.ip_forward = 1net.ipv4.conf.default.proxy_arp = 0net.ipv4.conf.all.rp_filter = 1kernel.sysrq = 1net.ipv4.conf.default.send_redirects = 1net.ipv4.conf.all.send_redirects = 0net.ipv4.icmp_echo_ignore_broadcasts=1net.ipv4.conf.default.forwarding=1[...]

If you need to modify /etc/sysctl.conf, run

sysctl -p


afterwards.

The following step is important if the IP addresses of your virtual machines are from a different subnet than the host system's IP address. If you don't do this, networking will not work in the virtual machines!


Open /etc/vz/vz.conf and set NEIGHBOUR_DEVS to all:

vi /etc/vz/vz.conf

[...]NEIGHBOUR_DEVS=all[...]

SELinux needs to be disabled if you want to use OpenVZ. Open /etc/sysconfig/selinux and set the value of SELINUX to disabled:

vi /etc/sysconfig/selinux

# This file controls the state of SELinux on the system.# SELINUX= can take one of these three values:# enforcing - SELinux security policy is enforced.# permissive - SELinux prints warnings instead of enforcing.# disabled - SELinux is fully disabled.SELINUX=disabled# SELINUXTYPE= type of policy in use. Possible values are:# targeted - Only targeted network daemons are protected.# strict - Full SELinux protection.SELINUXTYPE=targeted

Finally, reboot the system:

reboot


If your system reboots without problems, then everything is fine!


Run

uname -r


and your new OpenVZ kernel should show up:

[root@server1 ~]# uname -r
2.6.18-238.5.1.el5.028stab085.5
[root@server1 ~]#

Installing And Using OpenVZ On CentOS 5.6 - Page 2

View the original article here