Setting Up a Test Server

Tue, 12/15/2009 - 10:22am
Submitted by brian_andle

Update - PowerSource has a nice new "How To: Guide" on how to setup a test server with links to the various resources, something I wasn't comfortable posting to the public. If you're a Technical Contact you can visit PowerSource and look up KB 59250. -Brian

Setting Up a Test Server

A test server is pretty much an invaluable tool if you plan on creating customizations or testing what if scenarios. Any customization I publish goes through 3 phases. First I create and test a customization on my test server. After that is moves to phase 2 where I release the customization on my Production Server for my staff to use. This is an important step and can also be dangerous, if you don't test enough you risk corrupting data, with that said, staff will quickly let you know something is wrong. If any issues are found I quickly retract the customization and test/fix the scenario on my test server. The last step if I can is to release the page to PDS for all our visitors.

Setting up a test server is pretty easy; a simple desktop with as little as 2gb of ram can run a test server. It won't be as fast as a production server, but it will get the job done. Below are the steps to setup a test server for the first time and how to update it in the future (Windows).

1. Download Newest PS, Oracle and Oracle Jobs (Download appropriate 32bit/64bit version)
2. Install Java 1.5
3. Install Oracle, when installing Oracle make sure to use the same passwords you did when you setup your live server as this will make it easier later.
4. Install Oracle Jobs.
5. Install PS (You can Install PS on Win 2000, 2003 and XP, if you install on XP make sure you select 2003 compatibility mode)
6. Export data from your live server; make sure to do this off-peak when there aren't users accessing the database to prevent issues when testing applications that use the PSM tables. (See Oracle Backup and Restore Guide from PowerSource on how to export from your production server)
7. Copy the data dump to your new test server.
8. Follow the Backup and Restore Guide on how to import the data and what tables to truncate.
9. Start PowerSchool (Let PS install any schema updates if needed and restart according to PS app)
10. From the PowerSchool Menu select" Web Server Properties", Click "Set Default Values" and Save.
11. From the PowerSchool Menu select "Export Web Server Configuration"
12. From the PowerSchool hidden menu select “Turn E-mail Off” (You will also need to disable any AutoComm jobs you have if you using AutoComm)
13. Log into the Test Server.
14. System->ReportWorks Admin->ReportWorks Preferences.
15. Change Scheduler node to "Localhost" and in the Scheduler Send Report remove the production server ip and change to localhost
16. System->System Settings->Server Settings and set the web server address to your test server address.
17. Restart the server and re-launch PowerSchool.
18. Congratulations you have setup a Test Server.

Now anytime you need to update PowerSchool Test Sever with new data you just need to follow the below steps.

1. Export data from your live server; make sure to do this off-peak when there aren't users accessing the database to prevent issues when testing applications that use the PSM tables. (See Oracle Backup and Restore Guide from PowerSource on how to export from your production server)
2. Copy the data dump to your new test server.
3. Stop PowerSchool and Stop the Tomcat Service.
4. Follow the Backup and Restore Guide on how to drop the current database.
5. Follow the Backup and Restore Guide on how to import the data and what tables to truncate.
6. Start PowerSchool (Let PS install any schema updates if needed and restart according to PS app)
7. From the PowerSchool hidden menu select “Turn E-mail Off” (You will also need to disable any AutoComm jobs you have if you using AutoComm)
7. System->ReportWorks Admin->ReportWorks Preferences
8. Change Scheduler node to "Localhost" and the Scheduler Send Report remove the production server ip and change to localhost
9. System->System Settings->Server Settings and set the web server address to your test server address.
10. Restart the server and re-launch PowerSchool.

Updating your PowerSchool Test Server to the newest PowerSchool.
1. Download Release Notes
2. Download new Oracle Jobs if the Release Notes say to do so.
3. Download new PowerSchool
4. Shutdown PowerSchool
5. Install new Oracle Jobs if the Release Notes say to do so.
6. Install new PowerSchool
7. Start PowerSchool
8. Done

Brian Andle

Comments

Here's what I do

Submitted by Matthew on Thu, 01/14/2010 - 11:53pm

Setting Up a Test Server
Orginally posted by Brian Andle - Updated by me - Parts taken from the install PS Install guide
1. Download Newest PS, Oracle and Oracle Jobs (Download appropriate 32bit/64bit version) on your new test server

2. Install Java 1.5 (Don't think you have to do this anymore)

3. Install Oracle on the test server, when installing Oracle make sure to use the same passwords you did when you setup your live server as this will make it easier later.

4. Install PS (You can Install PS on Win 2000, 2003 and XP, if you install on XP make sure you select 2003 compatibility mode) or copy the application from your live server, if you copy it make sure you change the IP's in the following files:

Windows & Mac:
\PowerSchoolPremier\data\config\dalx\serverconfig.props
\PowerSchoolPremier\system\Tomcat\webapps\powerschool-sdkhttpinvoke\WEB-INF\classes\powerschool-config.properties
\PowerSchoolPremier/system/Tomcat/webapps/powerschool-sys-mgmt/WEB-INF/classes\ powerschool-config.properties
NOTE: In 6.1 the Tomcat files will be moved to \Program Files\Tomcat\...

5. Export data from your live server; make sure to do this off-peak when there aren't users accessing the database to prevent issues when testing applications that use the PSM tables. (See Oracle Backup and Restore Guide from PowerSource on how to export from your production server)
Taking a dump of your live database is easy:
Windows: [oracle drive] :\oracle\scripts\export.bat, run the "export.bat [SID] [name of dump file]" - example: E:\oracle\scripts\export.bat PSPRODDB PSPRODDB-Jan12
Mac: (see install guide)

6. Copy the data dump from the below location on your live sever to your new test server in the same location. Its is located in:
Windows: [drive]:\oradata\[SID]\data_pump_dir\PSPRODDB-Jan12 <-from out example above
Mac: /u02/oradata/[SID]/data_pump_dir/PSPRODDB-Jan12 <-from out example above

7. Start PowerSchool on the test server (Let PS install any schema updates if needed and restart according to PS app, you may restart several times. In theory running the schema updates before on no data should be faster than running them after importing the data)

8. Import the data on the test server, remember you should have copied the file over from the live server to the test server in step 7. We need to drop the old database on the test server and insert the new one on the test server.
Let's remove the old database first on the test server, run the DropSchema script:
Windows: [oracle drive] :\oracle\scripts\DropSchema.bat, run the "DropSchema.bat [SID]" - example: E:\oracle\scripts\DropSchema.bat PSPRODDB
Mac: (same theory, just different commands, see install guide)
Then let's import the data:
Windows: [oracle drive] :\oracle\scripts\export.bat, run the "export.bat [SID] [name of dump file]" - example: E:\oracle\scripts\export.bat PSPRODDB PSPRODDB-Jan12
Mac: (see install guide)

Run the oracle jobs installer

9. Lets remove the old server configuration from the test server. In an array, if you start it up you would see the all your servers in the list under server settings. We want to clear that first and the set up it up later. (From install guide) Oracle saves on exit, so make sure you actually type Exit.

Windows
1.Open a Command prompt.
2.Enter sqlplus / as sysdba
3.Press Enter/Return.
4.Press Enter/Return.
5.Enter truncate table ps.server_instance;
6.Press Enter/Return.
7.Enter truncate table ps.server_config;
8.Press Enter/Return.
9.Enter Exit
Mac
1.Open Terminal.
2.Enter sudo su – oracle
3.Press Enter/Return.
4.Enter the password for the admin account you are using.
5.Press Enter/Return.
6.Enter sqlplus / as sysdba
7.Press Enter/Return.
8.Enter truncate table ps.server_instance;
9.Press Enter/Return.
10.Enter truncate table ps.server_config;
11.Press Enter/Return.
12.Enter Exit

10. From the PowerSchool Menu select" Web Server Properties", Click "Set Default Values" and Save.

11. From the PowerSchool Menu select "Export Web Server Configuration" ( I don't know why Brian said to do this, I never have, but what the heck.)
Restart the Powerschool Application

12. From the PowerSchool hidden menu select “Turn E-mail Off” (You will also need to disable any AutoComm jobs you have if you using AutoComm)

13. Log into the Test Server.

14. System->ReportWorks Admin->ReportWorks Preferences.

15. Change Scheduler node to "Localhost" and in the Scheduler Send Report remove the production server ip and change to localhost

16. This should be set, but I always check. System->System Settings->Server Settings and set the web server address to your test server address.

17. Restart the server and re-launch PowerSchool. ( I don't usually do this, but how can it hurt)

18. Congratulations you have setup a Test Server.

IF YOU GET AN ERROR START UP THE APPLICATION NODE AND ITS SAYS TO SEE THE DALX LOGS. IT USUALLY MEANS THE DATABASE IS LOCKED. SEE THE INSTALL GUIDE ON HOW TO UNLOCK IT. ANOTHER REASON YOU MAY GET THE ERROR IS THAT THE PASSWORDS DON'T MATCH THE LIVE SERVER, SEE ALTER PERMISSIONS FROM THE INSTALL GUIDE. THE LOG FILE WILL TELL YOU WHY.

I can't get PS to install on

Submitted by vmccoy on Thu, 01/07/2010 - 8:20pm

I can't get PS to install on an XP sp3 station using win2000 compatibility mode. Do you have any suggestions?

Re: I can't get PS to install on

Submitted by brian_andle on Fri, 01/08/2010 - 8:18am

Is there a error message? Do you have Java 1.5 installed? Are you using XP Pro or Home?

The message is

Submitted by vmccoy on Fri, 01/08/2010 - 1:29pm

The message is "Non-Supported Operating system detected". Java 1.5 is installed, XP Pro with SP3.

Re: The message is

Submitted by brian_andle on Fri, 01/08/2010 - 6:43pm

It sounds like you didn't set compatibility mode on the installer file.

2003 compatibility mode in XP?

Submitted by scaleb on Wed, 01/06/2010 - 12:33pm

"You can Install PS on Win 2000, 2003 and XP, if you install on XP make sure you select 2003 compatibility mode"... is this even possible? My XP compatibility modes end with 2000, which believe it or not actually worked.

Re: 2003 compatibility mode in XP?

Submitted by brian_andle on Wed, 01/06/2010 - 2:36pm

I believe the option appears when you have Service Pack 3 installed. I use Vista and Win 7 generally and I saw the 2003 in my XP Mode in Win 7.

in partnership with Creative Breakthroughs