Jump to content

Tutorial for making a test install?


CheersnGears

Recommended Posts

If you want to set up a test site without upgrading that is relatively easy. What you should do is just make a subdomain or place to put it in. if you want to upgrade somewhere else, then go about making a clone of the current database and name it something else. make a copy of all the files needed by IPS and then put those where the subdomain root is. Once you have that edit the config file to point to the new database and then see if it works. When you go to upgrade do like you normally would and then put -TESTINSTALL at the end of your license. Not going into much detail but I hope it helps. 

Link to comment
Share on other sites

Hi Cheersn

I've done this myself and I'll explain the steps that I use but may not be correct or maybe long winded by other members but it works for me. (based on cpanel and phpmyadmin)

1) I created a sub folder, copied all the files from my original folder and placed them in the new folder (So I have an exact copy).

2) I then accessed my cPanel > PHPMyAdmin - went to my database name > selected 'Operations' and copied the database and gave it a new name (remember to make a new user in MySQL Databases and add it to the copied database).

3) I then went to my FTP and edited the 'conf_global.php' to reflect the new details.

4) Once that was working correctly and the forums loaded and tested, I then got the BETA5, downloaded and uploaded the files to my copied subfolder overwriting all the files. Once completed I ran the upgrade and followed the instructions.

5) That should be it, rather quick and simple process and I haven't experienced any errors.

**As above this may not be the best or correct way, but It's just how I've done my duplicates

*** I take no responsibility for any errors that may occur

Link to comment
Share on other sites

How I did it.

  • download copy of config.php from live site
  • login to cpanel and create a new database IPSV4b5 for example
  • Assign existing user to the database
  • create directory / subdomain for the test install (remember that this is the URL that will be used for all test installs
  • Upload the files for IPB v4
  • copy public and upload folders for live site (don't move, download locally - you could also compress these two folders and move the compressed file and then extract that by using cpanel file manager) then upload them to the directory for the test install (I personally took it offline for maintenance for 5 minutes).
  • You can do this part in one of 2 ways, take live forum offline or leave live (crude but effective) change the upload paths to the uploads paths for the test database you can also do this via phpmyadmin but I'm not 100 certain on what needs changed in the database but only do it once you have copied the database (see below)
  • login to phpmyadmin, go to existing database, and then select operations,

  • Untick create database before copying and in the field above, enter the database information and then click go to copy the database to the test install database
  • once it has copied, go to the config.php in the test install directory edit and enter the test database information (replacing the live database information).
  • then go to www.domain.com/admin/upgrade and run the upgrader, it will ask you to convert to UTF8 if you haven't already done so.
  • Follow the upgrade steps
Edited by craigf136
Link to comment
Share on other sites

Could you guys post the steps needed for doing a test upgrade of an existing site?  I'd like to make a duplicate of my existing site into my test url and run the 4.0  upgrade tool on it just to see what breaks.

Seeing this question has been brought up a few times, ​Here you go.... http://community.invisionpower.com/topic/406362-upgrade-from-ip-34x-to-ips40/

Link to comment
Share on other sites

  • 1 month later...
  • 1 year later...
On 1/15/2015 at 5:08 PM, Dean_ said:

Hi Cheersn

I've done this myself and I'll explain the steps that I use but may not be correct or maybe long winded by other members but it works for me. (based on cpanel and phpmyadmin)

1) I created a sub folder, copied all the files from my original folder and placed them in the new folder (So I have an exact copy).

2) I then accessed my cPanel > PHPMyAdmin - went to my database name > selected 'Operations' and copied the database and gave it a new name (remember to make a new user in MySQL Databases and add it to the copied database).

3) I then went to my FTP and edited the 'conf_global.php' to reflect the new details.

4) Once that was working correctly and the forums loaded and tested, I then got the BETA5, downloaded and uploaded the files to my copied subfolder overwriting all the files. Once completed I ran the upgrade and followed the instructions.

5) That should be it, rather quick and simple process and I haven't experienced any errors.

**As above this may not be the best or correct way, but It's just how I've done my duplicates

*** I take no responsibility for any errors that may occur

Thanks for this. However I followed it exactly but get the following error:

Fatal error: Call to a member function language() on null in /home/directory/SiteURL/system/Output/Output.php on line 535

Any thoughts? 

Thanks!

Link to comment
Share on other sites

  • 3 months later...
On 14/12/2016 at 5:04 PM, Dr. Dan Ardebili said:

Thanks for this. However I followed it exactly but get the following error:

Fatal error: Call to a member function language() on null in /home/directory/SiteURL/system/Output/Output.php on line 535

Any thoughts? 

Thanks!

You need to UPGRADE your install instead of trying to access the board via "main" URL. You need to go to: www.yourdomain.com/testinstall/admin/upgrade/

Change yourdomain and testinstall to whatever you use in your install.

Link to comment
Share on other sites

  • 3 years later...
20 hours ago, breatheheavy said:

I have a question... My current IPB database is 5.59 GB.

Is it still a good idea to clone my entire site with the million+ posts for a test site? 

"It depends." 🙂 TL;DR: I clone a copy of my production sites to test upgrades, and some of my databases are many magnitudes larger than yours, however I have reasons to do so in my testing plans that you may not. If you can afford it and have the technical resources to do so, it's probably a good idea.

If you're looking to only test functionality where old content is not needed, or if you're looking to do things like new template/plugin/application development, you probably can get away with the simplicity of maintaining a separate environment. This has the benefit of not being as resource intensive, yet without testing a clone of your production environment, you need to remember that your testing is limited and subject to change when the conditions do. Often, this is a good candidate for a local install that's used for development that can live in a virtual machine on your local computer. This is nice, because you can spin up multiple copies quickly to test out different things.

If your expectations for testing are that you will be aware of any and all impacting changes to your existing community, then starting with a copy of your production site is a good idea if you have the resources to support doing so. You won't know about breaking changes in the install of a plugin that isn't adhering to IPS guidelines and makes a modification to a giant table that times out, or if migrating breaks existing permissions for users, or if important samples of previously posted content will look as you expect. A good reason to have a clone of production for testing is that you can minimize surprises when making the changes in production and pre-choreograph the process for making those changes to production. You can include things like load testing, looking at the full stack that might be involved if you have things like CDNs or third-party providers for e-mail, or storage like S3. It's also a great way to test things like impact of different versions of elasticsearch or redis.

The downside can often be the cost of maintaining those environments, whether that be costs associated with server infrastructure. These costs may be in storage space, CPU allotment, limitations imposed by your hosting provider, etc.

For me, maintaining things with a cloud provider that uses virtual machines makes spinning up copies quick and easy. You can script the necessary steps you'll need (changes to e-mail settings, so your test site doesn't fire off e-mails to your users unexpectedly, changing values in conf_global.php, making adjustments to constants.php, etc.), and then all that's left is making sure the test license is applied. If things go wrong, it's a few clicks to wipe everything and start again.

Hope that helps!

Link to comment
Share on other sites

48 minutes ago, Paul E. said:

"It depends." 🙂 TL;DR: I clone a copy of my production sites to test upgrades, and some of my databases are many magnitudes larger than yours, however I have reasons to do so in my testing plans that you may not. If you can afford it and have the technical resources to do so, it's probably a good idea.

If you're looking to only test functionality where old content is not needed, or if you're looking to do things like new template/plugin/application development, you probably can get away with the simplicity of maintaining a separate environment. This has the benefit of not being as resource intensive, yet without testing a clone of your production environment, you need to remember that your testing is limited and subject to change when the conditions do. Often, this is a good candidate for a local install that's used for development that can live in a virtual machine on your local computer. This is nice, because you can spin up multiple copies quickly to test out different things.

If your expectations for testing are that you will be aware of any and all impacting changes to your existing community, then starting with a copy of your production site is a good idea if you have the resources to support doing so. You won't know about breaking changes in the install of a plugin that isn't adhering to IPS guidelines and makes a modification to a giant table that times out, or if migrating breaks existing permissions for users, or if important samples of previously posted content will look as you expect. A good reason to have a clone of production for testing is that you can minimize surprises when making the changes in production and pre-choreograph the process for making those changes to production. You can include things like load testing, looking at the full stack that might be involved if you have things like CDNs or third-party providers for e-mail, or storage like S3. It's also a great way to test things like impact of different versions of elasticsearch or redis.

The downside can often be the cost of maintaining those environments, whether that be costs associated with server infrastructure. These costs may be in storage space, CPU allotment, limitations imposed by your hosting provider, etc.

For me, maintaining things with a cloud provider that uses virtual machines makes spinning up copies quick and easy. You can script the necessary steps you'll need (changes to e-mail settings, so your test site doesn't fire off e-mails to your users unexpectedly, changing values in conf_global.php, making adjustments to constants.php, etc.), and then all that's left is making sure the test license is applied. If things go wrong, it's a few clicks to wipe everything and start again.

Hope that helps!

Huge thank you for this reply!

NGL, that sounds overwhelming. Perhaps I should make a topic on IPS requesting to hire someone to create a copy of my forum for me on my server. I'm pretty tech savvy, but a lot of this goes over my head 😩 

Thank you again. 

Link to comment
Share on other sites

14 minutes ago, breatheheavy said:

Huge thank you for this reply!

NGL, that sounds overwhelming. Perhaps I should make a topic on IPS requesting to hire someone to create a copy of my forum for me on my server. I'm pretty tech savvy, but a lot of this goes over my head 😩 

Thank you again. 

No worries! Happy to help. It doesn't need to be complicated, and the good thing is you can start small and learn and modify your testing plans as your knowledge base grows.

Here's the information you need to install IPS. It's the same process regardless of whether or not it's on a server in a data center, or on your local desktop:

Just pay special attention to what you need to do with your license to mark a test install if you're exposing it to the internet.

Here's the information you need to setup a development install from IPS:

This is what you need to do to develop plugins/applications/theme hooks/etc. that can be created here and then downloaded and transferred to your production site (or you can sell them on the IPS marketplace).

A good place to start Googling is learning how to create (L)AMP environment on whatever type of operating system you have on your computer. The instructions are a little different depending on whether or not you have Windows, MacOS, Linux, or something else. Look into virtualization options as well for your OS. Things like virtualbox.org work universally, and most modern versions of operating systems have some native virtualization available. For Windows 10, look into the Linux subsystem: https://docs.microsoft.com/en-us/windows/wsl/

You'll probably want something similar to whatever you have on your production server for simplicity sake. For example, choose the same web server (apache, nginx, etc.), MySQL, and PHP version if you can.

Link to comment
Share on other sites

  • 2 years later...

Looks like this subject comes up every few years or so. So I'll try to make the background short.

Inherited a site that is at 4.4.5.2 trying to update to 4.7.2.1. Host is on PHP 7.4FASTCGI need to move up to 8.X. Automated update from admincp failed due to PHP Version... moved up PHP version to 8x ... site is just blank white page so put PHP back to 7x. Suggestions from folks here is to build a test system and try manual upgrade on it.

(1) Created a sub domain - test.xxxx.com (where xxxx.com is my actual domain)

(2) Copied all files from xxxx.com to test.xxxx.com

(3) Created a new db host->mysql.test.xxxx.com ... database->xxxxtest ... sql_user -> xxxxtestadmin

(4) Uploaded a copy of the original xxxx DB into xxxxtest DB

(5) Changed home/xxxxtest/test.xxxx.com/forums/conf_global.php to match all the appropriate settings.

(6) Changed home/xxxtest/test.xxxx.com/index.html all references to www.xxxx.com to www.test.xxxx.com AND redirection_index.php from xxxx.com to test.xxxx.com

(7) Set php version to 7x

(8) And when I hit the URL test.xxxx.com... I'm in an infinite loop of redirection (see attached image).

(9) I can hit the URL https://test.xxxx.com/phpinfo.php and that comes back ok

Any suggestions would be helpful. Thank you!

 

Could contain: Page, Text, Number, Symbol, Chart, Plot, White Board

Link to comment
Share on other sites

You should not have or need an index.html nor a redirection_index.php.  You should only have index.php with the standard IPS source code.  Your server should have the ability to just serve the IPS index.php without you creating these random redirects.  (If they don't just have them set the directory index to index.php or set the following in your .htaccess "DirectoryIndex index.php".)

Link to comment
Share on other sites

14 hours ago, Randy Calvert said:

You should not have or need an index.html nor a redirection_index.php.  You should only have index.php with the standard IPS source code.  Your server should have the ability to just serve the IPS index.php without you creating these random redirects.  (If they don't just have them set the directory index to index.php or set the following in your .htaccess "DirectoryIndex index.php".)

I didn't create the redirect's... they were just "there" from previous installations and copied over from the primary site. I'm a windows guy so I'll do some more reading on .htaccess and how it works.  For me Unix = "black arts" 🙂 Thanks!

Link to comment
Share on other sites

3 hours ago, Daniel F said:

Make sure to delete all the content from the datastore directory and please also verify that the htaccess file is correct if there’s one! 

I don't know what "the datastore" is. Can you give me a little more information. One of the goals is to keep the data in the database for historical purposes... so I'm hoping you don't mean I need a "fresh" database.

2 minutes ago, Martin A. said:

Also looks like you're using a mix of www.test.domain.com and test.domain.com. All those redirects are between those two URLs. Stick to one of them.

Thanks!... I'm learning as I go. I'm an embedded software engineer, web stuff is all pretty new to me.

I'll try and figure that out.

 

Link to comment
Share on other sites

2 minutes ago, galenb said:

I don't know what "the datastore" is. Can you give me a little more information. One of the goals is to keep the data in the database for historical purposes... so I'm hoping you don't mean I need a "fresh" database.

He means the /home/xxxxtest/test.xxxx.com/forums/datastore folder. This holds cached data which can mess things up. Emptying this does not cause permanent data loss.

Link to comment
Share on other sites

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...