When attempting to install GPCC in a Greenplum 7 environment using a non-standard administrator user (e.g., dbadmin instead of the default gpadmin), the installation script gpccinstall may fail to automatically configure the monitoring components.
Common issues(./gpccinstall error) include:
gpmon` user.INSTALLATION IN PROGRESS...
Using PwdLogin, connection Pguser is gpmon and Pghost is 127.0.0.1
Failed to connect to database as gpmon pq: role "gpmon" does not exist
gpperfmon` database.INSTALLATION IN PROGRESS...
Using PwdLogin, connection Pguser is gpmon and Pghost is 127.0.0.1
Failed to connect to database as gpmon pq: database "gpperfmon" does not exist
pg_hba.conf` authentication during the installation process.INSTALLATION IN PROGRESS...
Using PwdLogin, connection Pguser is gpmon and Pghost is 127.0.0.1
Failed to connect to database as gpmon pq: no pg_hba.conf entry for host "127.0.0.1", user "gpmon", database "gpperfmon", SSL off
VMware Tanzu Greenplum 7.x + Greenplum Command Center 7.x
In Greenplum 7, the `gpccinstall` script is optimized for the default `gpadmin` environment. When using a different superuser (like `dbadmin`) to manage the database, the script may encounter unexpected error due the original code design.
To successfully install GPCC using a non-standard administrator user, make sure the non-standard user has equivalent privilege as gpadmin, and manual preparation of the `gpperfmon` environment is required before running the installer. Follow these steps:
Manually append the required entries to `$COORDINATOR_DATA_DIRECTORY/pg_hba.conf` to allow the `gpmon` user to connect.
# Append the following lines to pg_hba.conf
local gpperfmon gpmon md5
host all gpmon 127.0.0.1/28 md5
host all gpmon ::1/128 md5
host all gpmon samenet md5
Reload the configuration:
gpstop -u
Create the `gpmon` superuser and set a password that complies with your organization's password policy (especially if `advanced_password_check` is enabled).
psql postgres -c "CREATE ROLE gpmon WITH SUPERUSER CREATEDB LOGIN ENCRYPTED PASSWORD 'your_strong_password';"
createdb gpperfmon
Execute the `gpccinstall` script using the `-W` flag to prompt for the `gpmon` password created in Step 2.
./gpccinstall-7.x.x -W
# When prompted: Password for GPDB user gpmon: [Enter Password]
For seamless future access, add the credentials to the `~/.pgpass` file of the installation user:
*:<coordinator_port>:gpperfmon:gpmon:your_strong_password