Article 4QVGT curl is not able to get response, RHEL 7.2

curl is not able to get response, RHEL 7.2

by
james000
from LinuxQuestions.org on (#4QVGT)
Hi,

I have two RHEL 7.2 servers and running below command. Though both servers are made in a similar way, one server can get the curl output with the required token, and another server not.
In below output, auth.lb.pre.vuspoint.com is load balancer and I can ping it from this server. This LB is pointing to two servers on backend, which have tokens. Below command (which is failing on this server, but working on other) is supposed to get token from any of those backend server.
Code:[root@serv-portal3 ~]# curl -k --location --request POST "https://auth.lb.pre.vuspoint.com/auth/realms/PRE-REALM/protocol/openid-connect/token" --header "Content-Type: application/x-www-form-urlencoded" --data "client_secret=fd68ddbf-5740-4912-b714-1aaeb453fafc&grant_type=password&client_id=snapshotui_1.1&username=snapshotmpctestuser&password=snapshotmpc"
curl: (35) TCP connection reset by peer
[root@serv-portal3 ~]#
[root@serv-portal3 ~]# curl -v -k --location --request POST "https://auth.lb.pre.vuspoint.com/auth/realms/PRE-REALM/protocol/openid-connect/token" --header "Content-Type: application/x-www-form-urlencoded" --data "client_secret=fd68ddbf-5740-4912-b714-1aaeb453fafc&grant_type=password&client_id=snapshotui_1.1&username=snapshotmpctestuser&password=snapshotmpc"
* About to connect() to auth.lb.pre.vuspoint.com port 443 (#0)
* Trying 172.30.74.73...
* Connected to auth.lb.pre.vuspoint.com (172.30.74.73) port 443 (#0)
* Initializing NSS with certpath: sql:/etc/pki/nssdb
* NSS error -5961 (PR_CONNECT_RESET_ERROR)
* TCP connection reset by peer
* Closing connection 0
curl: (35) TCP connection reset by peer
[root@serv-portal3 ~]#
[root@serv-portal3 ~]# openssl s_client -connect auth.lb.pre.vuspoint.com:443
CONNECTED(00000003)
write:errno=104
---
no peer certificate available
---
No client certificate CA names sent
---
SSL handshake has read 0 bytes and written 249 bytes
---
New, (NONE), Cipher is (NONE)
Secure Renegotiation IS NOT supported
Compression: NONE
Expansion: NONE
---
[root@serv-portal3 ~]#There is no firewall between this server and loadbalancer and to another server also, where LB is pointing. Network team says that it is server issue and things are working fine on their end, though I don't believe it always. But above output is not sufficient to prove if it is network side issue.

Please suggest, what I am missing and should be checked.

Thankslatest?d=yIl2AUoC8zA latest?i=_bKsqms5o-4:ZnoQ4hhVKhc:F7zBnMy latest?i=_bKsqms5o-4:ZnoQ4hhVKhc:V_sGLiP latest?d=qj6IDK7rITs latest?i=_bKsqms5o-4:ZnoQ4hhVKhc:gIN9vFw_bKsqms5o-4
External Content
Source RSS or Atom Feed
Feed Location https://feeds.feedburner.com/linuxquestions/latest
Feed Title LinuxQuestions.org
Feed Link https://www.linuxquestions.org/questions/
Reply 0 comments