cannot connect to website after changing hosts

Status
Not open for further replies.

mbrowne12589

New Member
Messages
10
Reaction score
0
Points
0
i changed hosts by adding x10hosting nameservers to my website at cheapnames.com.....at first it seemed ok as after i went to the site it asked me to enter new info. but when i entered mysql database it said i had no access to this database.....then when i tried to go to the site it said:
Connection Problems

Sorry, SMF was unable to connect to the database. This may be caused by the server being busy. Please try again later

is this because i have not waited the 24-48 hours it might take to change hosts? or something else?
 

Skizzerz

Contributors
Staff member
Contributors
Messages
2,928
Reaction score
118
Points
63
Hello,

Please post the contents of SMF's Settings.php file, removing all database passwords and other passwords first
 

mbrowne12589

New Member
Messages
10
Reaction score
0
Points
0
Hello,

Please post the contents of SMF's Settings.php file, removing all database passwords and other passwords first


First of all, thank you Mr. Skizzerz for helping me. I can't get into my smf files because now it is telling me my username does not exist! i will try to figure it out and post that Settings.php info. ASAP. Once again, thanks so much for the help.

---------- Post added at 08:22 AM ---------- Previous post was at 08:04 AM ----------

hi, i do not know if this is what you need....i could not get into my SMF forum to get the Settings.php info. but i got the Settings.php info. from the x10hosting site...i don't know if the info is the same but here it is from the x10hosting cpanel page:

<?php

/**

* Simple Machines Forum (SMF)

*

* @package SMF

* @author Simple Machines
http://www.simplemachines.org

* @copyright 2011 Simple Machines

* @license
http://www.simplemachines.org/about/smf/license.php BSD

*

* @version 2.0

*/

########## Maintenance ##########

# Note: If $maintenance is set to 2, the forum will be unusable! Change it to 0 to fix it.

$maintenance = 0; # Set to 1 to enable Maintenance Mode, 2 to make the forum untouchable. (you'll have to make it 0 again manually!)

$mtitle = 'Maintenance Mode'; # Title for the Maintenance Mode message.

$mmessage = 'Okay faithful users...we\'re attempting to restore an older backup of the database...news will be posted once we\'re back!'; # Description of why the forum is in maintenance mode.

########## Forum Info ##########

$mbname = 'My Community'; # The name of your forum.

$language = 'english'; # The default language file set for the forum.

$boardurl = '
http://127.0.0.1/smf'; # URL to your forum's folder. (without the trailing /!)

$webmaster_email = 'noreply@myserver.com'; # Email address to send emails from. (like noreply@yourdomain.com.)

$cookiename = 'SMFCookie150'; # Name of the cookie to set for authentication.

########## Database Info ##########

$db_type = 'mysql';

$db_server = 'localhost';

$db_name = 'smf_smfforum';

$db_user = '
xxxxxx';

$db_passwd = '
xxxxxxx';

$ssi_db_user = '';

$ssi_db_passwd = '';

$db_prefix = 'smf_';

$db_persist = 0;

$db_error_send = 1;

########## Directories/Files ##########

# Note: These directories do not have to be changed unless you move things.

$boarddir = dirname(__FILE__); # The absolute path to the forum's folder. (not just '.'!)

$sourcedir = dirname(__FILE__) . '/Sources'; # Path to the Sources directory.

$cachedir = dirname(__FILE__) . '/cache'; # Path to the cache directory.

########## Error-Catching ##########

# Note: You shouldn't touch these settings.

$db_last_error = 0;

 

# Make sure the paths are correct... at least try to fix them.

if (!file_exists($boarddir) && file_exists(dirname(__FILE__) . '/agreement.txt'))

$boarddir = dirname(__FILE__);

if (!file_exists($sourcedir) && file_exists($boarddir . '/Sources'))

$sourcedir = $boarddir . '/Sources';

if (!file_exists($cachedir) && file_exists($boarddir . '/cache'))

$cachedir = $boarddir . '/cache';

?>

i am still trying to get into my SMF forum area. It is currently not allowing me into it as it says my username does not exist.
 

Gouri

Community Paragon
Community Support
Messages
4,565
Reaction score
245
Points
63
Are you sure all the settings are correct?

Did you tried to use the repair_settings.php ? If not try it once....

You can find the repair_settings.php on simple machines site....
 

mbrowne12589

New Member
Messages
10
Reaction score
0
Points
0
hi, i used repair_settings.php but it did not help...i checked the values closely with the host's values and they matched up....seems like it is a database problem.....would clearing out the database and creating a new one help?




Are you sure all the settings are correct?

Did you tried to use the repair_settings.php ? If not try it once....

You can find the repair_settings.php on simple machines site....
 

descalzo

Grim Squeaker
Community Support
Messages
9,373
Reaction score
326
Points
83
$db_name = 'smf_smfforum';

is not right on x10hosting. The db name is of the form cPanelUsername_foo . The same with the db user name.

cPanel --> MySQL Databases will list the full names of the databases and database users assigned to them.
 

mbrowne12589

New Member
Messages
10
Reaction score
0
Points
0
i hear what you are saying but my forum worked fine with those settings until i changed the domain name...i am sorry for misleading you but changing domain names (not hosts as i listed) was the real change i made.....i had to bring my new domain name to x10 (changing the generic one they gave me) from the place i bought it so the namesrevers had to be changed and i may be taking for granted that changing the domain name affected the site to the point where i cant get on anymore. Would going away from x10's generic domain name possibly mean i need to change the format of the db and user as you stated?
 

Skizzerz

Contributors
Staff member
Contributors
Messages
2,928
Reaction score
118
Points
63
Hello,

I am not positive that you posted the correct settings file. Please log into cPanel, open up the File Manager, browse to the SMF folder, then right-click Settings.php and hit "View"

Then copy/paste that here and wrap it inside of [php]Paste your settings file here[/php]. If done correctly, it should produce something like:
PHP:
<?php
//Settings file stuff
?>
 
Last edited:

mbrowne12589

New Member
Messages
10
Reaction score
0
Points
0
thanks, here it is.....i hope this has nothing to do with cheapnames.com (the place i bought the domain) not unlocking the site name over to x10 or something like that....it worked before i changed the domain name
<?php

/**
* Simple Machines Forum (SMF)
*
* @package SMF
* @author Simple Machines http://www.simplemachines.org
* @copyright 2011 Simple Machines
* @license http://www.simplemachines.org/about/smf/license.php BSD
*
* @version 2.0
*/

########## Maintenance ##########
# Note: If $maintenance is set to 2, the forum will be unusable! Change it to 0 to fix it.
$maintenance = '0'; # Set to 1 to enable Maintenance Mode, 2 to make the forum untouchable. (you'll have to make it 0 again manually!)
$mtitle = 'Maintenance Mode'; # Title for the Maintenance Mode message.
$mmessage = 'Okay faithful users...we\'re attempting to restore an older backup of the database...news will be posted once we\'re back!'; # Description of why the forum is in maintenance mode.

########## Forum Info ##########
$mbname = 'My Community'; # The name of your forum.
$language = 'english'; # The default language file set for the forum.
$boardurl = 'http://takemebacktososua.com'; # URL to your forum's folder. (without the trailing /!)
$webmaster_email = 'noreply@myserver.com'; # Email address to send emails from. (like noreply@yourdomain.com.)
$cookiename = 'SMFCookie11'; # Name of the cookie to set for authentication.

########## Database Info ##########
$db_type = 'mysql';
$db_server = 'localhost';
$db_name = 'smf_new';
$db_user = 'cpanelusernameremoved,security_userone';
$db_passwd = 'omgwtfthisisntreal.';
$ssi_db_user = '';
$ssi_db_passwd = '';
$db_prefix = 'smf_';
$db_persist = '0';
$db_error_send = 1;

########## Directories/Files ##########
# Note: These directories do not have to be changed unless you move things.
$boarddir = '/home/cpanelname/public_html'; # The absolute path to the forum's folder. (not just '.'!)
$sourcedir = '/home/cpanelname/public_html/Sources'; # Path to the Sources directory.
$cachedir = dirname(__FILE__) . '/cache'; # Path to the cache directory.

########## Error-Catching ##########
# Note: You shouldn't touch these settings.
$db_last_error = 0;

# Make sure the paths are correct... at least try to fix them.
if (!file_exists($boarddir) && file_exists(dirname(__FILE__) . '/agreement.txt'))
$boarddir = dirname(__FILE__);
if (!file_exists($sourcedir) && file_exists($boarddir . '/Sources'))
$sourcedir = $boarddir . '/Sources';
if (!file_exists($cachedir) && file_exists($boarddir . '/cache'))
$cachedir = $boarddir . '/cache';

?>

let me know when you have finished reviewing this so i can change all the usernames and passwords...there is very little on the site now..
i have changed the usernames and passwords a few times from the original site that worked fine when i first signed up...dont know if that makes a diffference to you or not.....
 
Last edited by a moderator:

Skizzerz

Contributors
Staff member
Contributors
Messages
2,928
Reaction score
118
Points
63
OK, your $db_name is incorrect. Go into cPanel and click on MySQL databases, once there you should see a database like yourcpanelname_smf. Change $db_name to that name you see there instead of the current value of "smf_new"
 

Livewire

Abuse Compliance Officer
Staff member
Messages
18,169
Reaction score
216
Points
63
Did some formatting tweaks (quote tag) and removed the usernames/passes for security, we don't want to run the risk of someone messing it up in the meantime and they shouldn't be needed for what skizzerz was looking at.
 
Status
Not open for further replies.
Top