2 Replies Latest reply on May 16, 2012 7:43 PM by Tfenn

    How to have PItoPI APS add a prefix from an external data source


      Help or ideas please.


      I'm planning to use the PItoPI APS connector to create tags in my 'big PI'  Server while sourcing it's tags from many 'little PI' Servers which reside on seperate devices.


      To ensure the tag names are unique on the big PI Server, I need to add a unique device identifier as a prefix (or post fix) to each tag name as it is created by the APS connector. 


      The obvious answer is to put the unique identifer into the tag creation setting's 'literal text field' when manually setting up the interface configuration, however this means that each device must be configured manually.  I'm hoping to automate the tag name construction and so that I can build an ' installation image' for each device it  will automatically configure itself on startup by finding the devices ID using a script or some other method. 


      As I understand it the PItoPI APS connector cannot source the literal text from an external data source (text file, db etc.). 


      One thought I had is to write an installation script which finds the target device's ID and then alters the the literal name field in the APS connector's configuration file.  Is this a possible option?  Any other ideas welcomed.


      Thank you in advance. 

        • Re: How to have PItoPI APS add a prefix from an external data source

          Hi Tony...not related to PItoPI APS but the same principle.  You could: On the little PI System have the Powershell Tools for the PI System, which connects to the AF Server of the big PI System.  The Powershell script would connect to an AF Database, e.g. "Configuration", search for the tag prefix based on an AF Element being named as the little PI System VM name (and inheriting from a specific Element Template), then have the Powershell script modify the PItoPI APS config (to be determined).  Finally, set a flag in the AF Database to say that the prefix has been applied.  


          If you have Windows 2k8 R2 as the little PI System host OS then you can use the Windows local policy to set your Powershell script on startup...it would check the flag and only run if it has not already been applied.  Or you could even has the Powershell script remove itself from the local policy once it has done it's business.


          Is that along the lines of what you meant?

            • Re: How to have PItoPI APS add a prefix from an external data source

              Hi Rhys


              Thank you for your reply.


              The key thing (and I'm guilty of not digging into this further myself yet) is figuring out if the PItoPI APS Connector has a config file where I could modify the prefix text before starting up the connector   If so then I can try what you suggest as each little PC has to some how be 'registered' with the big PI anyway and I will have to create an AF structure for each one on registration.  As you can appreciate I'm trying to use as much out of the box stuff as possible.