root <[EMAIL PROTECTED]> writes:
>> action "Starting PostgreSQL: " su -l $PGUSER -c "$DAEMON start -D '$PGDATA' -l
>$PGLOG"
I dunno what "action" is, but I'll bet that the problem with this script
is that the arguments of su end up getting scanned twice in the shell
script, once when action is called and again somewhere inside it,
so that the stuff after -c ends up looking like multiple arguments to
su, not just one argument.
If there are only two levels of scanning, it might work to say
action "Starting PostgreSQL: " su -l $PGUSER -c "'$DAEMON start -D $PGDATA -l $PGLOG'"
The idea here is to substitute for the $-variables the first time
through, then have a single-quoted string seen by the second rescan.
A complaint to the author of the "action" subroutine might be in order
too, since his sloppiness is forcing you into some ugly and rather
error-prone pushups.
regards, tom lane
---------------------------(end of broadcast)---------------------------
TIP 6: Have you searched our list archives?
http://www.postgresql.org/search.mpl