当前位置:网站首页>Fedora 21 installs lamp host server
Fedora 21 installs lamp host server
2022-07-03 17:48:00 【Brother Xing plays with the clouds】
not long ago Fedora 21 Released , There are three versions , One of them The server edition , The original tip is Server The server edition , Have a look first LAMP yes Linux、Apache、MySQL/MariaDB、PHP For short .
The example domain name used in this tutorial is server1.example.com,IP The address is 192.168.0.100, In fact, your installation is different , Please modify accordingly .
1、 Install the database first MySQL/MariaDB 5.
MariaDB Installation command :
yum install mariadb mariadb-server
by MariaDB Create boot up :
systemctl enable mariadb.service
start-up mysql service :
systemctl start mariadb.service
mysql_secure_installation
Set super root User password , Follow the instructions :
[[email protected] ~]# 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 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 MariaDB root user without the proper authorisation.
Set root password? [Y/n] <– ENTER New password: <– Input password Re-enter new password: <– Enter the password again 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 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] <– ENTER … 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] <– ENTER … Success!
By default, MariaDB 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] <– 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] <– ENTER … Success!
Cleaning up…
All done! If you’ve completed all of the above steps, your MariaDB installation should now be secure.
Thanks for using MariaDB! [[email protected] ~]#
2、 install Apache2
yum install httpd
Set the automatic startup with the system :
systemctl enable httpd.service
Start the service :
systemctl start httpd.service
Next we need to add Apache The service covers the firewall command as follows :
firewall-cmd --set-default-zone=public
firewall-cmd --permanent --zone=public --add-service=httpfirewall-cmd --permanent --zone=public --add-service=httpsfirewall-cmd --reload
Okay , Input IP Address :http://192.168.0.100, have a look apache Operation of the :
Fedora System Apache Default root /var/www/html, Profile directory /etc/httpd/conf/httpd.conf, Other configuration file directories /etc/httpd/conf.d/ directory.
3、 install PHP5
Installation command :
yum install php
restart apache command :
systemctl restart httpd.service
4、 test PHP5 obtain PHP5 Installation :
Create a probe file in the root directory : nano /var/www/html/info.php
Add file content :
<?php
phpinfo();
?>Then access the probe file :http://192.168.0.100/info.php
5、 Give Way MySQL obtain PHP5 Support : First search for support plug-ins : yum search php install : yum install php-mysqlnd php-mssql php-opcache Restart the service : systemctl restart httpd.service
Visit the probe file again , See if it supports .
6、 install phpMyAdmin Management database :
yum install phpmyadmin
Now let's set PHPMyAdmin. We have changed Apache Configure the phpMyAdmin Allowing connections is not limited to localhost Address access (< Catalog /usr/share/phpMyAdmin/ >):
nano /etc/httpd/conf.d/phpMyAdmin.conf
The configuration is as follows :
<Directory /usr/share/phpMyAdmin/>
# AddDefaultCharset UTF-8
# <IfModule mod_authz_core.c>
# # Apache 2.4
# <RequireAny>
# Require ip 127.0.0.1
# Require ip ::1
# </RequireAny>
# </IfModule>
# <IfModule !mod_authz_core.c>
# # Apache 2.2
# Order Deny,Allow
# Deny from All
# Allow from 127.0.0.1
# Allow from ::1
# </IfModule>
Require all granted
</Directory>restart apache:
systemctl restart httpd.service
OK Installation completed , Now access phpmyadmin:http://192.168.0.100/phpmyadmin/
Reference link :
- Apache: http://httpd.apache.org/
- PHP: http://www.php.net/
- MySQL: http://www.mysql.com/
- Fedora: http://fedoraproject.org/
- phpMyAdmin: http://www.phpmyadmin.net/
边栏推荐
- [combinatorics] recursive equation (four cases where the non-homogeneous part of a linear non-homogeneous recursive equation with constant coefficients is the general solution of the combination of po
- [combinatorics] recursive equation (solution of linear non-homogeneous recursive equation with constant coefficients | standard form and general solution of recursive equation | proof of general solut
- PR second time
- List of financial products in 2022
- QT adjust win screen brightness and sound size
- vs2013已阻止安装程序,需安装IE10
- 自动渗透测试工具核心功能简述
- 微服务组件Sentinel控制台调用
- Collection of the most beautiful graduation photos in the graduation season, collection of excellent graduation photos
- Kotlin's collaboration: Context
猜你喜欢

POM in idea XML graying solution

Leetcode 108 converts an ordered array into a binary search tree -- recursive method

Play with fancy special effects. This AE super kit is for you

Research Report on market demand and investment planning for the development of China's office chair industry, 2022-2028

Investigation on the operation prospect of the global and Chinese Anti enkephalinase market and analysis report on the investment strategy of the 14th five year plan 2022-2028

Automata and automatic line of non-standard design

聊聊支付流程的设计与实现逻辑

Is AI too slow to design pictures and draw illustrations? 3 sets of practical brushes to save you

国内如何购买Google Colab会员

Market demand survey and marketing strategy analysis report of global and Chinese pet milk substitutes 2022-2028
随机推荐
i++与++i的区别:通俗易懂的讲述他们的区别
Remote office tools sharing | community essay solicitation
Deops入门
自动渗透测试工具核心功能简述
(8) HS corner detection
Where is the database account used when running SQL tasks in data warehouse tasks configured
Managing multiple selections with MVVM - managing multiple selections with MVVM
【JokerのZYNQ7020】DDS_ Compiler。
毕业总结
ArrayList分析3 : 删除元素
Golang unit test, mock test and benchmark test
Qt调节Win屏幕亮度和声音大小
Is AI too slow to design pictures and draw illustrations? 3 sets of practical brushes to save you
Baiwen.com 7 days Internet of things smart home learning experience punch in the next day
AcWing 4489. Longest subsequence
2021 ICPC regional competition (Shanghai) g.edge groups (tree DP)
Mathematical formula (test)
Write a program to process a list container of string type. Find a special value in the container 9.27: and delete it if found. Rewrite the above procedure with deque container.
Talk about the design and implementation logic of payment process
Classroom attendance system based on face recognition tkinter+openpyxl+face_ recognition