diff options
author | Vadim B. Mikheev <vadim4o@yahoo.com> | 2000-10-16 14:52:28 +0000 |
---|---|---|
committer | Vadim B. Mikheev <vadim4o@yahoo.com> | 2000-10-16 14:52:28 +0000 |
commit | 2c7de17b075baf7be270acf4d541bd4b17047e4c (patch) | |
tree | c9b7aff45678be41380551d87b6168f317064934 /src/bin/initdb/initdb.sh | |
parent | 07a55ebf646eb244f52afc11fcca189b0d006970 (diff) | |
download | postgresql-2c7de17b075baf7be270acf4d541bd4b17047e4c.tar.gz postgresql-2c7de17b075baf7be270acf4d541bd4b17047e4c.zip |
New file naming. Database OID is used as "tablespace" id and
relation OID is used as file node on creation but may be changed later
if required. Regression Tests Approved (c) -:)))
Diffstat (limited to 'src/bin/initdb/initdb.sh')
-rw-r--r-- | src/bin/initdb/initdb.sh | 25 |
1 files changed, 6 insertions, 19 deletions
diff --git a/src/bin/initdb/initdb.sh b/src/bin/initdb/initdb.sh index 6b7e474d5e8..86d8d0289ea 100644 --- a/src/bin/initdb/initdb.sh +++ b/src/bin/initdb/initdb.sh @@ -23,7 +23,7 @@ # # Copyright (c) 1994, Regents of the University of California # -# $Header: /cvsroot/pgsql/src/bin/initdb/Attic/initdb.sh,v 1.104 2000/09/29 13:38:02 petere Exp $ +# $Header: /cvsroot/pgsql/src/bin/initdb/Attic/initdb.sh,v 1.105 2000/10/16 14:52:21 vadim Exp $ # #------------------------------------------------------------------------- @@ -414,8 +414,8 @@ fi # # CREATE TEMPLATE1 DATABASE -rm -rf "$PGDATA"/base/template1 || exit_nicely -mkdir "$PGDATA"/base/template1 || exit_nicely +rm -rf "$PGDATA"/base/1 || exit_nicely +mkdir "$PGDATA"/base/1 || exit_nicely if [ "$debug" = yes ] then @@ -427,7 +427,7 @@ fi BACKENDARGS="-boot -C -F -D$PGDATA $BACKEND_TALK_ARG" FIRSTRUN="-boot -x -C -F -D$PGDATA $BACKEND_TALK_ARG" -echo "Creating template database in $PGDATA/base/template1" +echo "Creating template database in $PGDATA/base/1" [ "$debug" = yes ] && echo "Running: $PGPATH/postgres $FIRSTRUN template1" cat "$TEMPLATE1_BKI" \ @@ -435,7 +435,7 @@ cat "$TEMPLATE1_BKI" \ | "$PGPATH"/postgres $FIRSTRUN template1 \ || exit_nicely -echo $short_version > "$PGDATA"/base/template1/PG_VERSION || exit_nicely +echo $short_version > "$PGDATA"/base/1/PG_VERSION || exit_nicely ########################################################################## @@ -450,6 +450,7 @@ then cat "$GLOBAL_BKI" \ | sed -e "s/POSTGRES/$POSTGRES_SUPERUSERNAME/g" \ -e "s/PGUID/$POSTGRES_SUPERUSERID/g" \ + -e "s/ENCODING/$MULTIBYTEID/g" \ | "$PGPATH"/postgres $BACKENDARGS template1 \ || exit_nicely @@ -459,20 +460,6 @@ then cp "$POSTGRESQL_CONF_SAMPLE" "$PGDATA"/postgresql.conf || exit_nicely chmod 0600 "$PGDATA"/pg_hba.conf "$PGDATA"/postgresql.conf - echo "Adding template1 database to pg_database" - - echo "open pg_database" > "$TEMPFILE" - echo "insert (template1 $POSTGRES_SUPERUSERID $MULTIBYTEID template1)" >> $TEMPFILE - #echo "show" >> "$TEMPFILE" - echo "close pg_database" >> "$TEMPFILE" - - [ "$debug" = yes ] && echo "Running: $PGPATH/postgres $BACKENDARGS template1 < $TEMPFILE" - - "$PGPATH"/postgres $BACKENDARGS template1 < "$TEMPFILE" - # Gotta remove that temp file before exiting on error. - retval="$?" - rm -f "$TEMPFILE" || exit_nicely - [ "$retval" -ne 0 ] && exit_nicely fi |