Commit graph

38 commits

Author SHA1 Message Date
Micah Anderson
ad04b1fbe7 Merge remote-tracking branch 'lelutin/squeeze_my_cnf' into shared 2012-04-11 18:25:17 -04:00
Gabriel Filion
8180e27115 Import my.cnf from Debian Squeeze
Lenny support was phased out and squeeze is the current stable.

There is an instruction in the file that originally came from lenny:
skip-bdb doesn't exist anymore in the mysql version in squeeze, so the
config file makes a fresh mysql install crash on Squeeze.

Signed-off-by: Gabriel Filion <lelutin@gmail.com>
2012-04-09 02:26:23 -04:00
Micah Anderson
d66e58c325 Merge commit '356fdab8147f8a32a3f14514f2bb77f4f312c734' into shared
Conflicts:
	files/munin/mysql_connections
	manifests/server/base.pp
	manifests/server/munin/default.pp
2012-03-07 11:49:28 -05:00
Micah Anderson
e9ff8b6a23 Merge remote-tracking branch 'lelutin/root_pw_no_arg' into shared
Conflicts:
	manifests/server/base.pp
2012-03-07 11:02:01 -05:00
mh
356fdab814 add some other mysql plugins 2010-12-21 22:10:34 +01:00
Gabriel Filion
e894ddb718 Avoid root password leak to process list
The current procedure of setting the root MySQL password leaks the root
password by giving it to the setmysqlpass.sh script on the command line.
This means that during the couple of seconds that the script is
executing, the password is visible in the process list!

Since we're already writing the password in the /root/.my.cnf file, make
the setmysqlpass.sh script parse this file to retrieve the password
instead of receiving it from a command line argument.

Also, in some shells the 'echo' command might appear in the process
list. Use a heredoc notation to create the output without using a
command.

Signed-off-by: Gabriel Filion <lelutin@gmail.com>
2010-12-18 12:50:17 +01:00
Gabriel Filion
af8b414c32 Avoid root password leak to process list
The current procedure of setting the root MySQL password leaks the root
password by giving it to the setmysqlpass.sh script on the command line.
This means that during the couple of seconds that the script is
executing, the password is visible in the process list!

Since we're already writing the password in the /root/.my.cnf file, make
the setmysqlpass.sh script parse this file to retrieve the password
instead of receiving it from a command line argument.

Also, in some shells the 'echo' command might appear in the process
list. Use a heredoc notation to create the output without using a
command.

Signed-off-by: Gabriel Filion <lelutin@gmail.com>
2010-12-15 08:30:53 -05:00
Micah Anderson
9583889456 add mysql munin graphs and adjust the file distribution to match the right location of where they are 2010-11-01 19:43:23 -04:00
Micah Anderson
fa67257056 . remove the check_mysql_health script from the mysql module, instead it belongs in the nagios module
. change the default nagios::service::mysql check to use the check_mysql_health 'connection-time' check mode, which is identical to the original check, with some additional information

. stop using nagios::plugin::deploy because this doesn't work when more than one node attempts to realize this class

. stop exporting the nagios_command because this doesn't work when more than one node attempts to realize this class

. remove the check_health define, instead this be how it was before, as the previous nagios::service::mysql define
2010-10-18 20:52:42 -04:00
Micah Anderson
9463479afa add new version of check_mysql_health plugin 2010-10-17 14:30:59 -04:00
Micah Anderson
784bd6271f add a more advanced mysql health check plugin:
* create a mysql::server::nagios::base class with the common parts needed for the basic plugin, and the health plugin
 * make mysql::server:nagios inherit mysql::server:nagios::base
 * create a new class mysql::server::nagios::check_health inheriting ::base

the nagios module has also received a new define to setup the different nagios::service pieces for the different health check modes that might be desired

its assumed you would setup the different health check modes in site-mysql/init.pp as different hosts will require different modes and/or parameters, for example:

class site-mysql::server {
  include mysql::server::nagios::check_health

  nagios::service::mysql_health { [ 'connection-time', 'uptime', 'threads-connected', 'threadcache-hitrate' ]:
    require => Mysql_grant[$nagios_mysql_user],
  }

  case $hostname {
    "eider": {
      nagios::service::mysql_health { [ 'slave-io-running', 'slave-sql-running', 'slave-lag' ]:
    require => Mysql_grant[$nagios_mysql_user],
      }
    }
  }
}
2010-09-27 13:18:51 -04:00
Micah Anderson
a3e7b031a3 Merge remote branch 'remotes/immerda/master'
Conflicts:
	manifests/server/base.pp
2010-09-22 13:12:51 -04:00
Micah Anderson
eaf52f77a3 increase timeout before killing to account for slower startup speed of larger databases 2010-09-22 12:55:10 -04:00
mh
828e93c72d as we are in ruby we need to double escape that 2010-04-04 12:27:12 +02:00
mh
d40e1130bc escape table and db names 2010-04-04 12:21:33 +02:00
mh
b296d7a710 improve optimize script to work as well on weird named tables 2010-04-02 17:52:44 +02:00
Jerome Charaoui
9ec0ef766c make backup and optimize cron jobs optional; introduce $mysql_backup_cron, $mysql_backup_dir and$mysql_optimize_cron; use a module_dir for scripts 2009-12-10 14:52:50 -05:00
Jerome Charaoui
dcc761cbfd add Debian support 2009-12-10 12:22:25 -05:00
mh
911dbc4426 be nicer during mysql backup
sometimes it can happen that by locking all tables we run into
error 24, which means to many open files.

According to http://rackerhacker.com/2007/08/19/mysql-errcode-24-when-using-lock-tables/
we can use single-transaction to be nicer during backups.
2009-11-19 02:36:13 +01:00
mh
d4cccaa62f set home so .my.cnf is found as we run it as cron weekly 2009-02-22 13:07:39 +00:00
mh
95c5cd82d9 fixing integer conversion 2009-02-22 13:02:08 +00:00
mh
288a33be75 merged with puzzle 2009-02-21 17:22:47 +00:00
mh
2dc631bd2a Merge commit 'puzzle/development' 2008-10-19 22:15:48 +00:00
mh
0403071c55 optimized default my.cnf 2008-08-07 10:09:21 +00:00
mh
aa99ee9826 merged with puzzle 2008-08-07 09:24:59 +00:00
mh
f0ade619a0 if we enable binary logs, we should also enable max days for them 2008-07-29 22:23:29 +00:00
mh
741a6ba1f6 merged with immerda, added data directory to be default 2008-07-14 21:25:49 +00:00
mh
7c987d7fe6 fixed log-bin location 2008-07-13 14:19:37 +00:00
mh
c7752a3775 fixing bin-log param 2008-07-11 15:40:49 +00:00
mh
58d0f7698f moved it to note clear about the used distribution 2008-07-11 14:45:13 +00:00
mh
1c5d976759 fixed merge regressions 2008-07-11 14:15:13 +00:00
mh
3a8613ab9d merged with puzzle 2008-07-11 14:13:03 +00:00
mh
15a84a8199 removed unneeded files 2008-07-01 18:33:27 +00:00
mh
b1e3145849 removed unneeded files 2008-07-01 18:33:22 +00:00
mh
f2db68fc8f removed unneeded files 2008-07-01 18:33:18 +00:00
mh
25fbef8060 merged with puzzle 2008-07-01 18:29:30 +00:00
mh
5c17a7fda8 merged with puzzle 2008-06-13 20:16:32 +00:00
andreas
fb948dd6b0 mysql dist-file in module 2008-02-29 20:14:05 +00:00