LAMP website server is short for Linux, Apache, MySQL, and PHP. Installing an apache server on a Linux system is not difficult, because the mainstream Linux release software libraries include the software to be installed, this article will show you how to install the Apache2web service, PHP5 (mod_php) and MySQL databases on the Fedora20 system. I hope you can correct them! 1. Security Tips: the host name used in this article is
The LAMP website server isLInux,APache,MYSQL,PThe abbreviation of HP. Installing an apache server on a Linux system is not difficult, because the mainstream Linux release software libraries include the software to be installed, this article will show you how to install Apache2 web Services, PHP5 (mod_php) and MySQL databases on the Fedora 20 system.
There may be errors. I hope you can correct them!
1 prompt before security:
The host name used in this article is server1.example.com and the IP address is 192.168.0.100. Modify these settings based on your host situation!
2. Install the database. Two databases are available: MySQL/MariaDB 5.
Run the following command to install MySQL:
Yum install mysql-server
Create a startup connection for MySQL (MySQL will be automatically started with the system) and start the MySQL service:
Systemctl enable mysqld. service
Note: If you receive such an error
Failed to issue method call: No such file or directory
Use the following command
Systemctl enable mariadb. service
Start mysql services
Systemctl start mysqld. service
Run
Mysql_secure_installation
Set the root user password (otherwise anyone can access your MySQL database !) :
[Root @ server1 ~] # Mysql_secure_installation
/Usr/bin/mysql_secure_installation: line 379: find_mysql_client: command not found
NOTE: running all parts of this script is recommended for all MariaDB
Servers in production use! Please read each step carefully!
In order to log into MariaDB to secure it, we'll need the current
Password for the root user. If you 've just installed MariaDB, and
You haven't set the root password yet, the password will be blank,
So you shoshould just press enter here.
Enter current password for root (enter for none): <-(Press Enter directly)
OK, successfully used password, moving on...
Setting the root password ensures that nobody can log into the MariaDB
Root user without the proper authorisation.
Set root password? [Y/n] <-(Press ENTER)
New password: <-(set the password)
Re-enter new password: <-(confirm the password once)
Password updated successfully!
Reloading privilege tables ..
... Success!
By default, a MariaDB installation has an anonymous user, allowing anyone
To log into MariaDB without having to have a user account created
Them. This is intended only for testing, and to make the installation
Go a bit smoother. You shoshould remove them before moving into
Production environment.
Remove anonymous users? [Y/n] <-(Press ENTER)
... Success!
Normally, root shoshould 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] <-(Press ENTER)
... Success!
By default, MariaDB comes with a database named 'test' that anyone can
Access. This is also intended only for testing, and shocould be removed
Before moving into a production environment.
Remove test database and access to it? [Y/n] <-(Press ENTER)
-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] <-(Press ENTER)
... Success!
Cleaning up...
All done! If you 've completed all of the above steps, your MariaDB
Installation shoshould now be secure.
Thanks for using MariaDB!
[Root @ server1 ~] #
3. Install the Apache2 server
Run the following command:
Yum install httpd
Now configure your system to start Apache at startup...
Systemctl enable httpd. service
And start Apache:
Systemctl start httpd. service
Enter the address in the browser to access http: // 192.168.0.100. If the following page is displayed, the installation is successful!
-------------------------------------- Split line --------------------------------------
Install the LAMP \ Vsftpd \ Webmin \ phpMyAdmin service and settings in Ubuntu 13.04Http://www.linuxidc.com/Linux/2013-06/86250.htm
Compile and install LAMP (Apache 2.2.44 + MySQL 5.6.10 + PHP 5.4.12) http://www.linuxidc.com/Linux/2013-03/80333p3.htm in CentOS 5.9
Source code construction of Web Server Architecture in RedHat 5.4 LAMP environment and application PHPWind http://www.linuxidc.com/Linux/2012-10/72484p2.htm
LAMP source environment to build WEB Server Linux + Apache + MySQL + PHP http://www.linuxidc.com/Linux/2013-05/84882.htm
Build http://www.linuxidc.com/Linux/2014-05/101087.htm in LAMP + Xcache Environment
-------------------------------------- Split line --------------------------------------
In the Fedora system, the default Apache root directory is/var/www/html. The configuration file address is/etc/httpd/conf/httpd. conf. Other configuration file directories:/etc/httpd/conf. d /.
For more details, refer to the highlights on the next page.: Http://www.linuxidc.com/Linux/2014-05/101266p2.htm