This topic describes user privileges and other requirements for PostgreSQL target hosts and databases collectively referred to as the target environment.
Target Environment Requirements
The operating system and architecture of the target environment must match those of the source environment. It is recommended that the source and the target environments should be identical and hardware configurations should match.
Compatible Operating System supported by the Plugin is CentOS 7.3/7.4/7.5/7.6 and RHEL 7.3/7.4/7.5/7.6. The underlying Operating System for both Source and Staging environment should be amongst these two versions.
There must be an installation of PostgreSQL on the target environment that is compatible with the installation of PostgreSQL on the source environment. Two installations of PostgreSQL are compatible if and only if:
They share the same vendor (for example, PostgreSQL is incompatible with EnterpriseDB Postgres Plus Advanced Server).
They share the same major version number (for example, 9.5.4 is compatible with 9.5, 9.5.3; however, it is incompatible with 9.3, 9.3.24, or 9.2).
They are compiled against the same architecture (in other words, 32-bit and 64-bit installations of Postgres are incompatible).
They are compiled with the same WAL segment size. The default WAL segment size of 16 MB is rarely changed in practice, so almost all installations of PostgreSQL are compatible with each other in terms of WAL segment size.
There must be an operating system user (i.e postgres) with the following privileges:
The Delphix Engine must be able to make an SSH connection to the target environment using the operating system user.
The operating system user must have read and execute privileges on the PostgreSQL binaries installed on the target environment.
The operating system user must have permission to run mount and umount as the superuser via sudo with neither a password nor a TTY. See Sudo Privilege Requirements for PostgreSQL Environments for further explanation of the commands, and Sudo File Configuration Examples for PostgreSQL Environments for examples of the /etc/sudoers file on different operating systems.
There must be a directory on the target environment where the Delphix Engine Plugin can be installed (for example, /var/tmp ) with the following properties:
The Plugin directory must be writable by the operating system user mentioned above.
The Plugin directory must have at least 1.5 GB of available storage.
There must be a mount point directory (for example, /mnt) that will be used as the base for mount points that are created when provisioning a VDB with the following properties:
The mount point directory must be writable by the operating system user mentioned above.
The mount point directory should be empty.
TCP/IP connectivity to and from the source environment must be configured as described in General Network and Connectivity Requirements.
Hostname and IP must be correctly set in /etc/hosts file, for example [postgres@source ~]$ hostname -i
The output of “hostname -i” command should produce the correct result as the IP address of the server. For example:
[postgres@source ~]$ hostname -i
10.110.207.113- When using the External Backup method for ingestion the directories being used for keeping Backup file and WAL file should be accessible by OS User.
- Zip must be installed on the Staging/Target Host for External Backup Support.
- The backup command and File should be in the below format:
PostgreSQL_T<YYYYMMDD>.zip where YYYY denotes Year, MM denotes month, DD denotes date. For example, PostgreSQL_T20190314.zip.
The above zip file should contain Database Full Backup from the Source created in tar format. Below flags with pg_basebackup is to be used for taking Source Database backup:
For PostgreSQL versions 9.4.x,9.5.x,9.6.x -<PATH_TO_PG_BIN>/pg_basebackup -p <PORT> -D <EMPTY_BACKUP_DIR> -F t -v -w -P -x
For PostgreSQL versions 10.x and 11.x<PATH_TO_PG_BIN>/pg_basebackup -p <PORT> -D <EMPTY_BACKUP_DIR> -F t -v -w -P -Xs
In order to optimize the performance, it is preferred to create an Environment Variable "DELPHIX_PG_PATH" which should be accessible by OS user.
Below should be the syntax for "DELPHIX_PG_PATH" variable:
DELPHIX_PG_PATH="binary_path:data_path1;binary_path:data_path2;"For example:
DELPHIX_PG_PATH="/usr/pgsql-9.6/bin:/var/lib/pgsql/9.6/data;/opt/edb/as9.6/bin:/opt/edb/as9.6/data;/usr/pgsql-9.6/bin:/tmp/TESING/data;"In the absence of "DELPHIX_PG_PATH" variable or if value of "DELPHIX_PG_PATH" variable is NULL then Linux "find" command will be used for Environment discovery which may impact the overall performance. Hence, it is preferred to create this Environment Variable with correct entries.
The variable "DELPHIX_PG_PATH" must be available to the environment user in a non-interactive way.