git://git.onelab.eu
/
myplc.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
8516771
)
Initialize the database correctly on F7+.
author
Daniel Hokka Zakrisson
<dhokka@cs.princeton.edu>
Thu, 29 Nov 2007 21:45:48 +0000
(21:45 +0000)
committer
Daniel Hokka Zakrisson
<dhokka@cs.princeton.edu>
Thu, 29 Nov 2007 21:45:48 +0000
(21:45 +0000)
plc.d/postgresql
patch
|
blob
|
history
diff --git
a/plc.d/postgresql
b/plc.d/postgresql
index
f5ad0d0
..
43fc7aa
100755
(executable)
--- a/
plc.d/postgresql
+++ b/
plc.d/postgresql
@@
-46,6
+46,12
@@
postgresql_start ()
return 1
}
+postgresql_init ()
+{
+ service postgresql initdb &> /dev/null || :
+ postgresql_start
+}
+
case "$1" in
start)
if [ "$PLC_DB_ENABLED" != "1" ] ; then
@@
-69,7
+75,7
@@
case "$1" in
# PostgreSQL must be started at least once to bootstrap
# /var/lib/pgsql/data
if [ ! -f $postgresql_conf ] ; then
- postgresql_
star
t
+ postgresql_
ini
t
check
service postgresql stop
check