kelly johnson
kelly johnson

Reputation: 1636

Where else can the variable innodb_buffer_pool_size be accessed besides my.cnf?

I've installed MAMP and have the latest phpMyAdmin on my Mac. I do not have a my.cnf nor a my.ini file. Yes, I have enabled all invisible files.

I've heard the free version of MAMP doesn't let you, but that doesn't seem right. I know MAMPPro has a drop-down but I'm not buying that.

What else could the file be called?

EDIT: I used grep to search for innodb_buffer_pool_size within the entire MAMP folder and the only files that had that variable inside were assigning an array to it, not just a simple size. Just for more completeness on this question.

Upvotes: 18

Views: 60749

Answers (2)

RolandoMySQLDBA
RolandoMySQLDBA

Reputation: 44343

You can do the following:

MySQL 5.0+

SHOW VARIABLES LIKE 'innodb_buffer_pool_size';

MySQL 5.1+

SELECT variable_value FROM information_schema.global_variables
WHERE variable_name = 'innodb_buffer_pool_size';

In order to set it for MySQL, you must have a physically manifest my.cnf or my.ini

Add this to the config file

[mysqld]
innodb_buffer_pool_size = 1G

and restart mysql

You can try placing the my.cnf in /etc and restarting mysql

Please keep in mind that 128M is the default value for innodb_buffer_pool_size in MySQL 5.5. Once you get my.cnf in the correct place in the DB Server and restart mysql, things will be different.

Upvotes: 40

daemonofchaos
daemonofchaos

Reputation: 795

If you have a configuration file for MySQL from MAMP then it would be located in /Applications/MAMP/db/mysql/my.cnf.

If there is no configuration file then the default value of 8MB.

Upvotes: 0

Related Questions