Configure and Installing Apache, PHP, and MySQL on Fedora/CentOS
1. Install Apache (httpd), PHP, MySQL (server and client) and php-mysql bridge:
yum -y install httpd php mysql mysql-server php-mysql
2. Make the new services to start automatically on boot:
/sbin/chkconfig httpd on /sbin/chkconfig --add mysqld /sbin/chkconfig mysqld on
3. Start http and mysqld:
/sbin/service httpd start /sbin/service mysqld start
4. Change Mysql root password:
mysqladmin -u root password 'newpassword'
5. Additional changes to Mysql security:
mysql -u root -pnewpasssword mysql> DROP DATABASE test; mysql> DELETE FROM mysql.user WHERE user = ''; mysql> FLUSH PRIVILEGES;
6. Create your new database
mysql> CREATE DATABASE newdb; mysql> GRANT ALL PRIVILEGES ON newdb.* TO 'newuser'@'localhost' IDENTIFIED BY 'newdbpassword';
7. Install APC.
- Log in to post comments