You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
20 lines
419 B
20 lines
419 B
#!/bin/bash
|
|
# Author: Athmane Madjoudj <athmanem@gmail.com>
|
|
|
|
t_Log "Running $0 - initializing and starting PostgreSQL"
|
|
|
|
t_Log "Initialize PostgreSQL DB "
|
|
if [ $centos_ver -ge 8 ]; then
|
|
postgresql-setup --initdb
|
|
elif (t_GetPkgRel postgresql | grep -q el7) then
|
|
postgresql-setup initdb
|
|
elif (t_GetPkgRel postgresql | grep -q el6) then
|
|
service postgresql initdb
|
|
fi
|
|
|
|
t_ServiceControl postgresql start
|
|
sleep 15
|
|
|
|
|
|
|