Magento database config file

Developers often need to make changes in the “Magento database config file” for the site development purpose. For example, domain transfer, backups and editing etc. Mostly the merchants have very little knowledge about the use of MySQL databases. Specially all they knew about cPanel & admin access. Hence, in this article, we tried here to focus on use and access details of database.

magento database config file raw

There are a lot of databases under cPanel. Hence occasionally you might need just one of them for an application or website etc. Here we will take Mage database as an example.

Accessing Magento database config file

Case study: Backup

Firstly, let’s make the Mage website available. Next assume that we have FTP access but don’t have the database details. Here our task is to do a database backup. As a result, the question arises, “How to find the access credentials of that specific database?”

magento database config file xml

Now let’s move to ‘/app/etc/’ under main site DIR (Mage site installed). Then access the XML doc ‘local.xml’. Therefore, access the “local.xml” using your cPanel editor.














That is how we can access to DB credentials using your cPanel. Lastly, Use “php mini admin” or any “php script” in your cPanel to create a backup. All you need to use accurate DB details.

Case study: Config & domain transfer

Another key point is the website transfer process. Now you are ready to transfer Mage docs and DB to another host. Hence, it is possible that you’re using new DB credentials in your new hosting server such as hostname, username, DB name and password etc. Then all you need is to access the “/app/etc/local.xml” file on new server. Now edit the DB credentials using cPanel in the new hosting server.







Finally, save the updated values using the “HTML editor” to effect changes.

“Although as you can see transferring websites is bit tricky for non-developers. As a result, we’re providing 100% free website transfer services to our clients. Hence, all  three plans includes the service absolutely in free of cost! So, feel free to move in with Aspiration Hosting. You can also enjoy dedicated Mage hosting with us for $9.99 per month.”

Tanzia Farin Chy for aspiration hosting