Posted on March 30, 2012, 4:33 pm, by Rhys, under
Bash,
DBA,
Linux.
I’ve been busy setting up the Percona Nagios MySQL Plugins but ran into an issue with the pmp-check-mysql-deleted-files plugin; UNK could not list MySQL’s open files After a little debugging we tracked this down to a problem caused by running multiple instances of mysqld. This is something the script author (Baron Schwartz) mentions in his [...]
Posted on March 7, 2012, 6:42 pm, by Rhys, under
DBA,
Linux.
I’m working on a script to do some basic auditing of my Linux servers. One thing I want to record is the install details from an rpm query. The following command will provide us with some basic details of the rpms installed and ordered by date. ?View Code BASHrpm -qa –queryformat ‘%{NAME} %{VERSION} %{INSTALLTIME:date}\n’ –last; [...]
I don’t have access, like many DBAs, to the inner bowels of Active Directory. While I’m more than happy for it to stay this way I still want to check that certain things have been setup correctly and haven’t been “cleaned-up” by a security nazi focused domain administrator. One such situation arose recently with Service Principal Names. SPNs [...]
Posted on March 2, 2012, 2:31 pm, by Rhys, under
DBA,
MySQL.
Here’s a very simple stored procedure I use to run some maintenance on MySQL tables. It allows you to run OPTIMIZE TABLE or ANALYZE TABLE on all (or most) tables in a MySQL database. ?View Code MYSQLDELIMITER $$ DROP PROCEDURE IF EXISTS `db_maintenance`$$ CREATE DEFINER = ‘root’@'%’ PROCEDURE db_maintenance ( IN p_mode TINYINT, [...]