Posting in the Magento forums has been disabled pending the implementation of a new and improved forum solution which should better serve the community.

For new questions please post at magento.stackexchange.com, the community-run support site for the Magento community. We will be providing updates on the new forum solution soon. For questions or concerns please email community@magento.com.

Magento Forum

How reinstall a new version but using a database from previous installation
 
cadoworld
Jr. Member
 
Total Posts:  27
Joined:  2008-10-12
 

Hi,
My problem is simple ... I have a version magento 1.2. up and running. I tried several time to update to 1.3 but I got alway an error.

I am thinking to keep the database and reinstall a new clean version 3.0 of magento. But I am not programmer and I know the name of the database will be different than the one install by default. Does someone could give me step by step what to do to reinstall the database.

I have a full access to my admin and sql. Please Help me!
phil

 
Magento Community Magento Community
Magento Community
Magento Community
 
Dx3webs
Sr. Member
 
Avatar
Total Posts:  178
Joined:  2008-12-16
 

i have just had to do this for the same reasons

download a clean version of 1.2

make a copy of your existing database

install and point the clean 1.2 to your database copy

do the upgrade

fix all the bugs (which are well documented in this section)

 
Magento Community Magento Community
Magento Community
Magento Community
 
cadoworld
Jr. Member
 
Total Posts:  27
Joined:  2008-10-12
 

Well, if I try to install a new version, magento create a new sql database by default which I can’t change immediately. how do I change via mysql?

 
Magento Community Magento Community
Magento Community
Magento Community
 
Dx3webs
Sr. Member
 
Avatar
Total Posts:  178
Joined:  2008-12-16
 

magento does not create your database it only asks you for your username, database name and password

if you create a copy of your existing database it will just read this and carry on

 
Magento Community Magento Community
Magento Community
Magento Community
 
Oldgamer
Sr. Member
 
Avatar
Total Posts:  142
Joined:  2008-09-12
 
magicker - 09 April 2009 01:04 PM

magento does not create your database it only asks you for your username, database name and password

if you create a copy of your existing database it will just read this and carry on

This is the info I’m looking for the long time.
Let say I have production database filled with orders and products. Will I lose anything when I point new Magento installation to this db?
Can you confirm that everything will be intact?

I am asking this because sometimes upgrade goes ugly and I feel that it would much easier just remove all files and install new Magento instead of looking for errors. Sure, some files need to be copied back like changed email templates and images.

 
Magento Community Magento Community
Magento Community
Magento Community
 
vianetz
Guru
 
Avatar
Total Posts:  537
Joined:  2008-04-13
Munich, Germany
 

In my opinion it is always easier to start with a new Magento installation and just use the old local.xml to set the database strings. If you first call the Magento URL the SQL database update scripts will be run and update your database. In a normal case this should go fine so everything keeps intact.

But you should always keep a backup of your database.

 
Magento Community Magento Community
Magento Community
Magento Community
 
Oldgamer
Sr. Member
 
Avatar
Total Posts:  142
Joined:  2008-09-12
 
massi - 12 April 2009 09:40 AM

In my opinion it is always easier to start with a new Magento installation and just use the old local.xml to set the database strings. If you first call the Magento URL the SQL database update scripts will be run and update your database. In a normal case this should go fine so everything keeps intact.

But you should always keep a backup of your database.

massi,

I feel we getting closer to what I’m looking for smile
One thing: do you mean copy old local.xml file after installation to point magento to old database?
In that case I guess we can point installation to any database while install and just copy old local.xml file after to re-point Magento. I’m not sure if I sound clear, sorry.

 
Magento Community Magento Community
Magento Community
Magento Community
 
vianetz
Guru
 
Avatar
Total Posts:  537
Joined:  2008-04-13
Munich, Germany
 

Yes, you can point to any Magento database in local.xml. Just edit the related lines in this file. I’m not sure I understand your question?!

 
Magento Community Magento Community
Magento Community
Magento Community
 
Oldgamer
Sr. Member
 
Avatar
Total Posts:  142
Joined:  2008-09-12
 

thank you a lot,
I think I understood.
You actually answered my question.
I just wanted to be sure I got it right.

 
Magento Community Magento Community
Magento Community
Magento Community
 
Dx3webs
Sr. Member
 
Avatar
Total Posts:  178
Joined:  2008-12-16
 

just make sure you back up your database!!!

mysqldump -h localhost -u xxxxx -p db_name > backup-file.sql

 
Magento Community Magento Community
Magento Community
Magento Community
 
vianetz
Guru
 
Avatar
Total Posts:  537
Joined:  2008-04-13
Munich, Germany
 

I already refered to this in my previous post.

 
Magento Community Magento Community
Magento Community
Magento Community
 
Oldgamer
Sr. Member
 
Avatar
Total Posts:  142
Joined:  2008-09-12
 

Sure.
I prefer to backup DB using my host backup feature, though.

 
Magento Community Magento Community
Magento Community
Magento Community
Magento Community
Magento Community
Back to top