Warning: preg_match(): Unknown modifier '-' in /home/akl1986/public_html/support/wp-content/plugins/redux-framework/redux-core/inc/extensions/metaboxes/class-redux-extension-metaboxes.php on line 783

Warning: preg_match(): Unknown modifier '-' in /home/akl1986/public_html/support/wp-content/plugins/redux-framework/redux-core/inc/extensions/metaboxes/class-redux-extension-metaboxes.php on line 783

Warning: preg_match(): Unknown modifier '-' in /home/akl1986/public_html/support/wp-content/plugins/redux-framework/redux-core/inc/extensions/metaboxes/class-redux-extension-metaboxes.php on line 783

Warning: preg_match(): Unknown modifier '-' in /home/akl1986/public_html/support/wp-content/plugins/redux-framework/redux-core/inc/extensions/metaboxes/class-redux-extension-metaboxes.php on line 783

Warning: preg_match(): Unknown modifier '-' in /home/akl1986/public_html/support/wp-content/plugins/redux-framework/redux-core/inc/extensions/metaboxes/class-redux-extension-metaboxes.php on line 783

Warning: preg_match(): Unknown modifier '-' in /home/akl1986/public_html/support/wp-content/plugins/redux-framework/redux-core/inc/extensions/metaboxes/class-redux-extension-metaboxes.php on line 783

Warning: preg_match(): Unknown modifier '-' in /home/akl1986/public_html/support/wp-content/plugins/redux-framework/redux-core/inc/extensions/metaboxes/class-redux-extension-metaboxes.php on line 783

Warning: preg_match(): Unknown modifier '-' in /home/akl1986/public_html/support/wp-content/plugins/redux-framework/redux-core/inc/extensions/metaboxes/class-redux-extension-metaboxes.php on line 783

Warning: Cannot modify header information - headers already sent by (output started at /home/akl1986/public_html/support/wp-content/plugins/redux-framework/redux-core/inc/extensions/metaboxes/class-redux-extension-metaboxes.php:783) in /home/akl1986/public_html/support/wp-includes/feed-rss2.php on line 8
How to Install Apache – AKLWEB HOST LLC Support Center https://support.aklwebhost.com Fri, 27 Dec 2019 06:49:42 +0000 en-US hourly 1 https://wordpress.org/?v=6.4.4 How to Install Apache, MySQL, and PHP on CentOS 6 https://support.aklwebhost.com/knowledgebase/how-to-install-apache-mysql-and-php-on-centos-6/ https://support.aklwebhost.com/knowledgebase/how-to-install-apache-mysql-and-php-on-centos-6/#respond Fri, 27 Dec 2019 06:49:42 +0000 https://support.aklwebhost.com/?post_type=manual_kb&p=2868 Introduction

LAMP is an acronym that stands for Linux, Apache, MySQL, and PHP. This software stack is the most popular open-source solution for the setup of web servers.

Since we have decided to use the CentOS 6 x64 distribution of Linux on a AKLWEB Host VPS, we will only introduce how to install the other components in this article.

Prerequisites

In this article, we assume that you have set up a CentOS 6 x64 AKLWEB Host VPS from scratch and have logged in as root. Non-root users will need to use the sudo command.

Step One: Install Apache

To install and start Apache, open your SSH terminal and input the following commands:

yum -y install httpd
service httpd start

Check if Apache is installed and running properly with:

service httpd status

Note: You cannot check if Apache is running properly by visiting the IP address of your AKLWEB Host VPS from your browser, as the firewall will block your visit by default.

You need to open port 80 to make your web server accessible:

/sbin/iptables -I INPUT -p tcp --dport 80 -j ACCEPT
/etc/rc.d/init.d/iptables save

Step Two: Install MySQL

To install and start MySQL, open your SSH terminal and input the following commands:

yum -y install mysql-server
service mysqld start

On production servers, you should secure MySQL with the following command:

/usr/bin/mysql_secure_installation

The command prompt will ask for your current MySQL root password. Leave it blank by pressing ENTER.

Then, answer the command prompt as specified below:

Set root password? [Y/n] Y
New password: YourDesiredPassword
Re-enter new password: YourDesiredPassword
Remove anonymous user? [Y/n] Y
Disallow root login remotely? [Y/n] Y
Remove test database and access to it? [Y/n] Y
Reload privilege tables now? [Y/n] Y

Step Three: Install PHP

To install PHP on your AKLWEB Host VPS, open your SSH terminal and input the following command:

yum -y install php php-mysql

Depending on the web applications that you intend on running, you may need to install some PHP modules to your server. You can check available modules by typing the following command:

yum search php-

To see more details about the modules that you are interested in, input the following command. Remember to replace NameOfTheModule with the name of the module that you pick from the screen.

yum info NameOfTheModule

Usually, you will need two modules: php-mcrypt and php-mbstring. Install them with the following commands:

yum -y install php-mcrypt.x86_64
yum -y install php-mbstring.x86_64

You can install other modules in the same fashion.

To get the stack functioning, you also need to set Apache and MySQL to run automatically when your VPS boots (PHP will run automatically with Apache):

chkconfig httpd on
chkconfig mysqld on

Restart Apache web server to put all changes into effect:

service httpd restart

That’s it. You have installed a LAMP stack onto your AKLWEB Host VPS.

]]>
https://support.aklwebhost.com/knowledgebase/how-to-install-apache-mysql-and-php-on-centos-6/feed/ 0
How to Install Apache, MySQL, and PHP on Ubuntu https://support.aklwebhost.com/knowledgebase/how-to-install-apache-mysql-and-php-on-ubuntu-2/ https://support.aklwebhost.com/knowledgebase/how-to-install-apache-mysql-and-php-on-ubuntu-2/#respond Tue, 26 Nov 2019 06:32:30 +0000 https://support.aklwebhost.com/?post_type=manual_kb&p=2162 LAMP includes Apache, MySQL, PHP, and Ubuntu. This guide was written for Ubuntu 14.04.

Step One: Install Apache

Apache is a free open source software for web servers.

To install Apache on Ubuntu, type these commands:

sudo apt-get update
sudo apt-get install apache2

Or just copy and paste this:

sudo apt-get update; sudo apt-get install apache2

Tahhda. Let’s check if Apache was installed correctly. Run the command: hostname -I and note down that IP. Open up your Internet Browser and direct your browser to that IP (Example: http://108.61.212.235 ). The page should load and say “It Works!”.

Step Two: Install MySQL

MySQL is a database management system. Let’s install MySQL on Ubuntu. Type these commands:

sudo apt-get install mysql-server php5-mysql

During the install, MySQL will request for you to setup a password.

Once that has been installed, run these commands:

sudo mysql_install_db

Then write:

sudo /usr/bin/mysql_secure_installation

Step Three: Install PHP

Now write these commands:

sudo apt-get install php5 libapache2-mod-php5 php5-mcrypt
]]>
https://support.aklwebhost.com/knowledgebase/how-to-install-apache-mysql-and-php-on-ubuntu-2/feed/ 0