Site Links
Home
Features
Documentation
Pricing & Order
Members Area
Support Options
UBBDev.com
UBBWiki.com
Who's Online
2 registered (id242, Gizmo), 34 Guests and 14 Spiders online.
Key: Admin, Global Mod, Mod
Featured Member
Registered: 12/24/05
Posts: 122
Top Posters (30 Days)
Ruben 48
DennyP 24
Gizmo 23
Dunny 17
SteveS 14
AllenAyres 12
dbremer 10
drkknght00 9
SD 9
driv 8
Latest Photos
OK Corral Shoot Out
Testing
Basildon Train Station
Basildon Town Centre looking from the rounderbout
Basildon Town Square
Page 1 of 5 1 2 3 4 5 >
Topic Options
#178189 - 02/10/07 10:30 PM Gizmo's UBB.Threads 7.x Transfer Guide for Dummies (or not)
Gizmo Online   cat

Registered: 06/05/06
Posts: 14994
Loc: Portland, OR; USA
1. Backup your current files, this is simple with the "tar" command in Linux/Unix/BSD as:
 Code:
tar -cvpzf my_ubb_backup.tgz /path/to/threads


Additionally, if you're on a "windows" machine you can zip the directory or use any other archival tools available on the machine; if you don't have any you *could* download them file by file via FTP but it will take quite a while.

2. Now you'll want to backup your database, you can do this from free tools like PHPMyAdmin, however I recommend doing so through the command line (in Linux/Unix/BSD) as:
 Code:
mysqldump -uusername -ppassword my_database_name > my_database_name.sql


(Note that you can optionally use the -hhostname and -Pport trigger should you be communicating with a non-local SQL server; please note that most servers do not allow non-local access.)

You can also tar the output by:
 Code:
tar -cvpzf my_ubb_database.tgz my_database_name.sql


Alternatively, if you're on another OS or cannot use Linux command line tools, you can use web utilities like PHPMyAdmin to download an archive of your sql data. Please note that on large forums this is not recommended, and it is always recommended to use the "compression" options within PHPMyAdmin itself (tar/globalzip are recommended).

The Linux/Command Line versions will take MUCH less time to import/export, as you're not going through a php script which uses the web server; you're accessing the SQL server directly.

3. Now you'll want to transfer your backups to your new server. You'd do this either by downloading the database and forum backups to your hard disk, and uploading them to the new server -OR- you can place them both in a web-accessible directory on your old server, and use the "wget" command in Linux/Unix/BSD to download them, ex:
 Code:
wget http://www.yousite.tld/files/my_ubb_database.tgz
wget http://www.yoursite.tld/files/my_ubb_backup.tgz


From here you'll need to decide how you'll put the old files on the new server. If the new server is a Linux machine and you can access it via SSH and have access to "tar" and mysql command line this is a simple process. If your new server is windows based you'll want to be sure it has compression tools if you wish to place a compressed archive (that you likely created in steps 1 and 2) on it.

You'll want to decompress the files on the new server; in Linux/Unix/BSD with tar you'd do:
 Code:
tar -xzvf my_ubb_backup.tgz
tar -xzvf my_ubb_database.tgz


Once tar has extracted the files, you'll want to change to the appropriate directories within the extracted files, and use the "mv" command to move the forum files to their proper new location, EX:
cd the/directories/that/where/created/when/you/made/your/backup/ (by not using a starting slash you tell the command to go from where you are now vs the physical path ont he server)
mv forum /the/new/location/of/your/forum

4. Now that the old files are on the new server, you need to import your database; you can again use PHPMyAdmin or use the command line to import the database. The command line way of doing this (note, this is not the MySQL command line, simply the Linux command line) would be:
 Code:
mysql -h localhost -uuser -ppass database_name < databasebackupfile.sql


(Note that you can optionally use the -hhostname and -Pport trigger should you be communicating with a non-local SQL server; please note that most servers do not allow non-local access.)

The Linux/Command Line versions will take MUCH less time to import/export, as you're not going through a php script which uses the web server; you're accessing the SQL server directly.

Now that the database and files are now on the new server, you need to update your permissions of files and directories, they may or may not have been carried over via your backup (if you used tar), so you'll want to make sure that your files are chmodded 666 and your directories 777.

After checking your permissions, you'll want to update your includes/config.inc.php file, updating the paths (and urls if they're different) for the new server. At the time I'm writing this article, these lines are:
 Code:
  'FULL_URL' => '',
  'BASE_URL' => '',
  'FULL_PATH' => '',
  'SESSION_PATH' => '',
  'REFERERS' => '',
  'ATTACHMENTS_PATH' => '',
  'ATTACHMENTS_URL' => '',


You'll also want to update the MySQL connect information in your includes/config.inc.php file:
 Code:
  'DATABASE_SERVER' => 'localhost',
  'DATABASE_USER' => 'username',
  'DATABASE_PASSWORD' => 'password',
  'DATABASE_NAME' => 'databasename',
  'TABLE_PREFIX' => 'table_prefix',
  'HOMEPAGE_URL' => 'http://www.example.com',


5. From here, you should be completely moved over, it may sound quite difficult at first, but it's really not. Time can vary based on the size of your database, and some sites will be larger than others.

Additionally, if you don't feel comfortable about preforming the move yourself, you can always hire a developer *ahem*orme*ahem* to preform the migration for you.
_________________________
Forums: UGN Security & VNC Web Design & Development
UBB.Threads: UBB.Wiki, My UBBSkins, UBB.Sitemaps
Longtime UBB Supporter, UBB Beta Tester & Resident Post-A-Holic.
UBB Modifications, Styling, Coding Services, Disaster Recovery, and more!
Top
Express Hosting
Express Hosting "We are the official hosting company of UBB.threads. Ask us about our free migration services to migrate your UBB.threads installation."
#178205 - 02/11/07 07:01 AM Re: Gizmo's UBB.Threads 7.x Transfer Guide for Dummies (or not) [Re: Gizmo]
Mark S Offline
Carpal Tunnel
Registered: 07/04/06
Posts: 4447
Loc: Liverpool : England : UK
Very handy Gizmo \:\)

If only for the comand lines at the very least.
I'm going to be doing a sort of transfer when we have 7.1 Final
so i can give it a blast.
_________________________
Version v7.5.6 smile smile < Threads satisfaction status
People who inspire me Rick Gizmo Ian David jgeoff ntdoc
Oooo i hear 8 is coming? just after 7 my friend.
Top
#178225 - 02/11/07 05:00 PM Re: Gizmo's UBB.Threads 7.x Transfer Guide for Dummies (or not) [Re: Mark S]
Gizmo Online   cat

Registered: 06/05/06
Posts: 14994
Loc: Portland, OR; USA
hehe, i need to write an upgrade guide for within 7.x ;\)
_________________________
Forums: UGN Security & VNC Web Design & Development
UBB.Threads: UBB.Wiki, My UBBSkins, UBB.Sitemaps
Longtime UBB Supporter, UBB Beta Tester & Resident Post-A-Holic.
UBB Modifications, Styling, Coding Services, Disaster Recovery, and more!
Top
#178650 - 02/17/07 06:33 PM Re: Gizmo's UBB.Threads 7.x Transfer Guide for Dummies (or not) [Re: Gizmo]
Conrad Offline
addict
Registered: 08/04/04
Posts: 425
Good work, Gizmo. \:\)

Regarding "tar" and file/directory permissions, does anyone know for sure whether they carry over or not?
Top
#178654 - 02/17/07 07:33 PM Re: Gizmo's UBB.Threads 7.x Transfer Guide for Dummies (or not) [Re: Conrad]
Gizmo Online   cat

Registered: 06/05/06
Posts: 14994
Loc: Portland, OR; USA
they should with the -p flag
_________________________
Forums: UGN Security & VNC Web Design & Development
UBB.Threads: UBB.Wiki, My UBBSkins, UBB.Sitemaps
Longtime UBB Supporter, UBB Beta Tester & Resident Post-A-Holic.
UBB Modifications, Styling, Coding Services, Disaster Recovery, and more!
Top
#178707 - 02/18/07 06:20 PM Re: Gizmo's UBB.Threads 7.x Transfer Guide for Dummies (or not) [Re: Gizmo]
Conrad Offline
addict
Registered: 08/04/04
Posts: 425
I can move a tar file manually to the new server by downloading it to my desktop first, right? And I take it that I would use binary for this, which seems to be the way to move zip files as well?

If I was to do it using the "wget" command then how do I then transfer & unpack it in the right directory, namely the "/public_html/" one?

And how would I be able to "wget" the database dump into a directory that is not the www one, say one level above the web root?
Top
#178710 - 02/18/07 07:18 PM Re: Gizmo's UBB.Threads 7.x Transfer Guide for Dummies (or not) [Re: Conrad]
Gizmo Online   cat

Registered: 06/05/06
Posts: 14994
Loc: Portland, OR; USA
1. You CAN.
2. You'd untar it, then cd to the directory of files you wish to move, then:
mv old_public_html/* /path/to/new_public_html

And WGet is a linux command, you can run it from any directory that you have permissions to run it from; but on the site you're grabbing it from, it has to be in the webroot to use wget to grab it.
_________________________
Forums: UGN Security & VNC Web Design & Development
UBB.Threads: UBB.Wiki, My UBBSkins, UBB.Sitemaps
Longtime UBB Supporter, UBB Beta Tester & Resident Post-A-Holic.
UBB Modifications, Styling, Coding Services, Disaster Recovery, and more!
Top
#178725 - 02/19/07 11:22 AM Re: Gizmo's UBB.Threads 7.x Transfer Guide for Dummies (or not) [Re: Gizmo]
Conrad Offline
addict
Registered: 08/04/04
Posts: 425
The directory I'm currently in when I type in "tar -cvpzf my_ubb_backup.tgz /path/to/threads" is where the zipped file will be placed?

OR is there a command that I can add to that line that will point to the directory where I want the zipped file to be saved?
Top
#178737 - 02/19/07 03:06 PM Re: Gizmo's UBB.Threads 7.x Transfer Guide for Dummies (or not) [Re: Conrad]
Ian Offline
Registered: 06/05/06
Posts: 4337
Loc: Essex, UK
just put the full path to the chosen directory before the my_ubb_backup.tgz - so /full/path/to/my_ubb_backup.tgz
Top
#178743 - 02/19/07 04:44 PM Re: Gizmo's UBB.Threads 7.x Transfer Guide for Dummies (or not) [Re: Ian]
Gizmo Online   cat

Registered: 06/05/06
Posts: 14994
Loc: Portland, OR; USA
If you do ian's route you can specify the directory, if no directory is defined the file will be created wherever you execute the command (assuming you have write access to that directory)
_________________________
Forums: UGN Security & VNC Web Design & Development
UBB.Threads: UBB.Wiki, My UBBSkins, UBB.Sitemaps
Longtime UBB Supporter, UBB Beta Tester & Resident Post-A-Holic.
UBB Modifications, Styling, Coding Services, Disaster Recovery, and more!
Top
Page 1 of 5 1 2 3 4 5 >



Moderator:  AllenAyres, Harold, Ian, Ron M 
Shout Box

Today's Birthdays
No Birthdays
Recent Topics
Ability to "like" individual posts (not Facebook "likes)
by doug
05/23/12 09:03 AM
Island Permissions
by ThreadsUser
05/22/12 03:03 PM
streaming video
by prkrgrp
05/20/12 07:02 PM
New Posts Corrupted? Can someone help?
by PianoWorld
05/19/12 09:41 AM
Custom forum permissions
by ntdoc
05/18/12 02:07 PM
Forum Stats
10489 Members
36 Forums
33841 Topics
181698 Posts

Max Online: 978 @ 06/24/07 11:19 PM
Random Image