Skip to content
ohsudo, Home

Tags

#connections

no pg_hba.conf entry
Databases

PostgreSQL "no pg_hba.conf entry for host": allow this connection, the safe way

Fix PostgreSQL "FATAL: no pg_hba.conf entry for host": read the host, user and SSL in the message, add a narrow rule to pg_hba.conf, reload it, and handle Docker and SSL.

Intermediate · 4 min read

is not allowed to connect
Databases

MySQL "ERROR 1130: Host is not allowed to connect": an account is a user and a host

Fix MySQL ERROR 1130 "Host is not allowed to connect to this MySQL server": see which accounts exist, create one for the right host and grant it access, without root.

Beginner · 4 min read

ORA-12541
Databases

Oracle "ORA-12541: no listener": start it, or connect to the address it really uses

Fix Oracle ORA-12541 "TNS:no listener" (or "Cannot connect. No listener at host"): start it with lsnrctl, check the host and port, listener.ora, firewalls and Docker.

Beginner · 4 min read

ECONNREFUSED 127.0.0.1:27017
Databases

MongoDB "connect ECONNREFUSED 127.0.0.1:27017": why it refuses, and how to fix it

Fix MongoDB "connect ECONNREFUSED 127.0.0.1:27017" and ::1:27017: start mongod, read exit code 14, check bindIp, IPv6 localhost in Node.js, and Docker service names.

Beginner · 4 min read

ERROR 2002 (HY000)
Databases

MySQL "Can't connect to local MySQL server through socket": find out why (ERROR 2002)

Fix MySQL ERROR 2002 "Can't connect to local MySQL server through socket": is the server running, where is the socket, and why localhost differs from 127.0.0.1.

Beginner · 4 min read

ORA-12154
Databases

Oracle "ORA-12154: TNS:could not resolve the connect identifier specified": how to fix it

Fix Oracle ORA-12154: the client can't find your connect identifier. Check tnsnames.ora, TNS_ADMIN and sqlnet.ora, an @ in the password, or use Easy Connect.

Intermediate · 4 min read

too many clients already
Databases

PostgreSQL "FATAL: sorry, too many clients already": find who holds the connections

Fix PostgreSQL "FATAL: sorry, too many clients already": see who holds the connections, end the idle ones, size your pools, and add PgBouncer before raising the limit.

Intermediate · 4 min read

network-related or instance-specific
Databases

SQL Server "A network-related or instance-specific error" (error 40, error 26): how to fix it

Fix SQL Server "A network-related or instance-specific error occurred": check the service, TCP/IP, the instance name, SQL Browser, port 1433 and the Windows firewall.

Intermediate · 4 min read

ERROR 1040 (HY000): Too many connections
Databases

MySQL "ERROR 1040: Too many connections": get in, find who holds them, fix it

Fix MySQL and MariaDB "Too many connections": log in with the reserved admin connection, find idle and stuck connections, then fix pools, timeouts or max_connections.

Intermediate · 4 min read

Is the server running on that host and accepting TCP/IP connections?
Databases

PostgreSQL "Connection refused … Is the server running?": find out why nothing answers on 5432

Fix PostgreSQL "connection refused": check that it runs, read why it did not start, then fix listen_addresses, the port, the firewall or Docker.

Beginner · 3 min read