Wednesday, July 27, 2016

Configuring Centos with Apache , Mysql and PHP

http://www.tecmint.com/things-to-do-after-minimal-rhel-centos-7-installation/#C6

before installing apache, fix the hostname, /etc/hosts file

=================================================
Install Apache
=================================================
# yum install httpd
LISTEN 80 , change it to any port you like
# firewall-cmd --add-service=http
# firewall-cmd --permanent --add-port=3221/tcp
# firewall-cmd --reload
# systemctl restart httpd.service
# systemctl start httpd.service
# systemctl enable httpd.service
=================================================
Install PHP
=================================================
# yum install php
# systemctl restart httpd.service
test php
# echo -e ""  > /var/www/html/phpinfo.php
# php /var/www/html/phpinfo.php

=================================================
Install MariaDB
=================================================
# yum install mariadb-server mariadb
# systemctl start mariadb.service
# systemctl enable mariadb.service
# firewall-cmd --add-service=mysql
secure mariadb using below
# /usr/bin/mysql_secure_installation

=================================================
phpmyadmin
=================================================
http://www.liquidweb.com/kb/how-to-install-and-configure-phpmyadmin-on-centos-7/


rpm -iUvh http://dl.fedoraproject.org/pub/epel/epel-release-latest-7.noarch.rpm

yum -y update

yum -y install phpmyadmin

vim /etc/httpd/conf.d/phpMyAdmin.conf
Require ip 127.0.0.1

Allow from 127.0.0.1

Require ip 127.0.0.1

Allow from 127.0.0.1

Then exit and save the file with the command :wq .

Restart Apache:

systemctl restart httpd

=================================================
Hardening Centos Apache
=================================================
disable http track and trace methods
=================================================
in /etc/httpd/conf/httpd.conf

TraceEnable off
ServerTokens ProductOnly
ServerSignature Off

The above two lines are to hide server version etc..

6 comments:

We are apptology and one of the earliest mobile application development company from India that started making Android, Windows and iOS apps. if you want need that type service then easily connect with us.
visit here:Mobile app development services

Run 3 Unblocked amazing Free Online Game. Its Run 3 Free Online Game just for Run 3 Game Lovers.
unblocked games at school

Where McAfee is recognized as the no. 1 antivirus brand, it can also put you in complicated situations like pushing frequent error prompts. If such things go on like this, you can take help of the well trained professionals available at McAfee Technical Support Team UK and get instant support for the same.
McAfee Support Number UK
McAfee Contact Number UK
McAfee Help Number UK
McAfee Phone Number UK

Downloading, installing and performing McAfee is the only way to protect your data and device from malware, viruses, and Trojans. To know about its programs, products, McAfee Installation, you can visit our official website. You can also download and install antivirus software from McAfee's official website. For more updates to visit us: -http://mcafeeactivateservice.com/mcafee-activate-dell.html or https://mcafeeactivateservices.blogspot.com/2019/09/install-mcafee-with-25-digit-mcafee.html

Thanks for sharing, nice post! Post really provice useful information!

FadoExpress là một trong những top công ty chuyển phát nhanh quốc tế hàng đầu chuyên vận chuyển, chuyển phát nhanh siêu tốc đi khắp thế giới, nổi bật là dịch vụ gửi hàng đi đài loangửi hàng đi pháp và dịch vụ gửi hàng đi canada uy tín, giá rẻ

Post a Comment

Share

Twitter Delicious Facebook Digg Stumbleupon Favorites More