[csw-devel] SF.net SVN: gar:[22129] csw/mgar/pkg/postgresql/trunk/files

guengel at users.sourceforge.net guengel at users.sourceforge.net
Sun Oct 6 12:13:05 CEST 2013


Revision: 22129
          http://gar.svn.sourceforge.net/gar/?rev=22129&view=rev
Author:   guengel
Date:     2013-10-06 10:13:05 +0000 (Sun, 06 Oct 2013)
Log Message:
-----------
postgresql/trunk: Added DATACHECKSUMS configuration option. PGLOCALE now en_US.UTF-8 by default.

Modified Paths:
--------------
    csw/mgar/pkg/postgresql/trunk/files/CSWpostgresql-server.postinstall.tmpl
    csw/mgar/pkg/postgresql/trunk/files/changelog.CSW
    csw/mgar/pkg/postgresql/trunk/files/cswpostgresql.tmpl
    csw/mgar/pkg/postgresql/trunk/files/postgresql.conf.tmpl

Modified: csw/mgar/pkg/postgresql/trunk/files/CSWpostgresql-server.postinstall.tmpl
===================================================================
--- csw/mgar/pkg/postgresql/trunk/files/CSWpostgresql-server.postinstall.tmpl	2013-10-06 09:18:25 UTC (rev 22128)
+++ csw/mgar/pkg/postgresql/trunk/files/CSWpostgresql-server.postinstall.tmpl	2013-10-06 10:13:05 UTC (rev 22129)
@@ -36,14 +36,10 @@
              is only recommended for pristine installations.
 
 
-In order to start the PostgreSQL server you can either use
+In order to start the PostgreSQL server use
 
- svcadm enable cswpostgresql- at BASE_VERSION_NODOT@    # Solaris 10+ only
+ svcadm enable cswpostgresql- at BASE_VERSION_NODOT@
 
-or
-
- @sysconfdir@/init.d/cswpostgresql- at BASE_VERSION_NODOT@ start
-
 ---
 EOF
 else

Modified: csw/mgar/pkg/postgresql/trunk/files/changelog.CSW
===================================================================
--- csw/mgar/pkg/postgresql/trunk/files/changelog.CSW	2013-10-06 09:18:25 UTC (rev 22128)
+++ csw/mgar/pkg/postgresql/trunk/files/changelog.CSW	2013-10-06 10:13:05 UTC (rev 22129)
@@ -1,6 +1,10 @@
-postgresql93 (9.3.0,REV=2013.10.05)
+postgresql93 (9.3.0,REV=2013.10.06)
 
   * New upstream release 9.3.0.
 
- -- Rafael Ostertag <raos at opencsw.org>  Sat, 05 Oct 2013 15:52:31 +0200
+  * Database cluster will be initialized using UTF-8 encoding by default.
 
+  * /etc/opt/csw/postgresql-93.conf has new configuration option `DATACHECKSUMS'.
+
+ -- Rafael Ostertag <raos at opencsw.org>  Sun, 06 Oct 2013 11:54:20 +0200
+

Modified: csw/mgar/pkg/postgresql/trunk/files/cswpostgresql.tmpl
===================================================================
--- csw/mgar/pkg/postgresql/trunk/files/cswpostgresql.tmpl	2013-10-06 09:18:25 UTC (rev 22128)
+++ csw/mgar/pkg/postgresql/trunk/files/cswpostgresql.tmpl	2013-10-06 10:13:05 UTC (rev 22129)
@@ -28,11 +28,13 @@
 [ -s @sysconfdir@/${USERCONF} ] && . @sysconfdir@/${USERCONF}
 
 # Defaults
-[ -z "${PGDATA}" ] && PGDATA=@PGDATA@
-[ -z "${SHUTDOWNMODE}" ] && SHUTDOWNMODE=fast
-[ -z "${PGENCODING}" ] && PGENCODING=UTF8
-[ -z "${PGSUPERUSER}" ] && PGSUPERUSER=postgres
-[ -z "${PGLOGOUTPUT}" ] && PGLOGOUTPUT=${PGDATA}/postgresql.log
+PGDATA=${PGDATA- at PGDATA@}
+SHUTDOWNMODE=${SHUTDOWNMODE-fast}
+PGENCODING=${PGENCODING-UTF8}
+PGLOCALE=${PGLOCALE-en_US.UTF-8}
+PGSUPERUSER=${PGSUPERUSER-postgres}
+PGLOGOUTPUT=${PGLOGOUTPUT-${PGDATA}/postgresql.log}
+DATACHECKSUMS=${DATACHECKSUMS-0}
 
 if [ -n "${SERVEROPTS}" ]
 then
@@ -43,8 +45,17 @@
 then
     PGLOCALE="--locale=${PGLOCALE}"
 fi
+case "${DATACHECKSUMS}" in
+    [yY][eE][sS]|[tT][rR][uU][eE]|1)
+	DATACHECKSUMS="-k"
+	;;
+    [nN][oO]|[fF][aA][lL][sS][eE]|0)
+	DATACHECKSUMS=""
+	;;
+esac
 
 
+
 # Exit if postgres user hasn't been created.
 # FIXME: This bit of code is old. It might be obsolete.
 if grep '^postgres:' /etc/passwd >/dev/null; then
@@ -105,7 +116,7 @@
      chown postgres "${PGDATA}"
      chmod 0700 "${PGDATA}"
      echo "Initialising PostgreSQL database..."
-     su postgres -c "\"${PGINIT}\" -D \"${PGDATA}\" -E ${PGENCODING} -U ${PGSUPERUSER} ${PGLOCALE}"
+     su postgres -c "\"${PGINIT}\" -D \"${PGDATA}\" -E ${PGENCODING} -U ${PGSUPERUSER} ${PGLOCALE} ${DATACHECKSUMS}"
      ;;
 
 *)

Modified: csw/mgar/pkg/postgresql/trunk/files/postgresql.conf.tmpl
===================================================================
--- csw/mgar/pkg/postgresql/trunk/files/postgresql.conf.tmpl	2013-10-06 09:18:25 UTC (rev 22128)
+++ csw/mgar/pkg/postgresql/trunk/files/postgresql.conf.tmpl	2013-10-06 10:13:05 UTC (rev 22129)
@@ -50,7 +50,7 @@
 # If none is specified, the locale is inherited from the environment
 # that initdb runs in.
 #
-# Default: <empty>
+# Default: en_US.UTF-8
 #PGLOCALE=en_US.UTF-8
 
 # Selects the user name of the database superuser. This defaults to
@@ -61,3 +61,14 @@
 #
 # Default: postgres
 #PGSUPERUSER=postgres
+
+# Use checksums on data pages to help detect corruption by the I/O
+# system that would otherwise be silent. Enabling checksums may incur
+# a noticeable performance penalty. This option can only be set during
+# initialization, and cannot be changed later. If set, checksums are
+# calculated for all objects, in all databases.
+#
+# Set to 1 to enable checksums. 0 disables checksums.
+#
+# Default: 0
+#DATACHECKSUMS=0
\ No newline at end of file

This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.



More information about the devel mailing list