i have a question need you help.
on /osp/local/mhoe/liuns/.ssh/config
if UseRsh = yes.
i can rsh localhost
vns101 linus> rsh localhost
Last login: Tue Mar 1 14:06:14 from psmf
mail: Cannot stat mailfile
You have mail.
[1] 18259
End of linus profile
vns101 linus>
but i cannot rsh to remote host:
vns101 linus> rsh 10.51.100.197
^Cvns101 linus>
if UseRsh = no.
i cannot rsh localhost
vns101 linus> rsh localhost
vns101 linus>
but i can rsh to remote host
vns101 linus> rsh 10.51.100.197
Last login: Tue Mar 1 14:08:15 2022
[1] 98100
End of linus profile
tis101 linus>
Related
I am trying to create master slave replication physically with postgresql11 in debian10. I got same errors from different linux dists so is it something related making the replication in same computer? Or something related with master-slave accounts ?
root#dlp:~# vi /etc/postgresql/11/main/postgresql.conf
listen_addresses = '*'
wal_level = replica
synchronous_standby_names = '*'
wal_keep_segments = 10
I configured the pg_hba.conf as follows:
#host replication all 127.0.0.1/32 md5
#host replication all ::1/128 md5
host replication rep_user 127.0.0.1/32 trust
host replication rep_user 10.0.0.30/32 trust
host replication rep_user 10.0.0.51/32 trust
After this segment:
#i didnt create new user as node1 i just used my root/postgres account for all the processes
root#node01:~# systemctl stop postgresql
root#node01:~# rm -rf /var/lib/postgresql/11/main/*
root#node01:~# su - postgres
postgres#node01:~$ pg_basebackup -R -h dlp.srv.world -U rep_user -D /var/lib/postgresql/11/main -P
I got the following error:
pg_basebackup: could not connect to server: could not connect to server: Connection refused
Is the server running on host "dlp.srv.world" (180.43.145.38) and accepting
TCP/IP connections on port 5432?
also in the root account postgres is working fine but i doest show that port 5432 listening?
netstat -nlt
tcp 0 0 127.0.0.1:631 0.0.0.0:* LISTEN
tcp6 0 0 ::1:631 :::* LISTEN
when i check the status of "postgresql" is says active but when i type :
systemctl status postgresql#11-main
Dec 14 06:20:52 debian postgresql#11-main[6260]: Error: /usr/lib/postgresql/11/bin/pg_ctl /
Dec 14 06:20:52 debian postgresql#11-main[6260]: pg_ctl: directory "/var/lib/postgresql/11/
Dec 14 06:20:52 debian systemd[1]: postgresql#11-main.service: Can't open PID file /run/pos
Dec 14 06:20:52 debian systemd[1]: postgresql#11-main.service: Failed with result 'protocol
Dec 14 06:20:52 debian systemd[1]: Failed to start PostgreSQL Cluster 11-main.
i got that error.
I'm having a problem with init.d script on my Raspberry PI 4 (4GB) with Raspbian 10.
I've followed the guide on the official docs and compiled RethinkDB without any problem.
Then I've configured as described in the Deployment docs.
Created conf file in /etc/rethinkdb/instances.d/<conf_name>.conf;
Copied init.d script sudo cp /home/pi/rethinkdb-2.4.1/packaging/assets/init/rethinkdb /etc/init.d/rethinkdb
Added Default Runlevel sudo update-rc.d rethinkdb defaults
I can start the server with command rethinkdb --config-file /etc/rethinkdb/instances.d/instance1.config and it gives me no problem
pi#homeserverpi:~ $ rethinkdb --config-file /etc/rethinkdb/instances.d/instance1.conf
WARNING: ignoring --server-name because this server already has a name.
Running rethinkdb 2.4.1 (CLANG 7.0.1 (tags/RELEASE_701/final))...
Running on Linux 5.4.72-v7l+ armv7l
Loading data from directory /home/pi/rethinkdb_data
Listening for intracluster connections on port 29015
Listening for client driver connections on port 28015
Listening for administrative HTTP connections on port 8182
Listening on cluster addresses: 127.0.0.1, 192.168.1.3, ::1, fe80::38b8:6928:e4fd:1a9c%3
Listening on driver addresses: 127.0.0.1, 192.168.1.3, ::1, fe80::38b8:6928:e4fd:1a9c%3
Listening on http addresses: 127.0.0.1, 192.168.1.3, ::1, fe80::38b8:6928:e4fd:1a9c%3
Server ready, "homeserverpi_9x0" 00eb027b-181c-4a15-a170-8ba8299f4f3f
But when I try to start the service it gives me this
sudo /etc/init.d/rethinkdb start rethinkdb: instance1: Starting instance. (logging to '/var/lib/rethinkdb/instance1/data/log_file')
/etc/init.d/rethinkdb: 224: /etc/init.d/rethinkdb: /usr/bin/rethinkdb: Permission denied
Permissions
pi#homeserverpi:~ $ ls -alh /etc/init.d/rethinkdb
-rwxr-xr-x 1 root root 7.5K Nov 30 00:20 /etc/init.d/rethinkdb
pi#homeserverpi:~ $ ls -alh /usr/bin/rethinkdb/
total 40K
drwxr-xr-x 2 root root 4.0K Nov 29 23:06 .
drwxr-xr-x 3 root root 36K Nov 29 23:06 ..
Can someone please help me on this?
Thank you
My system is ubuntu 16.04.
It's fine when i use ssh in terminal.
But when i use ssh-remove in vscode. There's always error about failed to ln vscode-remote-lock.root.xxxxx. \
So i delete the whole .vscode-server folder (include itself).
However the error still occurs.
Here is the log
[21:45:22.437] Log Level: 2
[21:45:22.438] remote-ssh#0.51.0
[21:45:22.438] linux x64
[21:45:22.439] SSH Resolver called for "ssh-remote+matrix5", attempt 1
[21:45:22.440] SSH Resolver called for host: matrix5
[21:45:22.440] Setting up SSH remote "matrix5"
[21:45:22.442] Acquiring local install lock: /tmp/vscode-remote-ssh-matrix5-install.lock
[21:45:22.450] Looking for existing server data file at /home/daijunjie/.config/Code/User/globalStorage/ms-vscode-remote.remote-ssh/vscode-ssh-host-matrix5-a0479759d6e9ea56afa657e454193f72aef85bd0-0.51.0/data.json
[21:45:22.459] Using commit id "a0479759d6e9ea56afa657e454193f72aef85bd0" and quality "stable" for server
[21:45:22.464] Install and start server if needed
[21:45:22.477] Checking ssh with "ssh -V"
[21:45:22.484] > OpenSSH_7.2p2 Ubuntu-4ubuntu2.10, OpenSSL 1.0.2g 1 Mar 2016
[21:45:22.485] askpass server listening on /run/user/1000/vscode-ssh-askpass-66a057c15bb13b290ef0a13841206f52de4b6934.sock
[21:45:22.486] Spawning local server with {"ipcHandlePath":"/run/user/1000/vscode-ssh-askpass-2e95ed95f8d502946556d089375e3fc7c0a83a60.sock","sshCommand":"ssh","sshArgs":["-v","-T","-D","33509","-o","ConnectTimeout=15","matrix5"],"dataFilePath":"/home/daijunjie/.config/Code/User/globalStorage/ms-vscode-remote.remote-ssh/vscode-ssh-host-matrix5-a0479759d6e9ea56afa657e454193f72aef85bd0-0.51.0/data.json"}
[21:45:22.486] Local server env: {"DISPLAY":"1","ELECTRON_RUN_AS_NODE":"1","SSH_ASKPASS":"/home/daijunjie/.vscode/extensions/ms-vscode-remote.remote-ssh-0.51.0/out/local-server/askpass.sh","VSCODE_SSH_ASKPASS_NODE":"/usr/share/code/code","VSCODE_SSH_ASKPASS_MAIN":"/home/daijunjie/.vscode/extensions/ms-vscode-remote.remote-ssh-0.51.0/out/askpass-main.js","VSCODE_SSH_ASKPASS_HANDLE":"/run/user/1000/vscode-ssh-askpass-66a057c15bb13b290ef0a13841206f52de4b6934.sock"}
[21:45:22.489] Spawned 13753
[21:45:22.570] > local-server> Spawned ssh: 13761
[21:45:22.571] stderr> OpenSSH_7.2p2 Ubuntu-4ubuntu2.10, OpenSSL 1.0.2g 1 Mar 2016
[21:45:22.748] stderr> debug1: Server host key: ecdsa-sha2-nistp256 SHA256:t5baR11kNfeoUNE2DkSopt8EuiL2Yw4Ki9KjcKoITiI
[21:45:22.889] stderr> No Kerberos credentials available
[21:45:22.889] stderr>
[21:45:22.890] stderr> No Kerberos credentials available
[21:45:22.890] stderr>
[21:45:22.891] stderr>
[21:45:22.892] stderr>
[21:45:22.892] stderr> No Kerberos credentials available
[21:45:22.893] stderr>
[21:45:23.013] Got askpass request: {"request":"daijunjie#matrix5's password:"}
[21:45:23.014] Showing password prompt
[21:45:23.015] Listening for interwindow password on /run/user/1000/vscode-ssh-askpass-f7c76e17b4f9729a3485ae2ea663cb3b0ed9b124.sock
[21:45:23.015] Writing password prompt to globalState
[21:45:26.975] Got password response
[21:45:26.975] Interactor gave response: *********
[21:45:26.977] Cleaning up other-window auth server
[21:45:27.208] stderr> Authenticated to matrix5 ([172.16.30.205]:22).
[21:45:27.270] > Last failed login: Thu Sep 3 21:41:40 CST 2020 from 10.8.117.207 on ssh:notty
> There were 19 failed login attempts since the last successful login.
[21:45:27.682] > ready: fe8e17d6d674
[21:45:27.714] > Linux 3.10.0-327.el7.x86_64 #1 SMP Thu Nov 19 22:10:57 UTC 2015
[21:45:27.715] Platform: linux
[21:45:27.760] > fe8e17d6d674: running
[21:45:27.804] > Acquiring lock on /home/daijunjie/.vscode-server/bin/a0479759d6e9ea56afa657e454193f72aef85bd0/vscode-remote-lock.root.a0479759d6e9ea56afa657e454193f72aef85bd0
[21:45:27.806] > \ln /home/daijunjie/.vscode-server/bin/a0479759d6e9ea56afa657e454193f72aef85bd0/vscode-remote-lock.root.a0479759d6e9ea56afa657e454193f72aef85bd0.target /home/daijunjie/.vscode-server/bin/a0479759d6e9ea56afa657e454193f72aef85bd0/vscode-remote-lock.root.a0479759d6e9ea56afa657e454193f72aef85bd0
[21:45:27.810] > Installation already in progress...
> fe8e17d6d674##24##
[21:45:27.811] Received install output: fe8e17d6d674##24##
[21:45:27.812] Server installation process already in progress - waiting and retrying
[21:45:27.813] Terminating local server
[21:45:27.815] stderr> ln: 无法创建硬链接"/home/daijunjie/.vscode-server/bin/a0479759d6e9ea56afa657e454193f72aef85bd0/vscode-remote-lock.root.a0479759d6e9ea56afa657e454193f72aef85bd0": 文件已存在
[21:45:27.826] Local server exit: 15
[21:45:28.823] askpass server listening on /run/user/1000/vscode-ssh-askpass-306602990a24ee3d283dacc59c308749803f4079.sock
[21:45:28.824] Spawning local server with {"ipcHandlePath":"/run/user/1000/vscode-ssh-askpass-2b79fa3a864c0ae128b0977807dba070c415f490.sock","sshCommand":"ssh","sshArgs":["-v","-T","-D","33509","-o","ConnectTimeout=15","matrix5"],"dataFilePath":"/home/daijunjie/.config/Code/User/globalStorage/ms-vscode-remote.remote-ssh/vscode-ssh-host-matrix5-a0479759d6e9ea56afa657e454193f72aef85bd0-0.51.0/data.json"}
[21:45:28.824] Local server env: {"DISPLAY":"1","ELECTRON_RUN_AS_NODE":"1","SSH_ASKPASS":"/home/daijunjie/.vscode/extensions/ms-vscode-remote.remote-ssh-0.51.0/out/local-server/askpass.sh","VSCODE_SSH_ASKPASS_NODE":"/usr/share/code/code","VSCODE_SSH_ASKPASS_MAIN":"/home/daijunjie/.vscode/extensions/ms-vscode-remote.remote-ssh-0.51.0/out/askpass-main.js","VSCODE_SSH_ASKPASS_HANDLE":"/run/user/1000/vscode-ssh-askpass-306602990a24ee3d283dacc59c308749803f4079.sock"}
[21:45:28.836] Spawned 13775
[21:45:28.925] > local-server> Spawned ssh: 13783
[21:45:28.926] stderr> OpenSSH_7.2p2 Ubuntu-4ubuntu2.10, OpenSSL 1.0.2g 1 Mar 2016
[21:45:29.104] stderr> debug1: Server host key: ecdsa-sha2-nistp256 SHA256:t5baR11kNfeoUNE2DkSopt8EuiL2Yw4Ki9KjcKoITiI
[21:45:29.248] stderr> No Kerberos credentials available
[21:45:29.248] stderr>
[21:45:29.248] stderr> No Kerberos credentials available
[21:45:29.249] stderr>
[21:45:29.249] stderr>
[21:45:29.249] stderr>
[21:45:29.250] stderr> No Kerberos credentials available
[21:45:29.250] stderr>
[21:45:29.376] Got askpass request: {"request":"daijunjie#matrix5's password:"}
[21:45:29.377] Showing password prompt
[21:45:29.377] Listening for interwindow password on /run/user/1000/vscode-ssh-askpass-16359f8f4e6c647b4da0a31ef6ce7a8f10a2f8a8.sock
[21:45:29.377] Writing password prompt to globalState
[21:45:32.725] Got password response
[21:45:32.726] Interactor gave response: *********
[21:45:32.727] Cleaning up other-window auth server
[21:45:33.007] stderr> Authenticated to matrix5 ([172.16.30.205]:22).
[21:45:33.069] > Last failed login: Thu Sep 3 21:41:40 CST 2020 from 10.8.117.207 on ssh:notty
> There were 19 failed login attempts since the last successful login.
[21:45:33.519] > ready: fe8e17d6d674
[21:45:33.552] > Linux 3.10.0-327.el7.x86_64 #1 SMP Thu Nov 19 22:10:57 UTC 2015
[21:45:33.553] Platform: linux
[21:45:33.597] > fe8e17d6d674: running
[21:45:33.642] > Acquiring lock on /home/daijunjie/.vscode-server/bin/a0479759d6e9ea56afa657e454193f72aef85bd0/vscode-remote-lock.root.a0479759d6e9ea56afa657e454193f72aef85bd0
[21:45:33.644] > \ln /home/daijunjie/.vscode-server/bin/a0479759d6e9ea56afa657e454193f72aef85bd0/vscode-remote-lock.root.a0479759d6e9ea56afa657e454193f72aef85bd0.target /home/daijunjie/.vscode-server/bin/a0479759d6e9ea56afa657e454193f72aef85bd0/vscode-remote-lock.root.a0479759d6e9ea56afa657e454193f72aef85bd0
[21:45:33.646] > Installation already in progress...
> fe8e17d6d674##24##
[21:45:33.647] Received install output: fe8e17d6d674##24##
[21:45:33.647] Server installation process already in progress - waiting and retrying
[21:45:33.648] Terminating local server
[21:45:33.649] stderr> ln: 无法创建硬链接"/home/daijunjie/.vscode-server/bin/a0479759d6e9ea56afa657e454193f72aef85bd0/vscode-remote-lock.root.a0479759d6e9ea56afa657e454193f72aef85bd0": 文件已存在
[21:45:33.661] Local server exit: 15
[21:45:34.658] askpass server listening on /run/user/1000/vscode-ssh-askpass-a481e1d41215dd72b1bfcec1ef65bf61e8af3a6f.sock
[21:45:34.659] Spawning local server with {"ipcHandlePath":"/run/user/1000/vscode-ssh-askpass-4a56ac9a4aefb156178058c9abf0f67b32b2ae5d.sock","sshCommand":"ssh","sshArgs":["-v","-T","-D","33509","-o","ConnectTimeout=15","matrix5"],"dataFilePath":"/home/daijunjie/.config/Code/User/globalStorage/ms-vscode-remote.remote-ssh/vscode-ssh-host-matrix5-a0479759d6e9ea56afa657e454193f72aef85bd0-0.51.0/data.json"}
[21:45:34.659] Local server env: {"DISPLAY":"1","ELECTRON_RUN_AS_NODE":"1","SSH_ASKPASS":"/home/daijunjie/.vscode/extensions/ms-vscode-remote.remote-ssh-0.51.0/out/local-server/askpass.sh","VSCODE_SSH_ASKPASS_NODE":"/usr/share/code/code","VSCODE_SSH_ASKPASS_MAIN":"/home/daijunjie/.vscode/extensions/ms-vscode-remote.remote-ssh-0.51.0/out/askpass-main.js","VSCODE_SSH_ASKPASS_HANDLE":"/run/user/1000/vscode-ssh-askpass-a481e1d41215dd72b1bfcec1ef65bf61e8af3a6f.sock"}
[21:45:34.672] Spawned 13797
[21:45:34.765] > local-server> Spawned ssh: 13805
[21:45:34.766] stderr> OpenSSH_7.2p2 Ubuntu-4ubuntu2.10, OpenSSL 1.0.2g 1 Mar 2016
[21:45:34.945] stderr> debug1: Server host key: ecdsa-sha2-nistp256 SHA256:t5baR11kNfeoUNE2DkSopt8EuiL2Yw4Ki9KjcKoITiI
[21:45:35.088] stderr> No Kerberos credentials available
[21:45:35.090] stderr>
[21:45:35.090] stderr> No Kerberos credentials available
[21:45:35.090] stderr>
[21:45:35.091] stderr>
[21:45:35.091] stderr>
[21:45:35.093] stderr> No Kerberos credentials available
[21:45:35.093] stderr>
[21:45:35.217] Got askpass request: {"request":"daijunjie#matrix5's password:"}
[21:45:35.217] Showing password prompt
[21:45:35.217] Listening for interwindow password on /run/user/1000/vscode-ssh-askpass-43041326a96864945a076333ad00ca828d430d5f.sock
[21:45:35.217] Writing password prompt to globalState
[21:45:36.737] Password dialog canceled
[21:45:36.737] Interactor signaled cancel
[21:45:36.737] Cleaning up other-window auth server
[21:45:36.778] stderr> Permission denied, please try again.
[21:45:36.851] Got askpass request: {"request":"daijunjie#matrix5's password:"}
[21:45:36.887] stderr> Permission denied, please try again.
[21:45:36.950] Got askpass request: {"request":"daijunjie#matrix5's password:"}
[21:45:36.986] stderr> Permission denied (publickey,gssapi-keyex,gssapi-with-mic,password).
[21:45:36.986] > local-server> ssh child died, shutting down
[21:45:36.989] Local server exit: 0
[21:45:36.989] Received install output: OpenSSH_7.2p2 Ubuntu-4ubuntu2.10, OpenSSL 1.0.2g 1 Mar 2016
debug1: Server host key: ecdsa-sha2-nistp256 SHA256:t5baR11kNfeoUNE2DkSopt8EuiL2Yw4Ki9KjcKoITiI
No Kerberos credentials available
No Kerberos credentials available
No Kerberos credentials available
Permission denied, please try again.
Permission denied, please try again.
Permission denied (publickey,gssapi-keyex,gssapi-with-mic,password).
[21:45:36.990] Resolver error: Permission denied (publickey,gssapi-keyex,gssapi-with-mic,password).
[21:45:36.993] ------
I'm so confused about it. Has any run into this problem?
Is there any 'clean' way to reinstall ssh-remote?
Check your Remote-SSH version. After many attempts at trying to fix this for me, I found that downgrading Remote-SSH on VScode from 0.65.4 to 0.51.0 resolved the issue.
(User mileage may vary)
Installed pghero according to the github docs (on CentOS 7), but seeing nothing in web browser (no connection error displayed, but browser is totally blank) and when starting service curl giving response. Looking at the logs I see...
[root#airflowetl ~]# pghero logs
==> /var/log/pghero/production.log <==
Started GET "/" for 127.0.0.1 at 2020-01-28 16:21:47 -1000
Processing by PgHero::HomeController#index as */*
Completed 500 Internal Server Error in 55ms
PG::ConnectionBad (FATAL: password authentication failed for user "airflow"):
...
...
...
Started GET "/" for 127.0.0.1 at 2020-01-28 23:51:28 -1000
Processing by PgHero::HomeController#index as */*
Completed 500 Internal Server Error in 11ms
PG::ConnectionBad (FATAL: Ident authentication failed for user "airflow"):
...
...
...
Jan 28 22:59:10 airflowetl.co.local systemd[1]: pghero-web-1.service holdoff time over, scheduling restart.
Jan 28 22:59:10 airflowetl.co.local systemd[1]: Stopped pghero-web-1.service.
Jan 28 22:59:10 airflowetl.co.local systemd[1]: start request repeated too quickly for pghero-web-1.service
Jan 28 22:59:10 airflowetl.co.local systemd[1]: Failed to start pghero-web-1.service.
Jan 28 22:59:10 airflowetl.co.local systemd[1]: Unit pghero-web-1.service entered failed state.
Jan 28 22:59:10 airflowetl.co.local systemd[1]: pghero-web-1.service failed.
Jan 28 23:09:36 airflowetl.co.local systemd[1]: Stopping pghero-web.service...
Jan 28 23:09:36 airflowetl.co.local systemd[1]: Stopped pghero-web.service.
Jan 28 23:09:36 airflowetl.co.local systemd[1]: Started pghero-web.service.
Jan 28 23:09:36 airflowetl.co.local systemd[1]: Started pghero-web-1.service.
Jan 28 23:09:37 airflowetl.co.local pghero-web-1.service[12134]: [12134] Puma starting in cluster mode...
Jan 28 23:09:37 airflowetl.co.local pghero-web-1.service[12134]: [12134] * Version 4.3.0 (ruby 2.6.3-p62), codename: Mysterious Trave
Jan 28 23:09:37 airflowetl.co.local pghero-web-1.service[12134]: [12134] * Min threads: 1, max threads: 16
Jan 28 23:09:37 airflowetl.co.local pghero-web-1.service[12134]: [12134] * Environment: production
Jan 28 23:09:37 airflowetl.co.local pghero-web-1.service[12134]: [12134] * Process workers: 3
Jan 28 23:09:37 airflowetl.co.local pghero-web-1.service[12134]: [12134] * Preloading application
Jan 28 23:09:38 airflowetl.co.local pghero-web-1.service[12134]: [12134] * Listening on tcp://0.0.0.0:3001
Jan 28 23:09:38 airflowetl.co.local pghero-web-1.service[12134]: [12134] ! WARNING: Detected 1 Thread(s) started in app boot:
Jan 28 23:09:38 airflowetl.co.local pghero-web-1.service[12134]: [12134] ! #<Thread:0x0000561740ea27e0#/opt/pghero/vendor/bundle/ruby
Jan 28 23:09:38 airflowetl.co.local pghero-web-1.service[12134]: [12134] Use Ctrl-C to stop
Jan 28 23:09:38 airflowetl.co.local pghero-web-1.service[12134]: [12134] - Worker 0 (pid: 12213) booted, phase: 0
Jan 28 23:09:38 airflowetl.co.local pghero-web-1.service[12134]: [12134] - Worker 1 (pid: 12215) booted, phase: 0
Jan 28 23:09:38 airflowetl.co.local pghero-web-1.service[12134]: [12134] - Worker 2 (pid: 12219) booted, phase: 0
...
and can see the
500 Internal Server Error in 55ms
error. Checking the service status, seeing...
[root#airflowetl ~]# service pghero status
Redirecting to /bin/systemctl status pghero.service
● pghero.service
Loaded: loaded (/etc/systemd/system/pghero.service; enabled; vendor preset: disabled)
Active: active (running) since Tue 2020-01-28 23:09:36 HST; 4s ago
Main PID: 12132 (sleep)
CGroup: /system.slice/pghero.service
└─12132 /bin/sleep infinity
Jan 28 23:09:36 airflowetl.co.local systemd[1]: Started pghero.service.
[root#airflowetl ~]# netstat -tulnp | grep 3001
tcp 0 0 0.0.0.0:3001 0.0.0.0:* LISTEN 12134/puma 4.3.0 (t
[root#airflowetl ~]# curl -v http://localhost:3001/
* About to connect() to localhost port 3001 (#0)
* Trying ::1...
* Connection refused
* Trying 127.0.0.1...
* Connected to localhost (127.0.0.1) port 3001 (#0)
> GET / HTTP/1.1
> User-Agent: curl/7.29.0
> Host: localhost:3001
> Accept: */*
>
< HTTP/1.1 500 Internal Server Error
< Content-Type: text/html; charset=UTF-8
< X-Request-Id: 2bad5f50-438e-4cb3-8e79-41c84eb75c2c
< X-Runtime: 0.017069
< Content-Length: 0
<
* Connection #0 to host localhost left intact
No experience with postgresql or db admin stuff, but appears that the error is due to the fact that I use ident authentication (and appears pghero wants to use a password):
[root#airflowetl ~]# cat /var/lib/pgsql/data/pg_hba.conf
# PostgreSQL Client Authentication Configuration File
# ===================================================
...
# 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 ident
#host all all 0.0.0.0/0 trust
host all all 0.0.0.0/0 md5
#host all all 127.0.0.1/32 trust
# IPv6 local connections:
host all all ::1/128 ident
# Allow replication connections from localhost, by a user with the
# replication privilege.
#local replication postgres peer
#host replication postgres 127.0.0.1/32 ident
#host replication postgres ::1/128 ident
#------------------------------------------------------------------------------
# CONNECTIONS AND AUTHENTICATION
#------------------------------------------------------------------------------
# - Connection Settings -
#listen_addresses = 'localhost' # what IP address(es) to listen on;
# comma-separated list of addresses;
# defaults to 'localhost'; use '*' for all
# (change requires restart)
listen_addresses = '*' # for apache-airflow connection
I did this following an article of setting up psql as backend for airflow orchestration tool.
Have tried using multiple urls
sudo pghero config:set DATABASE_URL=postgresql://airflow:xxxx#localhost:5432/airflow
sudo pghero config:set DATABASE_URL=postgresql+psycopg2://airflow:xxxx#localhost:5432/airflow
but same results.
Not sure how to move forward at this point. Anyone with more experience with pghero or postgresql know what could be done here?
No experience with postgresql or db admin stuff, but appears that the error is due to the fact that I use ident authentication (and appears pghero wants to use a password)
It isn't about what pghero wants. It is PostgreSQL which is demanding password authentication.
host all all 0.0.0.0/0 md5
host all all ::1/128 ident
You are using md5 (i.e. password) on all IPv4 connections (including "localhost"), and using ident on only the IPv6 connection from ::1, which is the IPv6 way of spelling "localhost". pghero is coming in over IPv4, not IPv6, so it is getting commanded to use a password.
You can change the "md5" to "ident" for the 0.0.0.0/0 line (but you probably shouldn't as "ident" is not very secure from outside hosts), or add a line before that one to indicate 127.0.0.1/32 specifically should use ident. Or change your pghero config to try to connect over IPv6 rather than IPv4.
Your new log file entry shows that it is trying ident and failing at that too. I don't understand why you are getting both, but they are 7 hours apart so maybe you had changed pg_hba.conf in between. PostgreSQL will create a more complete report and put it in the PostgreSQL server's log file about why the ident authentication failed. (It doesn't sent to the complete report to the unauthenticated client, because that would reveal sensitive information). Find the PostgreSQL server's log file.
I am trying to send a mail with a non root user (also by tuleap application) but i have some trouble.
when we use a root user with command
echo “TR : This is a test of sending mail” | mail -s Test <mail>
it return this log and my email is sent
Mar 10 16:59:09 localhost sendmail[11969]: t2AGx9Up011969: from=root, size=258, class=0, nrcpts=1, msgid=<201503101659.t2AGx9Up011969#localhost.localdomain>, relay=root#localhost
Mar 10 16:59:09 localhost sendmail[11970]: t2AGx9Js011970: from=<root#localhost.localdomain>, size=521, class=0, nrcpts=1, msgid=<201503101659.t2AGx9Up011969#localhost.localdomain>, proto=ESMTP, daemon=MTA, relay=localhost [127.0.0.1]
Mar 10 16:59:09 localhost sendmail[11969]: t2AGx9Up011969: to=<my mail>, ctladdr=root (0/0), delay=00:00:00, xdelay=00:00:00, mailer=relay, pri=30258, relay=[127.0.0.1] [127.0.0.1], dsn=2.0.0, stat=Sent (t2AGx9Js011970 Message accepted for delivery)
Mar 10 16:59:12 localhost sendmail[11972]: STARTTLS=client, relay=<my SMTP server>, version=TLSv1/SSLv3, verify=OK, cipher=DHE-RSA-AES256-GCM-SHA384, bits=256/256
Mar 10 16:59:15 localhost sendmail[11972]: t2AGx9Js011970: to=<my mail>, ctladdr=<root#localhost.localdomain> (0/0), delay=00:00:06, xdelay=00:00:06, mailer=relay, pri=120521, relay=<my SMTP server> [IP], dsn=2.0.0, stat=Sent (OK id=1YVNUv-002ihW-JJ)
but when we use an other use (like codendiadm as used by tuleap) with the same command, it return this log without sending mail
Mar 10 16:59:53 localhost sendmail[12024]: t2AGxrhg012024: from=codendiadm, size=258, class=0, nrcpts=1, msgid=<201503101659.t2AGxrhg012024#localhost.localdomain>, relay=codendiadm#localhost
Mar 10 16:59:53 localhost sendmail[12025]: t2AGxr16012025: from=<codendiadm#localhost.localdomain>, size=556, class=0, nrcpts=1, msgid=<201503101659.t2AGxrhg012024#localhost.localdomain>, proto=ESMTP, daemon=MTA, relay=localhost [127.0.0.1]
Mar 10 16:59:53 localhost sendmail[12024]: t2AGxrhg012024: to=<my mail>, ctladdr=codendiadm (495/492), delay=00:00:00, xdelay=00:00:00, mailer=relay, pri=30258, relay=[127.0.0.1] [127.0.0.1], dsn=2.0.0, stat=Sent (t2AGxr16012025 Message accepted for delivery)
Mar 10 16:59:57 localhost sendmail[12027]: STARTTLS=client, relay=<my SMTP server>, version=TLSv1/SSLv3, verify=OK, cipher=DHE-RSA-AES256-GCM-SHA384, bits=256/256
Mar 10 17:00:00 localhost sendmail[12027]: t2AGxr16012025: to=<my mail>, ctladdr=<codendiadm#localhost.localdomain> (495/492), delay=00:00:07, xdelay=00:00:07, mailer=relay, pri=120556, relay=<my SMTP server> [IP], dsn=5.1.1, stat=User unknown
Mar 10 17:00:00 localhost sendmail[12027]: t2AGxr16012025: t2AH0016012027: DSN: User unknown
Try to remove sendmail and install postfix instead. And tell me if it works better this way. You'll find how to do it here.