12 Replies Latest reply on Aug 9, 2017 9:22 AM by ujjwal

    PI SQL DAS on LINUX

    ujjwal

      Hi ,

       

      I am using PI JDBC driver and RJDBC package to access data from PI server on windows.

      However the client has a linux machine and PI SQL DAS is not available for linux.

      Can i get help in how to use PI JDBC on linux .Will i able to access PI server without PI SQL DAS?

      Pls help me in how to proceed.

        • Re: PI SQL DAS on LINUX
          cvillanua

          Hello Ujjwal,

           

          Thank you for posting in PI Square.

           

          There are different ways that you can use in order to access to PI System data from Linux. We have a KB article that talks about this topic: KB00276 - What methods can be used to access PI data from Linux and UNIX systems?

           

          We have a JDBC driver for Linux operating systems, you will have to meet the system requirements:

           

           

          Please let us know more about your use case so we can advise you.

           

          Thank you,

           

          Carlos.

           

            • Re: PI SQL DAS on LINUX
              ujjwal

              Can we have PI SQL DAS on PI server itself and PI jdbc driver on the client machine?

              If yes then can you pls provide the connection url how to connect to PI using jdbc

                • Re: PI SQL DAS on LINUX
                  John Messinger

                  Hi Ujjwal,

                   

                  So the PI-JDBC driver installed on a Linux client machine will still talk to PI SQL DAS installed on a Windows server. The PI SQL DAS can be installed on the PI Data Archive server itself, or it could be on a separate machine. Examples of the required connection URL can be found in the configuration section of the PI-JDBC documentation. We've recently set up this configuration - PI-JDBC driver on a Redhat Linux system, accessing data across the network from a Windows based PI SQL DAS. It's not quite a seamless setup and configuration experience, but once you get it done, it's quite reliable.

                   

                  Cheers,

                  John

                  1 of 1 people found this helpful
                    • Re: PI SQL DAS on LINUX
                      vkaufmann

                      To tack on a bit, once you have finished the configuration steps of PI JDBC on a Linux machine, it is highly recommended to follow through with the validation steps outlined in the documentation here.

                       

                      https://livelibrary.osisoft.com/LiveLibrary/content/en/jdbc-v3/GUID-5220AA54-D221-482C-BFDD-522B2B0E2CEB

                       

                      This is the best way to determine connectivity and data flow with both the AF server and PI Data Archive with GetSnap and GetEASnap.

                       

                      --Vince

                        • Re: PI SQL DAS on LINUX
                          ujjwal

                          Hi,

                           

                          As you told , I have installed PI JDBC driver on the linux machine and trying to access the PI server.

                          however,when i try to test connection using getsnap, I am getting the following error:

                           

                          java.sql.SQLException: /opt/pipc/jdbc/lib/libRdsaWrapper64-1.5b.so: libssl.so.1.0.0: cannot open shared object file: No such file or directory

                           

                          pls help me resolve this.

                           

                          Here is my code:

                           

                          $ java GetSnap

                          Enter Data Access Server name (required): ***

                          Enter PI Data Archive name (required): ***

                          Use trusted connection? [No]: Yes

                          Enter the protocol order for the connection [Https/Soap:5461,NetTcp:5462]: NetTcp:5462

                          Enter PI JDBC log level [0]: 0

                          Enter the PI tag name/name pattern [sinusoid]: sin*

                           

                           

                          Arguments:

                                  Data Access Server name: ***

                                  PI Data Archive name: ***

                                  Use trusted connection?: Yes

                                  Protocol order: NetTcp:5462

                                  Log level: 0

                                  PI tag name/name pattern: sin*

                           

                           

                          java.sql.SQLException: /opt/pipc/jdbc/lib/libRdsaWrapper64-1.5b.so: libssl.so.1.0.0: cannot open shared object file: No such file or directory

                            • Re: PI SQL DAS on LINUX
                              vkaufmann

                              This error is covered in the documentation

                              https://livelibrary.osisoft.com/LiveLibrary/content/en/jdbc-v3/GUID-D76EDBE2-A58E-4032-9FB8-5426FE6DC5C8

                              --Vince

                              2 of 2 people found this helpful
                              • Re: PI SQL DAS on LINUX
                                cvillanua

                                Hello Ujjwal,

                                 

                                From the manual: PI JDBC

                                This error message occurs on Linux systems where symbolic links for libssl.so.1.0.0 and libcrypto.so.1.0.0 are not defined:

                                java.sql.SQLException: /opt/pipc/jdbc/lib/libRdsaWrapper64-1.5b.so: libssl.so.1.0.0: cannot open shared object file: No such file or directory
                                java.sql.SQLException: /opt/pipc/jdbc/lib/libRdsaWrapper64-1.5b.so: libcrypto.so.1.0.0: cannot open shared object file: No such file or directory

                                The missing symbolic links can be created as shown below. The library file names (here libssl.so.1.0.1e and libcrypto.so.1.0.1e) vary depending on the OpenSSL version being installed. On Red Hat distributions you can use the symbolic links libssl.so.10 and libcrypto.so.10 as template.

                                Let us know if this fixes your issue.

                                Thank you,

                                Carlos.

                                3 of 3 people found this helpful
                                  • Re: PI SQL DAS on LINUX
                                    ujjwal

                                    Hi,

                                    I followed the steps to link the symbolic files. But I am facing the same issue(same error)

                                    • Re: PI SQL DAS on LINUX
                                      ujjwal

                                      The openSSL version is:

                                      OpenSSL 1.0.2k-fips  26 Jan 2017

                                      • Re: PI SQL DAS on LINUX
                                        ujjwal

                                        Hi Carlos,

                                         

                                        I have linked the library files and i am able to resolve that error.

                                        However when i try to connect to the PI server using getsnap i am getting the following error:

                                         

                                         

                                        WARNING: Connection to https://my_server:5461/DataAccessServer/Query failed. Error: [PI SQL DAS] Connection timed out

                                        Details: connect failed in tcp_connect()

                                         

                                         

                                        java.sql.SQLException: Connection to https://my_server:5461/DataAccessServer/Query failed. Error: [PI SQL DAS] Connection timed out

                                        Details: connect failed in tcp_connect()

                                         

                                         

                                         

                                         

                                         

                                        Here is my code and log details:

                                         

                                        $ java GetSnap my_server my_DAS  Yes Https/Soap:5461 5 sin%

                                         

                                         

                                        Arguments:

                                                Data Access Server name: my_server

                                                PI Data Archive name: my_DAS 

                                                Use trusted connection?: Yes

                                                Protocol order: Https/Soap:5461

                                                Log level: 5

                                                PI tag name/name pattern: sin%

                                         

                                         

                                        Aug 09, 2017 4:55:50 AM com.osisoft.jdbc.DriverExtension <init>

                                        FINER: Driver Version : 1.5.16096.2

                                        Aug 09, 2017 4:55:50 AM com.osisoft.jdbc.DriverExtension <init>

                                        INFO: New Connection : jdbc:pioledb://my_server /Data Source=my_DAS  ; Integrated Security=SSPI

                                        Aug 09, 2017 4:55:50 AM com.osisoft.jdbc.DriverExtension logProperties

                                        FINEST: Properties:

                                        LogLevel=5

                                        TrustedConnection=Yes

                                        LogConsole=True

                                        ProtocolOrder=Https/Soap:5461

                                        Aug 09, 2017 4:55:50 AM com.osisoft.rdsa.NativeRDSA verifyWrapperLibrary

                                        FINEST: /opt/pipc/jdbc/lib/libRdsaWrapper64-1.5b.so can be loaded.

                                        Aug 09, 2017 4:55:50 AM com.osisoft.jdbc.DriverExtension getAuthentication

                                        FINEST: Using trusted connection.

                                        Aug 09, 2017 4:55:50 AM com.osisoft.jdbc.ConnectionImpl <init>

                                        FINEST:  Trusted connection = true

                                        Stateless connection = false

                                        Aug 09, 2017 4:55:50 AM com.osisoft.rdsa.NativeRDSA create

                                        INFO: Trying to connect to https://my_server:5461/DataAccessServer/Query

                                        Aug 09, 2017 4:57:57 AM com.osisoft.jdbc.ConnectionImpl <init>

                                        WARNING: Connection to https://my_server:5461/DataAccessServer/Query failed. Error: [PI SQL DAS] Connection timed out

                                        Details: connect failed in tcp_connect()

                                         

                                         

                                        java.sql.SQLException: Connection to https://my_server:5461/DataAccessServer/Query failed. Error: [PI SQL DAS] Connection timed out

                                        Details: connect failed in tcp_connect()

                                         

                                         

                                        Could not connect using none of the specified protocols.

                                         

                                         

                                         

                                        If i try using NetTcp protocol instead I am getting a different error:

                                         

                                        WARNING: Connection to net.tcp://150.45.88.159:5462/DataAccessServer/Query failed. Error: NetTcp is not supported.

                                         

                                         

                                        java.sql.SQLException: Connection to net.tcp://150.45.88.159:5462/DataAccessServer/Query failed. Error: NetTcp is not supported.

                                         

                                        pls help me resolve this