FATAL: Ident authentication failed for user "calamari"
- Dominant language
- Python
- Stars
- 345
- Forks
- 175
- PR merge metrics
- No merged PRs in 30d
Description
Guys
I am getting this problem on CentOS6 , Centos7 , Salt version 2014 and 2015. This shows that this problem has to do with Calamari.
The problem look like , postgresql database and user are not getting created for some reason.
All the relevant services are getting started but calamari-ctl initialize is throwing error when it comes to database and its user.
Could you please tell me at which step the postgresql database and user is supposed to get created , is it the responsibility of calamari-ctl initialize command to create database and user ?
Could you please verify my sequence of steps :
1) install salt , salt-master , salt-minion package
2) install calamari-server package ( which will install supervisor , postgresql and httpd as dependencies )
3) calamari-ctl initialize command
4) If everything is OK , open dashboard
```
Installing calamari-server package
Running transaction check
Running transaction test
Transaction test succeeded
Running transaction
Installing : httpd-2.4.6-31.el7.centos.x86_64 1/6
Installing : postgresql-9.2.10-2.el7_1.x86_64 2/6
Installing : postgresql-server-9.2.10-2.el7_1.x86_64 3/6
Installing : mod_wsgi-3.4-12.el7_0.x86_64 4/6
Installing : supervisor-3.0-1.el7.noarch 5/6
Installing : calamari-server-1.3.0.1-49_g828960a.el7.centos.x86_64 6/6
setsebool: SELinux is disabled.
setsebool: SELinux is disabled.
Redirecting to /bin/systemctl restart salt-master.service
Redirecting to /bin/systemctl stop supervisord.service
Redirecting to /bin/systemctl start supervisord.service
Redirecting to /bin/systemctl stop httpd.service
Redirecting to /bin/systemctl start httpd.service
Thank you for installing Calamari.
Please run 'calamari-ctl initialize' as root to complete the installation.
Verifying : mod_wsgi-3.4-12.el7_0.x86_64 1/6
Verifying : postgresql-server-9.2.10-2.el7_1.x86_64 2/6
Verifying : postgresql-9.2.10-2.el7_1.x86_64 3/6
Verifying : supervisor-3.0-1.el7.noarch 4/6
Verifying : calamari-server-1.3.0.1-49_g828960a.el7.centos.x86_64 5/6
Verifying : httpd-2.4.6-31.el7.centos.x86_64 6/6
Installed:
calamari-server.x86_64 0:1.3.0.1-49_g828960a.el7.centos
Dependency Installed:
httpd.x86_64 0:2.4.6-31.el7.centos mod_wsgi.x86_64 0:3.4-12.el7_0 postgresql.x86_64 0:9.2.10-2.el7_1 postgresql-server.x86_64 0:9.2.10-2.el7_1 supervisor.noarch 0:3.0-1.el7
Complete!
[root@ceph-node1 ~]# systemctl status postgresql
postgresql.service - PostgreSQL database server
Loaded: loaded (/usr/lib/systemd/system/postgresql.service; disabled)
Active: inactive (dead)
[root@ceph-node1 ~]# supervisorctl status
carbon-cache RUNNING pid 5116, uptime 0:01:25
cthulhu STARTING
[root@ceph-node1 ~]#
[root@ceph-node1 ~]# calamari-ctl initialize
[INFO] Loading configuration..
[INFO] Starting/enabling salt...
[INFO] Starting/enabling postgres...
[ERROR] (OperationalError) could not connect to server: Connection refused
Is the server running on host "localhost" (::1) and accepting
TCP/IP connections on port 5432?
could not connect to server: Connection refused
Is the server running on host "localhost" (127.0.0.1) and accepting
TCP/IP connections on port 5432?
None None
[ERROR] We are sorry, an unexpected error occurred. Debugging information has
been written to a file at '/tmp/2015-06-25_1419.txt', please include this when seeking technical
support.
[root@ceph-node1 ~]#
[root@ceph-node1 ~]# supervisorctl status
carbon-cache RUNNING pid 5116, uptime 0:02:45
cthulhu RUNNING pid 6308, uptime 0:00:01
[root@ceph-node1 ~]#
[root@ceph-node1 ~]# service postgresql status
Redirecting to /bin/systemctl status postgresql.service
postgresql.service - PostgreSQL database server
Loaded: loaded (/usr/lib/systemd/system/postgresql.service; disabled)
Active: inactive (dead)
[root@ceph-node1 ~]#
[root@ceph-node1 ~]#
After restarting the node
[root@ceph-node1 calamari]#
[root@ceph-node1 calamari]# calamari-ctl initialize
[INFO] Loading configuration..
[INFO] Starting/enabling salt...
[INFO] Starting/enabling postgres...
[ERROR] (OperationalError) FATAL: Ident authentication failed for user "calamari"
None None
[ERROR] We are sorry, an unexpected error occurred. Debugging information has
been written to a file at '/tmp/2015-06-25_1426.txt', please include this when seeking technical
support.
[root@ceph-node1 calamari]#
[root@ceph-node1 calamari]# service postgresql status
Redirecting to /bin/systemctl status postgresql.service
postgresql.service - PostgreSQL database server
Loaded: loaded (/usr/lib/systemd/system/postgresql.service; enabled)
Active: active (running) since Thu 2015-06-25 17:22:07 EEST; 6min ago
Main PID: 1322 (postgres)
CGroup: /system.slice/postgresql.service
├─1322 /usr/bin/postgres -D /var/lib/pgsql/data -p 5432
├─1358 postgres: logger process
├─1397 postgres: checkpointer process
├─1398 postgres: writer process
├─1399 postgres: wal writer process
├─1400 postgres: autovacuum launcher process
└─1401 postgres: stats collector process
Jun 25 17:22:06 ceph-node1 systemd[1]: Starting PostgreSQL database server...
Jun 25 17:22:07 ceph-node1 systemd[1]: Started PostgreSQL database server.
[root@ceph-node1 calamari]#
[root@ceph-node1 calamari]#
[root@ceph-node1 calamari]# supervisorctl status
carbon-cache RUNNING pid 4546, uptime 0:04:26
cthulhu STARTING
[root@ceph-node1 calamari]#
```
Contributor guide
No contributing guide indexed for this repository
Research direction
Start with the calamari-ctl initialize entry point and review the PostgreSQL startup and authentication steps shown in the report. Use the recorded /tmp/2015-06-25_1419.txt debugging output and verify the initialization sequence; done means initialization completes without the connection-refused or Ident authentication errors.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- centos, postgresql, python
- Domain
- backend, databases
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 25/100