PSQL Service Script bug

En Centos 5.6 he descubierto un bug en el script del servicio de postgres, en el script figura una variable PGPORT = 5432 que sobreescribe la indicacion del puerto en postgresql.conf, para evitar que suceda esto hay que realizar la siguiente modificacion al archivo /etc/ini.d/postgresql, modificando el orden de las variables e insertando la captura de los datos del postgresql.conf :

PGDATA=/var/lib/pgsql/data
#PGPORT=5432  **<--- bug**
PGPORT=`/bin/cat $PGDATA/postgresql.conf | /bin/grep '^port' | /bin/sed 's/port = //g'`
Unless otherwise stated, the content of this page is licensed under GNU Free Documentation License.