1. Infrastructure 2. Configuration 1. Infrastructure · 1. Infrastructure Our project is to install...

43
CHEA Koemleang [email protected] http://koemleang.wordpress.com Contents 1. Infrastructure 2. Configuration a. Join the Web Server to the Domain Controller b. Install PHP, mysql, apache c. Install and configure wordpress and virtual host d. Install and configure moodle and virtual host e. Install and configure joomla and virtual host f. Install and configure phpBB3 and virtual host g. Install and configure glpi and virtual host 1. Infrastructure Our project is to install and configure the web application such as moodle, joomla , wordpress, … on one web server which using the DNS Service from the Active Directory on the Windows Server 2003.

Transcript of 1. Infrastructure 2. Configuration 1. Infrastructure · 1. Infrastructure Our project is to install...

Page 1: 1. Infrastructure 2. Configuration 1. Infrastructure · 1. Infrastructure Our project is to install and configure the web application such as moodle, joomla , wordpress, … on one

CHEA Koemleang [email protected]

http://koemleang.wordpress.com

Contents

1. Infrastructure

2. Configuration

a. Join the Web Server to the Domain Controller

b. Install PHP, mysql, apache

c. Install and configure wordpress and virtual host

d. Install and configure moodle and virtual host

e. Install and configure joomla and virtual host

f. Install and configure phpBB3 and virtual host

g. Install and configure glpi and virtual host

1. Infrastructure

Our project is to install and configure the web application such as moodle, joomla , wordpress, …

on one web server which using the DNS Service from the Active Directory on the Windows Server

2003.

Page 2: 1. Infrastructure 2. Configuration 1. Infrastructure · 1. Infrastructure Our project is to install and configure the web application such as moodle, joomla , wordpress, … on one

CHEA Koemleang [email protected]

http://koemleang.wordpress.com

2. Configuration

a. Join Web Server to the Domain Controller

Firstly, make sure that our domain is working properly

Configure the IP Address for the Web Server

Then configure the DNS server for the Web Server

Page 3: 1. Infrastructure 2. Configuration 1. Infrastructure · 1. Infrastructure Our project is to install and configure the web application such as moodle, joomla , wordpress, … on one

CHEA Koemleang [email protected]

http://koemleang.wordpress.com

Then, from the terminal, type yast

Go to Network Services � Windows Domain Membership

It will require you to install the samba-client, so just select Install

Then, type the domain name and select the option as below and OK

Page 4: 1. Infrastructure 2. Configuration 1. Infrastructure · 1. Infrastructure Our project is to install and configure the web application such as moodle, joomla , wordpress, … on one

CHEA Koemleang [email protected]

http://koemleang.wordpress.com

It will ask you whether to join the domain or not, just Yes

Then, type the password of the Administrator of the Domain Controller

Here is the result

Then, it need some more packages to be installed

Just OK

Page 5: 1. Infrastructure 2. Configuration 1. Infrastructure · 1. Infrastructure Our project is to install and configure the web application such as moodle, joomla , wordpress, … on one

CHEA Koemleang [email protected]

http://koemleang.wordpress.com

Just Quit the Control Center

Then, restart the machine by reboot

After that, we will see the Web Server on the Domain Controller

Page 6: 1. Infrastructure 2. Configuration 1. Infrastructure · 1. Infrastructure Our project is to install and configure the web application such as moodle, joomla , wordpress, … on one

CHEA Koemleang [email protected]

http://koemleang.wordpress.com

It also has the record on the DNS database

b. Install PHP, mysql, apache

In the Search Phrase, type php and enter; select php5, and php5-mysql

Page 7: 1. Infrastructure 2. Configuration 1. Infrastructure · 1. Infrastructure Our project is to install and configure the web application such as moodle, joomla , wordpress, … on one

CHEA Koemleang [email protected]

http://koemleang.wordpress.com

Then, search for mysql and select mysql

After that, search for apache and select apache2, apache2-mod_php5 and Accept

It will ask to install some more dependency packages, so just OK

Page 8: 1. Infrastructure 2. Configuration 1. Infrastructure · 1. Infrastructure Our project is to install and configure the web application such as moodle, joomla , wordpress, … on one

CHEA Koemleang [email protected]

http://koemleang.wordpress.com

Now, let’s start the apache2 by rcapache2 start

Start the mysql service by rcmysql start

After installing the needed packages and starting all the service, now let’s copy the web

applications to the Web Server by using the SSH Secure to /srv/www/htdocs/

Now we have all the web application on the Server in /srv/www/htdocs/

Page 9: 1. Infrastructure 2. Configuration 1. Infrastructure · 1. Infrastructure Our project is to install and configure the web application such as moodle, joomla , wordpress, … on one

CHEA Koemleang [email protected]

http://koemleang.wordpress.com

c. Install and configure wordpress and virtual host

Now we are going to set the password for the mysql database by entering the following

command line and press enter. The default password is blank

Now we create the database for wordpress as below

Extract the wordpress package as below

Then change the ownership of /srv/www/htdocs/ to wwwrun.www

Page 10: 1. Infrastructure 2. Configuration 1. Infrastructure · 1. Infrastructure Our project is to install and configure the web application such as moodle, joomla , wordpress, … on one

CHEA Koemleang [email protected]

http://koemleang.wordpress.com

Then go to wordpress directory. We will see on file named wp-config-sample.php

Rename it to wp-config.php and edit the file

Specify the database name, database user, and database password

Page 11: 1. Infrastructure 2. Configuration 1. Infrastructure · 1. Infrastructure Our project is to install and configure the web application such as moodle, joomla , wordpress, … on one

CHEA Koemleang [email protected]

http://koemleang.wordpress.com

Now let’s create the virtual host for wordpress by go to /etc/apache2/vhosts.d/ and copy the

vhost.template to wordpress.conf and edit it

Edit the file content as below

Create the Alias Name for the Web Server in the DNS database

Page 12: 1. Infrastructure 2. Configuration 1. Infrastructure · 1. Infrastructure Our project is to install and configure the web application such as moodle, joomla , wordpress, … on one

CHEA Koemleang [email protected]

http://koemleang.wordpress.com

Then restart the apache and mysql service as below

Access the wordpress through the browser by entering wordpress.server.net

Click Install WordPress

Page 13: 1. Infrastructure 2. Configuration 1. Infrastructure · 1. Infrastructure Our project is to install and configure the web application such as moodle, joomla , wordpress, … on one

CHEA Koemleang [email protected]

http://koemleang.wordpress.com

Now we have successfully installed the wordpress, so don’t forget the username and password

Later on, when we access the http://wordpress.server.net, it will show the webpage as below

Page 14: 1. Infrastructure 2. Configuration 1. Infrastructure · 1. Infrastructure Our project is to install and configure the web application such as moodle, joomla , wordpress, … on one

CHEA Koemleang [email protected]

http://koemleang.wordpress.com

To edit the webpage, type wordpress.server.net/wp-admin

Type the username and password

Page 15: 1. Infrastructure 2. Configuration 1. Infrastructure · 1. Infrastructure Our project is to install and configure the web application such as moodle, joomla , wordpress, … on one

CHEA Koemleang [email protected]

http://koemleang.wordpress.com

Now we are able to edit the webpage

d. Install and configure moodle and virtual host

Firstly, we have to create the database for the moodle

Page 16: 1. Infrastructure 2. Configuration 1. Infrastructure · 1. Infrastructure Our project is to install and configure the web application such as moodle, joomla , wordpress, … on one

CHEA Koemleang [email protected]

http://koemleang.wordpress.com

Then, extract the moodle package

After that, change the ownership of the moodle directory to wwwrun.www

Then, get into the moodle directory and edit the file config-dist.php

Specify the database name, database user, and database password

Now let’s create the virtual host for moodle in /etc/apache2/vhosts.d/ by copy the

vhost.template to moodle.conf and edit it by vim moodle.conf

Page 17: 1. Infrastructure 2. Configuration 1. Infrastructure · 1. Infrastructure Our project is to install and configure the web application such as moodle, joomla , wordpress, … on one

CHEA Koemleang [email protected]

http://koemleang.wordpress.com

Edit the file as below

As we have already created the virtual host for wordpress, so the Web Server cannot have

another virtual. To enable the Web Server to run multiple virtual host, we have to edit some option in

/etc/apache2/listen.conf

Edit the syntax as below

Don’t forget to create the alias name for the moodle in the DNS database

Page 18: 1. Infrastructure 2. Configuration 1. Infrastructure · 1. Infrastructure Our project is to install and configure the web application such as moodle, joomla , wordpress, … on one

CHEA Koemleang [email protected]

http://koemleang.wordpress.com

Restart the apache and mysql service as below

Access the moodle through the web browser by moodle.server.net

Click Next

Page 19: 1. Infrastructure 2. Configuration 1. Infrastructure · 1. Infrastructure Our project is to install and configure the web application such as moodle, joomla , wordpress, … on one

CHEA Koemleang [email protected]

http://koemleang.wordpress.com

Click Next

Click Next and then it will automatically create one directory named moodledata in

/srv/www/htdocs/

Type the database name, user name, and password and click Next

Page 20: 1. Infrastructure 2. Configuration 1. Infrastructure · 1. Infrastructure Our project is to install and configure the web application such as moodle, joomla , wordpress, … on one

CHEA Koemleang [email protected]

http://koemleang.wordpress.com

Scroll down and click Next

Click Next

Click Continue

Page 21: 1. Infrastructure 2. Configuration 1. Infrastructure · 1. Infrastructure Our project is to install and configure the web application such as moodle, joomla , wordpress, … on one

CHEA Koemleang [email protected]

http://koemleang.wordpress.com

Click Yes

Click Continue

Scroll down and click Continue

Page 22: 1. Infrastructure 2. Configuration 1. Infrastructure · 1. Infrastructure Our project is to install and configure the web application such as moodle, joomla , wordpress, … on one

CHEA Koemleang [email protected]

http://koemleang.wordpress.com

Click Continue

Click Continue

Click Continue

Page 23: 1. Infrastructure 2. Configuration 1. Infrastructure · 1. Infrastructure Our project is to install and configure the web application such as moodle, joomla , wordpress, … on one

CHEA Koemleang [email protected]

http://koemleang.wordpress.com

Click Continue

Click Continue

Click Continue

Page 24: 1. Infrastructure 2. Configuration 1. Infrastructure · 1. Infrastructure Our project is to install and configure the web application such as moodle, joomla , wordpress, … on one

CHEA Koemleang [email protected]

http://koemleang.wordpress.com

Complete the needed information and click Upate profile

Complete the Full site name and Short name for site and click Save Changes

Page 25: 1. Infrastructure 2. Configuration 1. Infrastructure · 1. Infrastructure Our project is to install and configure the web application such as moodle, joomla , wordpress, … on one

CHEA Koemleang [email protected]

http://koemleang.wordpress.com

Now we have successfully install the moodle

Later on, when we access the http://moodle.server.net, it will show the interface as below

Page 26: 1. Infrastructure 2. Configuration 1. Infrastructure · 1. Infrastructure Our project is to install and configure the web application such as moodle, joomla , wordpress, … on one

CHEA Koemleang [email protected]

http://koemleang.wordpress.com

e. Install and configure joomla and virtual host

First, we have to create the database for joomla as below

Create one directory for joomla and extract the joomla package into the directory

Then, change the ownership of the joomla directory to wwwrun.www

Edit the file /etc/php5/apache2/php.ini

Page 27: 1. Infrastructure 2. Configuration 1. Infrastructure · 1. Infrastructure Our project is to install and configure the web application such as moodle, joomla , wordpress, … on one

CHEA Koemleang [email protected]

http://koemleang.wordpress.com

Turn on the display_errors

Turn on the magic_quotes_gpc

Create the virtual host for the joomla in /etc/apache2/vhosts.d/; copy the vhost.template to

joomla.conf

Edit the file as below

Page 28: 1. Infrastructure 2. Configuration 1. Infrastructure · 1. Infrastructure Our project is to install and configure the web application such as moodle, joomla , wordpress, … on one

CHEA Koemleang [email protected]

http://koemleang.wordpress.com

Make sure to create the alias name for the joomla in the DNS database

Restart the apache and mysql service

Access the joomla through the browse by typing joomla.server.net

Page 29: 1. Infrastructure 2. Configuration 1. Infrastructure · 1. Infrastructure Our project is to install and configure the web application such as moodle, joomla , wordpress, … on one

CHEA Koemleang [email protected]

http://koemleang.wordpress.com

Click Next

Click Next

Complete the needed information and click Next

Page 30: 1. Infrastructure 2. Configuration 1. Infrastructure · 1. Infrastructure Our project is to install and configure the web application such as moodle, joomla , wordpress, … on one

CHEA Koemleang [email protected]

http://koemleang.wordpress.com

Enter the Site name and click Next

Complete the needed information and click Next

Remember the Admin password

Page 31: 1. Infrastructure 2. Configuration 1. Infrastructure · 1. Infrastructure Our project is to install and configure the web application such as moodle, joomla , wordpress, … on one

CHEA Koemleang [email protected]

http://koemleang.wordpress.com

Later on, when we access the http://joomla.server.net, it will show the interface as below

f. Install and configure phpBB3 and virtual host

Extract the phpBB3 into /srv/www/htdocs/

Page 32: 1. Infrastructure 2. Configuration 1. Infrastructure · 1. Infrastructure Our project is to install and configure the web application such as moodle, joomla , wordpress, … on one

CHEA Koemleang [email protected]

http://koemleang.wordpress.com

Change the permission to config.php

Create the virtual host for the phpBB3

Edit the file as below

Create alias for the phpBB3 in the DNS database

Page 33: 1. Infrastructure 2. Configuration 1. Infrastructure · 1. Infrastructure Our project is to install and configure the web application such as moodle, joomla , wordpress, … on one

CHEA Koemleang [email protected]

http://koemleang.wordpress.com

Restart the apache and mysql service

Access the phpBB3 through the browser to install it by phpbb3.server.net

Click Proceed to next step

Page 34: 1. Infrastructure 2. Configuration 1. Infrastructure · 1. Infrastructure Our project is to install and configure the web application such as moodle, joomla , wordpress, … on one

CHEA Koemleang [email protected]

http://koemleang.wordpress.com

Click Start install

Complete the needed information and click Proceed to next step

Click Proceed to next step

Page 35: 1. Infrastructure 2. Configuration 1. Infrastructure · 1. Infrastructure Our project is to install and configure the web application such as moodle, joomla , wordpress, … on one

CHEA Koemleang [email protected]

http://koemleang.wordpress.com

Complete the needed information and click Proceed to next step

Click Proceed to next step

Click Proceed to next step

Page 36: 1. Infrastructure 2. Configuration 1. Infrastructure · 1. Infrastructure Our project is to install and configure the web application such as moodle, joomla , wordpress, … on one

CHEA Koemleang [email protected]

http://koemleang.wordpress.com

Click Proceed to next step

Click Proceed to next step

Here is the successful installation

Page 37: 1. Infrastructure 2. Configuration 1. Infrastructure · 1. Infrastructure Our project is to install and configure the web application such as moodle, joomla , wordpress, … on one

CHEA Koemleang [email protected]

http://koemleang.wordpress.com

Later on, when we access the http://phpbb3.server.net, it will show the content as below

g. Install and configure glpi and virtual host

Extract the glpi package into /srv/www/htdocs/

Page 38: 1. Infrastructure 2. Configuration 1. Infrastructure · 1. Infrastructure Our project is to install and configure the web application such as moodle, joomla , wordpress, … on one

CHEA Koemleang [email protected]

http://koemleang.wordpress.com

Change the directory ownership to wwwrun.www

Grant the permission to the directory

Create the virtual host for the glpi by copying the vhost.template to glpi.conf and edit it

Edit file as below

Page 39: 1. Infrastructure 2. Configuration 1. Infrastructure · 1. Infrastructure Our project is to install and configure the web application such as moodle, joomla , wordpress, … on one

CHEA Koemleang [email protected]

http://koemleang.wordpress.com

Create the alias for glpi

Restart the apache and mysql service

Access the glpi from web browser to install it

Page 40: 1. Infrastructure 2. Configuration 1. Infrastructure · 1. Infrastructure Our project is to install and configure the web application such as moodle, joomla , wordpress, … on one

CHEA Koemleang [email protected]

http://koemleang.wordpress.com

Select the Language and click OK

Select the first option and click Continue

Click Installation

Page 41: 1. Infrastructure 2. Configuration 1. Infrastructure · 1. Infrastructure Our project is to install and configure the web application such as moodle, joomla , wordpress, … on one

CHEA Koemleang [email protected]

http://koemleang.wordpress.com

Click Continue

Fill up the information and click Continue

Select the database and click Continue

Page 42: 1. Infrastructure 2. Configuration 1. Infrastructure · 1. Infrastructure Our project is to install and configure the web application such as moodle, joomla , wordpress, … on one

CHEA Koemleang [email protected]

http://koemleang.wordpress.com

Click Continue

The installation is completed successfully

The default user is glpi and the password is glpi

Page 43: 1. Infrastructure 2. Configuration 1. Infrastructure · 1. Infrastructure Our project is to install and configure the web application such as moodle, joomla , wordpress, … on one

CHEA Koemleang [email protected]

One more thing to remember is that apache and mysql Services are just running on the memory

because we just start them manually. When the machine is shut down or restart, both of them will stop.

To make both of them start automatically when the machine is started, do the following