# Default number of PostgreSQL database clusters
NUMCLUSTERS=2
# Where to look for pgpool.conf.sample*
+PGPOOL_INSTALL_DIR=${PGPOOL_INSTALL_DIR:-"/usr/local"}
PGPOOLDIR=$PGPOOL_INSTALL_DIR/etc
+# PostgreSQL commands(initdb, pg_ctl, psql) install dir
+PGBIN=${PGBIN:-"/usr/local/pgsql/bin"}
# LD_LIBRARY_PATH
LPATH=/usr/local/pgsql/lib
# initdb args
echo "creating startall and shutdownall"
echo "LD_LIBRARY_PATH=$LPATH" > $STARTALL
echo 'dir=`pwd`' >> $STARTALL
+echo "PGPOOL_INSTALL_DIR=$PGPOOL_INSTALL_DIR" >> $STARTALL
chmod 755 $STARTALL
echo 'dir=`pwd`' > $SHUTDOWNALL
+echo "PGPOOL_INSTALL_DIR=$PGPOOL_INSTALL_DIR" >> $SHUTDOWNALL
echo '$PGPOOL_INSTALL_DIR/bin/pgpool -f $dir/etc/pgpool.conf -m f stop' >> $SHUTDOWNALL
chmod 755 $SHUTDOWNALL
echo 'dir=`pwd`' > $PGPOOL_RELOAD
+echo "PGPOOL_INSTALL_DIR=$PGPOOL_INSTALL_DIR" >> $PGPOOL_RELOAD
echo '$PGPOOL_INSTALL_DIR/bin/pgpool -f $dir/etc/pgpool.conf reload' >> $PGPOOL_RELOAD
chmod 755 $PGPOOL_RELOAD