Skip to main content

How to disable InnoDB in MySQL



If you do not need to use InnoDB storage for your site databases, you can disable this type of storage to save server resources.

Open the file /etc/mysql/my.cnf and add the following lines:


  innodb = OFF
 default-storage-engine = MyISAM 

Then we save the changes and restart the mysql server.

service mysql restart

Next, look at the log / var / log / syslog for errors.


  tail -200 / var / log / syslog |  grep mysql 

We are looking for errors, like this:

  [Warning] Failed to load slave replication state from table mysql.gtid_slave_pos: 1286: Unknown storage engine 'InnoDB' 

If there are such errors, then turn InnoDB back. Go to the mysql server, select the database mysql> use mysql; , and change the repository for it to myisam mysql> ALTER TABLE `mysql.gtid_slave_pos` ENGINE=MyISAM; .

We do the same with everyone. After changing the storage type, you can disable innodb and restart mysql again.




How do you rate the article?
Звёзд: 1Звёзд: 2Звёзд: 3Звёзд: 4Звёзд: 5 ( 1 rating, average: 4.00 out of 5)
Loading...

Add a comment

Your email will not be published.