mc_mysql / mysql functions¶
-
mc_states.modules.mc_mysql.
settings
(**kwargs)¶ mysql settings
- isPercona
- TDB
- isOracle
- TDB
- isMariaDB
- TDB
- number_of_table_indicator
- number of tables contained in the database
- port
- TBD
- user
- TBD
- group
- TBD
- root_passwd
- autogenerated root password (can be overriden before db install)
- sharedir
- TBD
- users
- TBD
- datadir
- TBD
- tmpdir
- TBD
- etcdir
- TBD
- logdir
- TBD
- basedir
- TBD
- sockdir
- TBD
- conn_host / conn_user / conn_pass
- autogenerated Connection settings, user/pass/host used by salt to manage users, grants and database creations
- character_set
- default character set on CREATE DATABASE (use utf8’ not ‘utf-8’)
- collate
- default collate on CREATE DATABASE
- noDNS
- Avoid name resolution on connections checks, must-have. This is the skip-name-resolv option
- memory_usage_percent / available_mem
- the macro will compute magiccaly the settings to fit this percentage of full memory on the host. So by default it’s 50% of all RAM on a dev envirronment and 85% for a production one where the MySQl server should be alone on a server. Then all others settings parameters in the ‘tunning’ key could be set to False to let the macro fill the gaps. If you set somtehing other than False for one of theses settings it will be used instead of the value computed by the macro, check the macro for details and comments on all theses parameters. Note the “_M” means Mo, so for 2Go of innodb_buffer_pool_size use 2024, that is 2024Mo. Tweak the ‘number_of_table_indicator’ to adjust some settings automatically from that, for example several Drupal instances using a lot of fields could manage several hundreds of tables. <=== IMPORTANT
If you want to fine tune the mysql server, read the method to know non documented parameters to override, the code is well documented but spared from configuration from end users.