What is LAMP ?? Generally, ask the peoples about the word LAMP most of them knows about the LAMP = LIGHT But Technical person...
What is LAMP ??
Generally, ask the peoples about the word LAMP most of them knows about the LAMP = LIGHT
But Technical persons should know about the Word LAMP
L = LINUX,
A = APACHE web server
M = MYSQL or MONGODB
P = PHP sometimes used PYTHON or PERL instead of PHP
LAMP = Linux,Apache,MySQL,Php
Now going to install the LAMP in the Amazon Linux, centos The versions are Apache 2.4, PHP 7.3, and mysql 8
Step 1: Install Apache 2.4
1. Before installing the webserver the software packages to be up to date.
command: sudo yum update -y
2. Install the Apache software packages and related dependencies.
command: yum install -y httpd24 httpd24-tools mod24_ssl
3. Check the command chkconfig to configure the Apache webserver to start at each system boot.
command: chkconfig httpd on
4. Start the httpd services
command: service httpd start
5. Check whether the Apache is installed or not in the server
command: httpd -v
6. Double check once with the browser it shows the page like this below
Step2: Install the mysql version 8.0
1. Using wget to download the required dependencies
command: wget https://dev.mysql.com/get/mysql80-community-release-el6-1.noarch.rpm
2. Install the downloaded package
command: yum localinstall mysql80-community-release-el6-1.noarch.rpm
3. To check the mysql Yum repositories added command successfully Command: yum repolist enabled | grep "mysql.*-community.*"
4. Install the mysql server
command: yum install mysql-community-server
5. Start the mysql server and check the status of the mysql server
command: service mysqld start
service mysqld status
6. Check whether successfully mysql installed on the server
command: mysql --version
After that, we have to change the root password and secure the mysql secure installation
7. Check the temporary password to change the root access
command: grep 'temporary password' /var/log/mysqld.log
8. To change the password and secure the mysql run the below command
command: mysql_secure_installation
After this enter the new root password
Then it will ask you the following options
Remove anonymous users?
Disallow root login remotely?
Reload privilege tables now?
choose option yes or no accordingly to user needs.
9. mysql-devel package is not installed so have to install
the command: yum install mysql-devel
10. Now login and check if the changed mysql root password work or not
command: mysql -u root -p
1.Install the mysql version 7.3
command: yum install -y php73*
73* will install the all php dependencies packages
2.Check whether successfully php installed on the server
command: php -v
Step4: Check the phpinfo page in the browser
1.In the server have to update the phpinfo page code in the /var/www/html path
command: cd /var/www/html
2.Create the index.php file
command: touch index.php
3. open the file and paste the below php code
code: <?php
phpinfo();
?>
4. Now check the browser
http://serveripaddress/index.php
After that create the virtual host and point the domain and change the directory path if required.
----------------------------------------!!!! Happy Learning with Techiev !!!!!!!!----------------------------------
-------------------------Subscribe our Youtube Channel by clicking the below link----------------------
----------------------------!!https://www.youtube.com/@techieview729!!---------------------