5 Replies Latest reply on May 29, 2013 10:01 AM by Gregor

    Managing Production and Test PI/AF environments

    OxleyCreek

      We are grappling with how to manage test and production PI systems.  Ideally we want to be able to make test a mirror of production, run the required tests (eg a new ACE calculation) and then copy the changes made in test back to production.

       

      To copy prod to test I did the following:

      • Backed up prod PI server and recovered to test
      • Edited MDB to change any aliases pointing to prod PI server to Test PI sever
      • Exported AF database from prod AF
      • Edited AF Export file and replaced any references to Prod PI wih Test PI. 
      • Imported export file into test AF.

      Our AF database is huge with hundreds of thousands of elements. The export files are enormous and require special editors to do the search and replace. 

       

      Is there a better way? I would like to be able to backup and restore the PIFD database to test AF and then use SQL  to replace the PI server references in the tables? Is this possible?

       

       Does OSIsoft have a suggested strategy for managing test and production PI/AF systems?  I have been tasked with automating the management of prod and test PI/AF system and would appreciate any suggestions on how to achieve this.

       

      Regards

       

       Michael Jones

        • Re: Managing Production and Test PI/AF environments
          hanyong

          One way to simplify this is to use substitution parameter for the PI Server referenced by attributes with PI Point Data Reference. The substitution parameter %Server% should be replaced with the default PI Server of the AF Server. This should avoid the need to manually update the server references. If you are using templates on the production server, changing this should be relatively easy. This would be quite helpful especially when you are mainly using 1 PI Server.

           

          A thing to take note is that if is possible that the attribute lock in the config settings, for example if you are using templates and "Create or Update PI Points" is used on the attribute. After that operation, the setting is always pointing to the same server, instead of dynamically replacing the substitution parameter. You can use the "Reset to Template" option to revert it. It is possible to do this in bulk using PI System Explorer or using the AF Builder add-in in Excel.

           

          Taking a backup and restore the PIFD database in the test environment should work as well. You probably want to install AF Server in the test environment and test the connection before you restore the PIFD database from production. This is to ensure that the things that the required user groups are created during the installation. Substitution parameters should still be effective even if you use this method.

           

          One pitfall that I would look out for is if you have the MDB-AF sync setup. When you migrate to a new server environment, AF Link subsystem will probably fail, because the underlying ID of the new environment is different from the production environment. In this case , it will be required to set it up again.