MyBB Community Forums

Full Version: Screwed up the config.php
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Pages: 1 2
Hello, my community has forums that I've spent a lot of time working on. 

And very recently our developer who installed them decided to resign. Due to this, we had to take away his super-administration privileges as well as add me and the owner to it (Since this wasn't set originally).
ANYHOW. In the process of doing this, (as I was rushing to get it done, I simply went to the config.php file located in forums/inc and attempted to edit it directly) I was working on another page at the moment which also happened to have a config.php, and me being completely stupid, didn't realize I overwrote the original MyBB config.php with an entirely different one. 

So now I'm stuck with this error: 

The installer is currently locked, please remove 'lock' from the install directory to continue.

And all my settings in the config.php have been set back to default since I copy & pasted the sample config posted on MyBB to at least get the config template there. Pretty much, I just can't figure out what to replace what with what. 
Any and all help would be appreciated for this stupid mistake!

[Image: unknown.png]
There is a file in /install called 'lock' - delete it, you'll be good to go.

EDIT: no wait, are you trying to reinstall?
No, I'm pretty much just trying to reconfigure only the config.php

In order to avoid having to start from scratch, unless there's a simple way of backing up all my plugins/templates/stylesheets/posts/etc.

I've deleted the lock file (don't know why I didn't think about actually bothering to listen to the error message.) 

And now I get this: [Image: unknown.png]

Would upgrading to mybb 1.8.12 (even though I already have it installed) be guaranteed to keep everything?

After backing up everything just incase it gets even worst, I decided to hit the upgrade button.

However now I get brought to this page:

[Image: unknown.png]
can you check latest entries of server error log (available at web host control panel) to trace cause of error 500 ..
I found this located in error_log in the forums/install folder. 
[01-Sep-2017 09:51:11 UTC] PHP Fatal error:  Uncaught Error: Call to undefined function mysql_connect() in /home/definiti/public_html/forums/inc/db_mysql.php:214
Stack trace:
#0 /home/definiti/public_html/forums/install/upgrade.php(84): DB_MySQL->connect(Array)
#1 {main}
  thrown in /home/definiti/public_html/forums/inc/db_mysql.php on line 214

Other than that, I'm not sure where to find the server error logs in Cpanel.
in the config.php file can you change database type from mysql to mysqli & check if upgrading works ..

as a precaution, take a backup of your database before proceeding to upgrade
That seemed to cure that problem, however now it wants me to select my previous version. 

As I'm pretty sure my previous version was the latest one, would I just select 1.8.11?

[Image: unknown.png]
see this post to get your MyBB version. see also common sql queries guidance
As I figured, the version number says 1.8.12.

However, since I'm only "upgrading" I can only choose 1.8.11 and below.
^ okay, you can select MyBB 1.8.11 and run upgrade process
Pages: 1 2