white page displays after setting up settings.php and .htaccess

Hi,

I downloaded elgg 1.5. I did set up all the stuff requested in tech requirements (created the mysql database and username, tested it is able to access, tested that apache2 mod_rewrite works, etc. etc.). As elgg wasn't able to write into .htaccess and settings.php, it showed me the web page with instructions how to do it manually. I followed those instructions, hit the browser refresh button, and got the white screen.

Browser shows that the page source is blank (empty, nothing in it). Apache access.log shows the page has accessed via the GET method, but error.log doesn't show anything (if I hook both access.log and error.log with tail -f, only access.log updates when I refresh from browser).

I found this bit of information from FAQ:

There is a white page after I submit my database settings

Check that the Apache mysql module is installed and is being loaded.

I googled for "apache mysql module debian package" and "apache mysql module". Google, that has helped me out for most of the stuff that really exist somewhere, failed on this one. None of the search attempts gave me any results that would explain what that "Apache mysql module" might be. I reasoned that perhaps I am missing php mysql component which I then fixed with "apt-get install php5-mysql" at my debian etch. But the "white screen of death" sticks.

Can anybody hint me,

a) what is "Apache mysql module". How to "check" it (as FAQ suggests)? How to get it (if the "check" tells to me that I am missing it)?

b) is there anything else I might have wrong?

c) what might be the best debugging options for the issue?

Thank you in advance for any hints :)

Just Trying

  • Hmmmm...

    Dyou have mod_rewrite installed? :)

  • Dagorath, yes. As I said, I even tested that it works. :)

  • I've got the same problem as JT before with external pages and it was usually that the path to the php files was incorrectly configured...

  • Jededitor, which external pages and php files you mean? For me, it is sure the elgg php files get picked up. When either settings.php or .htaccess is missing (I did the experiment with renaming temporarily either of them), I get the page that says correspondingly, what I am missing. From that I can conlcude with certainty three things:

    1. the index.php gets picked up
    2. the settings.php gets picked up
    3. the .htaccess file is found

    It is just, that if both settings.php and .htaccess are in place, I get the empty white screen.

     

  • I narrowed down to the line of code in site initialization, where the death happens. It is in database.php, function establish_db_link($dblinkname = "readwrite"), the line:

                        // Connect to database

                            if (!$dblink[$dblinkname] = mysql_connect($CONFIG->dbhost, $CONFIG->dbuser, $CONFIG->dbpass, true))

    It just drops there. No catchable exception is thrown, nothing comes to apache error.log, it just cuts here. The execution of the code don't reach beyond that line. That's it.

    The $dblinkname has the value "readwrite", the variables that go as arguments to mysql_connect contain exact proper values as ought to be -- I tested with mysql command-line terminal -- those host, user and pass are valid credentials. If I copy that mysql_connect command with the same parameter values to a separate php-file with only this line, and run it from command-line through php, it works.

    Any idea, how to debug it further?

     

  • Got it fixed. I discovered the .htaccess turned off the display_errors. Turning it back on helped me further -- the error said the function was undefined. Googling the error message, I found that I had to uncomment the line in php.ini file to load mysql extension. That solved it.