Duplicate Installation Problems

Hello everyone, I'm trying to duplicate an elgg installation but it's not working. I'm following the instructions but apparently my css won't load.

I believe the problem might be here:

"Note that you also need to delete the views cache on the test server after the copy process. This is a directory calledviews_simplecache in your data directory and the file called view_paths (or views for elgg 1.8+)."

This is really not clear to me. Do I have to delete the ENTIRE views_simplecache or just all of its CONTENTS? Also, I cannot find this file "views" (im on elgg 1.8+) inside the data directory.

Please help!


Further info:

Centos 6
SELinux off
777 permissions to all elgg directories (i'll change that later)
Applied restorecon -R to all elgg directories.
 

  • You can remove all the cached views and view_paths from the data directory. Then run the upgrade.php

  • Hi Team Webgalli, thank you very much for your answer. That's exactly the point, I do not have any "views_path" file, nor a file called "views".

    Here is what I have inside the directory:

    [root@localhost elgg_data]# ls -l
    total 32
    drwxrwxrwx. 5 elgg elgg 4096 Sep 3 11:50 2012
    drwxrwxrwx. 3 elgg elgg 4096 Sep 3 11:50 file_tools
    drwxrwxrwx. 2 elgg elgg 4096 Sep 3 12:16 system_cache
    drwxrwxrwx. 2 elgg elgg 20480 Sep 3 12:16 views_simplecache

    There is neither a file called "views" nor a file called "view_paths". Those files, as mentioned by the previous post, should be deleted! Since I cannot find them, I just issue a

    [root@localhost elgg_data]# rm -rf views_simplecache/*

    Without any success. Some files are recreated into the directory after the upgrade.php, but no CSS is loaded in the page! When I try to login, I'm redirected to www.example.com/action/login and this gives a 404.  :(

    I tried renaming htaccess_dist to .htaccess, no deal. Tried to comment the 64M limitation, included RewriteBase... i'm running out of options :(

     

     

  • Try doing the mod rewrite test (http://docs.elgg.org/wiki/Mod_rewrite_test) and let us know the results

  • Hi Mark, thanks for your reply!

    I did it, and it said "mod_rewrite does not work". Strange, I thought the module was loaded. I then issued a:

    [root@localhost html]# apachectl -t -D DUMP_MODULES | grep rewrite
    rewrite_module (shared)
    Syntax OK

    And it is apparently loaded! I restarted the service but still no deal.

    Here's a part of my /etc/httpd/conf/httpd.conf:

    <Directory />
    Options FollowSymLinks
    AllowOverride All
    </Directory>

    Everything is with the 777 permission. Any ideas?

  • Are you installing in a sub-directory? Have a look at this page: http://docs.elgg.org/wiki/Install_Troubleshooting

    On some servers i have had to set the PHP open_basedir path to the data directory in order to get it working. Also have a look at your logs and see are there any errors

     

  • Yes, but I changed the document root of my /etc/httpd/conf/httpd.conf accordingly and also tried with RewriteBase /:

    Other part of my /etc/httpd/conf/httpd.conf showing the default virtualhost:

    <VirtualHost *:80>
    ServerAdmin me@me.com
    DocumentRoot /var/www/html/extranet
    ServerName www.example.be
    ServerAlias example.be

    ErrorLog logs/example.be-error_log
    CustomLog logs/example.be-access_log common
    </VirtualHost>

    The result of httpd -S command is "Syntax OK".

    And there is plenty of errors in the log saying permission denied:

    [Mon Sep 03 14:25:20 2012] [error] [client 217.x.x.x] PHP WARNING: 2012-09-03 14:25:20 (CEST): "fopen(/var/www/html/extranet_data/views_simplecache/63a6785fc3fe257112997d6076c50c4e): failed to open stream: Permission denied" in file /var/www/html/extranet/engine/lib/cache.php (line 271), referer: http://www.example.be/upgrade.php


    But I had chmoded 777 everything!

    [root@localhost html]# chmod -R 777 *
    [root@localhost html]# ls -la
    total 20
    drwxr-xr-x. 5 root root 4096 Sep 3 14:24 .
    drwxr-xr-x. 6 root root 4096 Sep 3 12:05 ..
    drwxrwxrwx. 13 extranet extranet 4096 Sep 3 11:49 extranet
    drwxrwxrwx. 6 extranet extranet 4096 Sep 3 11:50 extranet_data
    drwxrwxrwx. 2 root root 4096 Sep 3 14:04 modrewritetest

    I'm really lost here :( Already disabled SELinux, reseted firewall, reinstalled apache, smoked cigarettes...

    I don't know what else to do, and the worst is that I could finally convince ppl at my work to use it. Any suggestion is seriously appreciated.

    I thank you all in advance!

  • You must first get mod_rewrite working. Check phpinfo() and see is it loading

  • It is loaded!

    a. modrewrite test -  It says now "mod_rewrite works"
    b. phpinfo - mod_rewrite appears in the "Loaded Modules" area
    c. The command apachectl -t -D DUMP_MODULES | grep rewrite returns "Syntax Ok"

    I just erased everything and start over. Nothing, still not loading the CSS.

    The error log:

     

    [Mon Sep 03 17:32:53 2012] [error] [client 217.x.x.x] Deprecated in 1.8: register_elgg_event_handler() was deprecated by elgg_register_event_handler() Called from [#6] /var/www/html/elgg/mod/spam_login_filter/start.php:344
    [Mon Sep 03 17:32:53 2012] [error] [client 217.x.x.x] Deprecated in 1.8: register_elgg_event_handler() was deprecated by elgg_register_event_handler() Called from [#5] /var/www/html/elgg/mod/spam_login_filter/start.php:20
    [Mon Sep 03 17:32:53 2012] [error] [client 217.x.x.x] Deprecated in 1.8: isadminloggedin() is deprecated by elgg_is_admin_logged_in() Called from [#5] /var/www/html/elgg/mod/spam_login_filter/start.php:27
    [Mon Sep 03 17:32:53 2012] [error] [client 217.x.x.x] File does not exist: /var/www/html/elgg/cache, referer: http://www.example.be/upgrade.php
    [Mon Sep 03 17:32:53 2012] [error] [client 217.x.x.x] File does not exist: /var/www/html/elgg/cache, referer: http://www.example.be/upgrade.php
    [Mon Sep 03 17:32:54 2012] [error] [client 217.x.x.x] File does not exist: /var/www/html/elgg/favicon.ico
    [Mon Sep 03 17:32:55 2012] [error] [client 217.x.x.x] Deprecated in 1.8: register_elgg_event_handler() was deprecated by elgg_register_event_handler() Called from [#6] /var/www/html/elgg/mod/spam_login_filter/start.php:344, referer: http://www.example.be/upgrade.php
    [Mon Sep 03 17:32:55 2012] [error] [client 217.x.x.x] Deprecated in 1.8: register_elgg_event_handler() was deprecated by elgg_register_event_handler() Called from [#5] /var/www/html/elgg/mod/spam_login_filter/start.php:20, referer: http://www.example.be/upgrade.php
    [Mon Sep 03 17:32:55 2012] [error] [client 217.x.x.x] Deprecated in 1.8: isadminloggedin() is deprecated by elgg_is_admin_logged_in() Called from [#5] /var/www/html/elgg/mod/spam_login_filter/start.php:27, referer: http://www.example.be/upgrade.php
    [Mon Sep 03 17:32:55 2012] [error] [client 217.x.x.x] PHP WARNING: 2012-09-03 17:32:55 (CEST): "unlink(/var/www/html/elgg_uploads/system_cache/en.php): Permission denied" in file /var/www/html/elgg/engine/classes/ElggFileCache.php (line 180), referer: http://www.example.be/upgrade.php
    [Mon Sep 03 17:32:55 2012] [error] [client 217.x.x.x] PHP WARNING: 2012-09-03 17:32:55 (CEST): "unlink(/var/www/html/elgg_uploads/system_cache/fr.php): Permission denied" in file /var/www/html/elgg/engine/classes/ElggFileCache.php (line 180), referer: http://www.example.be/upgrade.php
    [Mon Sep 03 17:32:55 2012] [error] [client 217.x.x.x] PHP WARNING: 2012-09-03 17:32:55 (CEST): "unlink(/var/www/html/elgg_uploads/system_cache/view_locations): Permission denied" in file /var/www/html/elgg/engine/classes/ElggFileCache.php (line 180), referer: http://www.example.be/upgrade.php
    [Mon Sep 03 17:32:55 2012] [error] [client 217.x.x.x] PHP WARNING: 2012-09-03 17:32:55 (CEST): "unlink(/var/www/html/elgg_uploads/system_cache/view_types): Permission denied" in file /var/www/html/elgg/engine/classes/ElggFileCache.php (line 180), referer: http://www.example.be/upgrade.php
    [Mon Sep 03 17:32:55 2012] [error] [client 217.x.x.x] Deprecated in 1.8: register_elgg_event_handler() was deprecated by elgg_register_event_handler() Called from [#6] /var/www/html/elgg/mod/spam_login_filter/start.php:344, referer: http://www.example.be/upgrade.php
    [Mon Sep 03 17:32:55 2012] [error] [client 217.x.x.x] Deprecated in 1.8: register_elgg_event_handler() was deprecated by elgg_register_event_handler() Called from [#5] /var/www/html/elgg/mod/spam_login_filter/start.php:20, referer: http://www.example.be/upgrade.php
    [Mon Sep 03 17:32:55 2012] [error] [client 217.x.x.x] Deprecated in 1.8: isadminloggedin() is deprecated by elgg_is_admin_logged_in() Called from [#5] /var/www/html/elgg/mod/spam_login_filter/start.php:27, referer: http://www.example.be/upgrade.php
    [Mon Sep 03 17:32:55 2012] [error] [client 217.x.x.x] PHP WARNING: 2012-09-03 17:32:55 (CEST): "fopen(/var/www/html/elgg_uploads/views_simplecache/63a6785fc3fe257112997d6076c50c4e): failed to open stream: Permission denied" in file /var/www/html/elgg/engine/lib/cache.php (line 271), referer: http://www.example.be/upgrade.php

  • I still think it is some problem with the views cache... please help

  • Hi again, I found an old post that seems totally related here, but there is no solution. Tomorrow I'll start over once again, disabling all third-parties plugins to see if I have a different result. But I'm still with my initial doubt regarding this phrase from the instructions:

    "Note that you also need to delete the views cache on the test server after the copy process. This is a directory called views_simplecache in your data directory and the file called view_paths (or views for elgg 1.8+)."

    Do I have to delete the entire views_simplecache directory or just its contents?

    Also, I don't find the "file called views_paths" nor the "views for elgg 1.8+" inside the data directory. I'm using elgg 1.8.4. Where exactly they supposed to be located?

    Thank you guys.