List:General Discussion« Previous MessageNext Message »
From:Eric Robinson Date:November 21 2009 5:38pm
Subject:Rename Database - Why Would This Not Work?
View as plain text  
I used a simple procedure to rename my MySQL 4.1.22 database, which has
only My-ISAM tables:
 
1. Stopped MySQL
2. Renamed the database directory from olddbname to newdbname
3. Started mysql
 
At this point, I grepped for 'olddbname' and found that many of the old
.MYI files still had references to 'olddbname'. So I...
 
4. Did mysqlcheck -o newdbname
 
Then all the references to 'olddbname' were removed from the index
files.
 
I then started our application and everything seems to be working fine
using the new database name. Yet I'm still worried because when I Google
it, I see people talking about lots of different ways to do a database
rename, and people are making it sound like a complicated, dangerous
procedure.
 
Why would my simple approach not work? Should I be watching for
potential problems down the road because I did it this way?
 

--
Eric Robinson
Director of Information Technology
Physician Select Management, LLC
775.885.2211 x 111

 

Thread
Rename Database - Why Would This Not Work?Eric Robinson21 Nov
  • Re: Rename Database - Why Would This Not Work?Rob Wultsch21 Nov
RE: Rename Database - Why Would This Not Work?Eric Robinson21 Nov
  • Re: Rename Database - Why Would This Not Work?Rob Wultsch22 Nov
    • Re: Rename Database - Why Would This Not Work?Michael Dykman22 Nov
RE: Rename Database - Why Would This Not Work?Eric Robinson23 Nov
  • Re: Rename Database - Why Would This Not Work?Jim Lyons23 Nov
  • Re: Rename Database - Why Would This Not Work?Johan De Meersman23 Nov
    • Re: Rename Database - Why Would This Not Work?Rob Wultsch23 Nov