aboutsummaryrefslogtreecommitdiffstats
path: root/databases
diff options
context:
space:
mode:
authormiwi <miwi@FreeBSD.org>2006-11-24 06:22:24 +0800
committermiwi <miwi@FreeBSD.org>2006-11-24 06:22:24 +0800
commitb6a75a950b7d52cafa5f30e7ec2f3103488514bf (patch)
tree69de85b90bf4a8921ac6a63be1bc2958781efa46 /databases
parent28af77d4915da44f4e0f0d0c387ab915817000d9 (diff)
downloadfreebsd-ports-graphics-b6a75a950b7d52cafa5f30e7ec2f3103488514bf.tar.gz
freebsd-ports-graphics-b6a75a950b7d52cafa5f30e7ec2f3103488514bf.tar.zst
freebsd-ports-graphics-b6a75a950b7d52cafa5f30e7ec2f3103488514bf.zip
mysqlsla analyzes general, slow, and raw MySQL statement logs.
mysqlsla can read multiple MySQL general and slow logs (and logs containing raw SQL statements), combine them, then run various analyses on all the queries. In addition, mysqlsla can correlate the analyses so that the queries in one analysis are used as the basis for subsequent analyses. Other options include limiting the output of each analysis to the top N queries, averaging execution time over N runs, customizing the order in which the analyses are ran, statement filtering, statement pattern matching, and mysqldumpslow-like formatting. WWW: http://hackmysql.com/mysqlsla PR: ports/105788 Submitted by: Alexander Zhuravlev <zaa at zaa.pp.ru>
Diffstat (limited to 'databases')
-rw-r--r--databases/Makefile1
-rw-r--r--databases/mysqlsla/Makefile43
-rw-r--r--databases/mysqlsla/distinfo3
-rw-r--r--databases/mysqlsla/files/patch-mysqlsla11
-rw-r--r--databases/mysqlsla/pkg-descr12
5 files changed, 70 insertions, 0 deletions
diff --git a/databases/Makefile b/databases/Makefile
index 53d9a09cb09..6b41969fc78 100644
--- a/databases/Makefile
+++ b/databases/Makefile
@@ -157,6 +157,7 @@
SUBDIR += mysqlcppapi
SUBDIR += mysqlman
SUBDIR += mysqlreport
+ SUBDIR += mysqlsla
SUBDIR += mysqltcl
SUBDIR += mytop
SUBDIR += namazu2
diff --git a/databases/mysqlsla/Makefile b/databases/mysqlsla/Makefile
new file mode 100644
index 00000000000..b508a278100
--- /dev/null
+++ b/databases/mysqlsla/Makefile
@@ -0,0 +1,43 @@
+# New ports collection makefile for: mysqlsla
+# Date created: 2006-11-23
+# Whom: Alexander Zhuravlev <zaa@zaa.pp.ru>
+#
+# $FreeBSD$
+
+PORTNAME= mysqlsla
+PORTVERSION= 1.3
+CATEGORIES= databases
+MASTER_SITES= http://hackmysql.com/scripts/
+EXTRACT_SUFX= .tgz
+
+MAINTAINER= zaa@zaa.pp.ru
+COMMENT= Mysqlsla analyzes general, slow, and raw MySQL statement logs
+
+RUN_DEPENDS= ${SITE_PERL}/${PERL_ARCH}/Term/ReadKey.pm:${PORTSDIR}/devel/p5-Term-ReadKey \
+ ${SITE_PERL}/${PERL_ARCH}/DBD/mysql.pm:${PORTSDIR}/databases/p5-DBD-mysql
+
+USE_PERL5= yes
+NO_BUILD= yes
+NO_WRKSUBDIR= yes
+
+PLIST_FILES= bin/mysqlsla
+PORTDOCS= mysqlsladoc.html
+
+.include <bsd.port.pre.mk>
+
+.if ${PERL_LEVEL} < 500805
+RUN_DEPENDS+= ${SITE_PERL}/${PERL_ARCH}/Time/HiRes.pm:${PORTSDIR}/devel/p5-Time-HiRes
+.endif
+
+do-install:
+ @${INSTALL_SCRIPT} ${WRKSRC}/mysqlsla ${PREFIX}/bin
+
+.if !defined(NOPORTDOCS)
+ @${ECHO_MSG} "===> Installing documentation for ${PKGNAME}"
+ @${MKDIR} ${DOCSDIR}
+. for i in ${PORTDOCS}
+ @${INSTALL_DATA} ${WRKSRC}/${i} ${DOCSDIR}
+. endfor
+.endif
+
+.include <bsd.port.post.mk>
diff --git a/databases/mysqlsla/distinfo b/databases/mysqlsla/distinfo
new file mode 100644
index 00000000000..3a6b09e71b3
--- /dev/null
+++ b/databases/mysqlsla/distinfo
@@ -0,0 +1,3 @@
+MD5 (mysqlsla-1.3.tgz) = fc426c50e084e3be5aedfccd6f395fac
+SHA256 (mysqlsla-1.3.tgz) = bd286d4071de17a04cfafaccae05bdab9fb9089cafe626d0b6fba14b46eba7a0
+SIZE (mysqlsla-1.3.tgz) = 14372
diff --git a/databases/mysqlsla/files/patch-mysqlsla b/databases/mysqlsla/files/patch-mysqlsla
new file mode 100644
index 00000000000..70e9bffbe09
--- /dev/null
+++ b/databases/mysqlsla/files/patch-mysqlsla
@@ -0,0 +1,11 @@
+--- mysqlsla.orig Thu Nov 23 18:31:31 2006
++++ mysqlsla Thu Nov 23 18:31:47 2006
+@@ -115,7 +115,7 @@ if( (!$op{'general'} && !$op{'slow'} &&
+
+ $op{'host'} ||= 'localhost';
+ $op{'port'} ||= 3306;
+-$op{'socket'} ||= '/var/run/mysqld/mysqld.sock';
++$op{'socket'} ||= '/tmp/mysql.sock';
+ $op{'avg'} ||= 1;
+ $op{'top'} ||= 0;
+ if(have_op 'safe') { $op{'filter'} = "-*,+SELECT,+USE"; }
diff --git a/databases/mysqlsla/pkg-descr b/databases/mysqlsla/pkg-descr
new file mode 100644
index 00000000000..e45f297ee1f
--- /dev/null
+++ b/databases/mysqlsla/pkg-descr
@@ -0,0 +1,12 @@
+mysqlsla analyzes general, slow, and raw MySQL statement logs.
+mysqlsla can read multiple MySQL general and slow logs (and logs
+containing raw SQL statements), combine them, then run various
+analyses on all the queries. In addition, mysqlsla can correlate
+the analyses so that the queries in one analysis are used as the
+basis for subsequent analyses. Other options include limiting the
+output of each analysis to the top N queries, averaging execution
+time over N runs, customizing the order in which the analyses are
+ran, statement filtering, statement pattern matching, and
+mysqldumpslow-like formatting.
+
+WWW: http://hackmysql.com/mysqlsla