diff --git a/tests/p_postgresql/1-config-postgresql.sh b/tests/p_postgresql/1-config-postgresql.sh
index 6f51a5c..8058422 100755
--- a/tests/p_postgresql/1-config-postgresql.sh
+++ b/tests/p_postgresql/1-config-postgresql.sh
@@ -4,12 +4,13 @@
 t_Log "Running $0 - initializing and starting PostgreSQL"
 
 t_Log "Initialize PostgreSQL DB "
-if (t_GetPkgRel postgresql | grep -q el7) then
+if (t_GetPkgRel postgresql | grep -q el8) then
+   postgresql-setup --initdb
+elif (t_GetPkgRel postgresql | grep -q el7) then
    postgresql-setup initdb
-else if (t_GetPkgRel postgresql | grep -q el6) then
+elif (t_GetPkgRel postgresql | grep -q el6) then
    service postgresql initdb
 fi
-fi
 
 t_ServiceControl postgresql start
 sleep 15