Database

Database connection failed: No such file or directory (2002) error ,i need set the parameter for my database connection

define(“DB_SERVER”,“localhost”);
define(“DB_USER”,“root”);
define(“DB_PASS”,“akanbiakanbi”);
define(“DB_NAME”,“project2”);
name to the database server, my user name, password.

@Hollami said:

define(“DB_SERVER”,“localhost”);
define(“DB_USER”,“root”);
define(“DB_PASS”,“akanbiakanbi”);
define(“DB_NAME”,“project2”);
name to the database server, my user name, password.

Hi, the problem is caused because you have put “localhost” in DB server.
You need to put the SQL server that is dispalyed in vPanel, eg. sql103.epizy.com

And also, the DB name should be sth like “epiz_123456_project2”, where you replace epiz_123456 with your actual username and project2 with the name you gave your database when creating it.


**DO NEVER SHARE YOUR PASSWORDS ON A PUBLIC FORUM!** **Change them Immediately**!!!

@Hollami said:

define(“DB_SERVER”,“localhost”);
define(“DB_USER”,“root”);
define(“DB_PASS”,“akanbiakanbi”);
define(“DB_NAME”,“project2”);
name to the database server, my user name, password.

Hi!
Can you please don’t make multiple threads?
I mean what’s the point, even if you will make multiple threads, it doesn’t help to speed up the time so you can get support.

Let’s keep this thread @Admin and maybe delete the others.

@UnknownLolz said:

@Hollami said:

define(“DB_SERVER”,“localhost”);
define(“DB_USER”,“root”);
define(“DB_PASS”,“akanbiakanbi”);
define(“DB_NAME”,“project2”);
name to the database server, my user name, password.

Hi!
Can you please don’t make multiple threads?
I mean what’s the point, even if you will make multiple threads, it doesn’t help to speed up the time so you can get support.

@UnknownLolz said:

@Hollami said:

define(“DB_SERVER”,“localhost”);
define(“DB_USER”,“root”);
define(“DB_PASS”,“akanbiakanbi”);
define(“DB_NAME”,“project2”);
name to the database server, my user name, password.

Hi!
Can you please don’t make multiple threads?
I mean what’s the point, even if you will make multiple threads, it doesn’t help to speed up the time so you can get support.

@Hollami has done this in the past and I don’t understand why he/she keeps doing that, let’s see Admin’s reaction.

@ChrisPAR said:

@Hollami said:

define(“DB_SERVER”,“localhost”);
define(“DB_USER”,“root”);
define(“DB_PASS”,“akanbiakanbi”);
define(“DB_NAME”,“project2”);
name to the database server, my user name, password.

Hi, the problem is caused because you have put “localhost” in DB server.
You need to put the SQL server that is dispalyed in vPanel, eg. sql103.epizy.com

And also, the DB name should be sth like “epiz_123456_project2”, where you replace epiz_123456 with your actual username and project2 with the name you gave your database when creating it.


**DO NEVER SHARE YOUR PASSWORDS ON A PUBLIC FORUM!** **Change them Immediately**!!!

And also, DB_user should be your epiz_123456 username, not root :smiley:

First of all, @Hollami I deleted some of your other topics because they are about the same issue. Next time, please post your question once. Whether you want to add it to a topic you created before or create a new one is up to you, just don’t post it everywhere. If you don’t know which category to use, pick one and use it (the homepage mixes the category into one feed anyeways). You’re not helping anyone, especially not yourself, if you’re fragmenting the help across multiple topics.

Did you know we have a knowledge base, stocked with articles which answer many common questions and errors? For example, the error above is described in this article: https://infinityfree.net/support/common-mysql-errors/ Did you check it already?

ok thanks

new here, so i need get somethings right

also pls , i need help linking from one page to another , my linking is generating error 404 page not found

@Hollami said:
also pls , i need help linking from one page to another , my linking is generating error 404 page not found

Did you search the web for basic HTML tutorials? Creating links is quite straight forward and there are at least thousands of guides available explaining how to do it. You don’t need to do anything specific to InfinityFree.

are you then saying its my code ?

@Hollami said:
are you then saying its my code ?

Essentially, yes. Either your code is generating a 404 error, or your link points to some place the server can’t find any code to serve a page.