how install wordpress in lampp server centos
Views: 7
0 0
Read Time:2 Minute, 45 Second

Install Lempp

If Don’t how install Lampp server see this tutorial

Creating WordPress MySQL Database

Our WordPress will require a database and a database user. To create one, simply use the following commands. Feel free to replace the database name, user and password as per your preferences:

# mysql -u root -pEnter password:
## Create database ##CREATE DATABASE wordpress;## Creating new user ##CREATE USER wordpress@localhost IDENTIFIED BY "secure_password";## Grant privileges to database ##GRANT ALL ON wordpress.* TO wordpress@localhost;## FLUSH privileges ##FLUSH PRIVILEGES;## Exit ##exit

Preparing WordPress Installation

Now we are ready to download the latest WordPress archive:

# cd /tmp && wget

Make Directory each website create new Directory

# mkdir /var/www/wp-site

Next extract the archive in our web directory:

# tar -xvzf latest.tar.gz -C /var/www/wp-site

The above will create the following directory, which will contain our WordPress script:


Now change the ownership of that directory to user “apache”:

# chown -R apache /var/www/wp-site

Creating Apache Virtual Host for WordPress

We will create a separate virtual host for our WordPress install. Open /etc/httpd/conf/httpd.conf with your favorite text editor:

# vim /etc/httpd/conf/httpd.conf

And add the following code at the bottom of the file and replace the marked text with the information related to your installation:

<VirtualHost <your-local-ip>:80> ServerAdmin DocumentRoot /var/www/wp-site/wordpress ServerName ServerAlias ErrorLog /var/log/httpd/neoistone-error-log CustomLog /var/log/httpd/neoistone-acces-log common

Save your changes and restart Apache:

# systemctl restart httpd

Installing WordPress on Website

Now we are ready to run our WordPress installation. To start the installation you can access either your server’s IP address at http://ip-address or if installing locally you can use http://localhost or if you are using a real domain, you can use the domain instead. You should see the following page:

Setup WordPress on CentOS 7

When you click on Let’s Go button, you will be redirected to the next page of the installation, where you will have to enter the database details we created earlier.

WordPress Database Settings

When you have enter the details, click the submit button. WordPress will attempt to create it’s configuration file called wp-config.php. If everything is fine you should see the following page:

WordPress Installation Setup

Once you click the “Run the installation” button, you will be asked to enter some details about your website: Site Title, Username, Password and Email address.

WordPress Website Details

When you have filled all the required information finalize the installation by clicking the button at the bottom. Your installation is now complete. Your front page should look something the image below:

WordPress Website View

And the WordPress dashboard looks as follows:

WordPress Admin Dashboard

You can now start managing your WordPress website.


You have successfully completed the installation of WordPress using LAMP on CentOS 7. If you had any difficulties or questions, please submit them in the comment section below.