Install WordPress on Fedora 20

To start install apache:

yum -y install httpd

Start the apache on system startup

systemctl start httpd.service
systemctl enable httpd.service

Install PHP

yum -y install php php-zlib php-iconv php-gd php-mbstring php-fileinfo php-curl php-xmlreader php-xmlwriter php-spl php-openssl php-pspell php-mysql

Install MariaDB database server.

yum -y install mariadb mariadb-server

Start MariaDB and on system startup

systemctl start mariadb.service
systemctl enable mariadb.service

Secure MariaDB installation.

mysql_secure_installation

Create Database:

Login with root in MariaDB.

mysql -u root -p

Create a database for WordPress.

CREATE DATABASE wordpress;

Create a user.

CREATE USER ‘wpuser’@’localhost’ IDENTIFIED BY ‘wppassword’;

Grant the permission to the created user to access database.

GRANTALL PRIVILEGES ON wordpress.* TO ‘wpuser’@’localhost’;

Configure and install WordPress:

Download the latest WordPress.

wget http://wordpress.org/latest.tar.gz

Extract it to /var/www/html/ directory.

tar -zxvf latest.tar.gz -C /var/www/html/

Make the apache user as the owner to WordPress directory.

chown -R apache:apache /var/www/html/wordpress/

Copy the wp-sample-config.php file and make it as wp-config.php file.

cp /var/www/html/wordpress/wp-config-sample.php /var/www/html/wordpress/wp-config.php

Edit the config file and mention the database information.

vi /var/www/html/wordpress/wp-config.php

Default will look like below.
// ** MySQL settings – You can get this info from your web host ** //
/** The name of the database for WordPress */
define(‘DB_NAME’, ‘database_name_here‘);
/** MySQL database username */
define(‘DB_USER’, ‘username_here‘);
/** MySQL database password */
define(‘DB_PASSWORD’, ‘password_here‘);
/** MySQL hostname */
define(‘DB_HOST’, ‘localhost‘);

Modified entries according to the created database user and database will look like.
// ** MySQL settings – You can get this info from your web host ** //
/** The name of the database for WordPress */
define(‘DB_NAME’, ‘wordpress‘);
/** MySQL database username */
define(‘DB_USER’, ‘wpuser‘);
/** MySQL database password */
define(‘DB_PASSWORD’, ‘wppassword‘);
/** MySQL hostname */
define(‘DB_HOST’, ‘localhost‘);
Install WordPress:

Visit http://your-ip-address/wordpress/wp-admin/install.php.