Wordpress Database Error establishing a database connection [duplicate] - database

This question already has answers here:
Can't connect to local MySQL server through socket '/var/mysql/mysql.sock' (38)
(43 answers)
Closed 1 year ago.
I updated my PHP from 5.4 to 7 and after that my wordpress website cannot connect to the database.
When I put the line define('WP_ALLOW_REPAIR', true); within the wp-config.php and go to address: http://www.address.com/wp-admin/maint/repair.php I still have the same error
Error establishing a database connection
When I connect to my wp-admin, I got the following:
Finally I checked my credential on my database within wp-config.php, they are correct but when I do a mysql> show databases; I got the following:
ERROR 2002 (HY000): Can't connect to local MySQL server through socket '/tmp/mysql.sock' (2)

please edit wp_config file
use this code:
define('WP_ALLOW_REPATR',true);

Related

DPY-4011: the database or network closed the connection

I am using Oracle 11.2.0, Python 3.10.3
I am trying to connect to a Infor Oracle database with the following script:
import oracledb
TEST="'xxxx':'XXX'/'XXX'"
with oracledb.connect(user="xxx", password="xxx", dsn=TEST, disable_oob=True)
it return:
oracledb.exceptions.DatabaseError: DPY-4011: the database or network closed the connection
could you help me?

MS sql database connetion error [duplicate]

This question already has answers here:
Cannot Connect to Server - A network-related or instance-specific error
(54 answers)
Closed 4 years ago.
I received this error when trying connecting to a MS SQL Instance.
A network-related or instance-specific error occurred while establishing a connection to SQL Server.
Can anyone suggest how to fix this error?
This error mostly occurs when the server name provided is wrong.
Check the server name and make sure it is correct
Try to connect to the server by pinging from cmd
ping servername

ColdFusion is not connecting datasource with SQL Server 2014 [duplicate]

This question already has an answer here:
ColdFusion 10/Windowns 7 Pro 64bit Connection verification failed for data source
(1 answer)
Closed 6 years ago.
I am trying to connect datasource in coldfusion admin with my local sql server 2014 but it is not connecting . I have tried every method to do this but no success.
I have also created new user but it is also not working.
I am getting this error
Connection verification failed for data source: mlc_new
java.sql.SQLInvalidAuthorizationSpecException: [Macromedia][SQLServer
JDBC Driver][SQLServer]Login failed for user 'tester'. The root cause
was that: java.sql.SQLInvalidAuthorizationSpecException:
[Macromedia][SQLServer JDBC Driver][SQLServer]Login failed for user
'tester'.
the datasource details are
datasource name: mlc_new db name: mlc_new sever: DEV-PC\SQLEXPRESS
username: tester password : somestring
Some details on SQL Server mixed authentication. To enable do, the following:
Connect to DB server (presumably via Windows Authentication
Right click for properties on the server icon
On the properties dialog go to Security
Select "SQL Server and Windows Authentication mode". Save.

SQL Server pulling data from different server [duplicate]

This question already has answers here:
Closed 11 years ago.
Possible Duplicate:
How can I connect to an external database from a sql statement or a stored procedure?
I have a database server 'A'(SQL Server 2008) and database server 'B' (SQL Server 2005).
I need to pull some data from a database on server 'B' when I am on server 'A'.
I tried this query on Server 'A':
SELECT *
FROM [ServerName].[DataBaseName].[dbo].[TableName]
I am getting this error :
Login failed for user 'NT AUTHORITY\ANONYMOUS LOGON'
Is there some thing wrong with my query or do we need to change any setting on the server
so that I will be able to access the database.
You might still need to add a login for the linked server...
exec sp_addlinkedsrvlogin ‘LinkedServer’, 'true'
This will cause your 'A' server to try to impersonate your login on server B.
There's more detailed info / reference here: http://blogs.msdn.com/b/sql_protocols/archive/2006/08/10/694657.aspx

Login failed in SQL Server Express [duplicate]

This question already has answers here:
Closed 12 years ago.
Possible Duplicate:
Cannot connect to UserPC\SQLExpress
I have been struggling to find a solution for this from long but in vain. I recently installed SQL Server Management Studio Express and tried to login with SQL authentication with 'sa' username. It was giving me error 233, so I enabled NamedPipes, Shared Memory and TCP IP from Configuration Manager.
Now, I when I try to login, it shows an Error:
Login failed for the user ''. Erorr: 18456
Screenshot:
I checked the server error logs and they were showing me
2011-01-07 01:35:12.47 spid17s Error: 17054, Severity: 16, State: 1.
Try logging in with "Windows Authentication" first and create a new user with a password. You can use this new username/password to login and find out if you are using the right user/pwd combination.
Hope this helps
You need to ensure that the user you are trying to login with (sarin) is a valid user in the database and has the right permissions.

Resources