From 8b07d735a4335f6b44010944610989a9d3503eea Mon Sep 17 00:00:00 2001 From: Holger Lindemann Date: Mon, 14 Mar 2011 14:54:52 +0100 Subject: [PATCH] =?utf8?q?"SET=20default=5Fwith=5Foids=20=3D=20true;"=20mu?= =?utf8?q?=C3=9F=20nicht=20mehr=20in=20der=20postgresql.conf=20ge=C3=A4nde?= =?utf8?q?rt=20werden.?= MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit --- scripts/inst_postgres.sh | 45 ++++++++++++++++++------------------ scripts/inst_postgres_deb.sh | 30 ++++++++++++------------ 2 files changed, 37 insertions(+), 38 deletions(-) diff --git a/scripts/inst_postgres.sh b/scripts/inst_postgres.sh index 66fbaa920..6d07e599a 100755 --- a/scripts/inst_postgres.sh +++ b/scripts/inst_postgres.sh @@ -139,32 +139,31 @@ if [ $cnt -eq 0 ]; then cat $PGHBA.org >> $PGHBA fi -CONFDIR=`dirname $PGHBA` +#CONFDIR=`dirname $PGHBA` #postgresql.conf anpassen, liegt vermutlich im gleichen Verzeichnis wie pg_hba.conf -if ! [ -f $CONFDIR/postgresql.conf ]; then - #doch nicht da, dann fragen - while :; do - writeln 13 1 'postgresql.conf' nicht gefunden. - tput bold - writeln 14 1 "Bitte den Pfad eingeben: " - tput rmso - read PGCONF - [ "$PGCONF#" != "#" ] && [ -f $PGCONF ] && break - tput bel - done - CONFDIR=`dirname $PGCONF` -fi - -mv $CONFDIR/postgresql.conf $CONFDIR/postgresql.conf.org +#if ! [ -f $CONFDIR/postgresql.conf ]; then +# #doch nicht da, dann fragen +# while :; do +# writeln 13 1 'postgresql.conf' nicht gefunden. +# tput bold +# writeln 14 1 "Bitte den Pfad eingeben: " +# tput rmso +# read PGCONF +# [ "$PGCONF#" != "#" ] && [ -f $PGCONF ] && break +# tput bel +# done +# CONFDIR=`dirname $PGCONF` +#fi + +#mv $CONFDIR/postgresql.conf $CONFDIR/postgresql.conf.org #Bei der V8.x OID einschalten. -sed 's/^.*default_with_oids.*/default_with_oids = true/i' $CONFDIR/postgresql.conf.org > $CONFDIR/postgresql.conf -cnt=`grep default_with_oids $CONFDIR/postgresql.conf | wc -l` -if [ $cnt -eq 0 ]; then - cp $CONFDIR/postgresql.conf.org $CONFDIR/postgresql.conf - echo "default_with_oids = true" >> $CONFDIR/postgresql.conf -fi - +#sed 's/^.*default_with_oids.*/default_with_oids = true/i' $CONFDIR/postgresql.conf.org > $CONFDIR/postgresql.conf +#cnt=`grep default_with_oids $CONFDIR/postgresql.conf | wc -l` +#if [ $cnt -eq 0 ]; then +# cp $CONFDIR/postgresql.conf.org $CONFDIR/postgresql.conf +# echo "default_with_oids = true" >> $CONFDIR/postgresql.conf +#fi tmp=`ls -r1 /etc/init.d/postgres*` PGSQL=`echo $tmp | cut -d " " -f 1` diff --git a/scripts/inst_postgres_deb.sh b/scripts/inst_postgres_deb.sh index 49cddc7b6..b0cf9cfe6 100755 --- a/scripts/inst_postgres_deb.sh +++ b/scripts/inst_postgres_deb.sh @@ -98,24 +98,24 @@ if [ $cnt -eq 0 ]; then cat $PGHBA.org >> $PGHBA fi -CONFDIR=`dirname $PGHBA` +#CONFDIR=`dirname $PGHBA` #postgresql.conf anpassen, liegt vermutlich im gleichen Verzeichnis wie pg_hba.conf -if ! [ -f $CONFDIR/postgresql.conf ]; then - echo $FEHLER - echo 'postgresql.conf' nicht gefunden. - echo PostgreSQL selber konfigurieren - ERRCNT=1 -fi - -mv $CONFDIR/postgresql.conf $CONFDIR/postgresql.conf.org +#if ! [ -f $CONFDIR/postgresql.conf ]; then +# echo $FEHLER +# echo 'postgresql.conf' nicht gefunden. +# echo PostgreSQL selber konfigurieren +# ERRCNT=1 +#fi + +#mv $CONFDIR/postgresql.conf $CONFDIR/postgresql.conf.org #Bei der V8.x OID einschalten. -sed 's/^.*default_with_oids.*/default_with_oids = true/i' $CONFDIR/postgresql.conf.org > $CONFDIR/postgresql.conf -cnt=`grep default_with_oids $CONFDIR/postgresql.conf | wc -l` -if [ $cnt -eq 0 ]; then - cp $CONFDIR/postgresql.conf.org $CONFDIR/postgresql.conf - echo "default_with_oids = true" >> $CONFDIR/postgresql.conf -fi +#sed 's/^.*default_with_oids.*/default_with_oids = true/i' $CONFDIR/postgresql.conf.org > $CONFDIR/postgresql.conf +#cnt=`grep default_with_oids $CONFDIR/postgresql.conf | wc -l` +#if [ $cnt -eq 0 ]; then +# cp $CONFDIR/postgresql.conf.org $CONFDIR/postgresql.conf +# echo "default_with_oids = true" >> $CONFDIR/postgresql.conf +#fi PGSQL=`ls -r1 /etc/init.d/postgres* | head -1 -` -- 2.20.1