The document says that "Initializing PXF also creates the $PXF_CONF user configuration directory if it does not already exist, and then populates conf and templates subdirectories with the following".
When we run the pxf cluster init command it is not creating the directory and throwing the below error.
[gpadmin@mdw_ipv4 local]$ PXF_CONF=/usr/local/greenplum-pxf pxf cluster init
Initializing PXF on master host, standby master host, and 2 segment hosts...
The PXF_CONF directory will be created on all the nodes only if gpadmin user has the necessary permissions to create, or write to, this directory.
So PXF_CONF directory should not be created in /usr/local, where it will have only root user permissions.
Under Procedure section, the 3rd point explains about the pxf cluster init command and the PXF_CONF directory is pointing to /usr/local.
The example needs to be updated with the directory structure which have gpadmin access.
https://gpdb.docs.pivotal.io/pxf/5-15/using/init_pxf.html PXF v5.15 is bundled with gpdb 6.18.2 however the steps to setup the bundled pxf are giving the error described below.
Configuring PXF -> Initializing PXF -> Initialization Overview
The document says that "Initializing PXF also creates the $PXF_CONF user configuration directory if it does not already exist, and then populates conf and templates subdirectories with the following".
When we run the pxf cluster init command it is not creating the directory and throwing the below error.
[gpadmin@mdw_ipv4 local]$ PXF_CONF=/usr/local/greenplum-pxf pxf cluster init Initializing PXF on master host, standby master host, and 2 segment hosts...
ERROR: PXF failed to initialize on 4 out of 4 hosts mdw_ipv4 ==> Instance already exists. Use 'pxf [cluster] reset' before attempting to re-initialize PXF smdw_ipv4 ==> mkdir: cannot create directory ‘/usr/local/greenplum-pxf’: Permission denied cp: cannot create directory ‘/usr/local/greenplum-pxf’: Permission denied... sdw1_ipv4 ==> mkdir: cannot create directory ‘/usr/local/greenplum-pxf’: Permission denied cp: cannot create directory ‘/usr/local/greenplum-pxf’: Permission denied... sdw2_ipv4 ==> mkdir: cannot create directory ‘/usr/local/greenplum-pxf’: Permission denied cp: cannot create directory ‘/usr/local/greenplum-pxf’: Permission denied...
The PXF_CONF directory will be created on all the nodes only if gpadmin user has the necessary permissions to create, or write to, this directory.
So PXF_CONF directory should not be created in /usr/local, where it will have only root user permissions.
Under Procedure section, the 3rd point explains about the pxf cluster init command and the PXF_CONF directory is pointing to /usr/local. The example needs to be updated with the directory structure which have gpadmin access.
gpadmin@gpmaster$ PXF_CONF=/usr/local/greenplum-pxf pxf cluster init