Chat now with support
Chat with Support

SharePlex 11.0 - SharePlex Installation and Setup Guide

About this Guide Conventions used in this guide Revision History SharePlex pre-installation checklist Download the SharePlex installer Installation and setup for Oracle cluster Installation and setup for remote capture Install SharePlex on Linux and UNIX Assign SharePlex users to security groups Set up an Oracle environment for replication Set up replication from Oracle to a different target type Generic SharePlex demonstration-all platforms Advanced SharePlex demonstrations for Oracle Advanced SharePlex Demonstrations for PostgreSQL Solve Installation Problems Database Setup Utilities General SharePlex Utilities Uninstall SharePlex Advanced installer options Install SharePlex as root Run the installer in unattended mode SharePlex installed items

How to find the ORACLE_SID and ORACLE_HOME

When setting up SharePlex to work with an Oracle database, you provide the ORACLE_SID and then SharePlex gets the ORACLE_HOME from the oratab file on Unix/Linux. Both values are stored in the SharePlex environment. SharePlex uses the Oracle libraries that are in the location specified with ORACLE_HOME.

To determine the ORACLE_SID and ORACLE_HOME being used by SharePlex:

Issue the orainfo command in sp_ctrl.

sp_ctrl (mysysl11:2101)> orainfo

Oracle instance #1:

Oracle SID ora12

Oracle HOME /oracle/products/12

Oracle Version 12

Oracle instance #2:

Oracle SID ora12

Oracle HOME /oracle/products/12

Oracle Version 12

To determine the default ORACLE_SID and ORACLE_HOME on UNIX and Linux:

On most Unix and Linux systems the oratab file is under /etc/oratab. On Oracle Solaris systems, it is under /var/opt/oracle, but sometimes there is an oratab file in the /etc directory as well.

The entry in the file looks like the following example:

qa12:/qa/oracle/ora12/app/oracle/product/12.0

In the example, qa12 is the ORACLE_SID and /qa/oracle/ora12/app/oracle/product/12.0 is the ORACLE_HOME.

Database Setup Utilities

The Database Setup utilities automatically configure a source or target database to allow SharePlex connections and to establish required database components that support replication.

Contents

HANA Setup (hana_setup)

Database Setup for HANA

Overview

Run the Database Setup utility for HANA (hana_setup) on a target HANA system to establish a user account, schema, and tables for use by SharePlex.

Supported databases

HANA on supported platforms

Guidelines for use

  • Run the setup utility on all target HANA instances in the SharePlex replication configuration.
  • Within a server cluster, run the setup utility on the node that has the mount point to the shared disk that contains the SharePlex variable-data directory.
  • For consolidated replication, run the setup utility for each variable-data directory.
  • The only supported connection method to HANA is by connect string. Connection through a DSN is not supported.

  • Make certain that you assign the required permissions that are shown in this setup process.

Required privileges

The setup utility must be run as a HANA Administrator in order to grant SharePlex the required privileges to operate on the database and to create the SharePlex database account.

Run database setup for HANA

  1. Shut down any running SharePlex processes and sp_cop on the target system.
  2. Run the hana_setup program from the bin subdirectory of the SharePlex product directory.

Important! If you installed the SharePlex instance on any port other than the default of 2100, use the -p option to specify the port number. For example, in the following command the port number is 9400.

$ /users/splex/bin> hana_setup -p9400

Table 6: Setup Prompts and Responses

Prompt Response

Enter the HANA connection string [] :

Enter a connection string that connects to the HANA database system. The required components of a connection string for SharePlex to connect to HANA are:

  • SERVERNODE: The name of the target HANA server, then a colon, then the HANA port number.
  • DRIVER: The path to the HANA ODBC driver.
  • CHAR_AS_UTF8: This must be passed as CHAR_AS_UTF8=1.

Example:

SERVERNODE=server1.dept.abc.corp:30015;DRIVER=/usr/sap/hdbclient/libodbcHDB.so;CHAR_AS_UTF8=1

You do not have to supply a user, password, and default database, because the setup utility prompts for those.

Enter the HANA Administrator name :

Enter the name of the HANA Administrator. This user will perform the work on the SharePlex account.

Enter the password for the Administrator account :

Enter the password of the Administrator.

Enter the name of the database :

Enter the name of the database that you want to contain the tables and other objects for use by SharePlex. You can enter the name of a new or existing database.

Database name database does not exist. Would you like to create it? [y] :

If this prompt is displayed, the specified database does not exist. Press Enter to have the setup utility create it for you.

Would you like to create a new SharePlex user [y]:

Press Enter to accept the default to create a new SharePlex database user account and schema of the same name in the specified database, or enter n to use an existing SharePlex account.

Enter the name of the new SharePlex user:

Enter the name of the existing SharePlex user:

One of these prompts is displayed depending on whether you elected to create a new user or use an existing user. Enter the name of the SharePlex user.

 

Enter the password of the SharePlex user :

Enter the password of the SharePlex user account.

Re-enter the password for the SharePlex user :

This prompt is only shown if you created a new user. Enter the SharePlex password again.

A successful setup terminates with a message similar to the following:

Completed SharePlex for HANA database configuration

SharePlex User name: splex

Database name: ndb5

Target specification in SharePlex configuration: r.ndb5

Grant privileges to SharePlex

Before you start SharePlex replication to a HANA target, grant the following privileges to the SharePlex database user in that target (where SP_USER is the name of the SharePlex database user):

  • GRANT USER ADMIN TO sp_user;
  • GRANT TABLE ADMIN TO sp_user;
  • GRANT CATALOG READ TO sp_user;
  • GRANT DATA ADMIN TO sp_user WITH ADMIN OPTION;
  • GRANT ROLE ADMIN TO sp_user WITH ADMIN OPTION;

Additionally, log in as the owner of each schema that contains objects that you want to replicate, then make the following grants on the schema:

  • GRANT CREATE ANY ON SCHEMA schema_name TO sp_user;
  • GRANT DEBUG ON SCHEMA schema_name TO sp_user;
  • GRANT DELETE, DROP, EXECUTE, INDEX, INSERT, SELECT, UPDATE ON SCHEMA schema_name TO sp_user;

MySQL Setup (mysql_setup)

Database Setup for MySQL

Overview

Run the Database Setup utility for MySQL (mysql_setup) on a MySQL system to establish SharePlex as a MySQL database user.

This utility creates the following:

  • A SharePlex user account with full DBA privileges
  • Tables and indexes for use by SharePlex and owned by the SharePlex user in a database of your choosing
  • A default database connection.

Supported databases

MySQL on Linux. For supported Linux platforms and versions, see the SharePlex Release Notes.

Guidelines for use

  • Run the setup utility on all MySQL instances in the SharePlex replication configuration.
  • Within a cluster, run the setup utility on the node to which the shared disk that contains the SharePlex variable-data directory is mounted.
  • For consolidated replication, run the setup utility for each variable-data directory.

Required privileges

Review the following requirements to ensure that the setup succeeds:

  • The setup utility must be run as a MySQL Administrator that retains all of that user's default privileges. Both local and cloud MySQL Administrators should have the required privileges by default. The Administrator user is able to grant SharePlex the required privileges to operate on the database and to create the SharePlex database account and objects.
  • (Cloud installations) Common restrictions on privileges in cloud-hosted database services make it difficult for the setup utility to succeed in every possible type of scenario. To ensure that the database setup succeeds, only use the setup utility for the following purposes: To do a first-time database setup with a new SharePlex user, or, to modify an existing SharePlex user that either owns the database or has access to it.

Run database setup for MySQL

Perform the following steps to to run database setup for MySQL:

  1. Shut down any running SharePlex processes and sp_cop on the MySQL system.
  2. Run the mysql_setup program from the bin subdirectory of the SharePlex product directory.

    Important! If you installed the SharePlex instance on any port other than the default of 2100, use the -p option to specify the port number. For example, in the following command the port number is 9400.

    C:\users\splex\bin> mysql_setup -p9400

Table 7: Setup prompts and responses

Prompt Response

Enter the MySQL connection string [] :

Enter a connection string that connects to the MySQL database.

Do not use a DSN.

If you are replicating data larger than 500 MB to MySQL Aurora on Amazon RDS, include the MySQL parameter max_allowed_packet in the connection string and set its value to the maximum size of the data. See the example.

Example connection string

DRIVER=/usr/lib64/libmyodbc5.so;socket=/var/lib/mysql/mysql.sock;character-set-server=utf8;collation-server=utf8_general_ci;max_allowed_packet=2G;wait_timeout= 6000;Server=servername.amazonaws.com

Enter the MySQL Administrator name :

Enter the name of the MySQL Administrator. This user will perform the setup work on the SharePlex account and schema.

Enter the password for the Administrator account :

Enter the password of the Administrator.

Enter the replication target database name :

Enter the name of the MySQL database where you want to install the SharePlex objects.

Database name database does not exist. Would you like to create it? [y] :

If this prompt is displayed, the specified database does not exist. Press Enter to have the setup utility create it for you.

Would you like to create a new SharePlex user [y]:

Press Enter to accept the default to create a new SharePlex database user account, or enter n to use an existing account as the SharePlex database user.

Enter the name of the new SharePlex user:

Enter the name of the existing SharePlex user:

One of these prompts is displayed depending on whether you elected to create a new user or use an existing user. Enter the name of the SharePlex user.

 

Enter the password for the SharePlex user :

Enter the password of the SharePlex user account.

Re-enter the password for the SharePlex user :

Enter the SharePlex password again.

A successful setup terminates with a message similar to the following:

Completed SharePlex for MySQL database configuration

SharePlex User name: mysql29

Database name: mysql29

Target specification in SharePlex configuration: r.mysql29

Configure SharePlex to support MySQL database on Azure platform

You can configure SharePlex to support the MySQL database on the Azure platform using the below steps:

  1. Add the DSN entry along with Socket path (SOCKET=) in the Odbc.ini file at /etc/odbc.ini and the …/var/odbc directory.
  2. Copy the /etc/odbcinst.ini file to the …/var/odbc directory.
  3. Run the MySQL setup utility.
This process creates the SharePlex tables, login and user accounts needed to run SharePlex replication.
 

Table 8: Setup Prompts and Responses

Prompt Response

Enter the MySQL DSN name or connection string [] :

Enter the MySQL DSN name or a connection string that connects to the MySQL database system.

Example: pslazpgdb02

Is DB hosted over Azure ? :

Y

Enter the Database hostname :

Enter the Azure database host name.

Note: MySQL Administrator name should be in the <username> format (Do not mention the hostname)

Example: pslazpgdb02.mysql.database.azure.com

If a user already exists for SharePlex then it should be entered in the <username@hostname> format.

If a new user needs to be created for SharePlex then is should be entered in the <username> format.

Enter the MySQL Administrator name :

Enter the name of the MySQL Administrator. This user will perform the setup work on the SharePlex account and schema.

Example: mysql

Enter the password for the Administrator account:

Enter the password of the Administrator.

Note: User 'mysql@pslazpgdb02.mysql.database.azure.com' got the superuser role.

Enter the replication target database name :

Enter the target database name on which replication needs to be performed.

Example: sp_mk

Would you like to create a new SharePlex user?

Enter the name of the existing SharePlex user:

N (If you want to create a user, enter “y”)

 

Enter the name of the SharePlex user.

Enter the password of the SharePlex user :

Enter the password of the SharePlex user account.

Re-enter the password for the SharePlex user :

This prompt is only shown if you created a new user. Enter the SharePlex password again.

A successful setup terminates with a message similar to the following:

Completed SharePlex for MySQL database configuration

SharePlex User name: mysql@pslazpgdb02.mysql.database.azure.com

Database name: sp_mk

The data source identifier in the SharePlex configuration is 'r.sp_mk' –

Related Documents

The document was helpful.

Select Rating

I easily found the information I needed.

Select Rating