DB problem

TPerry

Well-known member
I'm getting the following error on my site
An unexpected database error occurred. Please try again later.

I've checked all logs and cannot find anything out of the ordinary. The only thing I did was install mod-security (and then removed it via apt-get remove after I was getting errors). Now the site cannot be connected to at all.

I've also restarted the VPS just to check that and disabled all add ons.

I've checked all the config files for modification dates for Apache, php5 and mysql but none are recent. Any suggestions where to look since xenForo apparently doesn't write an error file that you can use.
 
An exception occurred: Mysqli prepare error: Unknown table engine 'InnoDB' in /var/www/twowheel/library/Zend/Db/Statement/Mysqli.php on line 77
  1. Zend_Db_Statement_Mysqli->_prepare() in Zend/Db/Statement.php at line 115
  2. Zend_Db_Statement->__construct() in Zend/Db/Adapter/Mysqli.php at line 381
  3. Zend_Db_Adapter_Mysqli->prepare() in Zend/Db/Adapter/Abstract.php at line 478
  4. Zend_Db_Adapter_Abstract->query() in Zend/Db/Adapter/Abstract.php at line 825
  5. Zend_Db_Adapter_Abstract->fetchOne() in XenForo/Error.php at line 50
  6. XenForo_Error::unexpectedException() in XenForo/Application.php at line 295
  7. XenForo_Application::handleException()
 
It's enabled - getting an error in syslog showing that it can't write to tmp/xxxx. Oh well, if I remove mysql, I guess the databases cannot be used again?

And now fixed. Permissions on /tmp were changed for some reason (may need to check a cron job I have set up to extract files to there).
chown root:root /tmp
chmod 1777 /tmp
/etc/init.d/mysql restart

fixed the problem.
 
Empty the tmp/ directory and/or check the write permissions.
It was a permission problem... chmod 1777 to /tmp for root:root did it.
Only thing I can guess is something with mod-security did it as the only chmod that is performed by my script is to an exact filename in a folder created in the /tmp directory.
 
Back
Top Bottom