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

Changing Servers

Charlie J

Active member
#1
Hello,
i have just changed my whole xenforo to another server and have downloaded the mysql file, how can i get xenforo to use the .sql file i downloaded from phpmyadmin
 

kaieivindm

Active member
#2
Asume you have created a new database at your new hosting company, and then imported your sql file.

You can ftp into your host, change /library/config.php and enter the new information there.

<?php

$config['db']['host'] = 'sql_server';
$config['db']['port'] = 'port_nr';
$config['db']['username'] = 'username';
$config['db']['password'] = 'password';
$config['db']['dbname'] = 'databasename';


$config['superAdmins'] = '1';

With that the forum should read your database information again.
 

Charlie J

Active member
#3
i used to have a DB on hostgator however i want to eliminate that and just stick to my dedicated server, i downloaded my .sql file from PHPMyAdmin and would like to be able to somehow still use this data but on my dedicated server.
 

Brogan

XenForo moderator
Staff member
#4
You need to export and import the database.

I recommend doing it via shell, rather than phpMyAdmin.
 

Charlie J

Active member
#5
Your not getting me... :/
i have a dedicated server from SoYouStart, they just give me 32gb ram and storage and its Linux CENTOS thats it..
 

Brogan

XenForo moderator
Staff member
#6
If your server is self managed then presumably you know how to create the database, etc.

If not, you should consider employing the services of a sysadmin.
 

Charlie J

Active member
#9
yeah thnks but its all through linux i made the file then imported it but idk how i can set the user of it etc i still get this DB error
 

Tracy Perry

Well-known member
#10
With MySQL you will have to create the DB (as root typically) then create a user and assign said user a password. Then you will assign that DB to the user you just created with all privileges.
You will then need to import the SQL file (and hope it's not corrupted) that you exported from phpMyAdmin into the new DB you created (either as the user or as root).
If you aren't familiar with doing this, then I would suggest an unmanaged dedicated server might not be the best option to go live with at this time unless you have some additional help that is familiar with those processes.
 

WSWD

Well-known member
#11
yeah thnks but its all through linux i made the file then imported it but idk how i can set the user of it etc i still get this DB error
Honestly, it sounds like you should have stayed with a host, or got cPanel on your new server. No way should you be using an unmanaged dedicated server if you don't know how to do these sorts of tasks.
 

Charlie J

Active member
#12
Ah alright ill try thanks, also how can i get it to automatically place a thread prefix in a certain forum, because i have something for my MC server called Staff Applications and i would like that when they post it places that automatically as currently im manually doing it
 

Charlie J

Active member
#19
Oh wow, well if you could help if not would help ALOT,
i moved my xenforo from HostGator to my dedicated server i use for my mc server on SYS
However since i moved everything is fine except
The following error occurred:
Not Found
The requested URL /login/ was not found on this server.

Apache/2.2.15 (CentOS) Server Port 80