You are heremySQL Monitoring & Tuning with mysqladr
mySQL Monitoring & Tuning with mysqladr
INSTALLATION of mysqlard
wget ftp.suse.com:/pub/suse/i386/9.0/suse/src/rrdtool-1.0.45-37.src.rpm
tar xzf
cd /usr/local/src/
wget wget http://www.sos.be/tiki-download_file.php?fileId=6
mv mv tiki-download_file.php?fileId=6 myslqard-0.9.1.tar.gz
tar xzvf myslqard-0.9.1.tar.gz
cd mysqlard-0.9.1
./configure --prefix=/usr --sysconfdir=/etc --datadir=/var/lib
make
make install
cp /var/lib/mysqlard/mysqlard.cnf /usr/local/etc/
vi mysqlard.pid
22300
vi /var/lib/mysqlard/mysqlard.server
# Source the config script
. /usr/local/etc/mysqlard.cnf######################
# Options, change them in /usr/local/etc/mysqlard.cnf or you can override
# them here, but that's not recommended. Read the comments in
# /usr/local/etc/mysqlard.cnf if you want to know what you're changing.step=${step:="60"}
minsamples=${minsamples:="720"}
datadir=${datadir:="/usr/local/share/mysqlard"}
pidfile=${pidfile:="/var/run/mysqlard.pid"}
RRDTOOL=${RRDTOOL:="/usr/local/bin/rrdtool"}
MYSQLARD=${MYSQLARD:="/usr/sbin/mysqlard"}
######################
vi /usr/local/etc/mysqlard.cnf
# Where the RRD files are stored
datadir="/usr/local/share/mysqlard"
# Where the graphs are stored
imgdir="${datadir}"
# Where the archived graphs are stored
archivedir="${imgdir}/archive"
# Full path to rrdtool
RRDTOOL="/usr/local/bin/rrdtool"
# Full path to the daemon
MYSQLARD="/usr/sbin/mysqlard" #=========
# PID file name
pidfile="/usr/local/etc/mysqlard.pid"
# Step time between samples in seconds.
step="60"
ls -l /var/lib/mysqlard -l
total 60
-rw-r--r-- 1 root root 722 May 10 00:19 mysql.gif
-rw-r--r-- 1 root root 403 May 10 00:19 mysqlar.daily
-rw-r--r-- 1 root root 410 May 10 00:19 mysqlar.monthly
-rw-r--r-- 1 root root 17734 May 10 00:19 mysqlar.php
-rw-r--r-- 1 root root 407 May 10 00:19 mysqlar.weekly
-rw-r--r-- 1 root root 1694 May 10 00:19 mysqlard.cnf
-rwxr-xr-x 1 root root 4217 May 10 00:19 mysqlard.server
-rw-r--r-- 1 root root 1934 May 10 00:19 rrdtool.gif
-rw-r--r-- 1 root root 1284 May 10 00:19 sos.gif
-rw-r--r-- 1 root root 1646 May 10 00:19 style.css
Links:
http://www.sos.be/tiki-index.php?page=MySQL+Activity+Report
Output of ./configure --prefix=/usr --sysconfdir=/etc --datadir=/var/lib
checking for a BSD-compatible install... /usr/bin/install -c
checking whether build environment is sane... yes
checking for gawk... gawk
checking whether make sets $(MAKE)... yes
checking for gcc... gcc
checking for C compiler default output... a.out
checking whether the C compiler works... yes
checking whether we are cross compiling... no
checking for suffix of executables...
checking for suffix of object files... o
checking whether we are using the GNU C compiler... yes
checking whether gcc accepts -g... yes
checking for gcc option to accept ANSI C... none needed
checking for style of include used by make... GNU
checking dependency style of gcc... gcc3
checking whether ln -s works... yes
checking for mv... /bin/mv
checking for rm... /bin/rm
checking for cp... /bin/cp
checking for sed... /bin/sed
checking for date... /bin/date
checking for dirent.h that defines DIR... yes
checking for library containing opendir... none required
checking how to run the C preprocessor... gcc -E
checking for egrep... grep -E
checking for ANSI C header files... yes
checking for sys/types.h... yes
checking for sys/stat.h... yes
checking for stdlib.h... yes
checking for string.h... yes
checking for memory.h... yes
checking for strings.h... yes
checking for inttypes.h... yes
checking for stdint.h... yes
checking for unistd.h... yes
checking for string.h... (cached) yes
checking syslog.h usability... yes
checking syslog.h presence... yes
checking for syslog.h... yes
checking for unistd.h... (cached) yes
checking for an ANSI C-conforming const... yes
checking for pid_t... yes
checking for unistd.h... (cached) yes
checking vfork.h usability... no
checking vfork.h presence... no
checking for vfork.h... no
checking for fork... yes
checking for vfork... yes
checking for working fork... yes
checking for working vfork... (cached) yes
checking for stdlib.h... (cached) yes
checking for GNU libc compatible malloc... yes
checking for vprintf... yes
checking for _doprnt... no
checking for strdup... yes
checking rrd.h usability... yes
checking rrd.h presence... yes
checking for rrd.h... yes
checking for rrd_update in -lrrd... yes
checking for rrdtool... /usr/local/bin/rrdtool
checking for mysql_config... /usr/bin/mysql_config
configure: creating ./config.status
config.status: creating Makefile
config.status: creating src/Makefile
config.status: creating man/Makefile
config.status: creating config.h
config.status: config.h is unchanged
config.status: executing depfiles commands
Output of make
make all-recursive
make[1]: Entering directory `/usr/local/src/mysqlard-0.9.1'
Making all in src
make[2]: Entering directory `/usr/local/src/mysqlard-0.9.1/src'
make[2]: Nothing to be done for `all'.
make[2]: Leaving directory `/usr/local/src/mysqlard-0.9.1/src'
Making all in man
make[2]: Entering directory `/usr/local/src/mysqlard-0.9.1/man'
make[2]: Nothing to be done for `all'.
make[2]: Leaving directory `/usr/local/src/mysqlard-0.9.1/man'
make[2]: Entering directory `/usr/local/src/mysqlard-0.9.1'
make[2]: Leaving directory `/usr/local/src/mysqlard-0.9.1'
make[1]: Leaving directory `/usr/local/src/mysqlard-0.9.1'
Output of make install
Making install in src
make[1]: Entering directory `/usr/local/src/mysqlard-0.9.1/src'
make[2]: Entering directory `/usr/local/src/mysqlard-0.9.1/src'
/bin/sh ../config/mkinstalldirs /usr/bin
/usr/bin/install -c mysqlar_graph /usr/bin/mysqlar_graph
/bin/sh ../config/mkinstalldirs /usr/sbin
/usr/bin/install -c mysqlard /usr/sbin/mysqlard
/bin/sh ../config/mkinstalldirs /var/lib/mysqlard
mkdir -p -- /var/lib/mysqlard
/usr/bin/install -c -m 644 mysqlard.cnf /var/lib/mysqlard/mysqlard.cnf
/usr/bin/install -c -m 644 mysqlar.php /var/lib/mysqlard/mysqlar.php
/usr/bin/install -c -m 644 sos.gif /var/lib/mysqlard/sos.gif
/usr/bin/install -c -m 644 rrdtool.gif /var/lib/mysqlard/rrdtool.gif
/usr/bin/install -c -m 644 mysql.gif /var/lib/mysqlard/mysql.gif
/usr/bin/install -c -m 644 style.css /var/lib/mysqlard/style.css
/usr/bin/install -c -m 644 mysqlar.daily /var/lib/mysqlard/mysqlar.daily
/usr/bin/install -c -m 644 mysqlar.weekly /var/lib/mysqlard/mysqlar.weekly
/usr/bin/install -c -m 644 mysqlar.monthly /var/lib/mysqlard/mysqlar.monthly
/bin/sh ../config/mkinstalldirs /var/lib/mysqlard
/usr/bin/install -c mysqlard.server /var/lib/mysqlard/mysqlard.server
make[2]: Leaving directory `/usr/local/src/mysqlard-0.9.1/src'
make[1]: Leaving directory `/usr/local/src/mysqlard-0.9.1/src'
Making install in man
make[1]: Entering directory `/usr/local/src/mysqlard-0.9.1/man'
make[2]: Entering directory `/usr/local/src/mysqlard-0.9.1/man'
make[2]: Nothing to be done for `install-exec-am'.
/bin/sh ../config/mkinstalldirs /usr/man/man1
/usr/bin/install -c -m 644 ./mysqlar_graph.1 /usr/man/man1/mysqlar_graph.1
/bin/sh ../config/mkinstalldirs /usr/man/man8
/usr/bin/install -c -m 644 ./mysqlard.8 /usr/man/man8/mysqlard.8
make[2]: Leaving directory `/usr/local/src/mysqlard-0.9.1/man'
make[1]: Leaving directory `/usr/local/src/mysqlard-0.9.1/man'
make[1]: Entering directory `/usr/local/src/mysqlard-0.9.1'
make[2]: Entering directory `/usr/local/src/mysqlard-0.9.1'
make[2]: Nothing to be done for `install-exec-am'.
make[2]: Nothing to be done for `install-data-am'.
make[2]: Leaving directory `/usr/local/src/mysqlard-0.9.1'
make[1]: Leaving directory `/usr/local/src/mysqlard-0.9.1'
