• Skip to main content
  • Skip to secondary menu
  • Skip to primary sidebar
  • Skip to footer
  • Home
  • About
  • Projects
    • GStaticMap WP Plugin
  • Contact
  • Privacy Policy

Lorenz Blog

All About Web & Mobile Application Development

  • Featured Articles
  • Gadgets
    • Android
    • Blackberry
  • Programming
    • Android
    • PHP
    • Java Script
    • MySQL
    • Postgresql
    • Flex
    • Web
  • Software
    • Mac OS
    • Windows
    • Linux
  • Web
You are Here » Home >> Information Technology >> Software >> How to Enable MySQL InnoDB Storage Engine on XAMPP

How to Enable MySQL InnoDB Storage Engine on XAMPP

March 11, 2008 by Lorensius Londa 16 Comments

InnoDB is one of MySQL storage engines, it supports transactions, row-level locking, and foreign-keys. However, by default, InnoDB is not enabled by XAMPP. To enable it, locate the my.cnf configuration file (normally in C:/xampp/mysql/bin directory) and search for the following lines:

# Comment the following if you are using InnoDB tables
skip-innodb
#innodb_data_home_dir = “C:/xampp/mysql/”
#innodb_data_file_path = ibdata1:10M:autoextend
#innodb_log_group_home_dir = “C:/xampp/mysql/”
#innodb_log_arch_dir = “C:/xampp/mysql/”
## You can set .._buffer_pool_size up to 50 – 80 %
## of RAM but beware of setting memory usage too high
#innodb_buffer_pool_size = 16M
#innodb_additional_mem_pool_size = 2M
## Set .._log_file_size to 25 % of buffer pool size
#innodb_log_file_size = 5M
#innodb_log_buffer_size = 8M
#innodb_flush_log_at_trx_commit = 1
#innodb_lock_wait_timeout = 50

Modify the lines and it should look like this:

# Comment the following if you are using InnoDB tables
#skip-innodb
innodb_data_home_dir = “C:/xampp/mysql/”
innodb_data_file_path = ibdata1:10M:autoextend
innodb_log_group_home_dir = “C:/xampp/mysql/”
innodb_log_arch_dir = “C:/xampp/mysql/”
## You can set .._buffer_pool_size up to 50 – 80 %
## of RAM but beware of setting memory usage too high
innodb_buffer_pool_size = 16M
innodb_additional_mem_pool_size = 2M
## Set .._log_file_size to 25 % of buffer pool size
innodb_log_file_size = 5M
innodb_log_buffer_size = 8M
innodb_flush_log_at_trx_commit = 1
innodb_lock_wait_timeout = 50

You can change the paremeters as you want, save it and then restart mysql service. To check wheter InnoDB is already enabled, go to Phpmyadmin page, point to Storage Engines menu and it should look like this:

innodb.jpg

Note:

If you have made changes as mentioned above but it still won’t work, try to locate my.ini file on WINDOWS directory, make the same changes on it and restart mysql. Sometimes during installation default my.cnf file will be copied into WINDOWS directory as my.ini and mysql uses it as default configuration file.

Facebooktwitterredditpinterestlinkedinmailby feather

Related posts:

  1. How to Empty All Tables in a MySQL Database with PHP
  2. How to Enable Theme in Google Apps
  3. How to Enable Android Jelly Bean OTA Update on Nexus S
  4. How to Set Time Zone in PHP and MySQL

Filed Under: Featured Articles, Information Technology, Software Tagged With: enable innodb, InnoDB, Mysql, mysql innodb, phpmyadmin, phpmyadmin innodb, XAMPP, xampp innodb

About Lorensius Londa

Passionate web and mobile application developer. Co-founder of TRUSTUDIO, loves programming, Android, aviation, travelling, photography, coffee and gym mania.

Reader Interactions

Comments

  1. spox says

    April 24, 2008 at 1:22 pm

    good article, i am sure xampp is very useful.

    Reply
  2. nugroho says

    May 10, 2008 at 8:58 pm

    I’ve tried it but still not works.. InnoDB still disabled although I’ve restart the xampp. Can u help me?

    Reply
  3. lorenz says

    May 12, 2008 at 1:49 pm

    I’ve never experienced like that,it always work. What xampp version do you use?The main line to comment is “skip-innodb”, make sure you’ve commented it and try to stop mysql service and start again.

    Reply
  4. Dele Agagu says

    May 15, 2008 at 1:46 am

    I tried the above but whatever changes i made to my.cnf file wasnt reflective on restarting mysql instance. The following worked for me:

    1. If you have MYSQL SYSTEM TRAY MONITOR, launch it – you will a little icon on the notification task bar on your windows machine.

    2. Right click it and choose Configure instance.

    3. Select Startup Variables on the left item listings.

    4. Toggle to InnoDB Parameters tab.

    5. At the footer of the window you will see a label:
    Options file: C:\WINDOWS\my.ini
    Section: mysqld

    6. On the further right of this label click on the

    Reply
  5. Dele Agagu says

    May 15, 2008 at 1:59 am

    I tried the above but whatever changes i made to my.cnf file in apachefriends folder, nothing was working. The following worked for me:

    1. If you have MYSQL SYSTEM TRAY MONITOR installed on your machine (it is bundled with MYSQL QUERY BROWSER), launch it – you will see a little icon on the notification task bar on your windows machine.

    2. Right click it and choose “Configure instance”.

    3. Select “Startup Variables” on the left item listings.

    4. Toggle to “InnoDB Parameters” tab. Select “Activate InnoDB”. You will notice all your settings are disabled.( to change your settings/uncomment as mentioned above, follow the next steps)

    5. At the footer of the InnoDB tab window you will see a label:
    Options file: C:\WINDOWS\my.ini
    Section: mysqld

    So this is where my configuration file was located. This ini file took precedent over the apachefriends folder > my.cnf. Locate this file and simply follow the uncommenting procedure of this post and save.

    6. Stop the mysql service by right clicking on the Monitor tray again. Select “Shutdown Instance”.

    7. Right click again and Select “Start Instance”.

    8. Now you will see all your InnoDB variables settings. 🙂

    Reply
  6. arifromdhoni says

    May 15, 2008 at 1:34 pm

    Thank you for your information. It works for me. But I’d installed XAMPP on C:/Program Files/xampp/ so all folders begin with C:/Program Files/xampp/ instead of C:/xampp/

    Reply
  7. Henry Cardona says

    December 10, 2008 at 10:47 am

    It was difficult to find the start options of mysql in my installation.

    Finally I found this information: http://dev.mysql.com/doc/refman/5.0/en/resetting-permissions.html

    There are several lines that help me to understand:
    “The appropriate –defaults-file setting can be found using the Services Manager:

    Start Menu -> Control Panel -> Administrative Tools -> Services

    Find the MySQL service in the list, right-click on it, and choose the Properties option. The Path to executable field contains the –defaults-file setting. ”

    The right settings worked when I changed no the my.ini file but the my.cfg located in: C:\xampp\mysql\bin\my.cnf

    C:\xampp\mysql\bin\mysqld-nt –defaults-file=C:\xampp\mysql\bin\my.cnf mysql

    Reply
  8. Storage Spain says

    June 12, 2009 at 1:01 pm

    Thanks for discussion about a valuable topic like MSQL and impliments of its for data storage.

    Reply
  9. sachin says

    April 21, 2010 at 12:45 am

    In my localhost i found my.ini in windows folder(C:WINDOWSmy.ini)

    But in that file only two lines are there
    [WinMySQLAdmin]
    Server=C:/Program Files/xampp/mysql/bin/mysqld-nt.exe

    Please help me how to enable INNODB in xampp

    Reply
  10. Lorenz says

    April 21, 2010 at 6:56 am

    Hi sachin,

    Add the following lines to your my.ini

    innodb_data_home_dir = “C:/Program Files/xampp/mysq”
    innodb_data_file_path = ibdata1:10M:autoextend
    innodb_log_group_home_dir = “C:/Program Files/xampp/mysq”
    innodb_log_arch_dir = “C:/Program Files/xampp/mysq”

    innodb_buffer_pool_size = 16M
    innodb_additional_mem_pool_size = 2M

    innodb_log_file_size = 5M
    innodb_log_buffer_size = 8M
    innodb_flush_log_at_trx_commit = 1
    innodb_lock_wait_timeout = 50

    Don’t forget to restart mysql server after doing the modification.

    Reply
    • paulrajj says

      September 1, 2010 at 7:25 pm

      @ Lorenz,
      Thanks for sharing this.
      I am using Xampp version 1.7.2 and mysql version 5.1.37
      I did all the corresponding changes to my.cnf file under mysql/bin folder and restarted mysql server.
      Still InnoDB feature is not been enabled and i dont find my.ini file under WINDOWS folder.
      Is there any other way or option to enable this ?

      Reply
      • lorenz says

        September 4, 2010 at 10:42 am

        Did you start mysql as service? if yes, see comment by Henry Cardona above. You can find where the right my.ini is located.

        Hope it helps

        Reply
  11. aditya says

    October 22, 2011 at 4:14 pm

    Nice post, it’s very useful.
    thanks

    Reply
  12. Eemon says

    October 23, 2011 at 2:50 am

    Thanks to Aditya for providing me this nice link. Helpful kit.

    Reply
  13. Janar says

    February 6, 2012 at 8:58 pm

    Thank you for the info. Thanks to your hint to look into the engines section I found that “InnoDB is the default storage engine on this MySQL server. ”

    So thank you very much 😀

    Reply

Leave a Reply Cancel reply

Your email address will not be published. Required fields are marked *

Primary Sidebar

About Me

A husband, father of two, passionate software developer, diy lover and home baker who loves to learn new things. Read More…

  • Facebook
  • GitHub
  • Google+
  • Instagram
  • Twitter
  • YouTube

Featured Articles

How to Setup MQTT Server Using Mosquitto and Libwebsocket on Freebsd

Blue Bamboo P25 Printer Android Demo Application With Source Code

Simple JSON RPC Client for Android

How to Send Message to Google Cloud Messaging (GCM) Server Using JSON and PHP

Footer

Recent Comments

  • Aditya Dabas on About
  • Ayten Göksenin Barutçu on How to Make Android Map Scrollable Inside a ScrollView Layout
  • mang jojot on About
  • Hussain on How to Programmatically Scan or Discover Android Bluetooth Devices

Recent Posts

  • How to Fix Blank Screen on WordPress Add/Edit Post Page
  • How to Programmatically Restart the ESP32 Board
  • How to Get Hardware Info of ESP32
  • How to Setup MQTT Server Using Mosquitto and Libwebsocket on Freebsd

Latest Tweets

  • @tricahyono_bowo @infobandung @infobdg Wah kejauhan om 355 days ago
  • Wilujeng enjing sadayana..Mohon info tempat powder coating dan sandblasting yg recommended di Bandung dunk @infobandung @infobdg359 days ago

Copyright © 2023 · Magazine Pro on Genesis Framework · WordPress · Log in