Install WordPress 4.1.1 on Fedora 21/20, CentOS/RHEL 7/6.6/5.11 - Comment Page: 2

This is guide, howto install WordPress 4.1.1 with Nginx or Apache on Fedora 21/20/19, CentOS 7/6.6/5.11 and Red Hat (RHEL) 7/6.6/5.11 servers. Wordpress needs web server with PHP and MariaDB or MySQL database. This guide uses Apache web server with PHP 5.6 or Nginx web server with PHP 5.6 (PHP-FPM) and MariaDB 10/5.5 database server or Mysql 5.6 database server. If you want to install Wordpress with Apache then use a - [Apache] sections and if you want install Wordpress with Nginx then use b - [Nginx] sections. 1. Install Needed Web and Database Servers [Apache] 1.1a Install the whole LAMP environment with following guide LAMP (Linux/Apache/MySQL/PHP) on Fedora, CentOS/Red Hat...

121 comments on “Install WordPress 4.1.1 on Fedora 21/20, CentOS/RHEL 7/6.6/5.11 - Comment Page: 2

1 2 3 4
    1. My server database version is below 5.3. In that case, is there any alternate way without changing MySQL version?

      Reply
      • Hi Shariar,

        Your database version is below 5.3? So could you tell your MySQL version? :)

        Reply
    2. Great tutorial! How do I go about setting up another WP Blog?

      Reply
      • Hi Kevin,

        Just use same method, but change location and names. :)

        Reply
        • Thanks JR, I will give it a try.

          Reply
    3. Hi , I’m sorry what can and can not in the subject , but I have very often when approaching the site crashes gateway error 504, how to fix it ?

      Reply
      • Hi TaresaDianafyn,

        HTTP 504 error is Gateway Timeout error.

        Could you first tell do you use Nginx or Apache?
        And more about your web server and PHP configurations?
        Do you get HTTP 504 errors on test server or on production server under high load?
        What you mean very often…is your setup working, but sometimes you get 504 or do you get it all page loads?

        Reply
    4. Hi,
      Thanks for the tutorial. you saved my week.
      still I have one issue.Im bit new to this server stuff. nginx config file is working fine if Im using the default permalink structure only. i want to use a structure like http://example.com/2012/12/30/post-name.
      I search and found some results but nothing is working on me. Is there a way to fix this.
      Thanks again.

      Reply
      • Hi kasun,

        You are welcome! :)

        Yes problem is that the WordPress permalink structure with nginx requires rewrite to index.php. Or alternatively urls have to contain index.php, like http://example.com/index.php/2012/12/30/post-name.

        I updated this guide conf and following if + rewrite do the trick:

        
        if (!-e $request_filename) {
            rewrite . /index.php last;
        }
        

        If you copy config again then it should work…please let me know, if you have still problems with it? :)

        Reply
        • ya permalinks working!
          Thanks lot JR

          Reply
          • Excellent! You are welcome!

            Reply
            • sorry to bug you.:) but I’m using w3 total cache plugin for wordpress. once I added the config change CPU went bit high. also site became bit slow. when i disable the w3 total cache its working fine. i did one mistake. my wordpress files are in var/www/ folder. any clue?

              Reply
              • No problem at all. :)

                W3 Total Cache performance depends totally your configuration?

                If you run WordPress on your own server / VPS server then W3TC is not probably the best choice for caching. It contains a lot of features, but at the same time, it is very heavy plugin to run. If you serve just almost static content, your cache time is very long and almost every page load comes from cache then it should be okay, but if you have logged in users or lot of commenters then it might be too heavy to run on every page load.

                Reply
    5. Fantastic blog, thanks alot.

      Reply
    6. Thanks a lot. I have successfully done all the steps, except for the pwgen one. I have RHEL 6.2. Yum said there is no package available. Could you please tell me where I can find instruction to intall this package? My linux knowledge is very shallow.
      Thanks.

      Reply
      • You are welcome!

        Do you have epel repository enabled on your system?


        Available Packages
        Name : pwgen
        Arch : x86_64
        Version : 2.06
        Release : 5.el6
        Size : 19 k
        Repo : epel
        Summary : Automatic password generation
        URL : http://sf.net/projects/pwgen
        License : GPL+
        Description : pwgen generates random, meaningless but pronounceable passwords.
        : These passwords contain either only lowercase letters, or upper
        : and lower case, or upper case, lower case and numeric digits.
        : Upper case letters and numeric digits are placed in a way that
        : eases memorizing the password.

        Reply
    7. Hi JR,
      I install WordPress as above and got everything smoothly. But when I tried to install a new theme with a zip file, WordPress asks me to provide log in information to FTP the file into the server. I have keyed in the correct username and password, but wordpress gives me the error: “Failed to onnect to FTP server http://www.mysite.org:21

      I have tried all the posssible ways that i can find online like change the uploads folder to wp-content/uploads, change the owner into root, change wp-upload folder to 777,etc. None of them works in my case.

      When I take a look at the server, the files is actually uploaded, just that it is not installed.

      Any idea on how to solve this?

      Thanks a lot JR

      Reply
      • Are you running WordPress with Apache or Nginx?

        Reply
        • Hi JR,
          I run WordPress with Apache

          Reply
          • To enable WordPress plugin and template installation without FTP.

            Add following to wp-config.php file:

            
            define('FS_METHOD', 'direct');
            

            Run following commands (change paths, if needed):

            
            chcon -R -t httpd_sys_content_rw_t /var/www/html/wordpress/wp-content
            
            chown -R apache: /var/www/html/wordpress/wp-content
            

            Is it working then?

            Reply
            • Hi JR,
              Yes, it finally works like a charm. Thanks you sooo much.

              May I know whether the “chcon -R ….” command is necsesary? I ran into some problem with it, and i chose to omit it. So I only add “define…” into wp-config file and do “chown…” in my system to make it work.

              Reply
              • Hi Naka,

                You are welcome! And I just quickly tested this and chcon command might be unnecessary, if you have SELinux disabled, SELinux permissive mode or some other reasons… :)

                Reply
            • Dude, Dude, Dude….. Thank you for posting this. (takes gun away from temple)

              Reply
    8. Thanks for your post JR! I have set up LAMP on LinuxMint12 and have a WordPress install running nicely, except for adding themes. I followed your instructions in the above comment to edit my wp-config file and used the chown command line with my user name rather than apache (apache did not work, nor did apache2).

      At this point I am no longer getting the ftp request from WordPress, but I am getting a message that a theme file cannot load and the install failed. I have tried 3 different themes and all end up having one file or another fail (no relation between them, just random files it seems).

      I also tried using sudo nautilus to copy the theme folders in, and they do copy over, but they do not show up in the themes list on the wp admin.

      Any suggestions? At this point I would love to either be able to upload themes or use nautilus to copy over theme folders and have them show up to be activated- either way would be great if you have any ideas! thanks :)

      Reply
      • Hi trishia,

        Try to chown your wp-content directory owner (user and group) to www-data (recursively). If you run default apache installation then it should be www-data, I assume that this is copied from Ubuntu to LinuxMint… :)

        Reply
    9. Hi,
      First of all, nice tutorial.
      I have been following your tutorial to create WordPress blog
      I used Nginx, PHP-FPM, mySQL

      I created user ‘wordpress’ with home directory and placed my wordpress file in /home/wordpress/public
      I hv created php-fpm pool with user=wordpress and group=wordpress
      I hv also created nginx conf for wordpress and place it at /etc/nginx/sites-available/wordpress and symlinks to /etc/nginx/sites-enabled/wordpress

      I can proceed with the installation of wordpress but several issue occur:
      1. The installation page is not shown properly (missing images, css not loaded)
      2. after installation, I can’t access wp-admin pages or main pages of my websites. the error is 403: Forbidden

      I use VPS and not installed wordpress locally.
      Can you tell me what seem wrong here?
      Thank you and very much appreciate~

      Reply
      • sorry to reply you too soon
        but i manage to fixed my problems
        I moved the file to /var/www/wordpress which is default nginx folder

        but the question is can’t i move the folder to another location like apache with suExec?

        Reply
        • Hi PeterB,

          Check /var/log/audit/audit.log file. Do you get any SELinux errors, when you try to run it under /home/wordpress/public directory?

          Reply
    10. It seemed to be running smoothly until I tried to navigate to http://wordpress/ and all it gave me was “Error establishing a database connection”. Can you help in any way? Thanks!

      Reply
      • Nevermind :) My password wasn’t correct when being declared in the wp_config.php file. Haha, whoops.

        Reply
        • Excellent to hear that you got it solved! :)

          Reply
    11. I followed the instructions here to install and run the Apache Server, MySQL and WordPress on my laptop running Fedora 16. I am trying to import content from my blog at WordPress.com. When my browser goes to:
      http://127.0.0.1/wp/wordpress/wp-admin/import.php
      I get this message: An Unexpected HTTP Error occurred during the API request.

      Like Trishia I also tried getting the plugin and putting it in the directory manually, but when I went to the dashboard page to enable it, it wasn’t even listed.

      I assume that my problem is related to not having an FTP server running on my laptop, although I never get so far as being prompted for FTP info. Anyway I tried following your suggestion to Naka on March 6, 2012. I added this line to my wp-config.php:

      define('FS_METHOD', 'direct');

      And I ran these commands after adjusting the paths:

      chcon -R -t httpd_sys_content_rw_t /var/www/html/wordpress/wp-content
       
      chown -R apache: /var/www/html/wordpress/wp-content

      This didn’t get me anywhere. At this point I’m confused as who the owner and group should be for all the WordPress directories. After running the above commands, my wp-content and its subdirectoreis are owned by apache with the group also being apache. The permissions are 755. The other directories under wordpress have my userid for both owner and group.

      Reply
    12. This tutorial was phenomenal. Thank you very much.

      Reply
    13. define('FS_METHOD', 'direct');

      …I found this really useful on my SME Server 8 installation – thank you!

      Reply
1 2 3 4

Leave a Reply

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.

Close