Thursday, November 22, 2012

Install apache,mysql,php (LAMP) on Centos 6/Scientific Linux 6

sudo yum install httpd

sudo service httpd start

sudo chkconfig httpd on

find your ip address by

ifconfig eth0 | grep inet | awk '{ print $2 }'

To check if Apache is installed, direct your browser to your server’s IP address (for example The page should display the words “It works!"

sudo yum install mysql-server

sudo service mysqld start

set mysql root pasword by

sudo /usr/bin/mysql_secure_installation

sudo chkconfig mysqld on

sudo yum install php php-mysql

search php modules by

yum search php-

install the module by

sudo yum install name of the module

to know more about this module

yum info name of the module

Test your webserver

sudo nano /var/www/html/info.php



save and exit

sudo service httpd restart


No comments:

Post a Comment