What is repair_settings.php?

Started by [Unknown], October 13, 2004, 12:54:38 AM

Previous topic - Next topic


For a more up to date version of this tutorial please see the On Line Manual

This file, repair_settings.php, is a tool to be used to repair some of the more crucial settings for your forum.  Simply upload the file, and navigate your browser to:

(where www.example.com/forum is your forum's URL.)

It can change maintenance mode, database-driven sessions, your default forum language, your cookie name, the format of URLs ("index.php/topic,1.0.html" vs. "index.php?topic=1.0"), your database connection information, and very importantly your URLs and paths.

Please note that if you installed SMF earlier than version 1.0 RC1, you will probably need to use this tool to restore your forum to working condition after changing servers or domains.  For versions 1.0 RC1 and later, these changes should be automatically detected and fixed.

You may also need to use this file if you change one of the above settings, and your forum stops working properly.  While this should not happen often, it is possible, which again is why this tool is provided.

If you would like to see more or different functionality in repair_settings.php, please say so in this topic.


Download repair_settings.php


Thanks for your suggestions.
The repair_settings.pho trick, altough very useful to know, didn't work for me and I found that the problem is that I can't log in to MySQL (version 4.0.21, to answer your question) with the user I had created in phpMyAdmin for the SMF database (even though I have assigned all priviledges to it). I have no idea why this is, but I thought I'd just follow your other suggestion and clean-install SMF locally assigning as user the master "root" user whose login works.
This has solved the issue and I now have SMF locally, awesome!


I tried the link, but it doesn't work for me. It could be that I did something wrong, so could you please be more specific?


what do you mean it doesn't work?
what you have to is download that file, then upload it to your smf's root folder, for example http://yourwebsite.com/smfdir/
then run it by going to http://yourwebsite.com/smfdir/repair_settings.php
now just follow the instruction


I assume this works for current SMF releases?



Liverpool FC Forum with 14 million+ posts.



downloaded it then uploaded it to my SMF folder in file manager and nothing must be doing something wrong
dont worry got it to work thanks :)


It fixed my problems with my forum, which was started from yabb, then yabbse, and smf. And had few server changes.
Good work!


why there are all recomended settings like  "home2/blablabla" ?? i dont have those folders at my ftp... oO

i cant change my sources and smf folders urls at "edit server settings" and when im sending pms to other users of forum im getting this error:

2: mail() has been disabled for security reasons
File: /home2/pe/peacemakers/Sources/Subs-Post.php
Line: 377


Quote from: MuNieK on March 28, 2005, 03:14:59 PM
why there are all recomended settings like  "home2/blablabla" ?? i dont have those folders at my ftp... oO

Because these are the full paths, not your FTP paths.  They are different - and SMF won't work without the full (proper) paths.

Quotei cant change my sources and smf folders urls at "edit server settings" and when im sending pms to other users of forum im getting this error:

2: mail() has been disabled for security reasons
File: /home2/pe/peacemakers/Sources/Subs-Post.php
Line: 377

Well, that looks clear as day to me - it's been disabled by your host!  You'll have to use SMTP instead of sendmail, then, in Edit Features and Options.



hmm i dont have email account on my host so what should i write there in options at:
SMTP server
SMTP port
SMTP username
SMTP password


and i dont have this folder at my ftp:

everything is in main folder i mean without any additional folders. damn i dont understund this staff :S

and when im changing to smtp im getting this error massage:

2: fsockopen() has been disabled for security reasons
File: /home2/pe/peacemakers/Sources/Subs-Post.php
Line: 556

thats not all :)
the upload avatar option dont work :/ and atachments neither T_T


Oh my...

It looks to me that your host has disabled basically everything that is of any use to a web site! Without fsockopen I don't believe you can use SMTP. I cannot believe they have disabled mail - I've never heard of that being a security concern - unless they are worried about the amount of mail it generates?

Basically, without neither or those I think it's impossible for your site to send email. Note this would be the same with any other PHP script - they have basically closed off possible avenues for getting mail out. I would ask them why they have disabled them both if I were you. Maybe someone here has a clever way around this, but I cannot see how myself.


EDIT: Would I be right in assuming this is a free host? I can't imagine a real host would disable mail functionality!
I'm only a half geek really...


please tell me some other free host for forum about my guild. Im tired of searching for them and filling up some blanks etc. :S im lost. If u can give me plz some links for free , good hosts. :(


Although they are post2host its one of the best.

www.astahost.com and www.trap17.com

The same admin runs them, dont spam, they deal with that. Trap17 is general chat and Astahost is computer centered talk, there actually pretty good and ive been with them for around a year.


its hard to get free host there if i understund what they wrote there... i need to "contribute"? sorry my english isnt the best and i dont know what shuold i do? Do u know some free hosters without any funny things like that? I just want to fill data and get host...


Regarding free SMF hosting, did you see this post from the other day?
- Eric


I hope this is right thread to put this.  I just moved my site from one server to another.  I followed the steps in the moving server thread (downloaded, uploaded through myphp, used the repair settings and chose all the suggestions).   The index page looks fine, everything is there; topics, last posts, latest members, etc.  However, there are two problems. 1)  it no longer sees me as administer...it's not accepting my password...I get a database error, try again later.   2) almost no matter what I click on (topics, categories, etc.)  I get an error of   Unknown column 'b.override_theme' in 'field list' 
the only things that work are if I click on stats or View 10 Most Recent Posts...and those posts do show up (unless I clink on the link to the actual post).

I'm wondering if it's an upgrade problem.  The original board is 1.0 Beta and the new board is the latest 1.0.3.    Or is it some other problem.  How to fix?


Your database was NOT 1.0.3, but you're using 1.0.3 sources.  You'll need to use upgrade.php to upgrade your old database.



I was afraid of that.   I was avoiding doing that because I'm worried about losing my current data (bad experiences in the past).   On the old server I don't have myphp and since smf doesn't have a simple restore button if things go wrong...so I've not been anxious monkey with the old board.   But that server is going away in a few days and I have to get this up and running on the new server, so I guess I better take a chance.  If it's not too much trouble, could someone explain step-by-step (without myphp) how to upgrade.  I saw the steps elsewhere but they require exporting from myphp.    

edit:    Re-reading the upgrade page it says I can use the update zip as this is an old board....is it correct that I download this zip, extract it and then ftp all of these files over the existing ones?  This won't ruin any of the current posts or categories?   Then online I pull up update.php?  Am I missing any steps or is there something else I should be doing?  Thanks.