diff options
author | Sean Chittenden <seanc@FreeBSD.org> | 2003-01-04 01:10:15 +0000 |
---|---|---|
committer | Sean Chittenden <seanc@FreeBSD.org> | 2003-01-04 01:10:15 +0000 |
commit | 62e1bb44328db7be12796334d8be63e24d48df05 (patch) | |
tree | 3a0c0b58f7ea4a90c14173ab0245e14436624053 /databases/postgresql7/files/pgsql.sh.tmpl | |
parent | I get the stupid award for this port. It NOW installs in the RIGHT place. (diff) |
Update PostgreSQL to 7.3.1[1]. Fixes builds for spac64. Many speed,
security, and feature additions. Reduce diffs between postgresql-devel
port. Re-initdb required when upgrading from previous release. See
release notes for details.
Schemas added are system catalogs updated. ::braces for impact::
http://developer.postgresql.org/docs/postgres/release.html#RELEASE-7-3-1
PR: ports/46701
Submitted by: girgen@pingpong.net
Notes
Notes:
svn path=/head/; revision=72481
Diffstat (limited to 'databases/postgresql7/files/pgsql.sh.tmpl')
-rw-r--r-- | databases/postgresql7/files/pgsql.sh.tmpl | 25 |
1 files changed, 17 insertions, 8 deletions
diff --git a/databases/postgresql7/files/pgsql.sh.tmpl b/databases/postgresql7/files/pgsql.sh.tmpl index d67d9b642f1b..98311c868ac3 100644 --- a/databases/postgresql7/files/pgsql.sh.tmpl +++ b/databases/postgresql7/files/pgsql.sh.tmpl @@ -3,38 +3,47 @@ # $FreeBSD$ # # For postmaster startup options, edit $PGDATA/postgresql.conf +# +# Note that PGDATA is set in ~pgsql/.profile, don't try to manipulate it here! +# PREFIX=%%PREFIX%% PGBIN=${PREFIX}/bin +logfile=/var/log/pgsql case $1 in start) - [ -d ${PREFIX}/lib ] && /sbin/ldconfig -m ${PREFIX}/lib - touch /var/log/pgsql - chmod 600 /var/log/pgsql - chown pgsql:pgsql /var/log/pgsql + touch ${logfile} + chmod 600 ${logfile} + chown pgsql:pgsql ${logfile} [ -x ${PGBIN}/pg_ctl ] && { su -l pgsql -c \ - '[ -d ${PGDATA} ] && exec %%PREFIX%%/bin/pg_ctl start -s -w -l /var/log/pgsql' + "[ -d \${PGDATA} ] && exec ${PREFIX}/bin/pg_ctl start -s -w -l ${logfile}" echo -n ' pgsql' } ;; stop) [ -x ${PGBIN}/pg_ctl ] && { - su -l pgsql -c 'exec %%PREFIX%%/bin/pg_ctl stop -s -m fast' + su -l pgsql -c "exec ${PREFIX}/bin/pg_ctl stop -s -m fast" echo -n ' pgsql' } ;; +restart) + [ -x ${PGBIN}/pg_ctl ] && { + exec su -l pgsql -c "exec ${PREFIX}/bin/pg_ctl restart -s -m fast" + } + ;; + status) [ -x ${PGBIN}/pg_ctl ] && { - exec su -l pgsql -c 'exec %%PREFIX%%/bin/pg_ctl status' + exec su -l pgsql -c "exec ${PREFIX}/bin/pg_ctl status" } ;; *) - echo "usage: `basename $0` {start|stop|status}" >&2 + echo "usage: `basename $0` {start|stop|restart|status}" >&2 exit 64 ;; esac |