1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

XF 1.2 DB.php error when trying to access my xenforo install.

Discussion in 'Troubleshooting and Problems' started by darren, Jan 2, 2014.

  1. darren

    darren Member

    Background info:

    My host had problems with my server which died and long story short there was no recent SQL backup.

    They rebuilt the SQL without error from the FRM (? if memory serves me correctly) files and I'm now getting the following error after it taking 45odd seconds to timeout:

    Fatal error: Call to undefined function spl_object_hash() in /var/www/vhosts/mysite.com/httpdocs/community/library/XenForo/Db.php on line 36

    Strangely when I enabled debug mode in the config.php the error just come up with a more basic internal server error message.

    The error log :

    [Thu Jan 02 13:05:08 2014] [warn] [client 82.9.169.x] mod_fcgid: stderr: PHP Fatal error: Call to undefined function spl_object_hash() in /var/www/vhosts/mysite.com/httpdocs/community/library/XenForo/Db.php on line 36
    [Thu Jan 02 13:05:54 2014] [warn] [client 82.9.169.x] mod_fcgid: read data timeout in 45 seconds
    [Thu Jan 02 13:05:54 2014] [error] [client 82.9.169.x] Premature end of script headers: index.php
    [Thu Jan 02 13:05:59 2014] [warn] [client 82.9.169.x] mod_fcgid: read data timeout in 45 seconds
    [Thu Jan 02 13:05:59 2014] [error] [client 82.9.169.x] Premature end of script headers: index.php

    any help would be greatly appreciated as my site has been down for near on 2 weeks now and i'm pulling my hair out!
     
  2. Brogan

    Brogan XenForo Moderator Staff Member

    What are you doing to trigger that error?
    It looks like the database integrity is compromised.

    Presumably you have also restored all of the server files from the correct .zip package, as well as restoring config.php and the install-lock.php file?
     
  3. darren

    darren Member

    just accessing index.php brings up the error.

    I have restored all server files from the same version package (latest) and the config.php is fine..

    However what is install-lock.php?
     
  4. Brogan

    Brogan XenForo Moderator Staff Member

    That's the file which is created once the software has been installed.
    However, your problem looks to be more fundamental and database related.
     
  5. darren

    darren Member

    Ive just tried to run the file to check if my server is update date enough?

    Requirements Not Met
    The following XenForo requirements were not met. Please contact your host for help.

    1. PHP 5.2.4 or newer is required. 5.1.6 does not meet this requirement. Please ask your host to upgrade PHP.
    2. The required PHP extension JSON could not be found. Please ask your host to install this extension.
    XenForo also requires MySQL 5.0 or newer. Please manually check that you meet this requirement.
     
  6. darren

    darren Member

    @Brogan Would the above incompatibility sound like something that would produce this error?

    It's strange as I'm with the same hosting company and one would assume the same version of PHP as prior which worked fine before?!

    Also install-lock.php is there also, basically they had a back up of my ftp files just not the SQL so rebuilt it via the FRM? files. That probably makes sense to you?
     
  7. Brogan

    Brogan XenForo Moderator Staff Member

    You definitely need to address those issues with your host.
    It appears you have been moved to another server when they restored your account and it is no longer compatible.
     
    darren likes this.
  8. darren

    darren Member

    Thanks mate, appreciate the speedy response and thank god I decided to try and run the compatibility tester.

    Will report back once they've upgraded.
     
  9. darren

    darren Member

    For anyone who has a similar problem.. PHP upgraded and site fully working once again.

    Thank you Brogan!
     

Share This Page