 | |  | | | ReviewPost How do I...? Wondering how to do something in ReviewPost? |
December 28th, 2010, 08:22 AM
|
#1 (permalink)
| | Member Verified Customer
Join Date: Dec 2010
Posts: 44
| Moving data to different database name ?
I setup reviewpost on a local test copy of vB 3.8.6 PL1 - reviewpost installed and integrated into vB database. Test copy is so that I can populate all the fields, customisations and tweaks first. After that is all done, I plan to transfer this customised reviewpost database to the live vB 3.8.x forum database.
Is it just a case of backing up reviewpost related database tables into sql file, and then reimporting them into live vB 3.8.x forum database ? Then edit paths in admin settings to reflect livevb's settings ?
i.e.
local test database name = localvb
live database name = livevb
so backup localvb database Quote: |
mysqldump localvb rp_admingroups rp_admlog rp_board rp_buddies rp_cache rp_captcha rp_categories rp_extrafields rp_favorites rp_invites rp_ipcache rp_iponline rp_languages rp_laston rp_messages rp_notify rp_paid_subscriptions rp_payments rp_phrases rp_productextras rp_products rp_reviewextras rp_reviewfields rp_reviews rp_reviewtypes rp_searchids rp_settings rp_sort rp_subscriptions rp_usergroups rp_users > reviewpost_backup.sql
| import backup into livevb database Quote: |
mysql livevb < reviewpost_backup.sql
|
Last edited by p4guru; December 28th, 2010 at 08:29 AM.
|
| |
December 28th, 2010, 08:29 AM
|
#2 (permalink)
| | Photopost Developer Verified Customer
Join Date: Jun 2002 Location: Abingdon,MD
Posts: 71,698
|
Yes that would work although you also need to move the reviewpost files and edit the config files also with proper info and paths.
Usually best to move the database and files and run a reinstall using the install script into the same tables you must imported so that all settings get set correctly to the real forum.
|
| |
December 28th, 2010, 08:30 AM
|
#3 (permalink)
| | Member Verified Customer
Join Date: Dec 2010
Posts: 44
|
Ah forgot about the files, so just copy all /reviewpost directory files to live site.
Thanks Chuck
|
| |
December 28th, 2010, 09:51 AM
|
#4 (permalink)
| | Photopost Developer Verified Customer
Join Date: Jun 2002 Location: Abingdon,MD
Posts: 71,698
|
yes the program is both the reviewpost directory and the database.
|
| |
December 29th, 2010, 02:47 AM
|
#5 (permalink)
| | Member Verified Customer
Join Date: Dec 2010
Posts: 44
|
One more question, with above mysqldump and import of database tables for reviewpost and moving /reviewpost directory over, would the user table automatically link correctly to the livevb database ?
On localvb test database, there's only 1 user account (admin)
On livevb database, there's 4,000+ user accounts with only 1 admin account (same username as on localvb test user admin account. edit: Okay decided to try a dummy livedbtest on local server. Backed up localdb and /reviewpost directory and imported into livedbtest database. problem:
But having trouble with updating livedbtest database with updated forum/reviewpost paths ?
When i edit config-inc.php and config-intr.php to updated database name from localvb to livedbtest and update forum paths, when i check in adm-index.php on livedbtest site, the edit config and integration values don't reflect what i changed in config-inc.php and config-intr.php on the new install ? I made sure to chmod 666 both files on the new path.
It seems /reviewpost/adm-misc.php?admact=editcfg is stuck with old settings and when i change them and hit save, it just reverts back to the old settings for localvb and not new new livedbtest paths/database name ? update: figured out the problem, the adm-index.php was directing to old paths so when i edited it, was editing old db and not new one so need to Quote:
Edit Global options from manual typed path to new location /newpath/reviewpost/adm-misc.php?admact=options&ppaction=options
Edit Config from manual typed path to new location /newpath/reviewpost/adm-misc.php?admact=editcfg
Edit Integration from manual typed path to new location /newpath/reviewpost/adm-misc.php?admact=editint
|
Last edited by p4guru; December 29th, 2010 at 07:46 AM.
|
| |
December 29th, 2010, 07:40 AM
|
#6 (permalink)
| | Photopost Developer Verified Customer
Join Date: Jun 2002 Location: Abingdon,MD
Posts: 71,698
|
As I suggested you need to physically change the paths in the database settings table for reviewpost or rerun the install script. The install script is after all the script which sets all that stuff. |
| |
December 29th, 2010, 08:05 AM
|
#7 (permalink)
| | Member Verified Customer
Join Date: Dec 2010
Posts: 44
|
Thanks. Just thought of my first suggestion for reviewpost. You have install.php and upgrade.php scripts. Why not have one standalone script called transfer.php which you can manually specify the new databasename and when loaded it will pull up the existing paths (old paths) with a field to change that path for each location that needs changing - domainpath/data paths etc ?
Would make transfers alot easier
1. mysqldump reviewpost tables reviewpost.sql
2. backup /reviewpost directory
3. backup destination database
4. import reviewpost.sql backup into destination database
5. copy /reviewpost directory to destination site
6. edit config.inc.php and config.intr.php to new paths and destination database
7. edit transfer.php to destination database, run transfer.php to update rest of the paths
Would help for those test installing on a local staging server before going live |
| |
December 29th, 2010, 08:49 AM
|
#8 (permalink)
| | Photopost Developer Verified Customer
Join Date: Jun 2002 Location: Abingdon,MD
Posts: 71,698
|
No need for a transfer.php file since install.php is the file that is created to install our application. You do the steps outlined as you have it just last step is install.php as that is the script that sets all the stuff you are referring to.
|
| |
December 29th, 2010, 09:44 AM
|
#9 (permalink)
| | Member Verified Customer
Join Date: Dec 2010
Posts: 44
|
Oh i think I get what you're saying, will give a it a test run on local server to see how it goes
Thanks
|
| |
December 29th, 2010, 10:21 PM
|
#10 (permalink)
| | Photopost Developer Verified Customer
Join Date: Jun 2002 Location: Abingdon,MD
Posts: 71,698
|
Yep should turn out fine.
|
| |
December 30th, 2010, 05:32 AM
|
#11 (permalink)
| | Member Verified Customer
Join Date: Dec 2010
Posts: 44
|
Just so i got this right i'd only have to run step 1, 4 and 5 for install.php to set the correct paths ?
step 1
/reviewpost/install.php?step=config
step 4
/reviewpost/install.php?step=3®type=external
step 5
/reviewpost/install.php
no need to reinstall language strings step ?
/reviewpost/phrases.php
edit: okay tried step 1, 4, 5 and ends up with blank page reviewpost install after import so guess that didn't work ?
So the 100% working method for me right now is
1. mysqldump reviewpost tables reviewpost.sql
2. backup /reviewpost directory
3. backup destination database
4. import reviewpost.sql backup into destination database
5. copy /reviewpost directory to destination site
6. edit config.inc.php and config.intr.php to new paths and destination database
7. Update paths via sql queries
custom queries where /386pl1live is new path and /386pl1 is old path Quote:
UPDATE `vb386pl1live`.`rp_settings` SET `setting` = 'http://192.168.56.101/vbulletin/386pl1live/reviewpost/data' WHERE `setting` ='http://192.168.56.101/vbulletin/386pl1/reviewpost/data';
UPDATE `vb386pl1live`.`rp_settings` SET `setting` = '/var/www/html/vbulletin/386pl1live/reviewpost/data/' WHERE `setting` ='/var/www/html/vbulletin/386pl1/reviewpost/data/';
UPDATE `vb386pl1live`.`rp_settings` SET `setting` = 'http://192.168.56.101/vbulletin/386pl1live' WHERE `setting` ='http://192.168.56.101/vbulletin/386pl1';
UPDATE `vb386pl1live`.`rp_settings` SET `setting` = 'http://192.168.56.101/vbulletin/386pl1live/reviewpost' WHERE `setting` ='http://192.168.56.101/vbulletin/386pl1/reviewpost';
UPDATE `vb386pl1live`.`rp_settings` SET `setting` = 'http://192.168.56.101/vbulletin/386pl1live/reviewpost/images' WHERE `setting` ='http://192.168.56.101/vbulletin/386pl1/reviewpost/images';
UPDATE `vb386pl1live`.`rp_settings` SET `setting` = '/var/www/html/vbulletin/386pl1live/reviewpost/uploads' WHERE `setting` ='/var/www/html/vbulletin/386pl1/reviewpost/uploads';
UPDATE `vb386pl1live`.`rp_settings` SET `setting` = 'http://192.168.56.101/vbulletin/386pl1live/reviewpost/uploads' WHERE `setting` ='http://192.168.56.101/vbulletin/386pl1/reviewpost/uploads';
UPDATE `vb386pl1live`.`rp_settings` SET `setting` = '/var/www/html/vbulletin/386pl1live/reviewpost/backup' WHERE `setting` ='/var/www/html/vbulletin/386pl1/reviewpost/backup';
|
Last edited by p4guru; December 30th, 2010 at 06:11 AM.
|
| |
December 30th, 2010, 06:20 AM
|
#12 (permalink)
| | Member Verified Customer
Join Date: Dec 2010
Posts: 44
|
One thing on 2nd test transfer, can't seem to login to the new path's installation could be cookie conflicts if
old path /386pl1
new path /386pl1live
when i log in, just redirects back to login page on new path install - seems if i login from /386pl1live path, when i hit submit, the url redirects to /386pl1 ?
does reviewpost have a datastore like cache that needs clearing even after manual sql updates for new paths ?
admin end has cookie settings page at /reviewpost/adm-misc.php?admact=options&ppaction=options§ion=13 but can't seem to find the value in rp_settings ? Update: looks like cookie prefix needs to be adjusted for both reviewpost and vBulletin config.php Quote:
update rp cookie prefix
UPDATE `vb386pl1live`.`rp_settings` SET `setting` = 'bbx' WHERE `rp_settings`.`id` =215;
|
Last edited by p4guru; December 30th, 2010 at 07:03 AM.
|
| |
December 30th, 2010, 08:08 AM
|
#13 (permalink)
| | Photopost Developer Verified Customer
Join Date: Jun 2002 Location: Abingdon,MD
Posts: 71,698
|
I think you are overthinking things here
If you move your database and directory and rerun the install script and use the proper information for your new site on the install every last thing will be reinstalled correctly on the new server integrated with the live site. Remember your installing essentially on a new server and this is how you set everything through the script.
Only way your going to have issues is if you run the install script and do not put in the proper information. We ask for cookie prefix, forum url table prefix etc all on the install. I recommend following the instructions I posted from the beginning to the letter.
Obviously you are not updating everything in a manual capacity which is why I never recommended you do that.
|
| |
December 30th, 2010, 08:32 AM
|
#14 (permalink)
| | Member Verified Customer
Join Date: Dec 2010
Posts: 44
|
Yeah not sure what happened when i tried install.php script method - set paths correctly but ended up with blank white pages throughout the install.
|
| |
December 30th, 2010, 08:42 AM
|
#15 (permalink)
| | Photopost Developer Verified Customer
Join Date: Jun 2002 Location: Abingdon,MD
Posts: 71,698
|
If you had a blank white page then the paths where not correct. Example if you run an install and integrate with vb and on the last step do not have the server path to your forum correct and turn on those vb integration switches you will have a blank page. It is one of the 5 things on the vbulletin integration faq in the FAQ forum.
|
| |
December 30th, 2010, 09:21 AM
|
#16 (permalink)
| | Member Verified Customer
Join Date: Dec 2010
Posts: 44
|
Yeah i had the forum path set fro install.php step 4 and 5. Not sure what went wrong as after install.php ran i checked phpmyadmin data for rp_settings all reflected the new paths from install.php
|
| |
December 30th, 2010, 09:27 AM
|
#17 (permalink)
| | Photopost Developer Verified Customer
Join Date: Jun 2002 Location: Abingdon,MD
Posts: 71,698
|
As stated the last step of install the server path to your forum was incorrect based on the error your saying. That path would not be in a database it is in the config-int.php file
That was your issue. if you want to try and recreate the error simply edit that file on the vbpath line put the wrong path and see what you get |
| |
December 31st, 2010, 01:38 AM
|
#18 (permalink)
| | Member Verified Customer
Join Date: Dec 2010
Posts: 44
|
Double checked the config-int.php it was correct as i never removed/changed it from 1st test data transfer run on livedb (386pl1live path) which worked fine when migrated data over.
Either way, thanks for all your help |
| |
December 31st, 2010, 10:23 AM
|
#19 (permalink)
| | Photopost Developer Verified Customer
Join Date: Jun 2002 Location: Abingdon,MD
Posts: 71,698
|
Your server path for your test forum and your live forum would never be the same right |
| |
January 1st, 2011, 08:36 AM
|
#20 (permalink)
| | Member Verified Customer
Join Date: Dec 2010
Posts: 44
|
no i mean first time i did test data transfer from test forum to live forum, i edited live forum files for the config-inc.php and config-intr.php paths to reflect the live forum and left it as is for 2nd test data transfer which ended up blank
|
| | |
Currently Active Users Viewing This Thread: 1 (0 members and 1 guests) | | | | Thread Tools | | | | Display Modes | Rate This Thread | Linear Mode | |
Posting Rules
| You may not post new threads You may not post replies You may not post attachments You may not edit your posts HTML code is Off | | | All times are GMT -5. The time now is 05:42 AM. | |