Changing Database configuration in magento site
Sometimes in order to move our site from one server to another server we are required to change database configuration as per new server. Although when you install fresh magento on your server it will ask for your database details from you and you don’t need to make any changes directly on your magento. But because now you need to just move your magento files from one server to another server so you need to change in magento files to make actual changes.
To Change database configuration
Just open the file app/etc/local.xml and look for below code
<default_setup> <connection> <host><![CDATA[localhost]]></host> <username><![CDATA[root]]></username> <password><![CDATA[123***]]></password> <dbname><![CDATA[magento]]></dbname> <active>1</active> </connection> </default_setup>
From the code above you can simply change host name , username, password and database name as well.
Change the url of admin section of Magento Site
You can change the admin section URL of your magento site from the change in same file (app/etc/local.xml) by simply changing following code
<adminhtml> <args> <frontName><![CDATA[secure]]></frontName> </args> </adminhtml>
From the above code you can understand we will use new admin url like
http://127.0.1.1/magento/secure
After changing the admin url don’t forget to flush all the cache from cache management from magento admin
Chandra Shekhar
Latest posts by Chandra Shekhar (see all)
- Best practices for micro service design - January 23, 2022
- Spring Boot - January 23, 2022
- Java - January 23, 2022
Recent Comments