You need to locate the mySQL config file (helpfully named) my.cnf file. On
linux it is located at /etc/my.cnf

Then under the [mysqld] add the following line as shown below!
*[mysqld]

default-storage_engine = InnoDB*

And don't forget to restart mysql. After this whenever you create a table
its default storage engine is InnoDB. but it will not change any existing
table storage engine to Innodb.

To do this there is two way.

a. You can change storage engine by alter command of tables, but one by one.

eg. *Alter table [tablename] engine=myisam; *

b. export the database , an then replace MyISAM with InnoDB in dump file
(sed -i 's/MyISAM/InnoDB/g' dbdump.sql) and import again.

Thanks,

On Mon, Apr 19, 2010 at 9:53 AM, Rob Wultsch <wult...@gmail.com> wrote:

> On Sun, Apr 18, 2010 at 8:31 PM, Angelina Paul <arshup...@gmail.com>
> wrote:
> > I want to change the mysql default storage engine from MyISAM to InnoDB.
> > What are the  steps involved .Is it edit my.cnf file and add a line
> > default-storage-engine=innodb and restart the mysql server?
>
> If you do not want to change any existing tables all you need to do is
> add the line to your cnf.
>
> > How I can bring my databases with mixed storage engine down without any
> data loss.
>
> mysqladmin shutdown
>
> > What steps I have to take if I encounter a page corruption in innodb
> tables.
>
> The right answer is restore from backup or failover to a slave. The
> answer you probably want is
> http://dev.mysql.com/doc/refman/5.0/en/forcing-recovery.html
>
> > why I am getting a message "*Error*: *No query specified*"  when I run a
> show engines\g commands -version (5.0.45)
>
> Exactly what are you running?
>
>
> --
> Rob Wultsch
> wult...@gmail.com
>
> --
> MySQL General Mailing List
> For list archives: http://lists.mysql.com/mysql
> To unsubscribe:
> http://lists.mysql.com/mysql?unsub=aim.prab...@gmail.com
>
>


-- 
Best Regards,

Prabhat Kumar
MySQL DBA
Datavail-India Mumbai
Mobile     : 91-9987681929
www.datavail.com

My Blog: http://adminlinux.blogspot.com
My LinkedIn: http://www.linkedin.com/in/profileprabhat

Reply via email to