database connection failed error: installing moodle 3.7.3 on bluehost server

database connection failed error: installing moodle 3.7.3 on bluehost server

by marc helfano -
Number of replies: 6

hi experts, and thank you.

im new to installing/troubleshooting moodle.

but i uploaded the moodle 3.7.3 zip file to my /public_jtml folder, i unzipped the folder, so i have a /public_html/moodle folder, then i web browser i went to mymaindomain.com/moodle and the install script began, then as i entered the database info , i clicked next and received this error message: and im unsure as to what to do to resolve it?

it appears in file manager that the moodledata folder has been created, but not the new mysql database... thus the error

thank you for the assistance.


NOTe: i DID NOT create a new database prior to this step, id assumed the installation process would do this new database creation...possibly i need to create this new datase with the same username and password im telling the moodle install..?

----

Error: Database connection failed

It is possible that the database is overloaded or otherwise not running properly.

The site administrator should also check that the database details have been correctly specified in config.php


Warning: mysqli::__construct(): (HY000/1045): Access denied for user 'admin'@'localhost' (using password: YES) in /home4/magicby5/public_html/moodle/lib/dml/mysqli_native_moodle_database.php on line 79
Attachment moodle373 db install error-1.jpg
Average of ratings: -
In reply to marc helfano

Re: database connection failed error: installing moodle 3.7.3 on bluehost server

by marc helfano -
also, there is co config.php file as yet, as mentioned in the error, as its still doing the early steps of the installation...?
In reply to marc helfano

Re: database connection failed error: installing moodle 3.7.3 on bluehost server

by Kenneth Odle -

Moodle does not automatically create a database. You will need to do that separately before you start the installation.

Once you enter the database details (database name, database username, mysql hostname, and database password), Moodle will then create the appropriate config.php file.

Nota bene: The credentials I mentioned above are database credentials that your PHP engine will use to read from and write to the database. These are completely separate from the credentials you will use to log in to Moodle once it is installed. Do not use a simple word like "admin" as a user name, for security reasons.

In reply to Kenneth Odle

Re: database connection failed error: installing moodle 3.7.3 on bluehost server

by marc helfano -
thank you, i will try this out, and create the database, using a strong username and password for the databases. moodle also asked for a 'port' on that same database input page? do i leave that blank?
In reply to marc helfano

Re: database connection failed error: installing moodle 3.7.3 on bluehost server

by marc helfano -
this worked, it got me to the next step, thank you. im trying to avoid paying a moodle/lms consultant to do this, as its really a very simple site, 2 courses, 25 users, etc...
thank you so much, i got it up and going!
also, currently i have my domain name for the moodle site 'redirected' to my primarydomainname.com/moodle folder (on bluehost), is there way to have the moodle site show my 'moodle' domain name instead of the primary/moodle in the urp bar? for when users use it , i dont want them to see my primary domain name there too ?
In reply to Kenneth Odle

Re: database connection failed error: installing moodle 3.7.3 on bluehost server

by Emma Richardson -
Picture of Documentation writers Picture of Particularly helpful Moodlers Picture of Plugin developers
Actually, if the user permissions are correct, moodle installation can in fact create the database.
In reply to marc helfano

Re: database connection failed error: installing moodle 3.7.3 on bluehost server

by Usman Asar -
Picture of Plugin developers Picture of Testers

Marc, your username and database names MUST be with your account username on bluehost

so they'll be like marc_databasename and same goes for database username.