This is the mail archive of the
cluster-cvs@sourceware.org
mailing list for the cluster.
cluster: RHEL5 - rgmanager: Make postgres-8.sh use su instead of sudo
- From: Lon Hohberger <lon at fedoraproject dot org>
- To: cluster-cvs-relay at redhat dot com
- Date: Wed, 3 Dec 2008 20:19:17 +0000 (UTC)
- Subject: cluster: RHEL5 - rgmanager: Make postgres-8.sh use su instead of sudo
Gitweb: http://git.fedorahosted.org/git/cluster.git?p=cluster.git;a=commitdiff;h=116b8d72fdde451a53838b21e4b713e05b822016
Commit: 116b8d72fdde451a53838b21e4b713e05b822016
Parent: cac8a502dd16197b3af7eed95686b13f473b900d
Author: Nicolas MONNET <nicolas.monnet@ingenico.com>
AuthorDate: Wed Dec 3 15:18:34 2008 -0500
Committer: Lon Hohberger <lhh@redhat.com>
CommitterDate: Wed Dec 3 15:18:34 2008 -0500
rgmanager: Make postgres-8.sh use su instead of sudo
Resolves part of #462910
---
rgmanager/src/resources/postgres-8.sh | 4 ++--
1 files changed, 2 insertions(+), 2 deletions(-)
diff --git a/rgmanager/src/resources/postgres-8.sh b/rgmanager/src/resources/postgres-8.sh
index 766646f..bfc3d59 100755
--- a/rgmanager/src/resources/postgres-8.sh
+++ b/rgmanager/src/resources/postgres-8.sh
@@ -160,8 +160,8 @@ start()
generate_config_file "$OCF_RESKEY_config_file" "$PSQL_gen_config_file" "$ip_addresses"
- sudo -u "$OCF_RESKEY_postmaster_user" $PSQL_POSTMASTER -c config_file="$PSQL_gen_config_file" \
- $OCF_RESKEY_postmaster_options &> /dev/null &
+ su - "$OCF_RESKEY_postmaster_user" -c "$PSQL_POSTMASTER -c config_file=\"$PSQL_gen_config_file\" \
+ $OCF_RESKEY_postmaster_options" &> /dev/null &
if [ $? -ne 0 ]; then
clog_service_start $CLOG_FAILED