ABSTRACT Install and configure the ODBC Client Connector and setup connection with Tableau, Power Bi, Excel

March 7, 2019 ODBC CONNECTOR CONFIGURATION

Installing and Configuring ODBC Client Connector

Version 1.0

Installing and Configuring ODBC Client Connector

This document provides instructions on how to install the ODBC client driver on your server or Windows desktop. Included are examples of how to connect to the BlackLynx server using the ODBC connector with Tableau, Power Bi, Microsoft Excel, and ISQL.

Table of Contents Install the ODBC Driver on Windows Desktop ...... 2 Upgrade Windows Client ...... 7 Sample Server Connections with Windows Clients ...... 8 Example 1: Connect Using Tableau ...... 8 Example 2: Connect Using Power BI ...... 10 Example 3: Connect Using Microsoft Excel ...... 12 Install and Run the ODBC Driver on Ubuntu Linux ...... 15 README File ...... 16 Run the Installation File ...... 16 Example ODBC connections with Linux clients ...... 18 Sample Connect with ISQL ...... 18 Sample Connect with LibreOffice ...... 19 Install and Run the ODBC Driver on Mac OS ...... 23 Install the ODBC Driver on Mac OS Desktop ...... 24 Example Mac OS installation ...... 26 Sample SQL queries ...... 27 Raw pcap data set 16GB ...... 27 Other datasets ...... 27 XML Dataset ...... 27 Fuzzy search ...... 27 Log files 21GB ...... 27 Unstructured text with regular expression 22GB ...... 27 Leading wildcard search on 65GB ...... 27

BlackLynx, Inc. ©2019 Page | 1 Installing and Configuring ODBC Client Connector

Install the ODBC Driver on Windows Desktop 1. Download the from: https://s3.amazonaws.com/ryft-public-sample- data/ODBC/blacklynx_odbc_client_win_64-2.1.20.0.msi 2. The Setup wizard displays to guide you through installing the BlackLynx ODBC Driver (64-bit). Click Next.

3. The End User License Agreement window displays. Ensure you read the agreement.

BlackLynx, Inc. ©2019 Page | 2 Installing and Configuring ODBC Client Connector

4. Select the I accept the terms in the License Agreement checkbox and click Next.

5. Specify or accept the default destination folder. Click Next.

6. Click Install and the installation starts.

7. Allow the program to update your system.

BlackLynx, Inc. ©2019 Page | 3 Installing and Configuring ODBC Client Connector

8. Once installation is complete, click Finish.

9. On your desktop, click Programs. You can now see the BlackLynx ODBC Driver X.X (64-bit) folder and its files. Select 64-bit ODBC Administrator.

**In Windows 10 environment it is located under Windows Administrative Tools -> ODBC Data Source Administrator (64-bit).

BlackLynx, Inc. ©2019 Page | 4 Installing and Configuring ODBC Client Connector

10. The ODBC Data Source Administrator pop-up window displays. On the User DSN tab, click Add to create a new data source.

11. On the Create New Data Source window ensure BlackLynx ODBC Driver is selected. Click Finish.

BlackLynx, Inc. ©2019 Page | 5 Installing and Configuring ODBC Client Connector

12. The Configure Ryft window displays. Enter a Name and Description for data source. Enter the User name and Password for the server, and specify the IP address of the server. By default, the Port is 7409, but should be changed to match your environment.

13. Click Test Connection to verify connectivity to the Ryft ONE server.

If the test is successful, this message displays.

If the IP address or the Port is bad, this message displays.

BlackLynx, Inc. ©2019 Page | 6 Installing and Configuring ODBC Client Connector

14. After a successful test, click OK to close the Connection Test pop-up. Click OK to close the Configure Ryft pop-up.

15. You’re back on the ODBC Data Source Administrator window. Notice that the data source named has been added. In our example capture it is BlackLynx – 0310.

16. Click OK to close this window.

Upgrade Windows Client When a new release of the Windows client is released, you need to run the new windows installer on your desktop and set up the connections to your BlackLynx servers. You can install the new version without uninstalling/deleting the old version, but the SDK does not allow BlackLynx to automatically recreate existing connections to the BlackLynx server. You must manually re-establish these connections.

Follow the same steps for installation, as covered in the beginning of this chapter. Ensure you complete the Configure window for each BlackLynx server connection.

BlackLynx, Inc. ©2019 Page | 7 Installing and Configuring ODBC Client Connector

Sample Server Connections with Windows Clients Example 1: Connect Using Tableau You can connect a business intelligence tool, like Tableau, to the BlackLynx server to view datasets stored on the server. From using pre-defined views to creating custom views using SQL, you can easily connect to your datasets from a BI tool, like Tableau, by using the BlackLynx Connector.

1. Open Tableau. From the left-hand menu, click More Servers… and then select Other Databases (ODBC)

2. The Server Connection window displays. Select your named datasource from the DSN drop-down list, and click Connect.

BlackLynx, Inc. ©2019 Page | 8 Installing and Configuring ODBC Client Connector

3. After successfully connecting to the BlackLynx server, then click Sign-in at the bottom of the window.

4. Tableau displays and shows that you are now connected to the BlackLynx server (ODBC).

5. Click on the New Custom SQL to execute a search.

BlackLynx, Inc. ©2019 Page | 9 Installing and Configuring ODBC Client Connector

Example 2: Connect Using Power BI Power BI can connect to the to the BlackLynx server using the connector.

1. Open the Power BI and select Get data.

2. Select Other -> ODBC and then hit the Connect button.

BlackLynx, Inc. ©2019 Page | 10 Installing and Configuring ODBC Client Connector

3. Select the immuta-blacklynx DSN and expand Advance options to enter a custom SQL statement:

4. Hit OK and the query will . Then you can Load.

BlackLynx, Inc. ©2019 Page | 11 Installing and Configuring ODBC Client Connector

Example 3: Connect Using Microsoft Excel Microsoft Excel can connect to the BlackLynx server using the connector. Please note that only the 64-bit version of Excel works with the Connector.

Open Microsoft Excel and follow these steps:

1. From the Data ribbon, select From Other Sources and then From ODBC.

BlackLynx, Inc. ©2019 Page | 12 Installing and Configuring ODBC Client Connector

2. The window displays. Select ODBC DSN and then click Next.

3. Select Ryft ONE as your ODBC data source and click Next.

BlackLynx, Inc. ©2019 Page | 13 Installing and Configuring ODBC Client Connector

4. The Connect to BlackLynx dialog box displays. Enter the information for the server and click Connect.

5. The Navigator will allow you to enter the custom SQL command.

BlackLynx, Inc. ©2019 Page | 14 Installing and Configuring ODBC Client Connector

6. Execute the Load button.

Install and Run the ODBC Driver on Ubuntu Linux The BlackLynx Connector can be run in a Linux/Ubuntu enabling clients like LibreOffice and ISQL to connect with the BlackLynx ODBC/JDBC server using the Linux driver.

The installation file, ryft1_odbc_client_linux_64-x.x-y.y.tar.gz, is stored in the “~/install” directory on the Ryft ONE. Install it in Ubuntu, and then follow the instructions in the README file to install the Ryft ONE ODBC connector. BlackLynx, Inc. ©2019 Page | 15 Installing and Configuring ODBC Client Connector

README File The README file contains the steps to install the driver in Linux. As stated in the file, this installation assumes OpenSSL components are already installed in your Linux distribution. If not, run sudo apt-get install libssl1.0.0 command.

This directory contains the installation of the Ryft ODBC driver.

/bin/x8664 - contains the binary.

/lib/x8664 - contains all of the libraries referenced by the Ryft ODBC driver components.

/errormessages - contains the XML error message source for all error issued by the Ryft ODBC driver.

1. Run 'sudo apt-get install unixodbc-dev unixodbc-bin unixodbc' to install the unixODBC components if you have not already done so.

2. Untar the Ryft ODBC Linux Client tarball using 'tar -xzf ryft1_odbc_client_linux-x.x-x.x.tar.gz'

3. Navigate to the ryft1_odbc_client_64 directory and run './install.sh' or optionally 'sudo ./install.sh'. If install is run as root, the Ryft ODBC Linux Client files will be installed in the /usr/local/ryft directory. If you are not running as root at the time of the install, the Ryft ODBC Linux Client files will instead be installed in the ~/ryft directory. If you did not run ./install.sh as root, you will have to update LD_LIBRARY_PATH to include the [INSTALL_DIR]/lib/x8664 directory.

4. During the installation the odbc.ini and odbcinst.ini files were created for you. If you previously had ODBC drivers and DSNs installed, you must merge the contents of these files with the ~/.odbc.ini and ~/.odbcinst.ini files. If you did not have a previous installation, you can copy these files as ~/.odbc.ini and ~/.odbcinst.ini.

5. To use Libre Office Base on Ubuntu, you must also run 'sudo apt-get install -base' if you have not already done so.

NOTE: This installation assumes that OpenSSL components are already installed in your Linux distribution. If the OpenSSL libraries are not installed in your distribution, run 'sudo apt-get install libssl1.0.0'.

Refer to the "Ryft Connectors: Installation and User Guide" for more information on installing and configuring your RyftOne ODBC driver. Run the Installation File 1. First, install the ODBC components and update cache, if it hasn’t already been done.

$ sudo apt-get install unixodbc-dev unixodbc-bin unixodbc 2. Move the file to the HOME directory.

3. Open a window and list the contents of the HOME directory.

4. Untar the installation file:

$ tar –xzf ryft1_odbc_server_linux_64-x.x-x.x.tar.gz 5. Go to the ryft1_odbc_client_64 directory and list the files.

6. As root, run the installation script. You need to enter the administrator password.

BlackLynx, Inc. ©2019 Page | 16 Installing and Configuring ODBC Client Connector

$ sudo ./install.sh o If you ran the command as Root, the Ryft ODBC Linux Client files are installed in the “/user/local/ryft” directory. o If you are not Root when you run the command, the files are installed in the “~/ryft” directory. You must also update the LD_LIBRARY_PATH to include the "[INSTALL_DIR]/lib/x8664" directory. o Enter the IP address of the ODBC server (default is 127.0.0.1) o Enter the port of the ODBC server (default is 7409) 7. Modify contents of the “odbc.ini” file, created during installation, using your preferred editor. Update the IP address and port associated with Server to point to your BlackLynx server.

8. If you have multiple servers, copy and paste the text and update the name (e.g. RyftODBC-100 and RyftODBC-200) and Servers information, like this.

9. Save and close the file.

10. During the installation the odbc.ini and odbcinst.ini files were created for you. If you previously had ODBC drivers and DSNs installed, you must merge the contents of these files with the odbc.ini and

BlackLynx, Inc. ©2019 Page | 17 Installing and Configuring ODBC Client Connector

odbcinst.ini files. If you did not have a previous installation, you must copy these files (as hidden files) to the home directory as ~/.odbc.ini and ~/.odbcinst.ini.

Example ODBC connections with Linux clients Sample Connect with ISQL

BlackLynx, Inc. ©2019 Page | 18 Installing and Configuring ODBC Client Connector

Sample Connect with LibreOffice If you want to use the LibreOffice with the BlackLynx ODBC/JDBC connector, you need to install LibreOffice Base; it is not part of the default Ubuntu distribution. Once installed you can then use Base Database component (database wizard) to connect to the Ryft ONE server using the Ryft Connector.

1. As root, install the libreoffice-base file to use LibreOffice Base on Ubuntu.

$ sudo apt-get install libreoffice-base 2. Start LibreOffice.

$ libreoffice 3. In LibreOffice, select Base Database, and the Database Wizard window opens. Select ODBC in the Connect to an existing database drop-down list.

BlackLynx, Inc. ©2019 Page | 19 Installing and Configuring ODBC Client Connector

4. Click Next. Browse the ODBC data sources and select RyftODBC. Click OK, and then click Next.

5. In the Set up the user authentication page, enter the “ryftuser” user name and select the Password required checkbox. Click Test Connection.

BlackLynx, Inc. ©2019 Page | 20 Installing and Configuring ODBC Client Connector

6. The Authentication Required window displays. Enter the password for the Ryft ONE server and click OK.

If the connectivity test is successful, this message displays. Click OK to proceed.

If the connectivity test fails, this message displays. Click OK and resolve the issue.

BlackLynx, Inc. ©2019 Page | 21 Installing and Configuring ODBC Client Connector

7. Click Finish to save the settings.

8. Give the connection a name, “Ryft-R0001” in this example, and then click Save.

BlackLynx, Inc. ©2019 Page | 22 Installing and Configuring ODBC Client Connector

9. Lastly, LibreOffice Base starts and shows the tables and views already established on the Ryft ONE server.

Install and Run the ODBC Driver on Mac OS This section covers how to install the ODBC client driver on your Mac OS desktop. Once you download and untar the installation file, review the README file.

This directory contains the installation of the Ryft ODBC driver. BlackLynx, Inc. ©2019 Page | 23 Installing and Configuring ODBC Client Connector

/lib - contains all of the libraries referenced by the Ryft ODBC driver components.

/errormessages - contains the XML error message source for all error messages issued by the Ryft ODBC driver.

1. Download and install the iODBC Driver Manager for Mac OS X (www.iodbc.org).

2. Untar the Ryft ODBC Mac OS X Client tarball using 'tar -xzf ryft1_odbc_client_macosx-x.x-x.x.tar.gz'.

3. Navigate to the ryft1_odbc_client_macosx directory and run './install.sh' or optionally 'sudo ./install.sh'. If install is run as root, the Ryft ODBC Mac OS X Client files will be installed in the /usr/local/lib and /usr/local/ryft directories. If you are not running as root at the time of the install, the Ryft ODBC Mac OS X Client files will instead be installed in ~/lib and ~/ryft.

4. During the installation the odbc.ini and odbcinst.ini files were created for you. These files are iODBC configuration files. If you preiously had ODBC drivers and DSNs installed, you must merge the contents of the odbc.ini and odbcinst.ini files with the ~/.odbc.ini and ~/.odbcinst.ini files. If no ~/.odbc.ini or ~/.odbcinst.ini file were located at the time of installation, these files were created for you.

Refer to the "Ryft Connector for ODBC Installation and User Guide" for more information on installing and configuring your RyftOne ODBC driver.

Install the ODBC Driver on Mac OS Desktop 1. Download and install the iODBC Driver Manager for Mac OSX from www.iodbc.org.

2. Download the ODBC Client for Mac OS, ryft1_odbc_client_macosx-x.x-y.y.tar.gz.

3. Open Terminal and go to the “Downloads” directory.

4. Untar the file using this command:

$ tar –xzf ryft1_odbc_client_macosx-x.x-x.x.tar.gz

5. Navigate to the ryft1_odbc_client_macosx directory.

6. Run the installation script. Ryft recommends running the script as the system administrator so that files are installed in the /usr/local/lib and /usr/local/ryft directories. Otherwise, the files will be installed in ~/lib and ~ryft directories. BlackLynx, Inc. ©2019 Page | 24 Installing and Configuring ODBC Client Connector

$ sudo ./install.sh

7. Once you start the installation script, the system prompts you for the following, and once entered, the system installs the Ryft ONE ODBC client:

a. The directory in which to install. By default, it will install in the “/Users/” directory. To accept the default, press Enter. b. The IP Address of the BlackLynx ODBC server. c. The IP Port of the BlackLynx ODBC server (default is 7409) 8. Press Enter and the installation is complete.

BlackLynx, Inc. ©2019 Page | 25 Installing and Configuring ODBC Client Connector

Example Mac OS installation

NOTE: During the installation the odbc.ini and odbcinst.ini files are automatically created for you. These files are ODBC configuration files. If you previously had ODBC drivers and DSNs installed, you must merge the contents of the odbc.ini and odbcinst.ini files with the ~/.odbc.ini and ~/.odbcinst.ini files.

BlackLynx, Inc. ©2019 Page | 26 Installing and Configuring ODBC Client Connector

Sample SQL queries Below is a list of sample SQL Queries to try out with the sample data on the BlackLynx server. Raw pcap data set 16GB select ip_src, ip_dst, http_req_uri from PCAP where ip_dst = '34.238.50.30' and http_req_method = 'GET' select * from PCAP where ip_dst = '34.238.50.30' and payload like '-r(561-69- \d{4})' select ip_src, ip_dst, http_req_uri from PCAP where ip_dst = '34.238.50.30' and http_req_method = 'GET'

select * from PCAP where ip_dst = '34.238.50.30' and payload like '-r(561-69- \d{4})' Other datasets There are other datasets available which can be installed on the server for demonstration purposes. A sample list is outlined below. XML Dataset select * from Chicago_Crime where Description LIKE '%ELECTRONIC%' and Block LIKE '%INDIANA%'

Fuzzy search select * from Passengers where Name like '-E2(Michelle Jones)'

Log files 21GB select * from logs where Results like '-r(host:..(?!ip-172-31-.*)(ip[-0-9]*).)-w20'

Unstructured text with regular expression 22GB select * from wikipedia where Results like '-r(beautiful (\w+ ){0,5}world)-w20'

Leading wildcard search on 65GB select * from CDR where msisdn like '%%%%%%951354' select * from CDR where msisdn like '-r((886682|8866271)\d{6})'

BlackLynx, Inc. ©2019 Page | 27