Wordpress Installation

Discussion in 'General' started by AndrewPienaar, May 19, 2020.

  1. showe1966

    showe1966 Member

    Sheesh I still can't get WP running. I am getting the following error. I think it's something to do with the php installation ?
    The big issue I have is that WP is not even starting, so I can't get much diagnostic information:-
    [proxy_fcgi:error] [pid 663021] [client xxxxxxx:35286] AH01071: Got error 'PHP message: PHP Warning: require(/var/www/clients/client1/web1/web/blog/wp-includes/version.php): failed to open stream: No such file or directory in /var/www/clients/client1/web1/web/blog/wp-settings.php on line 33PHP message: PHP Fatal error: require(): Failed opening required '/var/www/clients/client1/web1/web/blog/wp-includes/version.php' (include_path='.:/usr/share/php') in /var/www/clients/client1/web1/web/blog/wp-settings.php on line 33', referer: https://www.xxxxxxxx.com/blog/readme.html

    If I look on line 33 of wp-settings.php, it is checking for the php version or something:-

    line 32 global $wp_version, $wp_db_version, $tinymce_version, $required_php_version, $required_mysql_version, $wp_local_package;
    line 33 require ABSPATH . WPINC . '/version.php';

    Anyway I can see WP is not even starting. It errors out whilst trying to start....

    Can you guys give me any input on what the heck is the problem ??????
     
  2. showe1966

    showe1966 Member

    I installed wp cli interface to help with doing diagnostics.
    If i do wp config list, I get a "normal" response.
    i.e
    wp config list
    +------------------+------------------------------------------------------------------+----------+
    | name | value | type |
    +------------------+------------------------------------------------------------------+----------+
    | table_prefix | wp_ | variable |
    | WP_HOME | https://wxxxxxxxxxxx.com/blog/ | constant |
    | WP_SITEURL | https://wwwxxxxxxxxxxxxm/blog/ | constant |
    etc etc.
    If I type anything else, it just says the install doesn't exist:-
    wp db size --tables
    Error: This does not seem to be a WordPress installation.
    Pass --path=`path/to/wordpress` or run `wp core download`.
    If i try to run CLI install command, it complains that files are already in the install directory.
    This sucks totally !!!!
     
  3. showe1966

    showe1966 Member

    It seems the problem is that the following file can't be found during startup:-
    wp-includes/version.php
    I don't have any such sub-directory of my wp home directory, or such a files in it. I am not sure what to do ? I assumed that the files and that sub-directory was virtually created by php when the wp software started up ?
    Is that not the case ?
    Do I need to put that info in manually some how ?
     
  4. Taleman

    Taleman Well-Known Member HowtoForge Supporter

    How are you installing Wordpress? This thread had several methods of installing and warned about methods that do not work.
    What happens in the install, show listing of directories and files after install. From the errors you showed it seems the files did not get installed, or not in the right place or maybe have wrong owner or permissions.
    I have installed Wordpress on ISPConfig like @till adviced, it has worked every time. I have done installs in a subdirectory of the website, too.
     
    ahrasis likes this.
  5. nhybgtvfr

    nhybgtvfr Well-Known Member HowtoForge Supporter

    no, it's not checking for a php version, it's looking for wp-includes/version.php which gives details of the installed version of wordpress.

    wp-cli will only work properly (ie access the db) if the commands are run from the root of the wordpress install, or you provide it with the correct path.

    it really shouldn't be this difficult to install wordpress, but you've definitely got something wrong somewhere.
    cd to your wordpress install location and post the results of 'pwd' and 'ls -l'
     
  6. showe1966

    showe1966 Member

    Hey thanks for your replies !! I much appreciate !!!!
    Points:
    1. W.R.T. WP CLI, Yes, I did CD to my wp directory before running the CLI commands. My WP directory I want to be at www.example.com/blog.
    2. Here is what I get when I pwd from /var/www/clients/client1/web1/web/blog:
    cd /var/www/clients/client1/web1/web/blog
    root@server1 /var/www/clients/client1/web1/web/blog # pwd
    /var/www/clients/client1/web1/web/blog
    3. Here is what I get when I ls -l from /var/www/clients/client1/web1/web/blog:-
    ls -l
    total 200
    -rw-r--r-- 1 www-data www-data 405 Jan 23 16:07 index.php
    -rw-r--r-- 1 www-data www-data 19915 Jan 23 16:07 license.txt
    -rw-r--r-- 1 www-data www-data 7346 Jan 23 16:07 readme.html
    -rw-r--r-- 1 www-data www-data 434 Feb 10 19:29 wordfence-waf.php
    -rw-r--r-- 1 www-data www-data 7165 Jan 23 16:07 wp-activate.php
    -rw-r--r-- 1 www-data www-data 351 Jan 23 16:07 wp-blog-header.php
    -rw-r--r-- 1 www-data www-data 2328 Jan 23 16:07 wp-comments-post.php
    -rw-r--r-- 1 www-data www-data 3328 Feb 10 18:45 wp-config.old
    -rw-r--r-- 1 www-data www-data 3572 Mar 13 20:20 wp-config.php
    -rw-r--r-- 1 www-data www-data 3939 Jan 23 16:07 wp-cron.php
    -rw-r--r-- 1 www-data www-data 2496 Jan 23 16:07 wp-links-opml.php
    -rw-r--r-- 1 www-data www-data 3900 Jan 23 16:07 wp-load.php
    -rw-r--r-- 1 www-data www-data 45463 Jan 23 16:07 wp-login.php
    -rw-r--r-- 1 www-data www-data 8509 Jan 23 16:07 wp-mail.php
    -rw-r--r-- 1 www-data www-data 22298 Feb 10 22:59 wp-settings.php
    -rw-r--r-- 1 www-data www-data 31693 Jan 23 16:07 wp-signup.php
    -rw-r--r-- 1 www-data www-data 4747 Jan 23 16:07 wp-trackback.php
    -rw-r--r-- 1 www-data www-data 3236 Jan 23 16:07 xmlrpc.php
     
  7. showe1966

    showe1966 Member

    The reason why wp-settings.php is getting stuck at line 33 is because the installation has not worked, so the directory wp-includes does not even exist hence the file wp-includes/version.php is not found. I could manually create this info, but I assume it is generated automatically when wordpress installs right ? So my wordpress is not starting and it is not creating these files.....
     
  8. till

    till Super Moderator Staff Member ISPConfig Developer

    That's not a complete WordPress installation, these are just a few files from the first filesystem level. The folders with all the system files are missing. And also all the files are owned by the wrong user and group, they must be owned by user web1 and group client1 in this case.
     
  9. till

    till Super Moderator Staff Member ISPConfig Developer

    Here are the commands to install WordPress, it's really easy:
    Code:
    cd /var/www/clients/client1/web2/web
    wget https://wordpress.org/latest.tar.gz
    tar xfz latest.tar.gz
    rm latest.tar.gz
    mv wordpress/* .
    rmdir wordpress/
    chown -R web2:client1 *
    web2 and client1 must be adjusted, depending on your website! And the mv command has whitespace and then a dot at the end!

    That's all. Now open the domain of that website in a web browser and follow the instructions on the screen.
     
  10. showe1966

    showe1966 Member

    Right.....missing files....that would certainly explain the error messages....I will therefore now proceed as follows:-
    1. Remove everything currently in my target install directory (I assume i should also include removal of the hidden files .htaccess and .user.ini . Is that right ???? )
    2. Do download of wordpress again using the above commands and move everything to the target directory.
    The reason why this has happened is because I didn't find a list of the files that are installed when the wordpress installer is run anywhere on the web. Because, that's the easy step. So, I didn't know until now I was missing a bunch of files from my install.
    If and when I finally get all this done, i will post a set of complete step-by step instructions for other "wordpress noobs" like me to follow in the future.
     
  11. till

    till Super Moderator Staff Member ISPConfig Developer

    there is no need to move anything to the target directory, just choose the right directory in the first command.
     
  12. nhybgtvfr

    nhybgtvfr Well-Known Member HowtoForge Supporter

    my concern looking at that, is what are the ownership / permission settings of the blog folder?
    why are all those files listed as owned by www-data? if you uploaded them via ftp, or even extracted the tar.gz archive as the site owner via ssh, they should have the web##:client## ownership.

    just follow @till's instructions in post #29, or if using wp-cli, just go to the required root folder, and run 'wp core download' as the site's ssh user, that should give you the entire wordpress files/folders as the correct owner.
    you could then continue to configure and install it using wp-cli, but you might find it more straightforward to just browse to the site and continue the install via the browser.
     
  13. showe1966

    showe1966 Member

    I have continued to work on this. Following the instructions, I was able to install Wordpress via the GUI. However, I did notice 2 issues:
    1. There were problems with file permissions during install when i used the user created under ispconfig. The user didn't have sufficient permissions for some reason. So, I installed as root, then changed the file ownership.
    2. The config. file needed to be modified before it would work, due to the wordpress is not installed in the root directory of the website.
    FYI, I still didn't get my website up and running. That is becuase I am not just doing an install, I am trying to move an existing website to a new server. It has multiple plugins and security enhancements enabled on it, and the kind person who did this work for me didn't provide me with any notes about what he did. So, I am battling with wordfence right now....so, what I actually required are some instructions on how to move a secured Wordpress website to a new server...with different versions of all the software on it.....
    Once I do get through with all this, I will provide a post with a set of step by step instructions. For sure, I am learning quite a bit about Wordpress software right now. Generally, IMHO, it seems pretty contorted and messy to set up, and well written documentation is difficult to find. The main thrust of most of the articles seems to be to get you to buy the non-free edition. It reminds me of how it used to be with Windows....
     
  14. nhybgtvfr

    nhybgtvfr Well-Known Member HowtoForge Supporter

    install the plugin 'duplicator' by snap-creek on the wordpress site on the old server, access the wordpress backend on this site on the old server, use the plugin to create a package.
    it'll create an archive file of your whole site, and an installer.php file. copy both files to whatever folder you want to install the site to on the new server, make sure these 2 files have the correct web##:client## id's on the new server.
    if you're keeping the same domain, change the dns records / hosts file entries to point to the new server.
    browse to http(s)://<domain.tld>/<subfolder>/installer.php and follow the instructions to install the site on the new server.

    although that doesn't mean it'll install problem-free, it should, but you claim to have file permission problems when installing using the instructions provided in this thread. that would indicate some wider issue somewhere in your setup. if you followed @till's instructions (post #29) you should not have any file/folder permission problems.
     

Share This Page