How to duplicate a live site to use as a test site

This is what I mean.

Live > test site
Not Live !< test site.
This also wouldn't work with new posts and threads. If I make a new post on the test site and then someone makes a new post on the live site, there would be a conflict with the post numbers as they would be the same on both sites.
 
  • Like
Reactions: rdn
My question would be: how do you go back? If you make changes to the test-site, what would be the best way to update the live site to match the test-site.
 
If you wanted to apply any changes you have made to your test site to your live site, then you would need to document them and reapply them.

The purpose of having a test site is to test add-ons, upgrades, styles, tweaks and changes, etc. without affecting your live site.

That then enables you to put a proper plan together for repeating it on your live site.
 
I didn't see mention of PHP opcode cachers. If you're running one of those (such as XCache) don't forget to give the test forum a unique cache prefix in the config file. Otherwise things can get sideways in a hurry.
 
Getting an error. How do I correct it?
An exception occurred: Access denied for user '**************'@'******************' (using password: YES) in /Applications/MAMP/htdocs/library/Zend/Db/Adapter/Mysqli.php on line 333
 
Created user multiple times and even copied and pasted username and password from config. Still no dice.

This is the rest of the error but I'm assuming this is all related to the username issue?

  1. Zend_Db_Adapter_Mysqli->_connect() in Zend/Db/Adapter/Abstract.php at line 315
  2. Zend_Db_Adapter_Abstract->getConnection() in XenForo/Application.php at line 684
  3. XenForo_Application->loadDb()
  4. call_user_func_array() in XenForo/Application.php at line 921
  5. XenForo_Application->lazyLoad() in XenForo/Application.php at line 952
  6. XenForo_Application::get() in XenForo/Application.php at line 1336
  7. XenForo_Application::getDb() in XenForo/Error.php at line 52
  8. XenForo_Error::unexpectedException() in XenForo/Application.php at line 363
  9. XenForo_Application::handleException()
 
Deleted the database and now getting a new error when trying to import db.

CREATE TABLE `dark_postrating` (
`id` int( 10 ) unsigned NOT NULL AUTO_INCREMENT ,
`post_id` int( 10 ) unsigned NOT NULL ,
`user_id` int( 10 ) unsigned NOT NULL ,
`rated_user_id` int( 10 ) unsigned DEFAULT NULL ,
`rating` int( 10 ) unsigned NOT NULL ,
`date` int( 10 ) unsigned NOT NULL ,
PRIMARY KEY ( `id` ) ,
UNIQUE KEY `post_id_user_id` ( `post_id` , `user_id` ) ,
KEY `post_id_rating` ( `post_id` , `rating` ) ,
KEY `user_id_rating` ( `user_id` , `rating` ) ,
KEY `rated_user_id_rating` ( `rated_user_id` , `rating` ) ,
KEY `date` ( `date` )
) ENGINE = InnoDB DEFAULT CHARSET = utf8 AUTO_INCREMENT =3348;

MySQL said:

#1050 - Table '`******`.`dark_postrating`' already exists
 
Last edited:
Looking at the config.php for local testing shouldn't the following be changed since it's local?

$config['db']['host'] = 'mysql.****.com';
$config['db']['port'] = '3306';
 
Back
Top Bottom