We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
2 parents 69493c9 + f2b3ca3 commit 13e7055Copy full SHA for 13e7055
1 file changed
packaging/common/cfengine-hub/postinstall.sh
@@ -1060,7 +1060,10 @@ if [ -n "$httpds" ]; then
1060
fi
1061
1062
1063
-(cd /tmp && su cfpostgres -c "$PREFIX/bin/pg_ctl stop -D $PREFIX/state/pg/data -m smart" || su cfpostgres -c "$PREFIX/bin/pg_ctl stop -D $PREFIX/state/pg/data -m fast")
+# wait 5 minutes for smart shutdown to happen, on slower machines it might take a while
1064
+if ! (cd /tmp && su cfpostgres -c "$PREFIX/bin/pg_ctl stop -D $PREFIX/state/pg/data --timeout=300 -m smart"); then
1065
+ su cfpostgres -c "$PREFIX/bin/pg_ctl stop -D $PREFIX/state/pg/data --timeout=300 -m fast"
1066
+fi
1067
1068
# Have to be careful here because httpd/php/bin wants to be root:root
1069
chown root:$MP_APACHE_USER $PREFIX/httpd/php
0 commit comments