Open link in a new tab

Content

Expand project menu

Centos 7 - New install failed no connection

Hi dev's and folks,

I want to install for internal private usage a openproject installation. I have Centos 7 installed and I deactivated the firewall and SElinux. I created a new user with sudo privileges but I can't install OpenProject because of this error. The errors means I can't connect to the server because of a missing file or path. Maybe the server is not running or not acception local connections?

Created symlink from /etc/systemd/system/multi-user.target.wants/postgresql-10.service to /usr/lib/systemd/system/postgresql-10.service.
psql: konnte nicht mit dem Server verbinden: Datei oder Verzeichnis nicht gefunden
        Läuft der Server lokal und akzeptiert er Verbindungen
        auf dem Unix-Domain-Socket »/var/run/postgresql/.s.PGSQL.45432«?

I really don't know what to do I have tried to install it with root but I get the same error. I have restored my vm several times before I wrote here but at the moment I don't have any ideas. 

Can someone help? 

Thanks

Message actions

Hi,
I used the configure script and got the same error and i just figured out a solution.
The steps i followed to make it work:

  1. fully cleaned the database "rm -rf /var/lib/pgsql/10/data/"
  2. re-init the database (follow the official manual installation on the postgresql part....)
  3. edit the: /var/lib/pgsql/10/data/pg_hba.conf changing the method to TRUST where is IDENT
  4. openproject reconfigure

Ale

Message actions

Hi Ale,

Thank you so, I'm not the only one ;=) but i'm always the first one. It doesn't matter which linux software I want to install i always get in trouble.

  1. re-init the database (follow the official manual installation on the postgresql part....) <- Can you point me the link?

Can someone from the dev's have a look at this. Because it looks like a packaging issue on centos 7. I try it now again and set my VM back ;).... I will give you an update soon.....

UPDATE:

The problem is still the same on a fresh centos 7 installation. So you won't be able to install it with the normal installer.

I will try the steps from Ale if I get some more info... first attempt I wasn't able to fix it.

Total download size: 13 M
Installed size: 52 M
Downloading packages:
(1/4): libicu-50.1.2-17.el7.x86_64.rpm                                                                                                    | 6.9 MB  00:00:00     
warning: /var/cache/yum/x86_64/7/pgdg10/packages/postgresql10-10.8-1PGDG.rhel7.x86_64.rpm: Header V4 DSA/SHA1 Signature, key ID 442df0f8: NOKEY MB  --:--:-- ETA 
Public key for postgresql10-10.8-1PGDG.rhel7.x86_64.rpm is not installed
(2/4): postgresql10-10.8-1PGDG.rhel7.x86_64.rpm                                                                                           | 1.6 MB  00:00:00     
(3/4): postgresql10-libs-10.8-1PGDG.rhel7.x86_64.rpm                                                                                      | 355 kB  00:00:00     
(4/4): postgresql10-server-10.8-1PGDG.rhel7.x86_64.rpm                                                                                    | 4.5 MB  00:00:00     
-----------------------------------------------------------------------------------------------------------------------------------------------------------------
Total                                                                                                                             12 MB/s |  13 MB  00:00:01     
Retrieving key from file:///etc/pki/rpm-gpg/RPM-GPG-KEY-PGDG
Importing GPG key 0x442DF0F8:
 Userid     : "PostgreSQL RPM Building Project <pgsqlrpms-hackers@pgfoundry.org>"
 Fingerprint: 68c9 e2b9 1a37 d136 fe74 d176 1f16 d2e1 442d f0f8
 Package    : pgdg-redhat-repo-42.0-4.noarch (installed)
 From       : /etc/pki/rpm-gpg/RPM-GPG-KEY-PGDG
Running transaction check
Running transaction test
Transaction test succeeded
Running transaction
  Installing : postgresql10-libs-10.8-1PGDG.rhel7.x86_64                                                                                                     1/4 
  Installing : libicu-50.1.2-17.el7.x86_64                                                                                                                   2/4 
  Installing : postgresql10-10.8-1PGDG.rhel7.x86_64                                                                                                          3/4 
  Installing : postgresql10-server-10.8-1PGDG.rhel7.x86_64                                                                                                   4/4 
  Verifying  : libicu-50.1.2-17.el7.x86_64                                                                                                                   1/4 
  Verifying  : postgresql10-server-10.8-1PGDG.rhel7.x86_64                                                                                                   2/4 
  Verifying  : postgresql10-10.8-1PGDG.rhel7.x86_64                                                                                                          3/4 
  Verifying  : postgresql10-libs-10.8-1PGDG.rhel7.x86_64                                                                                                     4/4 

Installed:
  postgresql10.x86_64 0:10.8-1PGDG.rhel7                                      postgresql10-server.x86_64 0:10.8-1PGDG.rhel7                                     

Dependency Installed:
  libicu.x86_64 0:50.1.2-17.el7                                            postgresql10-libs.x86_64 0:10.8-1PGDG.rhel7                                           

Complete!
Initializing database ... OK

Created symlink from /etc/systemd/system/multi-user.target.wants/postgresql-10.service to /usr/lib/systemd/system/postgresql-10.service.
psql: konnte nicht mit dem Server verbinden: Datei oder Verzeichnis nicht gefunden
        Läuft der Server lokal und akzeptiert er Verbindungen
        auf dem Unix-Domain-Socket »/var/run/postgresql/.s.PGSQL.45432«?
Message actions

Yes exactly the same issue it's definitely an issue with postgres. 
Yesteday i spent most of my day trying to solve this thing. I managed to make it work but the way i solved it it's pretty unsafe. Setting trust to postgresql means everyone who has access to the machine is able to access the database as well. I ended up using a Debian Server (the setup just works) but i would be way happier to use a CentOS install since my network is all based on that distro.

Here's the link to the manual setup: https://github.com/opf/openproject/blob/stable/8/docs/installation/manual/README.md

Ale

Message actions

As a side note on the debian install the pg_hba.conf looks like this:

# Database administrative login by Unix domain socket
local   all             postgres                                peer
# TYPE  DATABASE        USER            ADDRESS                 METHOD
# "local" is for Unix domain socket connections only
local   all             all                                     peer
# IPv4 local connections:
host    all             all             127.0.0.1/32            md5
# IPv6 local connections:
host    all             all             ::1/128                 md5
# Allow replication connections from localhost, by a user with the
# replication privilege.
local   replication     all                                     peer
host    replication     all             127.0.0.1/32            md5
host    replication     all             ::1/128                 md5

But when i try to set it the same way on centos it fails...
Ale

Message actions

Hello, sorry for the inconvenience. I am looking into this issue. I'll update this ticket when it's fixed.

Message actions

Thank you Ale,

Yes this is not a solution "TRUST". Hmm yes ok, Ubuntu is ok but as you: I prefer CentOS.

Hi Cyril
Let me know when it's fixed. I can test it very fast since my snapshot is still available ;).

Thanks,

Message actions

A newer package has been released that fixes this issue. If you can, I would recommend reinstalling from scratch.

If not possible, you will need to purge the postgresql-server package, and remove /usr/lib/systemd/system/postgresql.service and /var/lib/pgsql for the installer to attempt to reinstall postgres10 automatically. Only do this after checking that you don't have anything valuable in that postgres instance (it was installed by OpenProject so there should only be the openproject database in there).

Message actions

Thanks, i'm gonna try right now! I'll let you know asap.
Ale

Message actions

Restored virtual machine - nothing was installed before that it's a blank system.

Then i did the following: 

sudo wget -O /etc/yum.repos.d/openproject-ce.repo \
 https://dl.packager.io/srv/opf/openproject-ce/stable/8/installer/el/7.repo


sudo yum install openproject

sudo openproject configure

But same error:

Installed:
  postgresql10.x86_64 0:10.8-1PGDG.rhel7                                      postgresql10-server.x86_64 0:10.8-1PGDG.rhel7                                     

Dependency Installed:
  libicu.x86_64 0:50.1.2-17.el7                                            postgresql10-libs.x86_64 0:10.8-1PGDG.rhel7                                           

Complete!
Initializing database ... OK

Created symlink from /etc/systemd/system/multi-user.target.wants/postgresql-10.service to /usr/lib/systemd/system/postgresql-10.service.
psql: konnte nicht mit dem Server verbinden: Datei oder Verzeichnis nicht gefunden
        Läuft der Server lokal und akzeptiert er Verbindungen
        auf dem Unix-Domain-Socket »/var/run/postgresql/.s.PGSQL.45432«?
Message actions

Shouldn't it be version 9?
sudo wget -O /etc/yum.repos.d/openproject-ce.repo \
https://dl.packager.io/srv/opf/openproject-ce/stable/9/installer/el/7.repo

Message actions

I can confirm it works! Thanks a lot!
Ale

Message actions

Same here... I can confirm in V.9.01 it's working fine the installation on CentOS 7. 

Thank you for fixing that.

Message actions

Hi all together

I've exactly the same problem, but with the V10.2. I've created also a new clean vm and installed with the instruction. But now there's exatly the same issue, after the configuration:

Installiert:
  postgresql10.x86_64 0:10.11-1PGDG.rhel7
  postgresql10-server.x86_64 0:10.11-1PGDG.rhel7

Abhängigkeit installiert:
  postgresql10-libs.x86_64 0:10.11-1PGDG.rhel7

Komplett!
Initializing database ... OK

Created symlink from /etc/systemd/system/multi-user.target.wants/postgresql-10.service to /usr/lib/systemd/system/postgresql-10.service.
psql: konnte nicht mit dem Server verbinden: Datei oder Verzeichnis nicht gefunden
        Läuft der Server lokal und akzeptiert er Verbindungen
        auf dem Unix-Domain-Socket »/var/run/postgresql/.s.PGSQL.45432«?

Could it be, there is a new bug? What can I test?

Thanks for reply

padi

Message actions

Patric Distel wrote:

Hi all together

I've exactly the same problem, but with the V10.2. I've created also a new clean vm and installed with the instruction. But now there's exatly the same issue, after the configuration:

I tested now with an other centos 7 vm (not our template) to be sure there is nothing on it and I have stil the exact the same error.

Anyone an idea?