Database installation: Data Directory problem

Hi,

I'm having trouble getting past the data directory requirement in step 3 of the install process. I keep getting the "Your directory .../.../... does not exist." message.

I'm trying to serve it locally, working with apache on macOS Mojave. I've been able to install Wordpress so I assume it's not an issue with the database.

I want to install Elgg in /users⁩/user-name/sites/elgg. To address the 'outside root' requirements I've put the data directory at /users⁩/user-name/elgg-data.

'Elgg-data' permissions are set to 750.

I've checked the php.ini file for the open_basedir issue, which I located using phpinfo();. This is all that it says there, which I assume means that this isn't what is causing the problem?:

; open_basedir, if set, limits all file operations to the defined directory
; and below.  This directive makes most sense if used in a per-directory
; or per-virtualhost web server configuration file.
; Note: disables the realpath cache
; http://php.net/open-basedir
;open_basedir =


These seem to be all of the steps that are covered in the trouble shooting guide and previous topic posts but I'm still getting the "does not exist" message.

There must be something that I've missed or misinterpreted?

Thanks

  •  

    the database is created in phpadmin

    this is the mysql interface

     

    modify setting.php in ellg-config

  • Thanks, but modify setting.php how? Can you elaborate some more?

    At the moment my sites/elgg-config only has a readme. That readme says it will eventually hold a settings.php but only after installation, which I can't get through because of the data directory issue.

    The readme has instructions for manually copying settings.php from vendor/elgg/elgg/elgg-config/settings.example.php, but I'm still not clear on how to do that in a way that will fix the data directory issue.

    I had a previous requirements issue with the elgg-config directory but that seemed to be fixed once I changed the permissions. Is what you're saying related to that?

  • Requirements: http://learn.elgg.org/en/3.x/intro/install.html#requirements

    STEP 1

    // Create DB
    // DB username=root password=password
    // DB must be encoding=utf8mb4

    
    mysql -u root -ppassword
    mysql > CREATE DATABASE elgg;
    mysql > exit;
    

    OR

    Use PhpMyAdmin or similat tools

    STEP 2

    // Create 2 directories
    // Use /var/www/ if this is a public server directory.
    // Otherwise, use /public_html/ or something else. Ask your hosting support about it.

    mkdir /var/www/username/www
    mkdir /var/www/username/data
    

    STEP 3

    // Set permissions

    
    chown -R username:username /var/www/username/www
    

    // Be sure that your server name is www-data
    // Otherwise, use apache, httpd or something else. Ask your hosting support about it.

    chown -R www-data:www-data /var/www/username/data
    chmod -R 750 /var/www/username/data
    

    STEP 4

    // SFTP way

    
    Download Elgg https://elgg.org/about/download
    UnZip to /var/www/username/www
    

    OR

    // Composer way

    
    composer self-update
    composer create-project elgg/starter-project:dev-master /var/www/username/www
    cd /var/www/username/www
    composer install
    composer install
    vendor/bin/elgg-cli install 
    

    STEP 5

    Go to yoursite.com/install.php and run Elgg installation


    Docs: http://learn.elgg.org/en/3.x/intro/install.html
     

    Troubleshootings: http://learn.elgg.org/en/3.x/intro/install.html#troubleshooting
     

    FAQs and Other Troubleshooting: http://learn.elgg.org/en/3.x/appendix/faqs.html
     

    Community discussions: https://elgg.org/search?q=installation&entity_type=object&entity_subtype=discussion&offset=0&search_type=entities

  • Forgot to add in Step 3:

    // Separatly, add these permissions for elgg-config folder:

    chown -R www-data:www-data /var/www/username/www/elgg-config
  • Thanks RvR, this helped me get it up and running.