Preparations
- Obtain and upload the tsdbtool package to the master node of the server cluster, and decompress it to obtain a complete software folder tsdbtool.
- Download the setuptool, CMake-3.5.2, psutil, pbr, lockfile, pycparser, cffi, bcrypt, six, PyNacl, cryptography, ipaddress, enum3, paramiko, zstd-dev, Xerces, re2c, and gporca source code packages and save them to the greenplumDep folder in the tsdbtool directory. For details about the download addresses, see Table 2.
- Obtain the Greenplum source package or RPM package and upload it to the tsdbtool directory.
- Configure each server with a unique hostname.
- Modify the installation configuration file greenplumconf.csv.
Table 1 describes the parameters in the greenplumconf.csv configuration file.
Table 1 Parameters in the greenplumconf.csv configuration file Parameter
Description
isopath
Specifies the OS image path, which must be uploaded to the OS of the server in advance for installing some dependencies.
prefixdir
Specifies the absolute path for installing the software after the source code is compiled. The path must exist in the OS. This parameter is invalid and not used for RPM package installation.
db_password
Specifies the password of the Greenplum database. The tool uses this field to set the password of the database.
os_root_user
Specifies the root username of the OS on the server where Greenplum is installed.
os_root_password
Specifies the password of user root for logging in to the OS of the server where Greenplum is installed.
version
Specifies the Greenplum version.
compile_flag
Determines the check process. Set this parameter to 1 for the check before RPM package compilation. Otherwise, set this parameter to 0. The number of check items is small during compilation.
master_dir
Specifies the directory of the master node. The value is directly written into the file as the MASTER_DIRECTORY value of the Greenplum configuration file and must be stored in the OS.
standby_server
Specifies the IP address of the standby node.
standby_dir
Specifies the directory of the standby node. The value must be the same as that of master_dir and must exist in the OS.
seg_server
Specifies the IP addresses of the SEG servers. Use semicolons (;) to separate multiple IP addresses.
seg_server_num
Specifies the number of SEG servers, which is used for verification.
seg_data_dir
Specifies the data directories of the SEG servers. Multiple directories are separated by semicolons (;). The value is directly written to the file as the value of DATA_DIRECTORY in the Greenplum configuration file and must be stored in the OS.
seg_mirror_data_dir
seg_dir_num
Specifies the data image directories of the SEG servers. Multiple directories are separated by semicolons (;). The value is directly written to the file as the value of MIRROR_DATA_DIRECTORY in the Greenplum configuration file. The number of image directories must be the same as the number of data directories and must exist in the OS.
Specifies the number of SEG directories, which is used for verification.
The following uses Greenplum 5.22.0 as an example. Before installing Greenplum using tsdbtool:
- Obtain and upload the tool package to the master node of the server, and decompress it to the /home directory to obtain the /home/tsdbtool directory.
- Upload the gpdb-5.22.0.tar.gz source package or RPM package to the /home/tsdbtool directory.
- Obtain and save the source code packages setuptool, CMake-3.5.2, psutil, pbr, lockfile, pycparser, cffi, bcrypt, six, PyNacl, cryptography, ipaddress, enum3, paramiko, zstd-dev, Xerces, re2c, and gporca to the greenplumDep folder in the tsdbtool directory.
- Modify the greenplumconf.csv file and create the prefixdir (not required if you install Greenplum using an RPM package), standby_dir, seg_data_dir, seg_mirror_data_dir, and master_dir directories in the system.