├── .gitignore ├── sysbench ├── README └── conf │ ├── lu0012.inc │ ├── pitbull.inc │ ├── perro.inc │ ├── work.inc │ └── au0013.inc ├── daniel ├── spider │ ├── web │ │ ├── requirements.txt │ │ ├── Dockerfile │ │ └── app.py │ ├── Dockerfile.generator │ ├── Dockerfile │ ├── generator.sh │ ├── init │ │ └── init_srv.sh │ └── docker-compose.yml ├── galera-sst-test │ ├── Dockerfile │ └── .docker-compose.yml.swp ├── broken_active_active_replication │ ├── init_db │ │ ├── 05_replia.sql │ │ └── 01_tables.sql │ ├── README.txt │ ├── changing.sh │ └── docker-compose.yml └── MDEV-19210 │ ├── Dockerfile │ ├── deb │ ├── mariadb.cnf │ ├── compose.yml │ └── Dockerfile │ ├── mariadb.cnf │ ├── mariadb-4.x-latest-gal-amd64-rhel-8.repo │ ├── compose.yml │ └── bb-11.4-pr2726-MDEV-19210-environment-file-pkgtest-latest-amd64-rhel-8-rpm-autobake.repo ├── monitoring ├── README.txt ├── mirmon │ ├── README.md │ └── webhook │ │ ├── mirmon_update.sh │ │ └── webhook.yaml ├── gnuplot_com_commit.sh └── com_commit_monitor.sh ├── metrics └── README.md ├── anel ├── jdbc_connect_blog │ ├── mariadb_data │ │ └── data.sql │ ├── mysql_data │ │ └── data.sql │ ├── target_conf │ │ └── target.cnf │ ├── Dockerfile │ ├── target_data │ │ └── data.sql │ └── docker-compose.yaml ├── odbc_driver │ ├── MariaDB_odbc_driver_template.ini │ ├── MariaDB_odbc_data_source_template.ini │ └── MariaDB_odbc_data_source_template-root.ini ├── k8s │ └── mariadb │ │ ├── mariadb-configmap.yaml │ │ ├── mariadb-secret.yaml │ │ ├── mariadb-service.yaml │ │ ├── mariadb-deployment.yaml │ │ ├── mariadb-deployment-from-secret.yaml │ │ ├── mariadb-deployment-with-phpmyadmin.yaml │ │ ├── mariadb-sts.yaml │ │ ├── wordpress-deployment-pvc.yaml │ │ ├── mariadb-deployment-pvc.yaml │ │ └── integrated-mariadb-deployment-with-phpmyadmin.yaml ├── docker-files │ ├── mariadb_connect.dockerfile │ ├── replication-example │ │ ├── config-files │ │ │ ├── secondary-2 │ │ │ │ └── secondary-2.cnf │ │ │ ├── primarycnf │ │ │ │ └── primary.cnf │ │ │ └── secondary-1 │ │ │ │ └── secondary-1.cnf │ │ ├── secondaryinit │ │ │ └── replinit.sql │ │ └── primaryinit │ │ │ └── primaryinit.sql │ ├── ecofiles │ │ └── test-nodejs.sh │ ├── file-key-management │ │ ├── config │ │ │ └── my.cnf │ │ ├── README.md │ │ └── test.sh │ └── nodejs-docker.dockerfile ├── shell_scripts │ └── pid_namespace │ │ └── README.md ├── .tmux.conf ├── .gdbinit └── .tmux-faustin.conf ├── upgrade-test └── after-common.result ├── dbt3_benchmark ├── dbt3_mysql │ ├── flush_io_caches │ ├── mysql_queries │ │ ├── 6.sql │ │ ├── 17.sql │ │ ├── 14.sql │ │ ├── 13.sql │ │ ├── 4.sql │ │ ├── 3.sql │ │ ├── 5.sql │ │ ├── 18.sql │ │ ├── 16.sql │ │ ├── 11.sql │ │ ├── 1.sql │ │ ├── 10.sql │ │ ├── 15.sql │ │ ├── 20.sql │ │ ├── 12.sql │ │ ├── 9.sql │ │ ├── 22.sql │ │ ├── 21.sql │ │ ├── 2.sql │ │ ├── 8.sql │ │ ├── 7.sql │ │ └── 19.sql │ └── flush.c ├── tests │ ├── results_db_conf │ │ └── results_db.conf │ ├── queries_conf │ │ ├── queries-mysql_17_19_20.conf │ │ ├── queries-mariadb_17_19_20.conf │ │ └── queries-p.conf │ ├── myisam_test_q20.conf │ ├── myisam_test_mariadb_5_3_mysql_5_5_mysql_5_6_17_19_20.conf │ ├── innodb_test_mariadb_5_3_mysql_5_5_mysql_5_6.conf │ ├── test_conf │ │ ├── test_myisam.conf │ │ └── test_innodb.conf │ ├── db_conf │ │ ├── db_mariadb_5_3_innodb.conf │ │ ├── db_mysql_5_6_innodb.conf │ │ ├── postgres_9_1.conf │ │ ├── db_mysql_5_6_myisam.conf │ │ ├── db_mariadb_5_3_innodb_igor.conf │ │ ├── db_mysql_5_5_myisam.conf │ │ ├── db_mysql_5_5_innodb.conf │ │ ├── db_mariadb_5_5_innodb.conf │ │ ├── db_mariadb_5_5_myisam.conf │ │ ├── db_mariadb_5_3_myisam.conf │ │ ├── db_mariadb_5_3_myisam_icp.conf │ │ ├── db_mariadb_5_5_myisam_icp.conf │ │ └── db_mariadb_5_5_myisam_igor.conf │ └── myisam_test_mariadb_5_3_mysql_5_5_mysql_5_6.conf └── config │ ├── s10 │ └── mysql_5_5_myisam_my.cnf │ └── s30 │ └── mysql_5_5_myisam_my.cnf ├── release ├── contributors │ └── stats.sh ├── create_package_tarballs │ ├── deb_files │ │ ├── MariaDB-C74CD1D8-public.gpg │ │ └── setup_repository │ ├── sles_files │ │ ├── setup_repository │ │ └── README │ └── rhel_files │ │ ├── setup_repository │ │ └── README ├── bb-new-to-old └── install-createrepo.sh ├── README.md ├── sanja ├── gitt ├── gitcl └── restore_git_dir.sh ├── faust └── tools │ ├── vlcrec │ ├── get_subtitles │ └── screenrecord ├── merging └── show_conflicts_resolution.sh ├── sql-bench-mysql ├── basic │ ├── tcpip.sqlbt │ ├── base.sqlbt │ ├── profiling.sqlbt │ ├── grant.sqlbt │ ├── grant-db.sqlbt │ ├── memory.sqlbt │ ├── myisam.sqlbt │ ├── innodb.sqlbt │ ├── grant-column.sqlbt │ ├── compiler_au0013.cnf │ ├── compiler_lu0012.cnf │ └── compiler_pitbull.cnf ├── O2 │ ├── base.sqlbt │ ├── compiler_lu0012.cnf │ └── compiler_pitbull.cnf ├── debug │ ├── base.sqlbt │ ├── compiler_au0013.cnf │ ├── compiler_lu0012.cnf │ └── compiler_pitbull.cnf ├── debug-full │ ├── base.sqlbt │ ├── skip-safemalloc.sqlbt │ ├── compiler_lu0012.cnf │ └── compiler_pitbull.cnf ├── README.txt └── conf │ ├── lu0012.cnf │ ├── perro.cnf │ ├── au0013.cnf │ └── pitbull.cnf ├── sql-bench ├── O2 │ ├── base.sqlbt │ ├── compiler_lu0012.cnf │ └── compiler_pitbull.cnf ├── basic │ ├── base.sqlbt │ ├── profiling.sqlbt │ ├── grant.sqlbt │ ├── tcpip.sqlbt │ ├── grant-db.sqlbt │ ├── key-cache-segments.sqlbt │ ├── userstat.sqlbt │ ├── memory.sqlbt │ ├── myisam.sqlbt │ ├── innodb.sqlbt │ ├── grant-column.sqlbt │ ├── pbxt.sqlbt │ ├── aria-trans.sqlbt │ ├── aria-notrans.sqlbt │ ├── aria-trans-check.sqlbt │ ├── compiler_au0013.cnf │ ├── compiler_lu0012.cnf │ └── compiler_pitbull.cnf ├── debug │ ├── base.sqlbt │ ├── compiler_au0013.cnf │ ├── compiler_lu0012.cnf │ └── compiler_pitbull.cnf ├── debug-full │ ├── base.sqlbt │ ├── skip-safemalloc.sqlbt │ ├── skip-mutex-deadlock-detector.sqlbt │ ├── compiler_lu0012.cnf │ └── compiler_pitbull.cnf ├── README.txt └── conf │ ├── lu0012.cnf │ ├── perro.cnf │ ├── au0013.cnf │ └── pitbull.cnf ├── reporting ├── README.md ├── kaj_gets_open_prs_until_date.py └── process_gitlog_csv.py └── robert └── sighup_test.sh /.gitignore: -------------------------------------------------------------------------------- 1 | .DS_Store 2 | -------------------------------------------------------------------------------- /sysbench/README: -------------------------------------------------------------------------------- 1 | Automation scripts for sysbench >= v.05 2 | -------------------------------------------------------------------------------- /daniel/spider/web/requirements.txt: -------------------------------------------------------------------------------- 1 | flask 2 | mariadb 3 | gunicorn 4 | -------------------------------------------------------------------------------- /monitoring/README.txt: -------------------------------------------------------------------------------- 1 | Collection of tools for monitoring various aspects of the server. 2 | -------------------------------------------------------------------------------- /daniel/galera-sst-test/Dockerfile: -------------------------------------------------------------------------------- 1 | ARG BASE 2 | FROM $BASE 3 | COPY wsrep_sst_mariabackup /usr/bin/ 4 | -------------------------------------------------------------------------------- /metrics/README.md: -------------------------------------------------------------------------------- 1 | # Metrics Tools 2 | 3 | The metrics tools have moved to https://github.com/MariaDB/metrics 4 | -------------------------------------------------------------------------------- /anel/jdbc_connect_blog/mariadb_data/data.sql: -------------------------------------------------------------------------------- 1 | CREATE TABLE t_maria (t int); 2 | INSERT INTO t_maria VALUES (1),(2),(3); 3 | -------------------------------------------------------------------------------- /anel/jdbc_connect_blog/mysql_data/data.sql: -------------------------------------------------------------------------------- 1 | CREATE TABLE t_mysql (t int); 2 | INSERT INTO t_mysql VALUES (4),(5),(6); 3 | -------------------------------------------------------------------------------- /upgrade-test/after-common.result: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MariaDB/mariadb.org-tools/HEAD/upgrade-test/after-common.result -------------------------------------------------------------------------------- /monitoring/mirmon/README.md: -------------------------------------------------------------------------------- 1 | See https://fi.mariadb.org/wiki/Mariadb.org_downloads_page#Adding_a_mirror for 2 | the documentation. 3 | -------------------------------------------------------------------------------- /dbt3_benchmark/dbt3_mysql/flush_io_caches: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MariaDB/mariadb.org-tools/HEAD/dbt3_benchmark/dbt3_mysql/flush_io_caches -------------------------------------------------------------------------------- /daniel/galera-sst-test/.docker-compose.yml.swp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MariaDB/mariadb.org-tools/HEAD/daniel/galera-sst-test/.docker-compose.yml.swp -------------------------------------------------------------------------------- /daniel/spider/Dockerfile.generator: -------------------------------------------------------------------------------- 1 | FROM almalinux 2 | RUN dnf install -y mariadb bind-utils 3 | COPY generator.sh / 4 | ENTRYPOINT ["/generator.sh"] 5 | 6 | -------------------------------------------------------------------------------- /daniel/broken_active_active_replication/init_db/05_replia.sql: -------------------------------------------------------------------------------- 1 | 2 | CHANGE MASTER TO MASTER_HOST='master2', MASTER_USER='repl', MASTER_PASSWORD='replicationpass'; 3 | -------------------------------------------------------------------------------- /anel/odbc_driver/MariaDB_odbc_driver_template.ini: -------------------------------------------------------------------------------- 1 | [MariaDB ODBC 3.1 Driver] 2 | Description = MariaDB Connector/ODBC v.3.1 3 | Driver = /usr/lib/x86_64-linux-gnu/libmaodbc.so 4 | -------------------------------------------------------------------------------- /anel/k8s/mariadb/mariadb-configmap.yaml: -------------------------------------------------------------------------------- 1 | apiVersion: v1 2 | kind: ConfigMap 3 | metadata: 4 | name: mariadb-configmap 5 | data: 6 | database_url: mariadb-internal-service #name of service 7 | -------------------------------------------------------------------------------- /release/contributors/stats.sh: -------------------------------------------------------------------------------- 1 | #!/bin/sh 2 | 3 | git config mailmap.file individuals 4 | git log mariadb-10.3.5..mariadb-10.3.6 --no-merges --format="%aN"|sort -u 5 | git config mailmap.file --unset 6 | -------------------------------------------------------------------------------- /release/create_package_tarballs/deb_files/MariaDB-C74CD1D8-public.gpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MariaDB/mariadb.org-tools/HEAD/release/create_package_tarballs/deb_files/MariaDB-C74CD1D8-public.gpg -------------------------------------------------------------------------------- /anel/k8s/mariadb/mariadb-secret.yaml: -------------------------------------------------------------------------------- 1 | apiVersion: v1 2 | kind: Secret 3 | metadata: 4 | name: mariadb-secret 5 | type: Opaque 6 | data: 7 | mariadb-root-password: c2VjcmV0 #echo -n 'secret'|base64 8 | -------------------------------------------------------------------------------- /daniel/MDEV-19210/Dockerfile: -------------------------------------------------------------------------------- 1 | FROM quay.io/almalinuxorg/8-init 2 | 3 | COPY *.repo /etc/yum.repos.d 4 | 5 | RUN dnf install -y MariaDB-server 6 | 7 | COPY mariadb.cnf /etc/my.cnf.d/ 8 | VOLUME /var/lib/mysql 9 | -------------------------------------------------------------------------------- /anel/odbc_driver/MariaDB_odbc_data_source_template.ini: -------------------------------------------------------------------------------- 1 | [MariaDB-server] 2 | Description=MariaDB server 3 | Driver=MariaDB ODBC 3.1 Driver 4 | SERVER=MariaDB 5 | USER=anel 6 | PASSWORD= 7 | DATABASE=test 8 | PORT=3306 9 | -------------------------------------------------------------------------------- /anel/odbc_driver/MariaDB_odbc_data_source_template-root.ini: -------------------------------------------------------------------------------- 1 | [MariaDB-server] 2 | Description=MariaDB server 3 | Driver=MariaDB ODBC 3.1 Driver 4 | SERVER=MariaDB 5 | USER=root 6 | PASSWORD= 7 | DATABASE=mysql 8 | PORT=3306 9 | -------------------------------------------------------------------------------- /anel/docker-files/mariadb_connect.dockerfile: -------------------------------------------------------------------------------- 1 | FROM mariadb:latest 2 | LABEL maintainer="anel@mariadb.org" 3 | RUN apt-get -y update && \ 4 | apt-get install mariadb-plugin-connect -y && \ 5 | rm -rf /var/lib/apt/lists/* 6 | -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | # mariadb.org-tools 2 | This project collects together various small scripts or projects that are used for MariaDB development, but for one reason or another do not make sense to keep inside the main MariaDB source tree. 3 | -------------------------------------------------------------------------------- /daniel/MDEV-19210/deb/mariadb.cnf: -------------------------------------------------------------------------------- 1 | 2 | [mariadb] 3 | 4 | wsrep_cluster_address=gcomm://node1,node2,node3 5 | wsrep_provider=/usr/lib/galera/libgalera_smm.so 6 | binlog_format=ROW 7 | wsrep_on=ON 8 | innodb_autoinc_lock_mode=2 9 | 10 | -------------------------------------------------------------------------------- /daniel/MDEV-19210/mariadb.cnf: -------------------------------------------------------------------------------- 1 | 2 | [mariadb] 3 | 4 | wsrep_cluster_address=gcomm://node1,node2,node3 5 | wsrep_provider=/usr/lib64/galera-4/libgalera_smm.so 6 | binlog_format=ROW 7 | wsrep_on=ON 8 | innodb_autoinc_lock_mode=2 9 | 10 | -------------------------------------------------------------------------------- /daniel/spider/Dockerfile: -------------------------------------------------------------------------------- 1 | FROM mariadb:lts 2 | RUN apt-get update && \ 3 | apt-get install -y mariadb-plugin-spider && \ 4 | rm -rf /var/lib/apt/lists/* /etc/mysql/mariadb.conf.d/spider.cnf 5 | COPY init/init_srv.sh /docker-entrypoint-initdb.d/ 6 | -------------------------------------------------------------------------------- /anel/k8s/mariadb/mariadb-service.yaml: -------------------------------------------------------------------------------- 1 | apiVersion: v1 2 | kind: Service 3 | metadata: 4 | name: mariadb-internal-service 5 | spec: 6 | selector: 7 | app: mariadb 8 | ports: 9 | - protocol: TCP 10 | port: 3306 11 | targetPort: 3306 12 | -------------------------------------------------------------------------------- /daniel/MDEV-19210/mariadb-4.x-latest-gal-amd64-rhel-8.repo: -------------------------------------------------------------------------------- 1 | [Galera-mariadb-4.x] 2 | name=Galera mariadb-4.x repo (build ) 3 | baseurl=https://ci.dev.mariadb.org/galera/mariadb-4.x/e0529a8366bb4d4aaf56f9426612cd825531674f/gal-amd64-rhel-8/rpms 4 | gpgcheck=0 5 | module_hotfixes = 1 6 | -------------------------------------------------------------------------------- /anel/jdbc_connect_blog/target_conf/target.cnf: -------------------------------------------------------------------------------- 1 | [mariadb] 2 | plugin_load_add=ha_connect.so 3 | connect_jvm_path=/usr/lib/jvm/java-11-openjdk-amd64/lib/server/ 4 | connect_class_path=/usr/share/mysql/mysql-test/plugin/connect/connect/std_data/JavaWrappers.jar:/usr/share/java/mariadb-java-client.jar 5 | -------------------------------------------------------------------------------- /daniel/broken_active_active_replication/init_db/01_tables.sql: -------------------------------------------------------------------------------- 1 | 2 | CREATE TABLE tbl ( id INT PRIMARY KEY NOT NULL AUTO_INCREMENT, val TEXT, updated DATETIME NOT NULL ON UPDATE CURRENT_TIMESTAMP); 3 | 4 | INSERT INTO tbl (val) VALUES ('dog'),('cat'), ('kangaroo'), ('possum'), ('quoll'), ('quokka'); 5 | -------------------------------------------------------------------------------- /daniel/MDEV-19210/compose.yml: -------------------------------------------------------------------------------- 1 | services: 2 | node1: 3 | build: . 4 | volumes: 5 | - v1:/var/lib/mysql 6 | node2: 7 | build: . 8 | volumes: 9 | - v2:/var/lib/mysql 10 | node3: 11 | build: . 12 | volumes: 13 | - v3:/var/lib/mysql 14 | volumes: 15 | v1: {} 16 | v2: {} 17 | v3: {} 18 | -------------------------------------------------------------------------------- /sanja/gitt: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | 3 | BRANCH=`git branch|grep '^\*'|awk '{print $2}'` 4 | echo '' 5 | echo 'https://buildbot.mariadb.net/buildbot/grid?category=main&branch='${BRANCH} 6 | echo 'https://internal.mariadb.net/buildbot/grid?category=main&branch='${BRANCH} 7 | echo 'https://buildbot.mariadb.org/#/grid?branch='${BRANCH} 8 | echo '' 9 | -------------------------------------------------------------------------------- /daniel/MDEV-19210/deb/compose.yml: -------------------------------------------------------------------------------- 1 | services: 2 | node1: 3 | build: . 4 | volumes: 5 | - v1:/var/lib/mysql 6 | node2: 7 | build: . 8 | volumes: 9 | - v2:/var/lib/mysql 10 | node3: 11 | build: . 12 | volumes: 13 | - v3:/var/lib/mysql 14 | volumes: 15 | v1: {} 16 | v2: {} 17 | v3: {} 18 | -------------------------------------------------------------------------------- /sanja/gitcl: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | 3 | BRANCH=`git rev-parse --show-toplevel` 4 | 5 | if [ "${BRANCH}" = '' ] 6 | then 7 | echo '' 8 | echo 'This command mast be run from a git repository' 9 | echo '' 10 | exit 1 11 | fi 12 | (cd ${BRANCH} && \ 13 | git clean -xdff && \ 14 | git submodule foreach --recursive git clean -xdf ) 15 | -------------------------------------------------------------------------------- /anel/jdbc_connect_blog/Dockerfile: -------------------------------------------------------------------------------- 1 | ARG mariadb_version=latest 2 | FROM "mariadb:$mariadb_version" 3 | 4 | RUN apt-get update && \ 5 | apt install openjdk-11-jdk-headless \ 6 | mariadb-plugin-connect \ 7 | mariadb-test-data \ 8 | libmariadb-java -y && \ 9 | rm -rf /var/lib/apt/lists/* 10 | -------------------------------------------------------------------------------- /daniel/broken_active_active_replication/README.txt: -------------------------------------------------------------------------------- 1 | Why active master/master in async doesn't work 2 | 3 | docker compose up 4 | 5 | # this will have a replication setup between two nodes. 6 | 7 | Run ./changing.sh locally. 8 | 9 | docker exec {container} mariadb -u root -ppassword -e 'show replia status\G' 10 | 11 | Observe replication failure 12 | -------------------------------------------------------------------------------- /daniel/MDEV-19210/bb-11.4-pr2726-MDEV-19210-environment-file-pkgtest-latest-amd64-rhel-8-rpm-autobake.repo: -------------------------------------------------------------------------------- 1 | [MariaDB-bb-11.4-pr2726-MDEV-19210-environment-file-pkgtest] 2 | name=MariaDB bb-11.4-pr2726-MDEV-19210-environment-file-pkgtest repo (build 40904) 3 | baseurl=https://ci.mariadb.org/40904/amd64-rhel-8-rpm-autobake/rpms 4 | gpgcheck=0 5 | module_hotfixes = 1 6 | -------------------------------------------------------------------------------- /anel/docker-files/replication-example/config-files/secondary-2/secondary-2.cnf: -------------------------------------------------------------------------------- 1 | [mariadb] 2 | server_id=3002 # used to uniquely identify the server 3 | log-basename=my-mariadb # used to be independent of to hostname changes (otherwise is in datadir/mysql) 4 | replicate_do_db=primary_db # database to replicate 5 | #binlog-format=MIXED #default 6 | 7 | -------------------------------------------------------------------------------- /anel/docker-files/ecofiles/test-nodejs.sh: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | 3 | # Start the mysqld 4 | mysqld 5 | 6 | # Run the unit tests 7 | FILTER=unit npm test 8 | # Run the integration tests 9 | # mysql -u root -e "CREATE DATABASE IF NOT EXISTS node_mysql_test" 10 | #MYSQL_HOST=localhost MYSQL_PORT=3306 MYSQL_DATABASE=node_mysql_test MYSQL_USER=root MYSQL_PASSWORD= FILTER=integration npm test 11 | -------------------------------------------------------------------------------- /anel/docker-files/replication-example/config-files/primarycnf/primary.cnf: -------------------------------------------------------------------------------- 1 | [mariadb] 2 | log-bin # enable binary loging 3 | server_id=3000 # used to uniquely identify the server 4 | log-basename=my-mariadb # used to be independent of to hostname changes (otherwise is in datadir/mysql) 5 | #binlog-format=MIXED #default 6 | #gtid_strict_mode=1 7 | 8 | -------------------------------------------------------------------------------- /anel/shell_scripts/pid_namespace/README.md: -------------------------------------------------------------------------------- 1 | # How to test 2 | 1. install mariadb-server from apt manager (ubuntu has 10.1 default) 3 | 2. start mariadb/mysql container to get mysqld/mariadbd 4 | ```bash 5 | $ docker container run --name mysql-cont --rm MYSQL_ROOT_PASSWORD=secret -d mysql 6 | ``` 7 | 3. Run the script and obtain the results (I stored mine in a file) 8 | ```bash 9 | $ ./testpidnamespace.sh >results.txt 2>&1 10 | ``` 11 | -------------------------------------------------------------------------------- /faust/tools/vlcrec: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env bash 2 | 3 | err() { 4 | echo >&2 "ERROR: $*" 5 | exit 1 6 | } 7 | 8 | command -v cvlc &>/dev/null || err "cvlc command not found" 9 | 10 | cvlc v4l2:///dev/video0 \ 11 | :input-slave=alsa://hw:0,0 \ 12 | --sout="#transcode{vcodec=h264,acodec=mpga,ab=128,channels=2,samplerate=44100,scodec=none}\ 13 | :file{dst=./$(date +'%Y-%m-%dT%H:%M:%S')_rec.mp4,no-overwrite}" \ 14 | --no-sout-all --sout-keep 15 | -------------------------------------------------------------------------------- /dbt3_benchmark/dbt3_mysql/mysql_queries/6.sql: -------------------------------------------------------------------------------- 1 | -- @(#)6.sql 2.1.8.1 2 | -- TPC-H/TPC-R Forecasting Revenue Change Query (Q6) 3 | -- Functional Query Definition 4 | -- Approved February 1998 5 | :b 6 | :x 7 | :o 8 | select 9 | sum(l_extendedprice * l_discount) as revenue 10 | from 11 | lineitem 12 | where 13 | l_shipdate >= ':1' 14 | and l_shipdate < date_add( ':1' , interval 1 year) 15 | and l_discount between :2 - 0.01 and :2 + 0.01 16 | and l_quantity < :3; 17 | :e 18 | -------------------------------------------------------------------------------- /dbt3_benchmark/tests/results_db_conf/results_db.conf: -------------------------------------------------------------------------------- 1 | DBMS = MariaDB 2 | DBMS_HOME = $PROJECT_HOME/bin/mariadb-5.3.2-beta-linux-x86_64 3 | DBMS_USER = root 4 | DATADIR = $DATADIR_HOME/dbt3_results_db 5 | CONFIG_FILE = $PROJECT_HOME/mariadb-tools/dbt3_benchmark/config/results_mariadb_my.cnf 6 | SOCKET = $PROJECT_HOME/temp/mysql_results.sock 7 | 8 | #Should be different than the $PORT value above 9 | PORT = 12341 10 | 11 | STARTUP_PARAMS = 12 | DBNAME = dbt3_results 13 | HOST = 127.0.0.1 -------------------------------------------------------------------------------- /release/bb-new-to-old: -------------------------------------------------------------------------------- 1 | #=============================================================================== 2 | # 3 | # The functionality of this pseudo-script has been incorporated into the prep 4 | # script. So the steps this one once performed are redundant and obsolete. 5 | # 6 | # Leaving this note here for posterity/documentation purposes, but we may just 7 | # remove this file eventually. 8 | # 9 | #=============================================================================== 10 | 11 | 12 | # vim: filetype=sh 13 | -------------------------------------------------------------------------------- /dbt3_benchmark/dbt3_mysql/mysql_queries/17.sql: -------------------------------------------------------------------------------- 1 | -- @(#)17.sql 2.1.8.1 2 | -- TPC-H/TPC-R Small-Quantity-Order Revenue Query (Q17) 3 | -- Functional Query Definition 4 | -- Approved February 1998 5 | :b 6 | :x 7 | :o 8 | select 9 | sum(l_extendedprice) / 7.0 as avg_yearly 10 | from 11 | lineitem, 12 | part 13 | where 14 | p_partkey = l_partkey 15 | and p_brand = ':1' 16 | and p_container = ':2' 17 | and l_quantity < ( 18 | select 19 | 0.2 * avg(l_quantity) 20 | from 21 | lineitem 22 | where 23 | l_partkey = p_partkey 24 | ); 25 | :e 26 | -------------------------------------------------------------------------------- /dbt3_benchmark/dbt3_mysql/mysql_queries/14.sql: -------------------------------------------------------------------------------- 1 | -- @(#)14.sql 2.1.8.1 2 | -- TPC-H/TPC-R Promotion Effect Query (Q14) 3 | -- Functional Query Definition 4 | -- Approved February 1998 5 | :b 6 | :x 7 | :o 8 | select 9 | 100.00 * sum(case 10 | when p_type like 'PROMO%' 11 | then l_extendedprice * (1 - l_discount) 12 | else 0 13 | end) / sum(l_extendedprice * (1 - l_discount)) as promo_revenue 14 | from 15 | lineitem, 16 | part 17 | where 18 | l_partkey = p_partkey 19 | and l_shipdate >= ':1' 20 | and l_shipdate < date_add( ':1' , interval 1 month); 21 | :e 22 | -------------------------------------------------------------------------------- /anel/docker-files/replication-example/config-files/secondary-1/secondary-1.cnf: -------------------------------------------------------------------------------- 1 | [mariadb] 2 | log-bin 3 | server_id=3001 # used to uniquely identify the server 4 | log-basename=my-mariadb # used to be independent of to hostname changes (otherwise is in datadir/mysql) 5 | # Change replicate_do_db for blog https://mariadb.com/kb/en/replication-and-binary-log-system-variables/ 6 | #replicate_do_db=primary_db # replicate only this DB 7 | #replicate_rewrite_db=sec_db # replicate rewrite on secondar 8 | #binlog-format=MIXED #default 9 | #gtid_strict_mode=1 10 | 11 | -------------------------------------------------------------------------------- /anel/docker-files/replication-example/secondaryinit/replinit.sql: -------------------------------------------------------------------------------- 1 | # Restore data from mariadbdump from primary (I wont do that, starting from fresh instance) 2 | 3 | # Change master related settings 4 | CHANGE MASTER TO 5 | MASTER_HOST='172.17.0.2', 6 | MASTER_USER='repluser', 7 | MASTER_PASSWORD='replsecret', 8 | MASTER_PORT=3306, 9 | MASTER_CONNECT_RETRY=10; 10 | #MASTER_LOG_FILE='my-mariadb-bin.000096', # this is needed only after doing mariadbdump 11 | #MASTER_LOG_POS=568,# this is needed only after doing mariadbdump 12 | 13 | # Start slave and show status 14 | #START SLAVE; 15 | #SHOW SLAVE STATUS\G -------------------------------------------------------------------------------- /daniel/spider/web/Dockerfile: -------------------------------------------------------------------------------- 1 | FROM python:latest 2 | 3 | # Set the working directory within the container 4 | WORKDIR /api-flask 5 | 6 | # Copy the necessary files and directories into the container 7 | COPY app.py requirements.txt /api-flask/ 8 | 9 | # Upgrade pip and install Python dependencies 10 | RUN pip3 install --upgrade pip && pip install --no-cache-dir -r requirements.txt 11 | 12 | # Expose port 80 for the Flask application 13 | EXPOSE 80 14 | 15 | # Define the command to run the Flask application using Gunicorn 16 | CMD ["gunicorn", "app:app", "-b", "0.0.0.0:80", "-w", "4", "--worker-tmp-dir=/dev/shm"] 17 | -------------------------------------------------------------------------------- /dbt3_benchmark/dbt3_mysql/mysql_queries/13.sql: -------------------------------------------------------------------------------- 1 | -- @(#)13.sql 2.1.8.1 2 | -- TPC-H/TPC-R Customer Distribution Query (Q13) 3 | -- Functional Query Definition 4 | -- Approved February 1998 5 | :b 6 | :x 7 | :o 8 | select 9 | c_count, 10 | count(*) as custdist 11 | from 12 | ( 13 | select 14 | c_custkey, 15 | count(o_orderkey) as c_count 16 | from 17 | customer left outer join orders on 18 | c_custkey = o_custkey 19 | and o_comment not like '%:1%:2%' 20 | group by 21 | c_custkey 22 | ) as c_orders 23 | group by 24 | c_count 25 | order by 26 | custdist desc, 27 | c_count desc; 28 | :e 29 | -------------------------------------------------------------------------------- /monitoring/mirmon/webhook/mirmon_update.sh: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | 3 | set -o nounset 4 | set -o pipefail 5 | set -o posix 6 | 7 | err() { 8 | echo >&2 "[$(date +'%Y-%m-%dT%H:%M:%S%z')]: $*" 9 | exit 1 10 | } 11 | 12 | # necessary commands 13 | for cmd in wget mirmon; do 14 | command -v $cmd >/dev/null || err "$cmd command not found" 15 | done 16 | 17 | typeset -r var_mirror_list_url="https://github.com/$1/raw/$2/monitoring/mirmon/mariadb_mirror_list" 18 | 19 | wget "$var_mirror_list_url" -O /usr/local/share/mariadb_mirror_list || err "Unable to get mirror list" 20 | mirmon -q -get update >/opt/webhooks/mirmon_call.log 21 | -------------------------------------------------------------------------------- /dbt3_benchmark/dbt3_mysql/mysql_queries/4.sql: -------------------------------------------------------------------------------- 1 | -- @(#)4.sql 2.1.8.1 2 | -- TPC-H/TPC-R Order Priority Checking Query (Q4) 3 | -- Functional Query Definition 4 | -- Approved February 1998 5 | :b 6 | :x 7 | :o 8 | select 9 | o_orderpriority, 10 | count(*) as order_count 11 | from 12 | orders 13 | where 14 | o_orderdate >= date ':1' 15 | and o_orderdate < date_add( ':1', interval 3 month) 16 | and exists ( 17 | select 18 | * 19 | from 20 | lineitem 21 | where 22 | l_orderkey = o_orderkey 23 | and l_commitdate < l_receiptdate 24 | ) 25 | group by 26 | o_orderpriority 27 | order by 28 | o_orderpriority; 29 | :e 30 | -------------------------------------------------------------------------------- /anel/docker-files/file-key-management/config/my.cnf: -------------------------------------------------------------------------------- 1 | [mysqld] 2 | slow_query_log=0 3 | long_query_time=10.0 4 | 5 | [mariadb] 6 | plugin_load_add=file_key_management 7 | file_key_management_filename=/etc/mysql/encryption/keyfile.enc 8 | file_key_management_filekey=FILE:/etc/mysql/encryption/keyfile.key 9 | file_key_management_encryption_algorithm=AES_CTR 10 | 11 | aria_encrypt_tables=ON 12 | encrypt_binlog=ON 13 | encrypt_tmp_disk_tables=ON 14 | encrypt_tmp_files=ON 15 | 16 | innodb_encrypt_log=ON 17 | innodb_encrypt_tables=FORCE 18 | innodb_encrypt_temporary_tables=ON 19 | innodb_encryption_rotation_iops=2000 20 | innodb_encryption_threads=4 -------------------------------------------------------------------------------- /dbt3_benchmark/dbt3_mysql/mysql_queries/3.sql: -------------------------------------------------------------------------------- 1 | -- @(#)3.sql 2.1.8.1 2 | -- TPC-H/TPC-R Shipping Priority Query (Q3) 3 | -- Functional Query Definition 4 | -- Approved February 1998 5 | :b 6 | :x 7 | :o 8 | select 9 | l_orderkey, 10 | sum(l_extendedprice * (1 - l_discount)) as revenue, 11 | o_orderdate, 12 | o_shippriority 13 | from 14 | customer, 15 | orders, 16 | lineitem 17 | where 18 | c_mktsegment = ':1' 19 | and c_custkey = o_custkey 20 | and l_orderkey = o_orderkey 21 | and o_orderdate < ':2' 22 | and l_shipdate > ':2' 23 | group by 24 | l_orderkey, 25 | o_orderdate, 26 | o_shippriority 27 | order by 28 | revenue desc, 29 | o_orderdate 30 | :n 10; 31 | :e 32 | -------------------------------------------------------------------------------- /anel/docker-files/nodejs-docker.dockerfile: -------------------------------------------------------------------------------- 1 | FROM node:15.3-buster 2 | LABEL maintainer="anel@mariadb.org" 3 | ARG DEBIAN_FRONTEND=noninteractive 4 | 5 | RUN apt-get -y update 6 | RUN apt-get -y upgrade 7 | RUN apt-get install apt-utils dialog -y 8 | RUN apt-get install build-essential -y 9 | 10 | # MariaDB packages 11 | VOLUME /packages 12 | 13 | # Source code 14 | VOLUME /code 15 | 16 | RUN useradd -ms /bin/bash buildbot && \ 17 | mkdir -p /buildbot /data && \ 18 | chown -R buildbot /buildbot /data /usr/local && \ 19 | curl -o /buildbot/buildbot.tac https://raw.githubusercontent.com/MariaDB/mariadb.org-tools/master/buildbot.mariadb.org/dockerfiles/buildbot.tac 20 | WORKDIR /buildbot 21 | -------------------------------------------------------------------------------- /anel/.tmux.conf: -------------------------------------------------------------------------------- 1 | # List of plugins 2 | set -g @plugin 'tmux-plugins/tpm' 3 | set -g @plugin 'tmux-plugins/tmux-sensible' 4 | set -g @plugin 'tmux-plugins/tmux-yank' 5 | 6 | bind -T copy-mode C-c send -X copy-pipe-no-clear "xsel -i --clipboard" 7 | bind -T copy-mode-vi C-c send -X copy-pipe-no-clear "xsel -i --clipboard" 8 | # Other examples: 9 | # set -g @plugin 'github_username/plugin_name' 10 | # set -g @plugin 'github_username/plugin_name#branch' 11 | # set -g @plugin 'git@github.com:user/plugin' 12 | # set -g @plugin 'git@bitbucket.com:user/plugin' 13 | set -g mouse on 14 | set -g @yank_action 'copy-pipe-no-clear' 15 | 16 | # Initialize TMUX plugin manager (keep this line at the very bottom of tmux.conf) 17 | run '~/.tmux/plugins/tpm/tpm' 18 | -------------------------------------------------------------------------------- /anel/jdbc_connect_blog/target_data/data.sql: -------------------------------------------------------------------------------- 1 | create table t(t int); 2 | insert into t values (1),(2); 3 | 4 | # Invoke for localhost 5 | 6 | #create table t_jdbc engine=connect 7 | # table_type=JDBC 8 | # tabname=t 9 | # connection='jdbc:mariadb://localhost/test?user=root&password'; 10 | #select * from t_jdbc; 11 | 12 | # Invoke for sources 13 | # check hostname -I first and change connection url 14 | create table db_mariadb_target engine=connect table_type=JDBC tabname=t_maria connection='jdbc:mariadb://mariadb-source/db_maria?user=root&password'; 15 | create table db_mysql_target engine=connect table_type=JDBC tabname=t_mysql connection='jdbc:mariadb://mysql-source/db_mysql?user=root&password'; 16 | -------------------------------------------------------------------------------- /anel/k8s/mariadb/mariadb-deployment.yaml: -------------------------------------------------------------------------------- 1 | apiVersion: apps/v1 2 | kind: Deployment # what to create? 3 | metadata: 4 | name: mariadb-deployment 5 | spec: # specification for deployment resource 6 | replicas: 2 # how many replicas of pods we want to create 7 | selector: 8 | matchLabels: 9 | app: mariadb 10 | template: # blueprint for pods 11 | metadata: 12 | labels: 13 | app: mariadb # service will look for this label 14 | spec: # specification for pods 15 | containers: 16 | - name: mariadb 17 | image: mariadb 18 | ports: 19 | - containerPort: 3306 #default one 20 | env: 21 | - name: MARIADB_ROOT_PASSWORD 22 | value: anel # works, don't use strings 23 | 24 | 25 | -------------------------------------------------------------------------------- /dbt3_benchmark/dbt3_mysql/mysql_queries/5.sql: -------------------------------------------------------------------------------- 1 | -- @(#)5.sql 2.1.8.1 2 | -- TPC-H/TPC-R Local Supplier Volume Query (Q5) 3 | -- Functional Query Definition 4 | -- Approved February 1998 5 | :b 6 | :x 7 | :o 8 | select 9 | n_name, 10 | sum(l_extendedprice * (1 - l_discount)) as revenue 11 | from 12 | customer, 13 | orders, 14 | lineitem, 15 | supplier, 16 | nation, 17 | region 18 | where 19 | c_custkey = o_custkey 20 | and l_orderkey = o_orderkey 21 | and l_suppkey = s_suppkey 22 | and c_nationkey = s_nationkey 23 | and s_nationkey = n_nationkey 24 | and n_regionkey = r_regionkey 25 | and r_name = ':1' 26 | and o_orderdate >= ':2' 27 | and o_orderdate < date_add( ':2' , interval 1 year) 28 | group by 29 | n_name 30 | order by 31 | revenue desc; 32 | :e 33 | -------------------------------------------------------------------------------- /monitoring/mirmon/webhook/webhook.yaml: -------------------------------------------------------------------------------- 1 | - id: mirmon_update_list 2 | execute-command: /opt/webhooks/mirmon_update.sh 3 | command-working-directory: /opt/webhooks 4 | response-message: OK starting mirmon update 5 | pass-arguments-to-command: 6 | - source: payload 7 | name: repository.full_name 8 | - source: payload 9 | name: head_commit.id 10 | trigger-rule: 11 | and: 12 | - match: 13 | type: payload-hash-sha1 14 | secret: my-secret 15 | parameter: 16 | source: header 17 | name: X-Hub-Signature 18 | - match: 19 | type: regex 20 | regex: monitoring/mirmon/mariadb_mirror_list 21 | parameter: 22 | source: payload 23 | name: head_commit.modified 24 | -------------------------------------------------------------------------------- /sanja/restore_git_dir.sh: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | # This script should be run from root directory of one of the git 3 | # repositories restored from tag made by list created by backup_git_dirs.sh 4 | # 5 | # It takes a lot of time 6 | 7 | echo "" 8 | echo " *** checkout not copied files *** " 9 | echo "" 10 | 11 | for filename in $( git status --short|grep '^ D '|sed 's/^ D //' ) ; do 12 | echo "$filename" 13 | git checkout $filename 14 | done 15 | 16 | echo "" 17 | echo " *** delete files deleted in backuped repository *** " 18 | echo "" 19 | 20 | for filename in $( egrep -v '(^/|\./|/\.\.$|/\.$|^\.\.$|^\.$|~|\*|\;|>|<|,|\|)' .backup_deleted_files_by_git_backup ) ; do 21 | echo "$filename" 22 | rm "$filename" 23 | done 24 | 25 | echo "" 26 | echo " *** done *** " 27 | echo "" 28 | 29 | -------------------------------------------------------------------------------- /dbt3_benchmark/dbt3_mysql/mysql_queries/18.sql: -------------------------------------------------------------------------------- 1 | -- @(#)18.sql 2.1.8.1 2 | -- TPC-H/TPC-R Large Volume Customer Query (Q18) 3 | -- Function Query Definition 4 | -- Approved February 1998 5 | :b 6 | :x 7 | :o 8 | select 9 | c_name, 10 | c_custkey, 11 | o_orderkey, 12 | o_orderdate, 13 | o_totalprice, 14 | sum(l_quantity) 15 | from 16 | customer, 17 | orders, 18 | lineitem 19 | where 20 | o_orderkey in ( 21 | select 22 | l_orderkey 23 | from 24 | lineitem 25 | group by 26 | l_orderkey having 27 | sum(l_quantity) > :1 28 | ) 29 | and c_custkey = o_custkey 30 | and o_orderkey = l_orderkey 31 | group by 32 | c_name, 33 | c_custkey, 34 | o_orderkey, 35 | o_orderdate, 36 | o_totalprice 37 | order by 38 | o_totalprice desc, 39 | o_orderdate 40 | :n 100; 41 | :e 42 | -------------------------------------------------------------------------------- /dbt3_benchmark/dbt3_mysql/mysql_queries/16.sql: -------------------------------------------------------------------------------- 1 | -- @(#)16.sql 2.1.8.1 2 | -- TPC-H/TPC-R Parts/Supplier Relationship Query (Q16) 3 | -- Functional Query Definition 4 | -- Approved February 1998 5 | :b 6 | :x 7 | :o 8 | select 9 | p_brand, 10 | p_type, 11 | p_size, 12 | count(distinct ps_suppkey) as supplier_cnt 13 | from 14 | partsupp, 15 | part 16 | where 17 | p_partkey = ps_partkey 18 | and p_brand <> ':1' 19 | and p_type not like ':2%' 20 | and p_size in (:3, :4, :5, :6, :7, :8, :9, :10) 21 | and ps_suppkey not in ( 22 | select 23 | s_suppkey 24 | from 25 | supplier 26 | where 27 | s_comment like '%Customer%Complaints%' 28 | ) 29 | group by 30 | p_brand, 31 | p_type, 32 | p_size 33 | order by 34 | supplier_cnt desc, 35 | p_brand, 36 | p_type, 37 | p_size; 38 | :e 39 | -------------------------------------------------------------------------------- /dbt3_benchmark/dbt3_mysql/mysql_queries/11.sql: -------------------------------------------------------------------------------- 1 | -- @(#)11.sql 2.1.8.1 2 | -- TPC-H/TPC-R Important Stock Identification Query (Q11) 3 | -- Functional Query Definition 4 | -- Approved February 1998 5 | :b 6 | :x 7 | :o 8 | select 9 | ps_partkey, 10 | sum(ps_supplycost * ps_availqty) as value 11 | from 12 | partsupp, 13 | supplier, 14 | nation 15 | where 16 | ps_suppkey = s_suppkey 17 | and s_nationkey = n_nationkey 18 | and n_name = ':1' 19 | group by 20 | ps_partkey having 21 | sum(ps_supplycost * ps_availqty) > ( 22 | select 23 | sum(ps_supplycost * ps_availqty) * :2 24 | from 25 | partsupp, 26 | supplier, 27 | nation 28 | where 29 | ps_suppkey = s_suppkey 30 | and s_nationkey = n_nationkey 31 | and n_name = ':1' 32 | ) 33 | order by 34 | value desc; 35 | :e 36 | -------------------------------------------------------------------------------- /anel/docker-files/file-key-management/README.md: -------------------------------------------------------------------------------- 1 | #### Create encrypted key 2 | ```bash 3 | # Generate 32 byte key and store in a file 4 | echo "1;"$(openssl rand -hex 32) > $PWD/encryption/keyfile 5 | ``` 6 | #### Encrypt encrypted key (re-encrypt) 7 | ```bash 8 | # Generate random key 9 | openssl rand -hex 128 > $PWD/encryption/keyfile.key 10 | # Re-encrypt key with random key 11 | openssl enc -aes-256-cbc -md sha1 -pass file:$PWD/encryption/keyfile.key -in $PWD/encryption/keyfile -out $PWD/encryption/keyfile.enc 12 | # Remove original key 13 | rm -rf $PWD/encryption/keyfile 14 | ``` 15 | 16 | #### References 17 | 18 | [1] [Transparent Data Encryption (TDE) Using MariaDB’s File Key Management Encryption Plugin](https://mariadb.com/resources/blog/mariadb-encryption-tde-using-mariadbs-file-key-management-encryption-plugin/) -------------------------------------------------------------------------------- /dbt3_benchmark/dbt3_mysql/mysql_queries/1.sql: -------------------------------------------------------------------------------- 1 | -- @(#)1.sql 2.1.8.1 2 | -- TPC-H/TPC-R Pricing Summary Report Query (Q1) 3 | -- Functional Query Definition 4 | -- Approved February 1998 5 | :b 6 | :x 7 | :o 8 | select 9 | l_returnflag, 10 | l_linestatus, 11 | sum(l_quantity) as sum_qty, 12 | sum(l_extendedprice) as sum_base_price, 13 | sum(l_extendedprice * (1 - l_discount)) as sum_disc_price, 14 | sum(l_extendedprice * (1 - l_discount) * (1 + l_tax)) as sum_charge, 15 | avg(l_quantity) as avg_qty, 16 | avg(l_extendedprice) as avg_price, 17 | avg(l_discount) as avg_disc, 18 | count(*) as count_order 19 | from 20 | lineitem 21 | where 22 | l_shipdate <= date_sub('1998-12-01', interval :1 day) 23 | group by 24 | l_returnflag, 25 | l_linestatus 26 | order by 27 | l_returnflag, 28 | l_linestatus; 29 | :e 30 | -------------------------------------------------------------------------------- /daniel/MDEV-19210/deb/Dockerfile: -------------------------------------------------------------------------------- 1 | FROM jrei/systemd-debian:12 2 | 3 | RUN apt-get update && apt-get install -y ca-certificates 4 | 5 | # build number from https://ci.mariadb.org/bb-11.4-pr2726-MDEV-19210-environment-file-pkgtest-latest-amd64-debian-12-deb-autobake.sources 6 | # 7 | RUN echo "deb [trusted=yes] https://ci.mariadb.org/40904/amd64-debian-12-deb-autobake/debs ./" > /etc/apt/sources.list.d/mariadb.list 8 | # from https://ci.mariadb.org/galera/mariadb-4.x-latest-gal-amd64-debian-12.sources 9 | RUN echo "deb [trusted=yes] https://ci.mariadb.org/galera/mariadb-4.x/7dce5149980931f8360a3e1287e3da6a6b9e1cc7/gal-amd64-debian-12/debs ./" > /etc/apt/sources.list.d/galera.list 10 | RUN apt-get update && apt-get install -y mariadb-server 11 | 12 | COPY mariadb.cnf /etc/mysql/mariadb.conf.d/ 13 | VOLUME /var/lib/mysql 14 | -------------------------------------------------------------------------------- /merging/show_conflicts_resolution.sh: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | # 3 | # Usage: show_conflicts_resolution.sh prev_commit cur_branch res_branch 4 | # Where 5 | # prev_commit - commit we want to merge 6 | # cur_branch - the branch where we are going merge to 7 | # res_branch - the branch with resolved conflicts, based on cur_branch 8 | # 9 | # Example: 10 | # ./show_conflicts_resolution.sh 275f434392d6e04ece74ddec70abde75c6d86603 mariadb-cs/10.5 mariadb-cs/bb-10.5-MDEV-25163 11 | 12 | PREV_COMMIT=$1 13 | CUR_BRANCH=$2 14 | RES_BRANCH=$3 15 | 16 | git checkout $CUR_BRANCH 17 | git cherry-pick -x $PREV_COMMIT 18 | if [[ $? -ne 0 ]] 19 | then 20 | git add -u 21 | git -c core.editor=true cherry-pick --continue 22 | git checkout -f HEAD^ . 23 | git show $RES_BRANCH | patch -p1 24 | git diff HEAD 25 | else 26 | echo "Hurrah! No conflicts." 27 | fi 28 | -------------------------------------------------------------------------------- /dbt3_benchmark/dbt3_mysql/mysql_queries/10.sql: -------------------------------------------------------------------------------- 1 | -- @(#)10.sql 2.1.8.1 2 | -- TPC-H/TPC-R Returned Item Reporting Query (Q10) 3 | -- Functional Query Definition 4 | -- Approved February 1998 5 | :b 6 | :x 7 | :o 8 | select 9 | c_custkey, 10 | c_name, 11 | sum(l_extendedprice * (1 - l_discount)) as revenue, 12 | c_acctbal, 13 | n_name, 14 | c_address, 15 | c_phone, 16 | c_comment 17 | from 18 | customer, 19 | orders, 20 | lineitem, 21 | nation 22 | where 23 | c_custkey = o_custkey 24 | and l_orderkey = o_orderkey 25 | and o_orderdate >= ':1' 26 | and o_orderdate < date_add( ':1' , interval 3 month) 27 | and l_returnflag = 'R' 28 | and c_nationkey = n_nationkey 29 | group by 30 | c_custkey, 31 | c_name, 32 | c_acctbal, 33 | c_phone, 34 | n_name, 35 | c_address, 36 | c_comment 37 | order by 38 | revenue desc 39 | :n 20; 40 | :e 41 | -------------------------------------------------------------------------------- /dbt3_benchmark/dbt3_mysql/mysql_queries/15.sql: -------------------------------------------------------------------------------- 1 | -- @(#)15.sql 2.1.8.1 2 | -- TPC-H/TPC-R Top Supplier Query (Q15) 3 | -- Functional Query Definition 4 | -- Approved February 1998 5 | :b 6 | create or replace view revenue:s (supplier_no, total_revenue) as 7 | select 8 | l_suppkey, 9 | sum(l_extendedprice * (1 - l_discount)) 10 | from 11 | lineitem 12 | where 13 | l_shipdate >= ':1' 14 | and l_shipdate < date_add(':1', interval 90 day) 15 | group by 16 | l_suppkey; 17 | 18 | :x 19 | :o 20 | select 21 | s_suppkey, 22 | s_name, 23 | s_address, 24 | s_phone, 25 | total_revenue 26 | from 27 | supplier, 28 | revenue:s 29 | where 30 | s_suppkey = supplier_no 31 | and total_revenue = ( 32 | select 33 | max(total_revenue) 34 | from 35 | revenue:s 36 | ) 37 | order by 38 | s_suppkey; 39 | 40 | drop view revenue:s; 41 | :e 42 | -------------------------------------------------------------------------------- /faust/tools/get_subtitles: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env bash 2 | 3 | set -o errexit 4 | set -o pipefail 5 | set -o posix 6 | 7 | err() { 8 | echo >&2 "ERROR: $*" 9 | exit 1 10 | } 11 | 12 | for cmd in youtube-dl dos2unix; do 13 | command -v $cmd &>/dev/null || err "$cmd command not found" 14 | done 15 | 16 | command -v ffmpeg &>/dev/null || command -v avconv &>/dev/null || err "ffmpeg or avconv required" 17 | 18 | [[ -n $1 ]] || { 19 | echo "Usage: $0 " 20 | exit 0 21 | } 22 | 23 | youtube-dl --write-auto-sub --write-sub --sub-format vtt --convert-subtitles srt "$1" || err "Unable to get subtitles" 24 | dos2unix -- *.srt || "dos2unix" 25 | # remove timestamps 26 | sed -r '/^[0-9]+$/{N;d}' -- *.srt >subtitles_duplicates.txt 27 | # remove duplicates //TEMP to be tested 28 | #awk '!seen[$0]++' subtitles_duplicates.txt >subtitles.txt 29 | -------------------------------------------------------------------------------- /anel/k8s/mariadb/mariadb-deployment-from-secret.yaml: -------------------------------------------------------------------------------- 1 | apiVersion: apps/v1 2 | kind: Deployment # what to create? 3 | metadata: 4 | name: mariadb-deployment 5 | spec: # specification for deployment resource 6 | replicas: 2 # how many replicas of pods we want to create 7 | selector: 8 | matchLabels: 9 | app: mariadb 10 | template: # blueprint for pods 11 | metadata: 12 | labels: 13 | app: mariadb # service will look for this label 14 | spec: # specification for pods 15 | containers: 16 | - name: mariadb 17 | image: mariadb 18 | ports: 19 | - containerPort: 3306 #default one 20 | env: 21 | - name: MARIADB_ROOT_PASSWORD 22 | valueFrom: 23 | secretKeyRef: 24 | name: mariadb-secret 25 | key: mariadb-root-password 26 | 27 | 28 | -------------------------------------------------------------------------------- /dbt3_benchmark/dbt3_mysql/mysql_queries/20.sql: -------------------------------------------------------------------------------- 1 | -- @(#)20.sql 2.1.8.1 2 | -- TPC-H/TPC-R Potential Part Promotion Query (Q20) 3 | -- Function Query Definition 4 | -- Approved February 1998 5 | :b 6 | :x 7 | :o 8 | select 9 | s_name, 10 | s_address 11 | from 12 | supplier, 13 | nation 14 | where 15 | s_suppkey in ( 16 | select 17 | distinct (ps_suppkey) 18 | from 19 | partsupp, 20 | part 21 | where 22 | ps_partkey=p_partkey 23 | and p_name like ':1%' 24 | and ps_availqty > ( 25 | select 26 | 0.5 * sum(l_quantity) 27 | from 28 | lineitem 29 | where 30 | l_partkey = ps_partkey 31 | and l_suppkey = ps_suppkey 32 | and l_shipdate >= ':2' 33 | and l_shipdate < date_ADD(':2',interval 1 year) 34 | ) 35 | ) 36 | and s_nationkey = n_nationkey 37 | and n_name = ':3' 38 | order by 39 | s_name; 40 | :e 41 | -------------------------------------------------------------------------------- /sql-bench-mysql/basic/tcpip.sqlbt: -------------------------------------------------------------------------------- 1 | # 2 | # Test to be run with configuration in the file, which is including this test. 3 | # 4 | # This sql-bench-test will automaticly get --suffix=_test_name as an argument 5 | # The different options which can be used are: 6 | # 7 | # mysqld_start_options Options given to the mysqld that is started. 8 | # This is prefixed with --skip-grant. 9 | # mysqld_init_command SQL commands given to mysqld before tests starts. 10 | # sql_bench_options Options given to sql-bench. 11 | # 12 | 13 | $sql_bench_test->{'tcpip'} = { 14 | mysqld_start_options => '--skip-grant-tables', 15 | mysqld_init_command => '', 16 | sql_bench_options => '--connect_options=\'host=LOCALHOST\' --comment="tcp/ip connection"', 17 | }; 18 | 19 | # This has to be the last line. See "perldoc -f require" for details. 20 | 1; 21 | -------------------------------------------------------------------------------- /dbt3_benchmark/dbt3_mysql/mysql_queries/12.sql: -------------------------------------------------------------------------------- 1 | -- @(#)12.sql 2.1.8.1 2 | -- TPC-H/TPC-R Shipping Modes and Order Priority Query (Q12) 3 | -- Functional Query Definition 4 | -- Approved February 1998 5 | :b 6 | :x 7 | :o 8 | select 9 | l_shipmode, 10 | sum(case 11 | when o_orderpriority = '1-URGENT' 12 | or o_orderpriority = '2-HIGH' 13 | then 1 14 | else 0 15 | end) as high_line_count, 16 | sum(case 17 | when o_orderpriority <> '1-URGENT' 18 | and o_orderpriority <> '2-HIGH' 19 | then 1 20 | else 0 21 | end) as low_line_count 22 | from 23 | orders, 24 | lineitem 25 | where 26 | o_orderkey = l_orderkey 27 | and l_shipmode in (':1', ':2') 28 | and l_commitdate < l_receiptdate 29 | and l_shipdate < l_commitdate 30 | and l_receiptdate >= ':3' 31 | and l_receiptdate < date_add( ':3' , interval 1 year) 32 | group by 33 | l_shipmode 34 | order by 35 | l_shipmode; 36 | :e 37 | -------------------------------------------------------------------------------- /sql-bench/O2/base.sqlbt: -------------------------------------------------------------------------------- 1 | # 2 | # Test to be run with configuration in the file, which is including this test. 3 | # 4 | # This sql-bench-test will automaticly get --suffix=_test_name as an argument 5 | # The different options which can be used are: 6 | # 7 | # mysqld_start_options Options given to the mysqld that is started. 8 | # Please keep it prefixed with --skip-grant-tables, 9 | # except for tests, which are related to GRANT. 10 | # mysqld_init_command SQL commands given to mysqld before tests starts. 11 | # sql_bench_options Options given to sql-bench. 12 | # 13 | $sql_bench_test->{'base'} = { 14 | mysqld_start_options => '--skip-grant-tables', 15 | mysqld_init_command => '', 16 | sql_bench_options => '--comment="base test (with MyISAM)"', 17 | }; 18 | 19 | # This has to be the last line. See "perldoc -f require" for details. 20 | 1; 21 | -------------------------------------------------------------------------------- /sql-bench-mysql/O2/base.sqlbt: -------------------------------------------------------------------------------- 1 | # 2 | # Test to be run with configuration in the file, which is including this test. 3 | # 4 | # This sql-bench-test will automaticly get --suffix=_test_name as an argument 5 | # The different options which can be used are: 6 | # 7 | # mysqld_start_options Options given to the mysqld that is started. 8 | # Please keep it prefixed with --skip-grant-tables, 9 | # except for tests, which are related to GRANT. 10 | # mysqld_init_command SQL commands given to mysqld before tests starts. 11 | # sql_bench_options Options given to sql-bench. 12 | # 13 | $sql_bench_test->{'base'} = { 14 | mysqld_start_options => '--skip-grant-tables', 15 | mysqld_init_command => '', 16 | sql_bench_options => '--comment="base test (with MyISAM)"', 17 | }; 18 | 19 | # This has to be the last line. See "perldoc -f require" for details. 20 | 1; 21 | -------------------------------------------------------------------------------- /sql-bench/basic/base.sqlbt: -------------------------------------------------------------------------------- 1 | # 2 | # Test to be run with configuration in the file, which is including this test. 3 | # 4 | # This sql-bench-test will automaticly get --suffix=_test_name as an argument 5 | # The different options which can be used are: 6 | # 7 | # mysqld_start_options Options given to the mysqld that is started. 8 | # Please keep it prefixed with --skip-grant-tables, 9 | # except for tests, which are related to GRANT. 10 | # mysqld_init_command SQL commands given to mysqld before tests starts. 11 | # sql_bench_options Options given to sql-bench. 12 | # 13 | $sql_bench_test->{'base'} = { 14 | mysqld_start_options => '--skip-grant-tables', 15 | mysqld_init_command => '', 16 | sql_bench_options => '--comment="base test (with MyISAM)"', 17 | }; 18 | 19 | # This has to be the last line. See "perldoc -f require" for details. 20 | 1; 21 | -------------------------------------------------------------------------------- /sql-bench/debug/base.sqlbt: -------------------------------------------------------------------------------- 1 | # 2 | # Test to be run with configuration in the file, which is including this test. 3 | # 4 | # This sql-bench-test will automaticly get --suffix=_test_name as an argument 5 | # The different options which can be used are: 6 | # 7 | # mysqld_start_options Options given to the mysqld that is started. 8 | # Please keep it prefixed with --skip-grant-tables, 9 | # except for tests, which are related to GRANT. 10 | # mysqld_init_command SQL commands given to mysqld before tests starts. 11 | # sql_bench_options Options given to sql-bench. 12 | # 13 | $sql_bench_test->{'base'} = { 14 | mysqld_start_options => '--skip-grant-tables', 15 | mysqld_init_command => '', 16 | sql_bench_options => '--comment="base test (with MyISAM)"', 17 | }; 18 | 19 | # This has to be the last line. See "perldoc -f require" for details. 20 | 1; 21 | -------------------------------------------------------------------------------- /sql-bench-mysql/basic/base.sqlbt: -------------------------------------------------------------------------------- 1 | # 2 | # Test to be run with configuration in the file, which is including this test. 3 | # 4 | # This sql-bench-test will automaticly get --suffix=_test_name as an argument 5 | # The different options which can be used are: 6 | # 7 | # mysqld_start_options Options given to the mysqld that is started. 8 | # Please keep it prefixed with --skip-grant-tables, 9 | # except for tests, which are related to GRANT. 10 | # mysqld_init_command SQL commands given to mysqld before tests starts. 11 | # sql_bench_options Options given to sql-bench. 12 | # 13 | $sql_bench_test->{'base'} = { 14 | mysqld_start_options => '--skip-grant-tables', 15 | mysqld_init_command => '', 16 | sql_bench_options => '--comment="base test (with MyISAM)"', 17 | }; 18 | 19 | # This has to be the last line. See "perldoc -f require" for details. 20 | 1; 21 | -------------------------------------------------------------------------------- /sql-bench-mysql/debug/base.sqlbt: -------------------------------------------------------------------------------- 1 | # 2 | # Test to be run with configuration in the file, which is including this test. 3 | # 4 | # This sql-bench-test will automaticly get --suffix=_test_name as an argument 5 | # The different options which can be used are: 6 | # 7 | # mysqld_start_options Options given to the mysqld that is started. 8 | # Please keep it prefixed with --skip-grant-tables, 9 | # except for tests, which are related to GRANT. 10 | # mysqld_init_command SQL commands given to mysqld before tests starts. 11 | # sql_bench_options Options given to sql-bench. 12 | # 13 | $sql_bench_test->{'base'} = { 14 | mysqld_start_options => '--skip-grant-tables', 15 | mysqld_init_command => '', 16 | sql_bench_options => '--comment="base test (with MyISAM)"', 17 | }; 18 | 19 | # This has to be the last line. See "perldoc -f require" for details. 20 | 1; 21 | -------------------------------------------------------------------------------- /sql-bench/debug-full/base.sqlbt: -------------------------------------------------------------------------------- 1 | # 2 | # Test to be run with configuration in the file, which is including this test. 3 | # 4 | # This sql-bench-test will automaticly get --suffix=_test_name as an argument 5 | # The different options which can be used are: 6 | # 7 | # mysqld_start_options Options given to the mysqld that is started. 8 | # Please keep it prefixed with --skip-grant-tables, 9 | # except for tests, which are related to GRANT. 10 | # mysqld_init_command SQL commands given to mysqld before tests starts. 11 | # sql_bench_options Options given to sql-bench. 12 | # 13 | $sql_bench_test->{'base'} = { 14 | mysqld_start_options => '--skip-grant-tables', 15 | mysqld_init_command => '', 16 | sql_bench_options => '--comment="base test (with MyISAM)"', 17 | }; 18 | 19 | # This has to be the last line. See "perldoc -f require" for details. 20 | 1; 21 | -------------------------------------------------------------------------------- /daniel/spider/generator.sh: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | set -x -v 3 | host= 4 | until [ -n "$host" ] 5 | do 6 | sleep 1 7 | cname=$(dig +short self.metadata.compute.edgeengine.io) 8 | # take cname from the form: 9 | # [instance-name].[deployment-scope].[target-name].[workload-slug].[stack-slug].[root-domain] 10 | read -r -a parts <<< "${cname//./ }" 11 | 12 | # The database host is the same as our name, with "gen" replaced by "db" 13 | host=${parts[0]/gen-/db-} 14 | done 15 | # altenately db-${parts[2]}-${parts[1]}-0 16 | db=$MARIADB_DATABASE 17 | user=$MARIADB_USER 18 | password=$MARIADB_PASSWORD 19 | 20 | while true 21 | do 22 | 23 | code=A$((1000 + RANDOM % 1000)) 24 | qty=$((1 + RANDOM % 10)) 25 | value=$(( RANDOM % 100 )).$(( RANDOM % 100)) 26 | echo "INSERT INTO sales(code, quantity, value) VALUES ('$code', $qty, $value);" 27 | sleep 1 28 | done | MYSQL_PWD="$password" mariadb --host "$host" --user "$user" "$db" 29 | -------------------------------------------------------------------------------- /dbt3_benchmark/dbt3_mysql/mysql_queries/9.sql: -------------------------------------------------------------------------------- 1 | -- @(#)9.sql 2.1.8.1 2 | -- TPC-H/TPC-R Product Type Profit Measure Query (Q9) 3 | -- Functional Query Definition 4 | -- Approved February 1998 5 | :b 6 | :x 7 | :o 8 | select 9 | nation, 10 | o_year, 11 | sum(amount) as sum_profit 12 | from 13 | ( 14 | select 15 | n_name as nation, 16 | year(o_orderdate) as o_year, 17 | l_extendedprice * (1 - l_discount) - ps_supplycost * l_quantity as amount 18 | from 19 | part, 20 | supplier, 21 | lineitem, 22 | partsupp, 23 | orders, 24 | nation 25 | where 26 | s_suppkey = l_suppkey 27 | and ps_suppkey = l_suppkey 28 | and ps_partkey = l_partkey 29 | and p_partkey = l_partkey 30 | and o_orderkey = l_orderkey 31 | and s_nationkey = n_nationkey 32 | and p_name like '%:1%' 33 | ) as profit 34 | group by 35 | nation, 36 | o_year 37 | order by 38 | nation, 39 | o_year desc; 40 | :e 41 | -------------------------------------------------------------------------------- /dbt3_benchmark/tests/queries_conf/queries-mysql_17_19_20.conf: -------------------------------------------------------------------------------- 1 | [queries_settings] 2 | QUERIES_HOME = $QUERIES_HOME/s$SCALE_FACTOR-m 3 | 4 | #[17] 5 | #QUERY=17.sql 6 | #EXPLAIN_QUERY=17_explain.sql 7 | #TIMEOUT=7200 8 | 9 | #[17-opt1] 10 | #QUERY=17-opt1.sql 11 | #EXPLAIN_QUERY=17-opt1_explain.sql 12 | #TIMEOUT=7200 13 | 14 | #[17-opt2] 15 | #QUERY=17-opt2.sql 16 | #EXPLAIN_QUERY=17-opt2_explain.sql 17 | #TIMEOUT=7200 18 | 19 | 20 | 21 | #[19] 22 | #QUERY=19.sql 23 | #EXPLAIN_QUERY=19_explain.sql 24 | #TIMEOUT=7200 25 | 26 | #[19-opt1] 27 | #QUERY=19-opt1.sql 28 | #EXPLAIN_QUERY=19-opt1_explain.sql 29 | #TIMEOUT=7200 30 | 31 | #[19-opt2] 32 | #QUERY=19-opt2.sql 33 | #EXPLAIN_QUERY=19-opt2_explain.sql 34 | #TIMEOUT=7200 35 | 36 | 37 | 38 | [20] 39 | QUERY=20.sql 40 | EXPLAIN_QUERY=20_explain.sql 41 | TIMEOUT=43200 42 | 43 | [20-opt1] 44 | QUERY=20-opt1.sql 45 | EXPLAIN_QUERY=20-opt1_explain.sql 46 | TIMEOUT=43200 -------------------------------------------------------------------------------- /sql-bench-mysql/debug-full/base.sqlbt: -------------------------------------------------------------------------------- 1 | # 2 | # Test to be run with configuration in the file, which is including this test. 3 | # 4 | # This sql-bench-test will automaticly get --suffix=_test_name as an argument 5 | # The different options which can be used are: 6 | # 7 | # mysqld_start_options Options given to the mysqld that is started. 8 | # Please keep it prefixed with --skip-grant-tables, 9 | # except for tests, which are related to GRANT. 10 | # mysqld_init_command SQL commands given to mysqld before tests starts. 11 | # sql_bench_options Options given to sql-bench. 12 | # 13 | $sql_bench_test->{'base'} = { 14 | mysqld_start_options => '--skip-grant-tables', 15 | mysqld_init_command => '', 16 | sql_bench_options => '--comment="base test (with MyISAM)"', 17 | }; 18 | 19 | # This has to be the last line. See "perldoc -f require" for details. 20 | 1; 21 | -------------------------------------------------------------------------------- /sql-bench/basic/profiling.sqlbt: -------------------------------------------------------------------------------- 1 | # 2 | # Test to be run with configuration in the file, which is including this test. 3 | # 4 | # This sql-bench-test will automaticly get --suffix=_test_name as an argument 5 | # The different options which can be used are: 6 | # 7 | # mysqld_start_options Options given to the mysqld that is started. 8 | # Please keep it prefixed with --skip-grant-tables, 9 | # except for tests, which are related to GRANT. 10 | # mysqld_init_command SQL commands given to mysqld before tests starts. 11 | # sql_bench_options Options given to sql-bench. 12 | # 13 | 14 | $sql_bench_test->{'profiling'} = { 15 | mysqld_start_options => '--skip-grant-tables', 16 | mysqld_init_command => 'set profiling=1', 17 | sql_bench_options => '--comment="set profiling"', 18 | }; 19 | 20 | # This has to be the last line. See "perldoc -f require" for details. 21 | 1; 22 | -------------------------------------------------------------------------------- /sql-bench-mysql/basic/profiling.sqlbt: -------------------------------------------------------------------------------- 1 | # 2 | # Test to be run with configuration in the file, which is including this test. 3 | # 4 | # This sql-bench-test will automaticly get --suffix=_test_name as an argument 5 | # The different options which can be used are: 6 | # 7 | # mysqld_start_options Options given to the mysqld that is started. 8 | # Please keep it prefixed with --skip-grant-tables, 9 | # except for tests, which are related to GRANT. 10 | # mysqld_init_command SQL commands given to mysqld before tests starts. 11 | # sql_bench_options Options given to sql-bench. 12 | # 13 | 14 | $sql_bench_test->{'profiling'} = { 15 | mysqld_start_options => '--skip-grant-tables', 16 | mysqld_init_command => 'set profiling=1', 17 | sql_bench_options => '--comment="set profiling"', 18 | }; 19 | 20 | # This has to be the last line. See "perldoc -f require" for details. 21 | 1; 22 | -------------------------------------------------------------------------------- /sql-bench/basic/grant.sqlbt: -------------------------------------------------------------------------------- 1 | # 2 | # Test to be run with configuration in the file, which is including this test. 3 | # 4 | # This sql-bench-test will automaticly get --suffix=_test_name as an argument 5 | # The different options which can be used are: 6 | # 7 | # mysqld_start_options Options given to the mysqld that is started. 8 | # Please keep it prefixed with --skip-grant-tables, 9 | # except for tests, which are related to GRANT. 10 | # mysqld_init_command SQL commands given to mysqld before tests starts. 11 | # sql_bench_options Options given to sql-bench. 12 | # 13 | 14 | $sql_bench_test->{'grant'} = { 15 | mysqld_start_options => '', 16 | mysqld_init_command => 'GRANT ALL PRIVILEGES on *.* to \'test\'@\'localhost\'', 17 | sql_bench_options => '--comment="grant to everything"', 18 | }; 19 | 20 | # This has to be the last line. See "perldoc -f require" for details. 21 | 1; 22 | -------------------------------------------------------------------------------- /sql-bench/basic/tcpip.sqlbt: -------------------------------------------------------------------------------- 1 | # 2 | # Test to be run with configuration in the file, which is including this test. 3 | # 4 | # This sql-bench-test will automaticly get --suffix=_test_name as an argument 5 | # The different options which can be used are: 6 | # 7 | # mysqld_start_options Options given to the mysqld that is started. 8 | # Please keep it prefixed with --skip-grant-tables, 9 | # except for tests, which are related to GRANT. 10 | # mysqld_init_command SQL commands given to mysqld before tests starts. 11 | # sql_bench_options Options given to sql-bench. 12 | # 13 | 14 | $sql_bench_test->{'tcpip'} = { 15 | mysqld_start_options => '--skip-grant-tables', 16 | mysqld_init_command => '', 17 | sql_bench_options => '--connect_options=\'host=LOCALHOST\' --comment="tcp/ip connection"', 18 | }; 19 | 20 | # This has to be the last line. See "perldoc -f require" for details. 21 | 1; 22 | -------------------------------------------------------------------------------- /sql-bench-mysql/basic/grant.sqlbt: -------------------------------------------------------------------------------- 1 | # 2 | # Test to be run with configuration in the file, which is including this test. 3 | # 4 | # This sql-bench-test will automaticly get --suffix=_test_name as an argument 5 | # The different options which can be used are: 6 | # 7 | # mysqld_start_options Options given to the mysqld that is started. 8 | # Please keep it prefixed with --skip-grant-tables, 9 | # except for tests, which are related to GRANT. 10 | # mysqld_init_command SQL commands given to mysqld before tests starts. 11 | # sql_bench_options Options given to sql-bench. 12 | # 13 | 14 | $sql_bench_test->{'grant'} = { 15 | mysqld_start_options => '', 16 | mysqld_init_command => 'GRANT ALL PRIVILEGES on *.* to \'test\'@\'localhost\'', 17 | sql_bench_options => '--comment="grant to everything"', 18 | }; 19 | 20 | # This has to be the last line. See "perldoc -f require" for details. 21 | 1; 22 | -------------------------------------------------------------------------------- /sql-bench/basic/grant-db.sqlbt: -------------------------------------------------------------------------------- 1 | # 2 | # Test to be run with configuration in the file, which is including this test. 3 | # 4 | # This sql-bench-test will automaticly get --suffix=_test_name as an argument 5 | # The different options which can be used are: 6 | # 7 | # mysqld_start_options Options given to the mysqld that is started. 8 | # Please keep it prefixed with --skip-grant-tables, 9 | # except for tests, which are related to GRANT. 10 | # mysqld_init_command SQL commands given to mysqld before tests starts. 11 | # sql_bench_options Options given to sql-bench. 12 | # 13 | 14 | $sql_bench_test->{'grant-db'} = { 15 | mysqld_start_options => '', 16 | mysqld_init_command => 'GRANT ALL PRIVILEGES on test.* to \'test\'@\'localhost\'', 17 | sql_bench_options => '--comment="grant to database"', 18 | }; 19 | 20 | # This has to be the last line. See "perldoc -f require" for details. 21 | 1; 22 | -------------------------------------------------------------------------------- /sql-bench-mysql/basic/grant-db.sqlbt: -------------------------------------------------------------------------------- 1 | # 2 | # Test to be run with configuration in the file, which is including this test. 3 | # 4 | # This sql-bench-test will automaticly get --suffix=_test_name as an argument 5 | # The different options which can be used are: 6 | # 7 | # mysqld_start_options Options given to the mysqld that is started. 8 | # Please keep it prefixed with --skip-grant-tables, 9 | # except for tests, which are related to GRANT. 10 | # mysqld_init_command SQL commands given to mysqld before tests starts. 11 | # sql_bench_options Options given to sql-bench. 12 | # 13 | 14 | $sql_bench_test->{'grant-db'} = { 15 | mysqld_start_options => '', 16 | mysqld_init_command => 'GRANT ALL PRIVILEGES on test.* to \'test\'@\'localhost\'', 17 | sql_bench_options => '--comment="grant to database"', 18 | }; 19 | 20 | # This has to be the last line. See "perldoc -f require" for details. 21 | 1; 22 | -------------------------------------------------------------------------------- /sql-bench/README.txt: -------------------------------------------------------------------------------- 1 | 0. This is fine tuned for running with MariaDB 2 | 3 | 1. What is it? 4 | This wrapper scripts are meant to run the sql-bench benchmark suite 5 | with various compiler options and different run time configurations. 6 | 7 | 2. Prerequisite 8 | - MariaDB bzr tree from lp:maria 9 | - Perl with DBD::MySQL 10 | 11 | 3. What you will find in those directories? 12 | Each directory represents a compiler/test combination to be run. 13 | 3.1 You can find each compiler configuration in 14 | - compiler_.cnf. 15 | 3.2 You can find the tests for that compiler configuration 16 | in the files ending with 17 | - *.sqlbt. 18 | 19 | 4. How to run? 20 | Run run-sql-bench.pl and check output for details. 21 | 22 | Note: name your test file like the $sql_bench_test array name. For 23 | instance $sql_bench_test->{'base'} should be named 24 | base.sqlbt 25 | 26 | -- 27 | Hakan Kuecuekyilmaz, , 2010-10-28. 28 | -------------------------------------------------------------------------------- /sql-bench/basic/key-cache-segments.sqlbt: -------------------------------------------------------------------------------- 1 | # 2 | # Test to be run with configuration in the file, which is including this test. 3 | # 4 | # This sql-bench-test will automaticly get --suffix=_test_name as an argument 5 | # The different options which can be used are: 6 | # 7 | # mysqld_start_options Options given to the mysqld that is started. 8 | # Please keep it prefixed with --skip-grant-tables, 9 | # except for tests, which are related to GRANT. 10 | # mysqld_init_command SQL commands given to mysqld before tests starts. 11 | # sql_bench_options Options given to sql-bench. 12 | # 13 | 14 | $sql_bench_test->{'key-cache-segments'} = { 15 | mysqld_start_options => '--skip-grant-tables --key-cache-segments=64', 16 | mysqld_init_command => '', 17 | sql_bench_options => '--comment="key-cache-segments=64"', 18 | }; 19 | 20 | # This has to be the last line. See "perldoc -f require" for details. 21 | 1; 22 | -------------------------------------------------------------------------------- /sql-bench-mysql/README.txt: -------------------------------------------------------------------------------- 1 | 0. This is fine tuned for running with MySQL 2 | 3 | 1. What is it? 4 | This wrapper scripts are meant to run the sql-bench benchmark suite 5 | with various compiler options and different run time configurations. 6 | 7 | 2. Prerequisite 8 | - MySQL bzr tree from lp:mysql-server 9 | - Perl with DBD::MySQL 10 | 11 | 3. What you will find in those directories? 12 | Each directory represents a compiler/test combination to be run. 13 | 3.1 You can find each compiler configuration in 14 | - compiler_.cnf. 15 | 3.2 You can find the tests for that compiler configuration 16 | in the files ending with 17 | - *.sqlbt. 18 | 19 | 4. How to run? 20 | Run run-sql-bench.pl and check output for details. 21 | 22 | Note: name your test file like the $sql_bench_test array name. For 23 | instance $sql_bench_test->{'base'} should be named 24 | base.sqlbt 25 | 26 | -- 27 | Hakan Kuecuekyilmaz, , 2011-05-17. 28 | -------------------------------------------------------------------------------- /sql-bench/debug-full/skip-safemalloc.sqlbt: -------------------------------------------------------------------------------- 1 | # 2 | # Test to be run with configuration in the file, which is including this test. 3 | # 4 | # This sql-bench-test will automaticly get --suffix=_test_name as an argument 5 | # The different options which can be used are: 6 | # 7 | # mysqld_start_options Options given to the mysqld that is started. 8 | # Please keep it prefixed with --skip-grant-tables, 9 | # except for tests, which are related to GRANT. 10 | # mysqld_init_command SQL commands given to mysqld before tests starts. 11 | # sql_bench_options Options given to sql-bench. 12 | # 13 | $sql_bench_test->{'skip-safemalloc'} = { 14 | mysqld_start_options => '--skip-grant-tables --skip-safemalloc', 15 | mysqld_init_command => '', 16 | sql_bench_options => '--comment="base test (with MyISAM and --skip-safemalloc)"', 17 | }; 18 | 19 | # This has to be the last line. See "perldoc -f require" for details. 20 | 1; 21 | -------------------------------------------------------------------------------- /dbt3_benchmark/dbt3_mysql/mysql_queries/22.sql: -------------------------------------------------------------------------------- 1 | -- @(#)22.sql 2.1.8.1 2 | -- TPC-H/TPC-R Global Sales Opportunity Query (Q22) 3 | -- Functional Query Definition 4 | -- Approved February 1998 5 | :b 6 | :x 7 | :o 8 | select 9 | cntrycode, 10 | count(*) as numcust, 11 | sum(c_acctbal) as totacctbal 12 | from 13 | ( 14 | select 15 | substr(c_phone, 1, 2) as cntrycode, 16 | c_acctbal 17 | from 18 | customer 19 | where 20 | substr(c_phone, 1, 2) in 21 | (':1', ':2', ':3', ':4', ':5', ':6', ':7') 22 | and c_acctbal > ( 23 | select 24 | avg(c_acctbal) 25 | from 26 | customer 27 | where 28 | c_acctbal > 0.00 29 | and substr(c_phone, 1, 2) in 30 | (':1', ':2', ':3', ':4', ':5', ':6', ':7') 31 | ) 32 | and not exists ( 33 | select 34 | * 35 | from 36 | orders 37 | where 38 | o_custkey = c_custkey 39 | ) 40 | ) as vip 41 | group by 42 | cntrycode 43 | order by 44 | cntrycode; 45 | :e 46 | -------------------------------------------------------------------------------- /sql-bench-mysql/debug-full/skip-safemalloc.sqlbt: -------------------------------------------------------------------------------- 1 | # 2 | # Test to be run with configuration in the file, which is including this test. 3 | # 4 | # This sql-bench-test will automaticly get --suffix=_test_name as an argument 5 | # The different options which can be used are: 6 | # 7 | # mysqld_start_options Options given to the mysqld that is started. 8 | # Please keep it prefixed with --skip-grant-tables, 9 | # except for tests, which are related to GRANT. 10 | # mysqld_init_command SQL commands given to mysqld before tests starts. 11 | # sql_bench_options Options given to sql-bench. 12 | # 13 | $sql_bench_test->{'skip-safemalloc'} = { 14 | mysqld_start_options => '--skip-grant-tables --skip-safemalloc', 15 | mysqld_init_command => '', 16 | sql_bench_options => '--comment="base test (with MyISAM and --skip-safemalloc)"', 17 | }; 18 | 19 | # This has to be the last line. See "perldoc -f require" for details. 20 | 1; 21 | -------------------------------------------------------------------------------- /sql-bench/basic/userstat.sqlbt: -------------------------------------------------------------------------------- 1 | # 2 | # Test to be run with configuration in the file, which is including this test. 3 | # 4 | # This sql-bench-test will automaticly get --suffix=_test_name as an argument 5 | # The different options which can be used are: 6 | # 7 | # mysqld_start_options Options given to the mysqld that is started. 8 | # Please keep it prefixed with --skip-grant-tables, 9 | # except for tests, which are related to GRANT. 10 | # mysqld_init_command SQL commands given to mysqld before tests starts. 11 | # sql_bench_options Options given to sql-bench. 12 | # 13 | 14 | # --userstat is available starting with MariaDB 5.2. 15 | $sql_bench_test->{'userstat'} = { 16 | mysqld_start_options => '--skip-grant-tables --userstat=1', 17 | mysqld_init_command => '', 18 | sql_bench_options => '--comment="userstat=1"', 19 | }; 20 | 21 | # This has to be the last line. See "perldoc -f require" for details. 22 | 1; 23 | -------------------------------------------------------------------------------- /sql-bench/basic/memory.sqlbt: -------------------------------------------------------------------------------- 1 | # 2 | # Test to be run with configuration in the file, which is including this test. 3 | # 4 | # This sql-bench-test will automaticly get --suffix=_test_name as an argument 5 | # The different options which can be used are: 6 | # 7 | # mysqld_start_options Options given to the mysqld that is started. 8 | # Please keep it prefixed with --skip-grant-tables, 9 | # except for tests, which are related to GRANT. 10 | # mysqld_init_command SQL commands given to mysqld before tests starts. 11 | # sql_bench_options Options given to sql-bench. 12 | # 13 | 14 | $sql_bench_test->{'memory'} = { 15 | mysqld_start_options => '--skip-grant-tables --default-storage-engine=memory --max-heap-table-size=1024M', 16 | mysqld_init_command => '', 17 | sql_bench_options => '--create-options="engine=memory" --comment="engine=memory"', 18 | }; 19 | 20 | # This has to be the last line. See "perldoc -f require" for details. 21 | 1; 22 | -------------------------------------------------------------------------------- /anel/docker-files/replication-example/primaryinit/primaryinit.sql: -------------------------------------------------------------------------------- 1 | # This script is run on a primary 2 | CREATE USER 'repluser'@'%' IDENTIFIED BY 'replsecret'; 3 | GRANT REPLICATION SLAVE ON *.* TO 'repluser'@'%'; 4 | CREATE DATABASE primary_db; 5 | # It is not allowed to have inserts during initialization 6 | #USE primary_db; 7 | #CREATE TABLE primary_db.primary_tbl (name char(20)); 8 | #INSERT INTO primary_db.primary_tbl values 9 | # ("Anna"), ("Andrea"), ("Kaj"), ("Monty"), ("Ian"), 10 | #("Vicentiu"), ("Daniel"), ("Faustin"),("Vlad"), 11 | #("Anel"); 12 | 13 | # This is run in case you want to do a mariadbdump (I will start with empty primary) 14 | # FLUSH TABLES WITH READ LOCK; 15 | # SHOW MASTER STATUS; 16 | # Do mariadbdump or alternatively start the slave with volume of existing DB(will not test this) 17 | # mariadbdump -h -P 3306 -u root -p --all-databases --single-transaction --quick > ~/mariadb-backup/backup-111-$(date +%FT%T).sql 18 | # After finishing on the slave run 19 | # UNLOCK TABLE -------------------------------------------------------------------------------- /sql-bench-mysql/basic/memory.sqlbt: -------------------------------------------------------------------------------- 1 | # 2 | # Test to be run with configuration in the file, which is including this test. 3 | # 4 | # This sql-bench-test will automaticly get --suffix=_test_name as an argument 5 | # The different options which can be used are: 6 | # 7 | # mysqld_start_options Options given to the mysqld that is started. 8 | # Please keep it prefixed with --skip-grant-tables, 9 | # except for tests, which are related to GRANT. 10 | # mysqld_init_command SQL commands given to mysqld before tests starts. 11 | # sql_bench_options Options given to sql-bench. 12 | # 13 | 14 | $sql_bench_test->{'memory'} = { 15 | mysqld_start_options => '--skip-grant-tables --default-storage-engine=memory --max-heap-table-size=1024M', 16 | mysqld_init_command => '', 17 | sql_bench_options => '--create-options="engine=memory" --comment="engine=memory"', 18 | }; 19 | 20 | # This has to be the last line. See "perldoc -f require" for details. 21 | 1; 22 | -------------------------------------------------------------------------------- /sql-bench/basic/myisam.sqlbt: -------------------------------------------------------------------------------- 1 | # 2 | # Test to be run with configuration in the file, which is including this test. 3 | # 4 | # This sql-bench-test will automaticly get --suffix=_test_name as an argument 5 | # The different options which can be used are: 6 | # 7 | # mysqld_start_options Options given to the mysqld that is started. 8 | # Please keep it prefixed with --skip-grant-tables, 9 | # except for tests, which are related to GRANT. 10 | # mysqld_init_command SQL commands given to mysqld before tests starts. 11 | # sql_bench_options Options given to sql-bench. 12 | # 13 | 14 | $sql_bench_test->{'myisam'} = { 15 | mysqld_start_options => '--skip-grant-tables --default-storage-engine=myisam --key-buffer-size=256M', 16 | mysqld_init_command => '', 17 | sql_bench_options => '--create-options="engine=myisam" --comment="engine=myisam key_buffer_size=256M"', 18 | }; 19 | 20 | # This has to be the last line. See "perldoc -f require" for details. 21 | 1; 22 | -------------------------------------------------------------------------------- /sql-bench-mysql/basic/myisam.sqlbt: -------------------------------------------------------------------------------- 1 | # 2 | # Test to be run with configuration in the file, which is including this test. 3 | # 4 | # This sql-bench-test will automaticly get --suffix=_test_name as an argument 5 | # The different options which can be used are: 6 | # 7 | # mysqld_start_options Options given to the mysqld that is started. 8 | # Please keep it prefixed with --skip-grant-tables, 9 | # except for tests, which are related to GRANT. 10 | # mysqld_init_command SQL commands given to mysqld before tests starts. 11 | # sql_bench_options Options given to sql-bench. 12 | # 13 | 14 | $sql_bench_test->{'myisam'} = { 15 | mysqld_start_options => '--skip-grant-tables --default-storage-engine=myisam --key-buffer-size=256M', 16 | mysqld_init_command => '', 17 | sql_bench_options => '--create-options="engine=myisam" --comment="engine=myisam key_buffer_size=256M"', 18 | }; 19 | 20 | # This has to be the last line. See "perldoc -f require" for details. 21 | 1; 22 | -------------------------------------------------------------------------------- /sql-bench/debug-full/skip-mutex-deadlock-detector.sqlbt: -------------------------------------------------------------------------------- 1 | # 2 | # Test to be run with configuration in the file, which is including this test. 3 | # 4 | # This sql-bench-test will automaticly get --suffix=_test_name as an argument 5 | # The different options which can be used are: 6 | # 7 | # mysqld_start_options Options given to the mysqld that is started. 8 | # Please keep it prefixed with --skip-grant-tables, 9 | # except for tests, which are related to GRANT. 10 | # mysqld_init_command SQL commands given to mysqld before tests starts. 11 | # sql_bench_options Options given to sql-bench. 12 | # 13 | $sql_bench_test->{'skip-mutex-deadlock-detector'} = { 14 | mysqld_start_options => '--skip-grant-tables --skip-mutex-deadlock-detector', 15 | mysqld_init_command => '', 16 | sql_bench_options => '--comment="base test (with MyISAM and --skip-mutex-deadlock-detector)"', 17 | }; 18 | 19 | # This has to be the last line. See "perldoc -f require" for details. 20 | 1; 21 | -------------------------------------------------------------------------------- /sql-bench/basic/innodb.sqlbt: -------------------------------------------------------------------------------- 1 | # 2 | # Test to be run with configuration in the file, which is including this test. 3 | # 4 | # This sql-bench-test will automaticly get --suffix=_test_name as an argument 5 | # The different options which can be used are: 6 | # 7 | # mysqld_start_options Options given to the mysqld that is started. 8 | # Please keep it prefixed with --skip-grant-tables, 9 | # except for tests, which are related to GRANT. 10 | # mysqld_init_command SQL commands given to mysqld before tests starts. 11 | # sql_bench_options Options given to sql-bench. 12 | # 13 | 14 | $sql_bench_test->{'innodb'} = { 15 | mysqld_start_options => '--skip-grant-tables --default-storage-engine=innodb --innodb-buffer-pool-size=256M', 16 | mysqld_init_command => '', 17 | sql_bench_options => '--create-options="engine=innodb" --comment="engine=innodb innodb-buffer-pool-size=256M"', 18 | }; 19 | 20 | # This has to be the last line. See "perldoc -f require" for details. 21 | 1; 22 | -------------------------------------------------------------------------------- /dbt3_benchmark/dbt3_mysql/mysql_queries/21.sql: -------------------------------------------------------------------------------- 1 | -- @(#)21.sql 2.1.8.1 2 | -- TPC-H/TPC-R Suppliers Who Kept Orders Waiting Query (Q21) 3 | -- Functional Query Definition 4 | -- Approved February 1998 5 | :b 6 | :x 7 | :o 8 | select 9 | s_name, 10 | count(*) as numwait 11 | from 12 | supplier, 13 | lineitem l1, 14 | orders, 15 | nation 16 | where 17 | s_suppkey = l1.l_suppkey 18 | and o_orderkey = l1.l_orderkey 19 | and o_orderstatus = 'F' 20 | and l1.l_receiptdate > l1.l_commitdate 21 | and exists ( 22 | select 23 | * 24 | from 25 | lineitem l2 26 | where 27 | l2.l_orderkey = l1.l_orderkey 28 | and l2.l_suppkey <> l1.l_suppkey 29 | ) 30 | and not exists ( 31 | select 32 | * 33 | from 34 | lineitem l3 35 | where 36 | l3.l_orderkey = l1.l_orderkey 37 | and l3.l_suppkey <> l1.l_suppkey 38 | and l3.l_receiptdate > l3.l_commitdate 39 | ) 40 | and s_nationkey = n_nationkey 41 | and n_name = ':1' 42 | group by 43 | s_name 44 | order by 45 | numwait desc, 46 | s_name 47 | :n 100 48 | :e 49 | -------------------------------------------------------------------------------- /sql-bench-mysql/basic/innodb.sqlbt: -------------------------------------------------------------------------------- 1 | # 2 | # Test to be run with configuration in the file, which is including this test. 3 | # 4 | # This sql-bench-test will automaticly get --suffix=_test_name as an argument 5 | # The different options which can be used are: 6 | # 7 | # mysqld_start_options Options given to the mysqld that is started. 8 | # Please keep it prefixed with --skip-grant-tables, 9 | # except for tests, which are related to GRANT. 10 | # mysqld_init_command SQL commands given to mysqld before tests starts. 11 | # sql_bench_options Options given to sql-bench. 12 | # 13 | 14 | $sql_bench_test->{'innodb'} = { 15 | mysqld_start_options => '--skip-grant-tables --default-storage-engine=innodb --innodb-buffer-pool-size=256M', 16 | mysqld_init_command => '', 17 | sql_bench_options => '--create-options="engine=innodb" --comment="engine=innodb innodb-buffer-pool-size=256M"', 18 | }; 19 | 20 | # This has to be the last line. See "perldoc -f require" for details. 21 | 1; 22 | -------------------------------------------------------------------------------- /anel/k8s/mariadb/mariadb-deployment-with-phpmyadmin.yaml: -------------------------------------------------------------------------------- 1 | apiVersion: apps/v1 2 | kind: Deployment # what to create? 3 | metadata: 4 | name: mariadb-deployment 5 | spec: # specification for deployment resource 6 | replicas: 2 # how many replicas of pods we want to create 7 | selector: 8 | matchLabels: 9 | app: mariadb 10 | template: # blueprint for pods 11 | metadata: 12 | labels: 13 | app: mariadb # service will look for this label 14 | spec: # specification for Pods 15 | containers: 16 | - name: mariadb 17 | image: mariadb 18 | ports: 19 | - containerPort: 3306 20 | env: 21 | - name: MARIADB_ROOT_PASSWORD 22 | value: anel 23 | - name: phpmyadmin 24 | image: bitnami/phpmyadmin:latest 25 | ports: 26 | - containerPort: 8080 27 | env: 28 | - name: DATABASE_HOST 29 | valueFrom: 30 | configMapKeyRef: 31 | name: mariadb-configmap 32 | key: database_url 33 | 34 | -------------------------------------------------------------------------------- /dbt3_benchmark/dbt3_mysql/mysql_queries/2.sql: -------------------------------------------------------------------------------- 1 | -- @(#)2.sql 2.1.8.2 2 | -- TPC-H/TPC-R Minimum Cost Supplier Query (Q2) 3 | -- Functional Query Definition 4 | -- Approved February 1998 5 | :b 6 | :x 7 | :o 8 | select 9 | s_acctbal, 10 | s_name, 11 | n_name, 12 | p_partkey, 13 | p_mfgr, 14 | s_address, 15 | s_phone, 16 | s_comment 17 | from 18 | part, 19 | supplier, 20 | partsupp, 21 | nation, 22 | region 23 | where 24 | p_partkey = ps_partkey 25 | and s_suppkey = ps_suppkey 26 | and p_size = :1 27 | and p_type like '%:2' 28 | and s_nationkey = n_nationkey 29 | and n_regionkey = r_regionkey 30 | and r_name = ':3' 31 | and ps_supplycost = ( 32 | select 33 | min(ps_supplycost) 34 | from 35 | partsupp, 36 | supplier, 37 | nation, 38 | region 39 | where 40 | p_partkey = ps_partkey 41 | and s_suppkey = ps_suppkey 42 | and s_nationkey = n_nationkey 43 | and n_regionkey = r_regionkey 44 | and r_name = ':3' 45 | ) 46 | order by 47 | s_acctbal desc, 48 | n_name, 49 | s_name, 50 | p_partkey 51 | :n 100; 52 | :e 53 | -------------------------------------------------------------------------------- /reporting/README.md: -------------------------------------------------------------------------------- 1 | [![Try it on Nbviewer](https://img.shields.io/badge/MariaDB_Statistics_2019-jupyter_notebook-blue?logo=jupyter)](https://nbviewer.jupyter.org/github/MariaDB/mariadb.org-tools/blob/master/reporting/MDBF_Statistics.ipynb?flush_cache=true) 2 | 3 | # Common workflows 4 | 5 | ### Generating gitlog committers datasets 6 | * Run Zak's [script](https://github.com/zakgreant/mariadb.org-tools/tree/master/reporting) to get a git-log CSV file 7 | * Assuming the output CSV from the step above is named `input.csv`, run `python3 process_gitlog_csv.py -s ./input.csv -o 'dataset.csv'` to correct some mistakes in the original CSV file. 8 | * Dataset should be good to go in the `MariaDB_Statistics_2019` Jupyter notebook 9 | 10 | ### Generating GitHub activity datasets 11 | * Install the [github-activity](https://github.com/choldgraf/github-activity) tool using `pip install git+https://github.com/choldgraf/github-activity` 12 | * Run `python3 process_github_activity --since '2019-01-01' --until '2019-12-31' --auth your_github_auth_token -o ./github_dataset.csv` 13 | -------------------------------------------------------------------------------- /sql-bench/basic/grant-column.sqlbt: -------------------------------------------------------------------------------- 1 | # 2 | # Test to be run with configuration in the file, which is including this test. 3 | # 4 | # This sql-bench-test will automaticly get --suffix=_test_name as an argument 5 | # The different options which can be used are: 6 | # 7 | # mysqld_start_options Options given to the mysqld that is started. 8 | # Please keep it prefixed with --skip-grant-tables, 9 | # except for tests, which are related to GRANT. 10 | # mysqld_init_command SQL commands given to mysqld before tests starts. 11 | # sql_bench_options Options given to sql-bench. 12 | # 13 | 14 | $sql_bench_test->{'grant-column'} = { 15 | mysqld_start_options => '', 16 | mysqld_init_command => 'GRANT ALL PRIVILEGES on test.* to \'test\'@\'localhost\'; CREATE table test.t1 (a int); GRANT SELECT (a) on test.t1 to \'test\'@\'localhost\';', 17 | sql_bench_options => '--comment="grant to database and column level grants"', 18 | }; 19 | 20 | # This has to be the last line. See "perldoc -f require" for details. 21 | 1; 22 | -------------------------------------------------------------------------------- /sql-bench-mysql/basic/grant-column.sqlbt: -------------------------------------------------------------------------------- 1 | # 2 | # Test to be run with configuration in the file, which is including this test. 3 | # 4 | # This sql-bench-test will automaticly get --suffix=_test_name as an argument 5 | # The different options which can be used are: 6 | # 7 | # mysqld_start_options Options given to the mysqld that is started. 8 | # Please keep it prefixed with --skip-grant-tables, 9 | # except for tests, which are related to GRANT. 10 | # mysqld_init_command SQL commands given to mysqld before tests starts. 11 | # sql_bench_options Options given to sql-bench. 12 | # 13 | 14 | $sql_bench_test->{'grant-column'} = { 15 | mysqld_start_options => '', 16 | mysqld_init_command => 'GRANT ALL PRIVILEGES on test.* to \'test\'@\'localhost\'; CREATE table test.t1 (a int); GRANT SELECT (a) on test.t1 to \'test\'@\'localhost\';', 17 | sql_bench_options => '--comment="grant to database and column level grants"', 18 | }; 19 | 20 | # This has to be the last line. See "perldoc -f require" for details. 21 | 1; 22 | -------------------------------------------------------------------------------- /sql-bench/basic/pbxt.sqlbt: -------------------------------------------------------------------------------- 1 | # 2 | # Test to be run with configuration in the file, which is including this test. 3 | # 4 | # This sql-bench-test will automaticly get --suffix=_test_name as an argument 5 | # The different options which can be used are: 6 | # 7 | # mysqld_start_options Options given to the mysqld that is started. 8 | # Please keep it prefixed with --skip-grant-tables, 9 | # except for tests, which are related to GRANT. 10 | # mysqld_init_command SQL commands given to mysqld before tests starts. 11 | # sql_bench_options Options given to sql-bench. 12 | # 13 | 14 | $sql_bench_test->{'pbxt'} = { 15 | mysqld_start_options => '--skip-grant-tables --default-storage-engine=pbxt --pbxt-index-cache-size=64M --pbxt-record-cache-size=name=196M', 16 | mysqld_init_command => '', 17 | sql_bench_options => '--create-options="engine=pbxt" --comment="engine=pbxt-index-cache-size=64M --pbxt-record-cache-size=name=196M"', 18 | }; 19 | 20 | # This has to be the last line. See "perldoc -f require" for details. 21 | 1; 22 | -------------------------------------------------------------------------------- /sql-bench/basic/aria-trans.sqlbt: -------------------------------------------------------------------------------- 1 | # 2 | # Test to be run with configuration in the file, which is including this test. 3 | # 4 | # This sql-bench-test will automaticly get --suffix=_test_name as an argument 5 | # The different options which can be used are: 6 | # 7 | # mysqld_start_options Options given to the mysqld that is started. 8 | # Please keep it prefixed with --skip-grant-tables, 9 | # except for tests, which are related to GRANT. 10 | # mysqld_init_command SQL commands given to mysqld before tests starts. 11 | # sql_bench_options Options given to sql-bench. 12 | # 13 | 14 | $sql_bench_test->{'aria-trans'} = { 15 | mysqld_start_options => '--skip-grant-tables --default-storage-engine=aria --aria-pagecache-buffer-size=256M', 16 | mysqld_init_command => '', 17 | sql_bench_options => '--create-options="engine=aria transactional=1 page_checksum=0" --comment="engine=aria aria-pagecache-buffer-size=256M transactional"', 18 | }; 19 | 20 | # This has to be the last line. See "perldoc -f require" for details. 21 | 1; 22 | -------------------------------------------------------------------------------- /sql-bench/basic/aria-notrans.sqlbt: -------------------------------------------------------------------------------- 1 | # 2 | # Test to be run with configuration in the file, which is including this test. 3 | # 4 | # This sql-bench-test will automaticly get --suffix=_test_name as an argument 5 | # The different options which can be used are: 6 | # 7 | # mysqld_start_options Options given to the mysqld that is started. 8 | # Please keep it prefixed with --skip-grant-tables, 9 | # except for tests, which are related to GRANT. 10 | # mysqld_init_command SQL commands given to mysqld before tests starts. 11 | # sql_bench_options Options given to sql-bench. 12 | # 13 | 14 | $sql_bench_test->{'aria-notrans'} = { 15 | mysqld_start_options => '--skip-grant-tables --default-storage-engine=aria --aria-pagecache-buffer-size=256M', 16 | mysqld_init_command => '', 17 | sql_bench_options => '--create-options="engine=aria transactional=0 page_checksum=0" --comment="engine=aria aria-pagecache-buffer-size=256M not transactional"', 18 | }; 19 | 20 | # This has to be the last line. See "perldoc -f require" for details. 21 | 1; 22 | -------------------------------------------------------------------------------- /dbt3_benchmark/dbt3_mysql/mysql_queries/8.sql: -------------------------------------------------------------------------------- 1 | -- @(#)8.sql 2.1.8.1 2 | -- TPC-H/TPC-R National Market Share Query (Q8) 3 | -- Functional Query Definition 4 | -- Approved February 1998 5 | :b 6 | :x 7 | :o 8 | select 9 | o_year, 10 | sum(case 11 | when nation = ':1' then volume 12 | else 0 13 | end) / sum(volume) as mkt_share 14 | from 15 | ( 16 | select 17 | year(o_orderdate) as o_year, 18 | l_extendedprice * (1 - l_discount) as volume, 19 | n2.n_name as nation 20 | from 21 | part, 22 | supplier, 23 | lineitem, 24 | orders, 25 | customer, 26 | nation n1, 27 | nation n2, 28 | region 29 | where 30 | p_partkey = l_partkey 31 | and s_suppkey = l_suppkey 32 | and l_orderkey = o_orderkey 33 | and o_custkey = c_custkey 34 | and c_nationkey = n1.n_nationkey 35 | and n1.n_regionkey = r_regionkey 36 | and r_name = ':2' 37 | and s_nationkey = n2.n_nationkey 38 | and o_orderdate between date('1995-01-01') and date ('1996-12-31') 39 | and p_type = ':3' 40 | ) as all_nations 41 | group by 42 | o_year 43 | order by 44 | o_year; 45 | :e 46 | -------------------------------------------------------------------------------- /sql-bench/basic/aria-trans-check.sqlbt: -------------------------------------------------------------------------------- 1 | # 2 | # Test to be run with configuration in the file, which is including this test. 3 | # 4 | # This sql-bench-test will automaticly get --suffix=_test_name as an argument 5 | # The different options which can be used are: 6 | # 7 | # mysqld_start_options Options given to the mysqld that is started. 8 | # Please keep it prefixed with --skip-grant-tables, 9 | # except for tests, which are related to GRANT. 10 | # mysqld_init_command SQL commands given to mysqld before tests starts. 11 | # sql_bench_options Options given to sql-bench. 12 | # 13 | 14 | $sql_bench_test->{'aria-trans-check'} = { 15 | mysqld_start_options => '--skip-grant-tables --default-storage-engine=aria --aria-pagecache-buffer-size=256M', 16 | mysqld_init_command => '', 17 | sql_bench_options => '--create-options="engine=aria transactional=1 page_checksum=1" --comment="engine=aria aria-pagecache-buffer-size=256M transactional page_checksum"', 18 | }; 19 | 20 | # This has to be the last line. See "perldoc -f require" for details. 21 | 1; 22 | -------------------------------------------------------------------------------- /dbt3_benchmark/dbt3_mysql/mysql_queries/7.sql: -------------------------------------------------------------------------------- 1 | -- @(#)7.sql 2.1.8.1 2 | -- TPC-H/TPC-R Volume Shipping Query (Q7) 3 | -- Functional Query Definition 4 | -- Approved February 1998 5 | :b 6 | :x 7 | :o 8 | select 9 | supp_nation, 10 | cust_nation, 11 | l_year, 12 | sum(volume) as revenue 13 | from 14 | ( 15 | select 16 | n1.n_name as supp_nation, 17 | n2.n_name as cust_nation, 18 | year(l_shipdate) as l_year, 19 | l_extendedprice * (1 - l_discount) as volume 20 | from 21 | supplier, 22 | lineitem, 23 | orders, 24 | customer, 25 | nation n1, 26 | nation n2 27 | where 28 | s_suppkey = l_suppkey 29 | and o_orderkey = l_orderkey 30 | and c_custkey = o_custkey 31 | and s_nationkey = n1.n_nationkey 32 | and c_nationkey = n2.n_nationkey 33 | and ( 34 | (n1.n_name = ':1' and n2.n_name = ':2') 35 | or (n1.n_name = ':2' and n2.n_name = ':1') 36 | ) 37 | and l_shipdate between date('1995-01-01') and date('1996-12-31') 38 | ) as shipping 39 | group by 40 | supp_nation, 41 | cust_nation, 42 | l_year 43 | order by 44 | supp_nation, 45 | cust_nation, 46 | l_year; 47 | :e 48 | -------------------------------------------------------------------------------- /anel/docker-files/file-key-management/test.sh: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | mkdir $PWD/encryption 3 | echo "-------- Create keys --------------- " 4 | # Generate 32 byte key and store in a file 5 | echo "1;"$(openssl rand -hex 32) > $PWD/encryption/keyfile 6 | # Generate random key to re-encrypt 7 | openssl rand -hex 128 > $PWD/encryption/keyfile.key 8 | # Re-encrypt key with random key 9 | openssl enc -aes-256-cbc -md sha1 -pass file:$PWD/encryption/keyfile.key -in $PWD/encryption/keyfile -out $PWD/encryption/keyfile.enc 10 | # Remove original key 11 | rm -rf $PWD/encryption/keyfile 12 | 13 | echo "-------- Create container --------------- " 14 | docker run --name mariadb-encrypted --rm \ 15 | -v $PWD/config:/etc/mysql/mariadb.conf.d \ 16 | -v $PWD/encryption:/etc/mysql/encryption \ 17 | -e MARIADB_ROOT_PASSWORD=secret -d mariadb 18 | 19 | echo "-------- Check container --------------- " 20 | docker exec -it mariadb-encrypted ls -C /usr/lib/mysql/plugin 21 | docker logs mariadb-encrypted 22 | #docker exec -it mariadb-encrypted mariadb -uroot -psecret "show plugins;" 23 | 24 | #echo "-------- Stop container --------------- " 25 | #docker stop mariadb-encrypted -------------------------------------------------------------------------------- /dbt3_benchmark/tests/myisam_test_q20.conf: -------------------------------------------------------------------------------- 1 | [common] 2 | RESULTS_DB_CONFIG = $PROJECT_HOME/mariadb-tools/dbt3_benchmark/tests/results_db_conf/results_db.conf 3 | TEST_CONFIG = $PROJECT_HOME/mariadb-tools/dbt3_benchmark/tests/test_conf/test_myisam.conf 4 | 5 | 6 | [mariadb_5_3_igor] 7 | QUERIES_CONFIG = $PROJECT_HOME/mariadb-tools/dbt3_benchmark/tests/queries_conf/q20.conf 8 | DB_CONFIG = $PROJECT_HOME/mariadb-tools/dbt3_benchmark/tests/db_conf/db_mariadb_5_3_myisam_igor.conf 9 | 10 | 11 | #[mariadb_5_3] 12 | #QUERIES_CONFIG = $PROJECT_HOME/mariadb-tools/dbt3_benchmark/tests/queries_conf/queries-mariadb.conf 13 | #DB_CONFIG = $PROJECT_HOME/mariadb-tools/dbt3_benchmark/tests/db_conf/db_mariadb_5_3_myisam.conf 14 | 15 | 16 | #[mysql_5_5] 17 | #QUERIES_CONFIG = $PROJECT_HOME/mariadb-tools/dbt3_benchmark/tests/queries_conf/queries-mysql.conf 18 | #DB_CONFIG = $PROJECT_HOME/mariadb-tools/dbt3_benchmark/tests/db_conf/db_mysql_5_5_myisam.conf 19 | 20 | 21 | #[mysql_5_6] 22 | #QUERIES_CONFIG = $PROJECT_HOME/mariadb-tools/dbt3_benchmark/tests/queries_conf/queries-mysql.conf 23 | #DB_CONFIG = $PROJECT_HOME/mariadb-tools/dbt3_benchmark/tests/db_conf/db_mysql_5_6_myisam.conf -------------------------------------------------------------------------------- /release/create_package_tarballs/deb_files/setup_repository: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env bash 2 | 3 | file=/etc/apt/sources.list.d/mariadb.list 4 | install_cmd='apt-get update && apt-get install mariadb-server' 5 | 6 | err() { 7 | msg=$1 8 | shift 9 | printf "[ERROR] $msg\n" "$@" >&2 10 | exit 1 11 | } 12 | 13 | for d in "$PWD" "${0%/*}"; do 14 | if [[ -f $d/Packages ]] ; then 15 | dir=$d 16 | if ! [[ $dir = /* ]] ; then 17 | dir=$PWD/$dir 18 | fi 19 | break 20 | fi 21 | done 22 | 23 | if ! [[ $dir ]] ; then 24 | err 'Could not find a "Packages" file. Please change to the top level directory of the unpacked archive and re-run this script.' 25 | fi 26 | 27 | if [[ -e $file ]] ; then 28 | err 'File "%s" already exists. Rename it and re-run this script, or manually create a new .list file.' "$file" 29 | fi 30 | 31 | if ! cat > "$file" <, 2010-12-16. 10 | # 11 | 12 | if [ $# != 3 ]; then 13 | echo "[ERROR]: Please use exactly three arguments" 14 | echo " Usage: $0 [title] [data series file name] [output file name]" 15 | echo " Example: $0 'COM_COMMIT Rate' com_commit.log com_commit_64.png" 16 | 17 | exit 1 18 | else 19 | TITLE="$1" 20 | DATA_SERIES_FILE="$2" 21 | OUTPUT_FILE="$3" 22 | fi 23 | 24 | echo "set terminal png size 640, 370" 25 | echo "set output \"$OUTPUT_FILE\"" 26 | 27 | echo "set term png font verdana 7" 28 | 29 | echo "set xtics rotate by -45" 30 | echo "set grid ytics" 31 | 32 | echo "set tmargin 2" 33 | echo "set rmargin 9" 34 | echo "set bmargin 5" 35 | echo "set lmargin 8" 36 | 37 | echo "set xdata time" 38 | echo "set timefmt \"%s\"" 39 | echo "set format x \"%H:%M:%S\"" 40 | 41 | echo "plot '$DATA_SERIES_FILE' using 1:3 title '$TITLE' with lines" 42 | -------------------------------------------------------------------------------- /release/create_package_tarballs/sles_files/setup_repository: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env bash 2 | 3 | file=/etc/zypp/repos.d/mariadb.repo 4 | install_cmd='zypper install -y MariaDB-server' 5 | 6 | err() { 7 | msg=$1 8 | shift 9 | printf "[ERROR] $msg\n" "$@" >&2 10 | exit 1 11 | } 12 | 13 | for d in "$PWD" "${0%/*}"; do 14 | if [[ -d $d/repodata ]] ; then 15 | dir=$d 16 | if ! [[ $dir = /* ]] ; then 17 | dir=$PWD/$dir 18 | fi 19 | break 20 | fi 21 | done 22 | 23 | if ! [[ $dir ]] ; then 24 | err 'Could not find a "repodata" directory. Please change to the top level directory of the unpacked archive. and re-run this script.' 25 | fi 26 | 27 | if [[ -e $file ]] ; then 28 | err 'File "%s" already exists. Rename it and re-run this script, or manually create a new .repo file.' "$file" 29 | fi 30 | 31 | if ! cat > "$file" <= 1.18.1. 29 | $bzr = '/usr/bin/bzr'; 30 | 31 | $mktemp = '/bin/mktemp'; 32 | 33 | $mkdir = '/bin/mkdir'; 34 | 35 | $sudo = '/usr/bin/sudo'; 36 | 37 | # Set the concurrency level (-j) to about: number of CPUs + 1. 38 | $make = '/usr/bin/make'; 39 | $concurrency = 3; 40 | 41 | # Perl with DBD::MySQL. 42 | $perl = '/usr/bin/perl'; 43 | 44 | # If you use ccache, a compiler cache, which reduces compile time, 45 | # then set the path to it here. 46 | $ccache = '/usr/bin/ccache'; 47 | 48 | # This has to be the last line. See "perldoc -f require" for details. 49 | 1; 50 | -------------------------------------------------------------------------------- /sql-bench/conf/perro.cnf: -------------------------------------------------------------------------------- 1 | # Configuration file for host: perro 2 | # 3 | # OS: openSUSE 11.1 (x86_64) 4 | # Platform: x86_64 5 | # CPU: Quad-core Intel @ 3.20GHz 6 | # RAM: 2GB 7 | # Disk(s): 2 x ST31000528AS S-ATA as software RAID 0 8 | 9 | # 10 | # Adjust the following variables according to your system. 11 | # 12 | 13 | # 14 | # Directories. 15 | # 16 | 17 | # Where to store the test results. 18 | $sql_bench_results = '/home/hakan/sql-bench-results'; 19 | 20 | # Where to compile the sources. You will need at least 1GB of disk space. 21 | # This is also the datadir directory. 22 | $work_dir = '/tmp'; 23 | 24 | # 25 | # Binaries. 26 | # 27 | 28 | # We need bzr >= 1.18.1. 29 | $bzr = '/usr/bin/bzr'; 30 | 31 | $mktemp = '/bin/mktemp'; 32 | 33 | $mkdir = '/bin/mkdir'; 34 | 35 | $sudo = '/usr/bin/sudo'; 36 | 37 | # Set the concurrency level (-j) to about: number of CPUs + 1. 38 | $make = '/usr/bin/make'; 39 | $concurrency = 3; 40 | 41 | # Perl with DBD::MySQL. 42 | $perl = '/usr/bin/perl'; 43 | 44 | # If you use ccache, a compiler cache, which reduces compile time, 45 | # then set the path to it here. 46 | $ccache = '/usr/bin/ccache'; 47 | 48 | # This has to be the last line. See "perldoc -f require" for details. 49 | 1; 50 | -------------------------------------------------------------------------------- /sql-bench-mysql/conf/lu0012.cnf: -------------------------------------------------------------------------------- 1 | # Configuration file for host: lu0012 2 | # 3 | # OS: Ubuntu 10.10 (x86_64) 4 | # Platform: x86_64 5 | # CPU: Dual-core Intel Core2 Duo @ 2.80GHz 6 | # RAM: 4GB 7 | # Disk(s): HITACHI HTS722016K9SA00 160GB 8 | 9 | # 10 | # Adjust the following variables according to your system. 11 | # 12 | 13 | # 14 | # Directories. 15 | # 16 | 17 | # Where to store the test results. 18 | $sql_bench_results = '/home/hakan/sql-bench-results'; 19 | 20 | # Where to compile the sources. You will need at least 1GB of disk space. 21 | # This is also the datadir directory. 22 | $work_dir = '/tmp'; 23 | 24 | # 25 | # Binaries. 26 | # 27 | 28 | # We need bzr >= 1.18.1. 29 | $bzr = '/usr/bin/bzr'; 30 | 31 | $mktemp = '/bin/mktemp'; 32 | 33 | $mkdir = '/bin/mkdir'; 34 | 35 | $sudo = '/usr/bin/sudo'; 36 | 37 | # Set the concurrency level (-j) to about: number of CPUs + 1. 38 | $make = '/usr/bin/make'; 39 | $concurrency = 3; 40 | 41 | # Perl with DBD::MySQL. 42 | $perl = '/usr/bin/perl'; 43 | 44 | # If you use ccache, a compiler cache, which reduces compile time, 45 | # then set the path to it here. 46 | $ccache = '/usr/bin/ccache'; 47 | 48 | # This has to be the last line. See "perldoc -f require" for details. 49 | 1; 50 | -------------------------------------------------------------------------------- /sql-bench-mysql/conf/perro.cnf: -------------------------------------------------------------------------------- 1 | # Configuration file for host: perro 2 | # 3 | # OS: openSUSE 11.1 (x86_64) 4 | # Platform: x86_64 5 | # CPU: Quad-core Intel @ 3.20GHz 6 | # RAM: 2GB 7 | # Disk(s): 2 x ST31000528AS S-ATA as software RAID 0 8 | 9 | # 10 | # Adjust the following variables according to your system. 11 | # 12 | 13 | # 14 | # Directories. 15 | # 16 | 17 | # Where to store the test results. 18 | $sql_bench_results = '/home/hakan/sql-bench-results'; 19 | 20 | # Where to compile the sources. You will need at least 1GB of disk space. 21 | # This is also the datadir directory. 22 | $work_dir = '/tmp'; 23 | 24 | # 25 | # Binaries. 26 | # 27 | 28 | # We need bzr >= 1.18.1. 29 | $bzr = '/usr/bin/bzr'; 30 | 31 | $mktemp = '/bin/mktemp'; 32 | 33 | $mkdir = '/bin/mkdir'; 34 | 35 | $sudo = '/usr/bin/sudo'; 36 | 37 | # Set the concurrency level (-j) to about: number of CPUs + 1. 38 | $make = '/usr/bin/make'; 39 | $concurrency = 3; 40 | 41 | # Perl with DBD::MySQL. 42 | $perl = '/usr/bin/perl'; 43 | 44 | # If you use ccache, a compiler cache, which reduces compile time, 45 | # then set the path to it here. 46 | $ccache = '/usr/bin/ccache'; 47 | 48 | # This has to be the last line. See "perldoc -f require" for details. 49 | 1; 50 | -------------------------------------------------------------------------------- /anel/.gdbinit: -------------------------------------------------------------------------------- 1 | set trace-commands on 2 | set pagination off 3 | set print pretty on 4 | set print array on 5 | set print array-indexes on 6 | set print elements 15000 7 | set print frame-arguments all 8 | set print sevenbit on 9 | set print static-members off 10 | handle SIGUSR1 nostop noprint 11 | handle SIGUSR2 nostop noprint 12 | handle SIGWAITING nostop noprint 13 | handle SIGLWP nostop noprint 14 | handle SIGPIPE nostop 15 | handle SIGALRM nostop 16 | handle SIGHUP nostop 17 | handle SIGTERM nostop noprint 18 | handle SIG32 nostop noprint 19 | handle SIG33 nostop noprint 20 | 21 | define find_page_in_pool 22 | set $buf_pool=$arg0 23 | set $space=$arg1 24 | set $page=$arg2 25 | 26 | set $chunk=$buf_pool->chunks 27 | set $i=$buf_pool->n_chunks 28 | set $found=0 29 | while ($i-- && !$found) 30 | set $j = $chunk->size 31 | set $b = $chunk->blocks 32 | while ($j--) 33 | if ($b->page.id.m_space==$space && $b->page.id.m_page_no==$page) 34 | print $b 35 | set $found=1 36 | loop_break 37 | end 38 | set $b++ 39 | end 40 | set $chunk++ 41 | end 42 | end 43 | 44 | document find_page_in_pool 45 | Buffer pool look-up: find_page_in_pool &buf_pool_ptr[0] space_id page_no" 46 | end 47 | -------------------------------------------------------------------------------- /sql-bench/conf/au0013.cnf: -------------------------------------------------------------------------------- 1 | # Configuration file for host: au0013 2 | # 3 | # OS: Mac OS X 10.6.5 4 | # Platform: x86_64 5 | # CPU: Dual-core Intel Core 2 Duo @ 2.8GHz 6 | # RAM: 4GB 7 | # Disk(s): 1 x ST9500420ASG S-ATA 8 | 9 | # 10 | # Adjust the following variables according to your system. 11 | # 12 | 13 | # 14 | # Directories. 15 | # 16 | 17 | # Where to store the test results. 18 | $sql_bench_results = '/Users/hakan/sql-bench-results'; 19 | 20 | # Where to compile the sources. You will need at least 1GB of disk space. 21 | # This is also the datadir directory. 22 | $work_dir = '/tmp'; 23 | 24 | # 25 | # Binaries. 26 | # 27 | 28 | # We need bzr >= 1.18.1. 29 | $bzr = '/usr/local/bin/bzr'; 30 | 31 | $mktemp = '/sw/sbin/mktemp'; 32 | 33 | $mkdir = '/sw/bin/mkdir'; 34 | 35 | $sudo = '/usr/bin/sudo'; 36 | 37 | # Set the concurrency level (-j) to about: number of CPUs + 1. 38 | $make = '/sw/bin/make'; 39 | $concurrency = 3; 40 | 41 | # Perl with DBD::MySQL. 42 | #$perl = '/usr/bin/perl'; 43 | $perl = '/sw/bin/perl'; 44 | 45 | # If you use ccache, a compiler cache, which reduces compile time, 46 | # then set the path to it here. 47 | $ccache = '/sw/bin/ccache'; 48 | 49 | # This has to be the last line. See "perldoc -f require" for details. 50 | 1; 51 | -------------------------------------------------------------------------------- /sql-bench-mysql/conf/au0013.cnf: -------------------------------------------------------------------------------- 1 | # Configuration file for host: au0013 2 | # 3 | # OS: Mac OS X 10.6.5 4 | # Platform: x86_64 5 | # CPU: Dual-core Intel Core 2 Duo @ 2.8GHz 6 | # RAM: 4GB 7 | # Disk(s): 1 x ST9500420ASG S-ATA 8 | 9 | # 10 | # Adjust the following variables according to your system. 11 | # 12 | 13 | # 14 | # Directories. 15 | # 16 | 17 | # Where to store the test results. 18 | $sql_bench_results = '/Users/hakan/sql-bench-results'; 19 | 20 | # Where to compile the sources. You will need at least 1GB of disk space. 21 | # This is also the datadir directory. 22 | $work_dir = '/tmp'; 23 | 24 | # 25 | # Binaries. 26 | # 27 | 28 | # We need bzr >= 1.18.1. 29 | $bzr = '/usr/local/bin/bzr'; 30 | 31 | $mktemp = '/sw/sbin/mktemp'; 32 | 33 | $mkdir = '/sw/bin/mkdir'; 34 | 35 | $sudo = '/usr/bin/sudo'; 36 | 37 | # Set the concurrency level (-j) to about: number of CPUs + 1. 38 | $make = '/sw/bin/make'; 39 | $concurrency = 3; 40 | 41 | # Perl with DBD::MySQL. 42 | #$perl = '/usr/bin/perl'; 43 | $perl = '/sw/bin/perl'; 44 | 45 | # If you use ccache, a compiler cache, which reduces compile time, 46 | # then set the path to it here. 47 | $ccache = '/sw/bin/ccache'; 48 | 49 | # This has to be the last line. See "perldoc -f require" for details. 50 | 1; 51 | -------------------------------------------------------------------------------- /sql-bench-mysql/basic/compiler_au0013.cnf: -------------------------------------------------------------------------------- 1 | # Base compile options for running sql-bench on host au0013. 2 | # 3 | # Hakan Kuecuekyilmaz, , 2011-03-16. 4 | 5 | # Configure environment variables. 6 | # Note: You can set ccache in the host specific config file. 7 | # In this case conf/au0013.cnf. 8 | # 9 | # This configuration is taken from BUILD/compile-pentium64-max --print. 10 | # 11 | $ENV{'CC'} = "gcc --pipe"; 12 | $ENV{'CFLAGS'} = "-Wall -Wextra -Wunused -Wwrite-strings -mtune=native -m64 -O3 -fno-omit-frame-pointer"; 13 | 14 | $ENV{'CXX'} = "g++"; 15 | $ENV{'CXXFLAGS'} = "-Wall -Wextra -Wunused -Wwrite-strings -Wno-unused-parameter -Wnon-virtual-dtor -felide-constructors -fno-exceptions -fno-rtti -mtune=native -m64 -O3 -fno-omit-frame-pointer"; 16 | $ENV{'CXXLDFLAGS'} = ""; 17 | 18 | $config = { 19 | # Configure invocation line. 20 | # Do not use --prefix here. 21 | configure_line => '--enable-assembler --with-extra-charsets=complex --enable-thread-safe-client --with-big-tables --with-readline --with-ssl --with-plugins=max --with-embedded-server --with-mysqld-ldflags=-all-static --with-client-ldflags=-all-static --enable-local-infile', 22 | }; 23 | 24 | # This has to be the last line. See "perldoc -f require" for details. 25 | 1; 26 | -------------------------------------------------------------------------------- /sql-bench-mysql/basic/compiler_lu0012.cnf: -------------------------------------------------------------------------------- 1 | # Base compile options for running sql-bench on host lu0012. 2 | # 3 | # Hakan Kuecuekyilmaz, , 2010-11-20. 4 | 5 | # Configure environment variables. 6 | # Note: You can set ccache in the host specific config file. 7 | # In this case conf/lu0012.cnf. 8 | # 9 | # This configuration is taken from BUILD/compile-pentium64-max --print. 10 | # 11 | $ENV{'CC'} = "gcc --pipe"; 12 | $ENV{'CFLAGS'} = "-Wall -Wextra -Wunused -Wwrite-strings -mtune=native -m64 -O3 -fno-omit-frame-pointer"; 13 | 14 | $ENV{'CXX'} = "g++"; 15 | $ENV{'CXXFLAGS'} = "-Wall -Wextra -Wunused -Wwrite-strings -Wno-unused-parameter -Wnon-virtual-dtor -felide-constructors -fno-exceptions -fno-rtti -mtune=native -m64 -O3 -fno-omit-frame-pointer"; 16 | $ENV{'CXXLDFLAGS'} = ""; 17 | 18 | $config = { 19 | # Configure invocation line. 20 | # Do not use --prefix here. 21 | configure_line => '--enable-assembler --with-extra-charsets=complex --enable-thread-safe-client --with-big-tables --with-readline --with-ssl --with-plugins=max --with-embedded-server --with-mysqld-ldflags=-all-static --with-client-ldflags=-all-static --enable-local-infile', 22 | }; 23 | 24 | # This has to be the last line. See "perldoc -f require" for details. 25 | 1; 26 | -------------------------------------------------------------------------------- /sql-bench-mysql/basic/compiler_pitbull.cnf: -------------------------------------------------------------------------------- 1 | # Base compile options for running sql-bench on host pitbull. 2 | # 3 | # Hakan Kuecuekyilmaz, , 2010-11-20. 4 | 5 | # Configure environment variables. 6 | # Note: You can set ccache in the host specific config file. 7 | # In this case conf/pitbull.cnf. 8 | # 9 | # This configuration is taken from BUILD/compile-pentium64-max --print. 10 | # 11 | $ENV{'CC'} = "gcc --pipe"; 12 | $ENV{'CFLAGS'} = "-Wall -Wextra -Wunused -Wwrite-strings -mtune=native -m64 -O3 -fno-omit-frame-pointer"; 13 | 14 | $ENV{'CXX'} = "g++"; 15 | $ENV{'CXXFLAGS'} = "-Wall -Wextra -Wunused -Wwrite-strings -Wno-unused-parameter -Wnon-virtual-dtor -felide-constructors -fno-exceptions -fno-rtti -mtune=native -m64 -O3 -fno-omit-frame-pointer"; 16 | $ENV{'CXXLDFLAGS'} = ""; 17 | 18 | $config = { 19 | # Configure invocation line. 20 | # Do not use --prefix here. 21 | configure_line => '--enable-assembler --with-extra-charsets=complex --enable-thread-safe-client --with-big-tables --with-readline --with-ssl --with-plugins=max --with-embedded-server --with-mysqld-ldflags=-all-static --with-client-ldflags=-all-static --enable-local-infile', 22 | }; 23 | 24 | # This has to be the last line. See "perldoc -f require" for details. 25 | 1; 26 | -------------------------------------------------------------------------------- /anel/k8s/mariadb/mariadb-sts.yaml: -------------------------------------------------------------------------------- 1 | apiVersion: v1 2 | kind: Service 3 | metadata: 4 | name: mariadb-service 5 | labels: 6 | app: mariadb 7 | spec: 8 | ports: 9 | - port: 3306 10 | name: mariadb-port 11 | clusterIP: None 12 | selector: 13 | app: mariadb 14 | --- 15 | apiVersion: apps/v1 16 | kind: StatefulSet 17 | metadata: 18 | name: mariadb-sts 19 | spec: 20 | serviceName: "mariadb-service" 21 | replicas: 3 22 | selector: 23 | matchLabels: 24 | app: mariadb 25 | template: 26 | metadata: 27 | labels: 28 | app: mariadb 29 | spec: 30 | containers: 31 | - name: mariadb 32 | image: mariadb 33 | ports: 34 | - containerPort: 3306 35 | name: mariadb-port 36 | env: 37 | # Using Secrets 38 | - name: MARIADB_ROOT_PASSWORD 39 | valueFrom: 40 | secretKeyRef: 41 | name: mariadb-secret 42 | key: mariadb-root-password 43 | volumeMounts: 44 | - name: datadir 45 | mountPath: /var/lib/mysql/ 46 | volumeClaimTemplates: 47 | - metadata: 48 | name: datadir 49 | spec: 50 | accessModes: [ "ReadWriteOnce" ] 51 | resources: 52 | requests: 53 | storage: 300M -------------------------------------------------------------------------------- /dbt3_benchmark/tests/myisam_test_mariadb_5_3_mysql_5_5_mysql_5_6_17_19_20.conf: -------------------------------------------------------------------------------- 1 | [common] 2 | RESULTS_DB_CONFIG = $PROJECT_HOME/mariadb-tools/dbt3_benchmark/tests/results_db_conf/results_db.conf 3 | TEST_CONFIG = $PROJECT_HOME/mariadb-tools/dbt3_benchmark/tests/test_conf/test_myisam.conf 4 | 5 | [mariadb_5_3_per_test_icp] 6 | QUERIES_CONFIG = $PROJECT_HOME/mariadb-tools/dbt3_benchmark/tests/queries_conf/queries-mariadb_17_19_20.conf 7 | DB_CONFIG = $PROJECT_HOME/mariadb-tools/dbt3_benchmark/tests/db_conf/db_mariadb_5_3_myisam_icp.conf 8 | 9 | 10 | #[mariadb_5_5_icp] 11 | #QUERIES_CONFIG = $PROJECT_HOME/mariadb-tools/dbt3_benchmark/tests/queries_conf/queries-mariadb_17_19_20.conf 12 | #DB_CONFIG = $PROJECT_HOME/mariadb-tools/dbt3_benchmark/tests/db_conf/db_mariadb_5_5_myisam_icp.conf 13 | 14 | 15 | [mysql_5_6] 16 | QUERIES_CONFIG = $PROJECT_HOME/mariadb-tools/dbt3_benchmark/tests/queries_conf/queries-mysql_17_19_20.conf 17 | DB_CONFIG = $PROJECT_HOME/mariadb-tools/dbt3_benchmark/tests/db_conf/db_mysql_5_6_myisam.conf 18 | 19 | 20 | [mysql_5_5] 21 | QUERIES_CONFIG = $PROJECT_HOME/mariadb-tools/dbt3_benchmark/tests/queries_conf/queries-mysql_17_19_20.conf 22 | DB_CONFIG = $PROJECT_HOME/mariadb-tools/dbt3_benchmark/tests/db_conf/db_mysql_5_5_myisam.conf 23 | 24 | 25 | -------------------------------------------------------------------------------- /dbt3_benchmark/dbt3_mysql/mysql_queries/19.sql: -------------------------------------------------------------------------------- 1 | -- @(#)19.sql 2.1.8.1 2 | -- TPC-H/TPC-R Discounted Revenue Query (Q19) 3 | -- Functional Query Definition 4 | -- Approved February 1998 5 | :b 6 | :x 7 | :o 8 | select 9 | sum(l_extendedprice* (1 - l_discount)) as revenue 10 | from 11 | lineitem, 12 | part 13 | where 14 | ( 15 | p_partkey = l_partkey 16 | and p_brand = ':1' 17 | and p_container in ('SM CASE', 'SM BOX', 'SM PACK', 'SM PKG') 18 | and l_quantity >= :4 and l_quantity <= :4+10 19 | and p_size between 1 and 5 20 | and l_shipmode in ('AIR', 'AIR REG') 21 | and l_shipinstruct = 'DELIVER IN PERSON' 22 | ) 23 | or 24 | ( 25 | p_partkey = l_partkey 26 | and p_brand = ':2' 27 | and p_container in ('MED BAG', 'MED BOX', 'MED PKG', 'MED PACK') 28 | and l_quantity >= :5 and l_quantity <= :5+10 29 | and p_size between 1 and 10 30 | and l_shipmode in ('AIR', 'AIR REG') 31 | and l_shipinstruct = 'DELIVER IN PERSON' 32 | ) 33 | or 34 | ( 35 | p_partkey = l_partkey 36 | and p_brand = ':3' 37 | and p_container in ('LG CASE', 'LG BOX', 'LG PACK', 'LG PKG') 38 | and l_quantity >= :6 and l_quantity <= :6+10 39 | and p_size between 1 and 15 40 | and l_shipmode in ('AIR', 'AIR REG') 41 | and l_shipinstruct = 'DELIVER IN PERSON' 42 | ); 43 | :e 44 | -------------------------------------------------------------------------------- /reporting/kaj_gets_open_prs_until_date.py: -------------------------------------------------------------------------------- 1 | import argparse 2 | import sys 3 | import pandas as pd 4 | from github_activity import get_activity 5 | 6 | from process_github_activity import setup_parser, compute_activity 7 | 8 | def main(): 9 | parser = setup_parser() 10 | args = parser.parse_args(sys.argv[1:]) 11 | 12 | df = compute_activity(args) 13 | ts_now = pd.to_datetime(args.until, utc=True) 14 | 15 | def to_ts(row): 16 | closed = pd.to_datetime(row['closedAt'], utc=True) 17 | created = pd.to_datetime(row['createdAt'], utc=True) 18 | row['closedAt'] = closed 19 | row['createdAt'] = created 20 | return row 21 | df = df.apply(to_ts, axis=1) 22 | 23 | stillopen = df.loc[df['state'] == 'OPEN'] 24 | were_open_now_closed = df.loc[df['state'].isin(['CLOSED', 'MERGED'])].loc[df['closedAt'] > ts_now] 25 | 26 | df = pd.concat([stillopen, were_open_now_closed], sort=False, ignore_index=True) 27 | 28 | def tr(row): 29 | row['openTimeDays'] = (ts_now - row['createdAt']).total_seconds() / (3600 * 24) 30 | return row 31 | 32 | df = df.apply(tr, axis=1) 33 | 34 | if args.output: 35 | df.to_csv(args.output) 36 | return 37 | print(df) 38 | 39 | if __name__ == "__main__": 40 | main() 41 | -------------------------------------------------------------------------------- /reporting/process_gitlog_csv.py: -------------------------------------------------------------------------------- 1 | import argparse 2 | import sys 3 | 4 | DESCRIPTION = "Get the git-log csv generated by Zak's script and process it a bit more" 5 | parser = argparse.ArgumentParser(description=DESCRIPTION) 6 | 7 | parser.add_argument( 8 | "-s", "--source", help="""Input CSV file""" 9 | ) 10 | 11 | parser.add_argument( 12 | "-o", "--output", default=None, help="""Output CSV file""" 13 | ) 14 | 15 | def process(source, output): 16 | csv = [] 17 | with open(source) as f: 18 | content = f.readlines() 19 | content = [x.strip() for x in content] 20 | csv.append(content[0]) 21 | for l in content[1:]: 22 | tokens = l.split(',') 23 | if len(tokens[2].split('@')) > 1: 24 | tokens.insert(2, 'No Organization') 25 | 26 | if tokens[2] == '' or tokens[2] == 'Unknown': 27 | tokens[2] = 'No Organization' 28 | 29 | csv.append(','.join(tokens)) 30 | 31 | if not output: 32 | print('\n'.join(csv)) 33 | return 34 | 35 | with open(output, "w") as ff: 36 | ff.write('\n'.join(csv)) 37 | 38 | def main(): 39 | args = parser.parse_args(sys.argv[1:]) 40 | process(args.source, args.output) 41 | 42 | if __name__ == "__main__": 43 | main() 44 | -------------------------------------------------------------------------------- /sql-bench/conf/pitbull.cnf: -------------------------------------------------------------------------------- 1 | # Configuration file for host: pitbull 2 | # 3 | # OS: Ubuntu 10.10 4 | # Platform: x86_64 5 | # CPU: Two socket hexa-core Intel Xeon X5660 @ 2.80GHz 6 | # RAM: 23GB 7 | # Disk(s): 1 x ST3500320NS S-ATA 8 | 9 | # 10 | # Adjust the following variables according to your system. 11 | # 12 | 13 | # 14 | # Directories. 15 | # 16 | 17 | # Where to store the test results. 18 | $sql_bench_results = '/home/hakan/sql-bench-results'; 19 | 20 | # Where to compile the sources. You will need at least 1GB of disk space. 21 | # This is also the datadir directory. 22 | #$work_dir = '/tmp'; 23 | #$work_dir = '/media/ssd_tmp'; 24 | $work_dir = '/data/sql-bench'; 25 | 26 | # 27 | # Binaries. 28 | # 29 | 30 | # We need bzr >= 1.18.1. 31 | $bzr = '/usr/bin/bzr'; 32 | 33 | $mktemp = '/bin/mktemp'; 34 | 35 | $mkdir = '/bin/mkdir'; 36 | 37 | $sudo = '/usr/bin/sudo'; 38 | 39 | # Set the concurrency level (-j) to about: number of CPUs + 1. 40 | $make = '/usr/bin/make'; 41 | $concurrency = 13; 42 | 43 | # Perl with DBD::MySQL. 44 | $perl = '/usr/bin/perl'; 45 | 46 | # If you use ccache, a compiler cache, which reduces compile time, 47 | # then set the path to it here. 48 | $ccache = '/usr/bin/ccache'; 49 | 50 | # This has to be the last line. See "perldoc -f require" for details. 51 | 1; 52 | -------------------------------------------------------------------------------- /sql-bench-mysql/conf/pitbull.cnf: -------------------------------------------------------------------------------- 1 | # Configuration file for host: pitbull 2 | # 3 | # OS: Ubuntu 10.10 4 | # Platform: x86_64 5 | # CPU: Two socket hexa-core Intel Xeon X5660 @ 2.80GHz 6 | # RAM: 23GB 7 | # Disk(s): 1 x ST3500320NS S-ATA 8 | 9 | # 10 | # Adjust the following variables according to your system. 11 | # 12 | 13 | # 14 | # Directories. 15 | # 16 | 17 | # Where to store the test results. 18 | $sql_bench_results = '/home/hakan/sql-bench-results'; 19 | 20 | # Where to compile the sources. You will need at least 1GB of disk space. 21 | # This is also the datadir directory. 22 | #$work_dir = '/tmp'; 23 | #$work_dir = '/media/ssd_tmp'; 24 | $work_dir = '/data/sql-bench'; 25 | 26 | # 27 | # Binaries. 28 | # 29 | 30 | # We need bzr >= 1.18.1. 31 | $bzr = '/usr/bin/bzr'; 32 | 33 | $mktemp = '/bin/mktemp'; 34 | 35 | $mkdir = '/bin/mkdir'; 36 | 37 | $sudo = '/usr/bin/sudo'; 38 | 39 | # Set the concurrency level (-j) to about: number of CPUs + 1. 40 | $make = '/usr/bin/make'; 41 | $concurrency = 13; 42 | 43 | # Perl with DBD::MySQL. 44 | $perl = '/usr/bin/perl'; 45 | 46 | # If you use ccache, a compiler cache, which reduces compile time, 47 | # then set the path to it here. 48 | $ccache = '/usr/bin/ccache'; 49 | 50 | # This has to be the last line. See "perldoc -f require" for details. 51 | 1; 52 | -------------------------------------------------------------------------------- /release/install-createrepo.sh: -------------------------------------------------------------------------------- 1 | #!/bin/bash - 2 | #=============================================================================== 3 | # 4 | # FILE: install-createrepo.sh 5 | # 6 | # USAGE: ./install-createrepo.sh 7 | # 8 | # DESCRIPTION: simple script to install createrepo on Ubuntu focal 9 | # 10 | #=============================================================================== 11 | 12 | set -o nounset # Treat unset variables as an error 13 | set -x 14 | 15 | sudo apt update 16 | wget \ 17 | http://old-releases.ubuntu.com/ubuntu/pool/universe/c/createrepo/createrepo_0.10.3-1_all.deb \ 18 | http://old-releases.ubuntu.com/ubuntu/pool/universe/d/deltarpm/deltarpm_3.6+dfsg-1build8_amd64.deb \ 19 | http://old-releases.ubuntu.com/ubuntu/pool/universe/d/deltarpm/python-deltarpm_3.6+dfsg-1build8_amd64.deb \ 20 | http://old-releases.ubuntu.com/ubuntu/pool/universe/p/python-lzma/python-lzma_0.5.3-4_amd64.deb \ 21 | http://old-releases.ubuntu.com/ubuntu/pool/universe/u/urlgrabber/python-urlgrabber_3.10.2-1_all.deb \ 22 | http://old-releases.ubuntu.com/ubuntu/pool/universe/y/yum/yum_3.4.3-3_all.deb \ 23 | http://old-releases.ubuntu.com/ubuntu/pool/universe/y/yum-metadata-parser/python-sqlitecachec_1.1.4-1_amd64.deb 24 | 25 | sudo apt install -y ./*.deb 26 | 27 | -------------------------------------------------------------------------------- /dbt3_benchmark/tests/queries_conf/queries-mariadb_17_19_20.conf: -------------------------------------------------------------------------------- 1 | [queries_settings] 2 | QUERIES_HOME = $QUERIES_HOME/s$SCALE_FACTOR-m 3 | 4 | #[17] 5 | #QUERY=17.sql 6 | #EXPLAIN_QUERY=17_explain.sql 7 | #TIMEOUT=7200 8 | 9 | #[17-opt1] 10 | #QUERY=17-opt1.sql 11 | #EXPLAIN_QUERY=17-opt1_explain.sql 12 | #TIMEOUT=7200 13 | 14 | #[17-opt2] 15 | #QUERY=17-opt2.sql 16 | #EXPLAIN_QUERY=17-opt2_explain.sql 17 | #TIMEOUT=7200 18 | 19 | 20 | 21 | #[19] 22 | #QUERY=19.sql 23 | #EXPLAIN_QUERY=19_explain.sql 24 | #TIMEOUT=7200 25 | 26 | #[19-opt1] 27 | #QUERY=19-opt1.sql 28 | #EXPLAIN_QUERY=19-opt1_explain.sql 29 | #TIMEOUT=7200 30 | 31 | #[19-opt2] 32 | #QUERY=19-opt2.sql 33 | #EXPLAIN_QUERY=19-opt2_explain.sql 34 | #TIMEOUT=7200 35 | 36 | 37 | 38 | #variant1 39 | [20-opt1] 40 | QUERY=20-opt1.sql 41 | EXPLAIN_QUERY=20-opt1_explain.sql 42 | STARTUP_PARAMS=--optimizer_switch='materialization=on' --optimizer_switch='in_to_exists=off' --optimizer_switch='semijoin=off' 43 | TIMEOUT=43200 44 | 45 | #variant2 46 | [20-opt2] 47 | QUERY=20-opt2.sql 48 | EXPLAIN_QUERY=20-opt2_explain.sql 49 | TIMEOUT=43200 50 | 51 | #variant3 52 | [20] 53 | QUERY=20.sql 54 | EXPLAIN_QUERY=20_explain.sql 55 | STARTUP_PARAMS=--optimizer_switch='materialization=off' --optimizer_switch='in_to_exists=on' --optimizer_switch='semijoin=off' 56 | TIMEOUT=43200 -------------------------------------------------------------------------------- /anel/.tmux-faustin.conf: -------------------------------------------------------------------------------- 1 | set -g default-terminal 'screen-256color' 2 | 3 | # default startup command 4 | # set-option -g default-command 'reattach-to-user-namespace -l $SHELL -l' 5 | 6 | set-option -g history-limit 300000 7 | bind S \ 8 | setw synchronize-panes \; \ 9 | display "Sync #{?synchronize-panes,ON,OFF}" 10 | 11 | # enable activity alerts 12 | setw -g monitor-activity on 13 | set -g visual-activity on 14 | 15 | # Mouse scrolling 16 | set -g mouse on 17 | 18 | # vi mode 19 | #set-window-option -g mode-keys vi 20 | setw -g mode-keys vi 21 | bind h select-pane -L 22 | bind j select-pane -D 23 | bind k select-pane -U 24 | bind l select-pane -R 25 | bind-key -r C-h select-window -t :- 26 | bind-key -r C-l select-window -t :+ 27 | 28 | # Faster escape sequences (default is 500ms). 29 | # This helps when exiting insert mode in Vim: http://superuser.com/a/252717/65504 30 | set -s escape-time 50 31 | 32 | # setup 'v' to begin selection as in Vim 33 | bind-key -T copy-mode-vi v send-keys -X begin-selection 34 | bind-key -T copy-mode-vi y send-keys -X copy-pipe-and-cancel 'reattach-to-user-namespace pbcopy' 35 | 36 | # update default binding of `Enter` to also use copy-pipe 37 | unbind-key -T copy-mode-vi Enter 38 | bind-key -T copy-mode-vi Enter send-keys -X copy-pipe-and-cancel 'reattach-to-user-namespace pbcopy' 39 | -------------------------------------------------------------------------------- /sql-bench-mysql/O2/compiler_lu0012.cnf: -------------------------------------------------------------------------------- 1 | # Compile options with lower optimization running sql-bench on host lu0012. 2 | # 3 | # Hakan Kuecuekyilmaz, , 2010-11-20. 4 | 5 | # Configure environment variables. 6 | # Note: You can set ccache in the host specific config file. 7 | # In this case conf/lu0012.cnf. 8 | # 9 | # This configuration is taken from BUILD/compile-pentium64-max --print and 10 | # the option -O3 was changed to -O2. 11 | # 12 | $ENV{'CC'} = "gcc --pipe"; 13 | $ENV{'CFLAGS'} = "-Wall -Wextra -Wunused -Wwrite-strings -mtune=native -m64 -O2 -fno-omit-frame-pointer"; 14 | 15 | $ENV{'CXX'} = "g++"; 16 | $ENV{'CXXFLAGS'} = "-Wall -Wextra -Wunused -Wwrite-strings -Wno-unused-parameter -Wnon-virtual-dtor -felide-constructors -fno-exceptions -fno-rtti -mtune=native -m64 -O2 -fno-omit-frame-pointer"; 17 | $ENV{'CXXLDFLAGS'} = ""; 18 | 19 | $config = { 20 | # Configure invocation line. 21 | # Do not use --prefix here. 22 | configure_line => '--enable-assembler --with-extra-charsets=complex --enable-thread-safe-client --with-big-tables --with-readline --with-ssl --with-plugins=max --with-embedded-server --with-mysqld-ldflags=-all-static --with-client-ldflags=-all-static --enable-local-infile', 23 | }; 24 | 25 | # This has to be the last line. See "perldoc -f require" for details. 26 | 1; 27 | -------------------------------------------------------------------------------- /sql-bench-mysql/O2/compiler_pitbull.cnf: -------------------------------------------------------------------------------- 1 | # Compile options with lower optimization running sql-bench on host pitbull. 2 | # 3 | # Hakan Kuecuekyilmaz, , 2010-11-20. 4 | 5 | # Configure environment variables. 6 | # Note: You can set ccache in the host specific config file. 7 | # In this case conf/pitbull.cnf. 8 | # 9 | # This configuration is taken from BUILD/compile-pentium64-max --print and 10 | # the option -O3 was changed to -O2. 11 | # 12 | $ENV{'CC'} = "gcc --pipe"; 13 | $ENV{'CFLAGS'} = "-Wall -Wextra -Wunused -Wwrite-strings -mtune=native -m64 -O2 -fno-omit-frame-pointer"; 14 | 15 | $ENV{'CXX'} = "g++"; 16 | $ENV{'CXXFLAGS'} = "-Wall -Wextra -Wunused -Wwrite-strings -Wno-unused-parameter -Wnon-virtual-dtor -felide-constructors -fno-exceptions -fno-rtti -mtune=native -m64 -O2 -fno-omit-frame-pointer"; 17 | $ENV{'CXXLDFLAGS'} = ""; 18 | 19 | $config = { 20 | # Configure invocation line. 21 | # Do not use --prefix here. 22 | configure_line => '--enable-assembler --with-extra-charsets=complex --enable-thread-safe-client --with-big-tables --with-readline --with-ssl --with-plugins=max --with-embedded-server --with-mysqld-ldflags=-all-static --with-client-ldflags=-all-static --enable-local-infile', 23 | }; 24 | 25 | # This has to be the last line. See "perldoc -f require" for details. 26 | 1; 27 | -------------------------------------------------------------------------------- /daniel/spider/docker-compose.yml: -------------------------------------------------------------------------------- 1 | version: '3' 2 | x-common-variables: &common-variables 3 | MARIADB_USER: sales 4 | MARIADB_PASSWORD: secret 5 | MARIADB_DATABASE: production_sales 6 | MARIADB_RANDOM_ROOT_PASSWORD: 1 7 | 8 | x-common-attributes: &common-attributes 9 | build: 10 | context: . 11 | environment: *common-variables 12 | healthcheck: 13 | test: ["CMD", "healthcheck.sh", "--connect", "--innodb_initialized"] 14 | start_period: 10s 15 | interval: 10s 16 | timeout: 5s 17 | retries: 3 18 | 19 | x-data-generator: &data-generator 20 | build: 21 | dockerfile: Dockerfile.generator 22 | context: . 23 | 24 | services: 25 | 26 | node1: 27 | <<: *common-attributes 28 | volumes: 29 | - 'node1:/var/lib/mysql' 30 | generatornode1: 31 | <<: *data-generator 32 | depends_on: 33 | node1: 34 | condition: service_healthy 35 | command: node1 production_sales sales secret 36 | 37 | node2: 38 | <<: *common-attributes 39 | volumes: 40 | - 'node2:/var/lib/mysql' 41 | generatornode2: 42 | <<: *data-generator 43 | depends_on: 44 | node2: 45 | condition: service_healthy 46 | command: node2 production_sales sales secret 47 | 48 | volumes: 49 | node1: 50 | driver: local 51 | node2: 52 | driver: local 53 | 54 | -------------------------------------------------------------------------------- /anel/jdbc_connect_blog/docker-compose.yaml: -------------------------------------------------------------------------------- 1 | version: "3.9" 2 | 3 | services: 4 | mariadb: 5 | image: mariadb:latest 6 | container_name: mariadb-source 7 | environment: 8 | - MARIADB_ALLOW_EMPTY_ROOT_PASSWORD=1 9 | - MARIADB_DATABASE=db_maria 10 | volumes: 11 | - ./mariadb_data:/docker-entrypoint-initdb.d:z 12 | healthcheck: 13 | test: ['CMD', "healthcheck.sh", "--connect"] 14 | 15 | mysql: 16 | image: mysql:latest 17 | container_name: mysql-source 18 | environment: 19 | - MYSQL_ALLOW_EMPTY_PASSWORD=1 20 | - MYSQL_DATABASE=db_mysql 21 | volumes: 22 | - ./mysql_data:/docker-entrypoint-initdb.d:z 23 | healthcheck: 24 | test: ['CMD', "mysqladmin", "--password=", "--protocol", "tcp", "ping"] 25 | 26 | jdbc_target: 27 | build: 28 | context: . 29 | args: 30 | mariadb_version: "latest" 31 | dockerfile: ./Dockerfile 32 | container_name: mariadb-target 33 | environment: 34 | - MARIADB_ALLOW_EMPTY_ROOT_PASSWORD=1 35 | - MARIADB_DATABASE=test 36 | volumes: 37 | - ./target_data/:/docker-entrypoint-initdb.d:z 38 | - ./target_conf/:/etc/mysql/conf.d/:z 39 | 40 | depends_on: 41 | mariadb: 42 | condition: service_healthy 43 | mysql: 44 | condition: service_healthy 45 | -------------------------------------------------------------------------------- /sql-bench/basic/compiler_au0013.cnf: -------------------------------------------------------------------------------- 1 | # Base compile options for running sql-bench on host au0013. 2 | # 3 | # Hakan Kuecuekyilmaz, , 2011-03-16. 4 | 5 | # Configure environment variables. 6 | # Note: You can set ccache in the host specific config file. 7 | # In this case conf/au0013.cnf. 8 | # 9 | # This configuration is taken from BUILD/compile-pentium64-max --print. 10 | # 11 | $ENV{'CC'} = "gcc --pipe"; 12 | $ENV{'CFLAGS'} = "-Wall -Wextra -Wunused -Wwrite-strings -mtune=native -m64 -O3 -fno-omit-frame-pointer"; 13 | 14 | $ENV{'CXX'} = "g++"; 15 | $ENV{'CXXFLAGS'} = "-Wall -Wextra -Wunused -Wwrite-strings -Wno-unused-parameter -Wnon-virtual-dtor -felide-constructors -fno-exceptions -fno-rtti -mtune=native -m64 -O3 -fno-omit-frame-pointer"; 16 | $ENV{'CXXLDFLAGS'} = ""; 17 | 18 | $config = { 19 | # Configure invocation line. 20 | # Do not use --prefix here. 21 | configure_line => '--enable-assembler --with-extra-charsets=complex --enable-thread-safe-client --with-big-tables --with-plugin-aria --with-aria-tmp-tables --without-plugin-innodb_plugin --with-readline --with-ssl --with-plugins=max --with-embedded-server --with-libevent --with-mysqld-ldflags=-all-static --with-client-ldflags=-all-static --enable-local-infile', 22 | }; 23 | 24 | # This has to be the last line. See "perldoc -f require" for details. 25 | 1; 26 | -------------------------------------------------------------------------------- /sql-bench/basic/compiler_lu0012.cnf: -------------------------------------------------------------------------------- 1 | # Base compile options for running sql-bench on host lu0012. 2 | # 3 | # Hakan Kuecuekyilmaz, , 2010-11-20. 4 | 5 | # Configure environment variables. 6 | # Note: You can set ccache in the host specific config file. 7 | # In this case conf/lu0012.cnf. 8 | # 9 | # This configuration is taken from BUILD/compile-pentium64-max --print. 10 | # 11 | $ENV{'CC'} = "gcc --pipe"; 12 | $ENV{'CFLAGS'} = "-Wall -Wextra -Wunused -Wwrite-strings -mtune=native -m64 -O3 -fno-omit-frame-pointer"; 13 | 14 | $ENV{'CXX'} = "g++"; 15 | $ENV{'CXXFLAGS'} = "-Wall -Wextra -Wunused -Wwrite-strings -Wno-unused-parameter -Wnon-virtual-dtor -felide-constructors -fno-exceptions -fno-rtti -mtune=native -m64 -O3 -fno-omit-frame-pointer"; 16 | $ENV{'CXXLDFLAGS'} = ""; 17 | 18 | $config = { 19 | # Configure invocation line. 20 | # Do not use --prefix here. 21 | configure_line => '--enable-assembler --with-extra-charsets=complex --enable-thread-safe-client --with-big-tables --with-plugin-aria --with-aria-tmp-tables --without-plugin-innodb_plugin --with-readline --with-ssl --with-plugins=max --with-embedded-server --with-libevent --with-mysqld-ldflags=-all-static --with-client-ldflags=-all-static --enable-local-infile', 22 | }; 23 | 24 | # This has to be the last line. See "perldoc -f require" for details. 25 | 1; 26 | -------------------------------------------------------------------------------- /sql-bench/basic/compiler_pitbull.cnf: -------------------------------------------------------------------------------- 1 | # Base compile options for running sql-bench on host pitbull. 2 | # 3 | # Hakan Kuecuekyilmaz, , 2010-11-20. 4 | 5 | # Configure environment variables. 6 | # Note: You can set ccache in the host specific config file. 7 | # In this case conf/pitbull.cnf. 8 | # 9 | # This configuration is taken from BUILD/compile-pentium64-max --print. 10 | # 11 | $ENV{'CC'} = "gcc --pipe"; 12 | $ENV{'CFLAGS'} = "-Wall -Wextra -Wunused -Wwrite-strings -mtune=native -m64 -O3 -fno-omit-frame-pointer"; 13 | 14 | $ENV{'CXX'} = "g++"; 15 | $ENV{'CXXFLAGS'} = "-Wall -Wextra -Wunused -Wwrite-strings -Wno-unused-parameter -Wnon-virtual-dtor -felide-constructors -fno-exceptions -fno-rtti -mtune=native -m64 -O3 -fno-omit-frame-pointer"; 16 | $ENV{'CXXLDFLAGS'} = ""; 17 | 18 | $config = { 19 | # Configure invocation line. 20 | # Do not use --prefix here. 21 | configure_line => '--enable-assembler --with-extra-charsets=complex --enable-thread-safe-client --with-big-tables --with-plugin-aria --with-aria-tmp-tables --without-plugin-innodb_plugin --with-readline --with-ssl --with-plugins=max --with-embedded-server --with-libevent --with-mysqld-ldflags=-all-static --with-client-ldflags=-all-static --enable-local-infile', 22 | }; 23 | 24 | # This has to be the last line. See "perldoc -f require" for details. 25 | 1; 26 | -------------------------------------------------------------------------------- /monitoring/com_commit_monitor.sh: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | # 3 | # Simple COM_COMMIT monitor 4 | # 5 | # Hakan Kuecuekyilmaz, , 2010-12-16. 6 | 7 | if [ $# != 2 ]; then 8 | echo "[ERROR]: Please use exactly two arguments" 9 | echo " Usage: $0 [time interval] [absolute | delta]" 10 | echo " Example: $0 10 delta" 11 | 12 | exit 1 13 | else 14 | INTERVALL="$1" 15 | MODE="$2" 16 | fi 17 | 18 | # Adjust this patch to match your path to the mysql client. 19 | MYSQL="/usr/local/mysql/bin/mysql" 20 | 21 | COMMIT_COUNT_QUERY="SELECT VARIABLE_VALUE FROM INFORMATION_SCHEMA.GLOBAL_STATUS WHERE VARIABLE_NAME = 'COM_COMMIT'" 22 | PROCESSES_COUNT_QUERY="SELECT count(*) FROM INFORMATION_SCHEMA.PROCESSLIST" 23 | 24 | while true 25 | do 26 | DATE=$(date +%s) 27 | PROCESSES_COUNT=$(echo $PROCESSES_COUNT_QUERY | $MYSQL -uroot --column-names=false) 28 | COMMIT_COUNT=$(echo $COMMIT_COUNT_QUERY | $MYSQL -uroot --column-names=false) 29 | 30 | sleep $INTERVALL 31 | 32 | if [ x"$MODE" = x"absolute" ]; then 33 | echo "$DATE $PROCESSES_COUNT $COMMIT_COUNT" 34 | else 35 | DATE=$(date +%s) 36 | 37 | COMMIT_COUNT2=$(echo $COMMIT_COUNT_QUERY | $MYSQL -uroot --column-names=false) 38 | DELTA=$(($COMMIT_COUNT2 - $COMMIT_COUNT)) 39 | 40 | echo "$DATE $PROCESSES_COUNT $DELTA" 41 | fi 42 | done 43 | -------------------------------------------------------------------------------- /anel/k8s/mariadb/wordpress-deployment-pvc.yaml: -------------------------------------------------------------------------------- 1 | apiVersion: v1 2 | kind: Service 3 | metadata: 4 | name: wordpress 5 | spec: 6 | selector: 7 | app: wordpress 8 | ports: 9 | - port: 80 10 | targetPort: 80 11 | protocol: TCP #default 12 | nodePort: 31000 13 | type: LoadBalancer 14 | --- 15 | 16 | apiVersion: apps/v1 17 | kind: Deployment 18 | metadata: 19 | name: wordpress-deployment 20 | spec: # specification for deployment resource 21 | replicas: 2 22 | selector: 23 | matchLabels: 24 | app: wordpress 25 | template: # blueprint for pods 26 | metadata: 27 | labels: 28 | app: wordpress 29 | spec: # specification for pods 30 | containers: 31 | - name: wordpress 32 | image: wordpress:latest ##4.8-apache 33 | ports: 34 | - containerPort: 80 35 | env: 36 | - name: WORDPRESS_DB_HOST 37 | valueFrom: 38 | configMapKeyRef: 39 | name: mariadb-configmap 40 | key: database_url 41 | #value: mariadb-internal-service 42 | - name: WORDPRESS_DB_PASSWORD 43 | valueFrom: 44 | secretKeyRef: 45 | name: mariadb-secret 46 | key: mariadb-root-password 47 | - name: WORDPRESS_DB_USER 48 | value: root 49 | - name: WORDPRESS_DEBUG 50 | value: "1" -------------------------------------------------------------------------------- /daniel/broken_active_active_replication/changing.sh: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | 3 | MARIADB_USER=testuser 4 | MARIADB_PASSWORD=password 5 | MARIADB_DATABASE=testdb 6 | 7 | db=$MARIADB_DATABASE 8 | user=$MARIADB_USER 9 | password=$MARIADB_PASSWORD 10 | delay=0 11 | set -x -v 12 | 13 | while true 14 | do 15 | 16 | port=$(( RANDOM % 2 + 3307)) 17 | id=$((RANDOM % 6 + 1)) 18 | value=$(( RANDOM % 100 )).$(( RANDOM % 100)) 19 | MYSQL_PWD="$password" mariadb --host 127.0.0.1 --port 3308 --user "$user" "$db" -e "UPDATE tbl SET val='$value' WHERE id=$id;" 20 | sleep $delay 21 | done & 22 | #| MYSQL_PWD="$password" mariadb --host 127.0.0.1 --port $port --user "$user" "$db" 23 | 24 | while true 25 | do 26 | port=$(( RANDOM % 2 + 3307)) 27 | id=$((RANDOM % 6 + 1)) 28 | MYSQL_PWD="$password" mariadb --host 127.0.0.1 --port $port --user "$user" "$db" -e "DELETE FROM tbl WHERE id=$id;" 29 | sleep $delay 30 | done & 31 | #| MYSQL_PWD="$password" mariadb --host 127.0.0.1 --port 3307 --user "$user" "$db" 32 | while true 33 | do 34 | port=$(( RANDOM % 2 + 3307)) 35 | id=$((RANDOM % 6 + 1)) 36 | value=$(( RANDOM % 100 )).$(( RANDOM % 100)) 37 | MYSQL_PWD="$password" mariadb --host 127.0.0.1 --port $port --user "$user" "$db" -e "INSERT INTO tbl (id, val) VALUES ($id, '$value');" 38 | sleep $delay 39 | done 40 | #| MYSQL_PWD="$password" mariadb --host 127.0.0.1 --port 3307 --user "$user" "$db" 41 | 42 | 43 | -------------------------------------------------------------------------------- /sql-bench/O2/compiler_lu0012.cnf: -------------------------------------------------------------------------------- 1 | # Compile options with lower optimization running sql-bench on host lu0012. 2 | # 3 | # Hakan Kuecuekyilmaz, , 2010-11-20. 4 | 5 | # Configure environment variables. 6 | # Note: You can set ccache in the host specific config file. 7 | # In this case conf/lu0012.cnf. 8 | # 9 | # This configuration is taken from BUILD/compile-pentium64-max --print and 10 | # the option -O3 was changed to -O2. 11 | # 12 | $ENV{'CC'} = "gcc --pipe"; 13 | $ENV{'CFLAGS'} = "-Wall -Wextra -Wunused -Wwrite-strings -mtune=native -m64 -O2 -fno-omit-frame-pointer"; 14 | 15 | $ENV{'CXX'} = "g++"; 16 | $ENV{'CXXFLAGS'} = "-Wall -Wextra -Wunused -Wwrite-strings -Wno-unused-parameter -Wnon-virtual-dtor -felide-constructors -fno-exceptions -fno-rtti -mtune=native -m64 -O2 -fno-omit-frame-pointer"; 17 | $ENV{'CXXLDFLAGS'} = ""; 18 | 19 | $config = { 20 | # Configure invocation line. 21 | # Do not use --prefix here. 22 | configure_line => '--enable-assembler --with-extra-charsets=complex --enable-thread-safe-client --with-big-tables --with-plugin-aria --with-aria-tmp-tables --without-plugin-innodb_plugin --with-readline --with-ssl --with-plugins=max --with-embedded-server --with-libevent --with-mysqld-ldflags=-all-static --with-client-ldflags=-all-static --enable-local-infile', 23 | }; 24 | 25 | # This has to be the last line. See "perldoc -f require" for details. 26 | 1; 27 | -------------------------------------------------------------------------------- /release/create_package_tarballs/rhel_files/setup_repository: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env bash 2 | 3 | file=/etc/yum.repos.d/mariadb.repo 4 | install_cmd='yum install MariaDB-server' 5 | gpgkey=https://supplychain.mariadb.com/MariaDB-Server-GPG-KEY 6 | 7 | err() { 8 | msg=$1 9 | shift 10 | printf "[ERROR] $msg\n" "$@" >&2 11 | exit 1 12 | } 13 | 14 | for d in "$PWD" "${0%/*}"; do 15 | if [[ -d $d/repodata ]] ; then 16 | dir=$d 17 | if ! [[ $dir = /* ]] ; then 18 | dir=$PWD/$dir 19 | fi 20 | break 21 | fi 22 | done 23 | 24 | if ! [[ $dir ]] ; then 25 | err 'Could not find a "repodata" directory. Please change to the top level directory of the unpacked archive. and re-run this script.' 26 | fi 27 | 28 | if [[ -e $file ]] ; then 29 | err 'File "%s" already exists. Rename it and re-run this script, or manually create a new .repo file.' "$file" 30 | fi 31 | 32 | if [[ -e $dir/MariaDB-Server-GPG-KEY ]]; then 33 | gpgkey="file://$dir/MariaDB-Server-GPG-KEY" 34 | fi 35 | 36 | if ! cat > "$file" <, 2010-11-20. 4 | 5 | # Configure environment variables. 6 | # Note: You can set ccache in the host specific config file. 7 | # In this case conf/pitbull.cnf. 8 | # 9 | # This configuration is taken from BUILD/compile-pentium64-max --print and 10 | # the option -O3 was changed to -O2. 11 | # 12 | $ENV{'CC'} = "gcc --pipe"; 13 | $ENV{'CFLAGS'} = "-Wall -Wextra -Wunused -Wwrite-strings -mtune=native -m64 -O2 -fno-omit-frame-pointer"; 14 | 15 | $ENV{'CXX'} = "g++"; 16 | $ENV{'CXXFLAGS'} = "-Wall -Wextra -Wunused -Wwrite-strings -Wno-unused-parameter -Wnon-virtual-dtor -felide-constructors -fno-exceptions -fno-rtti -mtune=native -m64 -O2 -fno-omit-frame-pointer"; 17 | $ENV{'CXXLDFLAGS'} = ""; 18 | 19 | $config = { 20 | # Configure invocation line. 21 | # Do not use --prefix here. 22 | configure_line => '--enable-assembler --with-extra-charsets=complex --enable-thread-safe-client --with-big-tables --with-plugin-aria --with-aria-tmp-tables --without-plugin-innodb_plugin --with-readline --with-ssl --with-plugins=max --with-embedded-server --with-libevent --with-mysqld-ldflags=-all-static --with-client-ldflags=-all-static --enable-local-infile', 23 | }; 24 | 25 | # This has to be the last line. See "perldoc -f require" for details. 26 | 1; 27 | -------------------------------------------------------------------------------- /sql-bench-mysql/debug-full/compiler_lu0012.cnf: -------------------------------------------------------------------------------- 1 | # Compile options for debug-full running sql-bench on host lu0012. 2 | # 3 | # Hakan Kuecuekyilmaz, , 2010-11-20. 4 | 5 | # Configure environment variables. 6 | # Note: You can set ccache in the host specific config file. 7 | # In this case conf/lu0012.cnf. 8 | # 9 | # This configuration is taken from BUILD/compile-pentium64-debug-max --print. 10 | # 11 | $ENV{'CC'} = "gcc --pipe"; 12 | $ENV{'CFLAGS'} = "-Wall -Wextra -Wunused -Wwrite-strings -mtune=native -m64 -DUNIV_MUST_NOT_INLINE -DEXTRA_DEBUG -DFORCE_INIT_OF_VARS -DSAFEMALLOC -DPEDANTIC_SAFEMALLOC"; 13 | 14 | $ENV{'CXX'} = "g++"; 15 | $ENV{'CXXFLAGS'} = "-Wall -Wextra -Wunused -Wwrite-strings -Wno-unused-parameter -Wnon-virtual-dtor -felide-constructors -fno-exceptions -fno-rtti -mtune=native -m64 -DUNIV_MUST_NOT_INLINE -DEXTRA_DEBUG -DFORCE_INIT_OF_VARS -DSAFEMALLOC -DPEDANTIC_SAFEMALLOC"; 16 | $ENV{'CXXLDFLAGS'} = ""; 17 | 18 | $config = { 19 | # Configure invocation line. 20 | # Do not use --prefix here. 21 | configure_line => '--enable-assembler --with-extra-charsets=complex --enable-thread-safe-client --with-big-tables --with-mysqld-ldflags=-static --with-client-ldflags=-static --with-readline --with-debug=full --with-ssl --with-plugins=max --with-embedded-server --enable-local-infile', 22 | }; 23 | 24 | # This has to be the last line. See "perldoc -f require" for details. 25 | 1; 26 | -------------------------------------------------------------------------------- /sql-bench-mysql/debug-full/compiler_pitbull.cnf: -------------------------------------------------------------------------------- 1 | # Compile options for debug-full running sql-bench on host pitbull. 2 | # 3 | # Hakan Kuecuekyilmaz, , 2010-11-20. 4 | 5 | # Configure environment variables. 6 | # Note: You can set ccache in the host specific config file. 7 | # In this case conf/pitbull.cnf. 8 | # 9 | # This configuration is taken from BUILD/compile-pentium64-debug-max --print. 10 | # 11 | $ENV{'CC'} = "gcc --pipe"; 12 | $ENV{'CFLAGS'} = "-Wall -Wextra -Wunused -Wwrite-strings -mtune=native -m64 -DUNIV_MUST_NOT_INLINE -DEXTRA_DEBUG -DFORCE_INIT_OF_VARS -DSAFEMALLOC -DPEDANTIC_SAFEMALLOC"; 13 | 14 | $ENV{'CXX'} = "g++"; 15 | $ENV{'CXXFLAGS'} = "-Wall -Wextra -Wunused -Wwrite-strings -Wno-unused-parameter -Wnon-virtual-dtor -felide-constructors -fno-exceptions -fno-rtti -mtune=native -m64 -DUNIV_MUST_NOT_INLINE -DEXTRA_DEBUG -DFORCE_INIT_OF_VARS -DSAFEMALLOC -DPEDANTIC_SAFEMALLOC"; 16 | $ENV{'CXXLDFLAGS'} = ""; 17 | 18 | $config = { 19 | # Configure invocation line. 20 | # Do not use --prefix here. 21 | configure_line => '--enable-assembler --with-extra-charsets=complex --enable-thread-safe-client --with-big-tables --with-mysqld-ldflags=-static --with-client-ldflags=-static --with-readline --with-debug=full --with-ssl --with-plugins=max --with-embedded-server --enable-local-infile', 22 | }; 23 | 24 | # This has to be the last line. See "perldoc -f require" for details. 25 | 1; 26 | -------------------------------------------------------------------------------- /daniel/broken_active_active_replication/docker-compose.yml: -------------------------------------------------------------------------------- 1 | version: "3" 2 | services: 3 | master1: 4 | image: mariadb:latest 5 | command: --log-bin --log-basename=mariadb 6 | environment: 7 | - MARIADB_ROOT_PASSWORD=password 8 | - MARIADB_USER=testuser 9 | - MARIADB_PASSWORD=password 10 | - MARIADB_DATABASE=testdb 11 | - MARIADB_REPLICATION_USER=repl 12 | - MARIADB_REPLICATION_PASSWORD=replicationpass 13 | ports: 14 | - 3307:3306 15 | volumes: 16 | - ./init_db:/docker-entrypoint-initdb.d:z 17 | healthcheck: 18 | test: ["CMD", "healthcheck.sh", "--connect", "--innodb_initialized"] 19 | interval: 10s 20 | timeout: 5s 21 | retries: 3 22 | master2: 23 | image: mariadb:latest 24 | command: --server-id=2 --log-basename=mariadb --log-bin 25 | environment: 26 | - MARIADB_ROOT_PASSWORD=password 27 | - MARIADB_MASTER_HOST=master1 28 | - MARIADB_REPLICATION_USER=repl 29 | - MARIADB_REPLICATION_PASSWORD=replicationpass 30 | - MARIADB_HEALTHCHECK_GRANTS=REPLICA MONITOR 31 | ports: 32 | - 3308:3306 33 | healthcheck: 34 | test: ["CMD", "healthcheck.sh", "--connect", "--replication_io", "--replication_sql", "--replication_seconds_behind_master=1", "--replication"] 35 | interval: 10s 36 | timeout: 5s 37 | retries: 3 38 | depends_on: 39 | master1: 40 | condition: service_healthy 41 | -------------------------------------------------------------------------------- /sql-bench-mysql/debug/compiler_au0013.cnf: -------------------------------------------------------------------------------- 1 | # Compile options for debug running sql-bench on host au0013. 2 | # 3 | # Hakan Kuecuekyilmaz, , 2011-05-06. 4 | 5 | # Configure environment variables. 6 | # Note: You can set ccache in the host specific config file. 7 | # In this case conf/au0013.cnf. 8 | # 9 | # This configuration is taken from BUILD/compile-pentium64-debug-max --print 10 | # but with --with-debug instead of --with-debug=full. 11 | # 12 | $ENV{'CC'} = "gcc --pipe"; 13 | $ENV{'CFLAGS'} = "-Wall -Wextra -Wunused -Wwrite-strings -mtune=native -m64 -DUNIV_MUST_NOT_INLINE -DEXTRA_DEBUG -DFORCE_INIT_OF_VARS -DSAFEMALLOC -DPEDANTIC_SAFEMALLOC"; 14 | 15 | $ENV{'CXX'} = "g++"; 16 | $ENV{'CXXFLAGS'} = "-Wall -Wextra -Wunused -Wwrite-strings -Wno-unused-parameter -Wnon-virtual-dtor -felide-constructors -fno-exceptions -fno-rtti -mtune=native -m64 -DUNIV_MUST_NOT_INLINE -DEXTRA_DEBUG -DFORCE_INIT_OF_VARS -DSAFEMALLOC -DPEDANTIC_SAFEMALLOC"; 17 | $ENV{'CXXLDFLAGS'} = ""; 18 | 19 | $config = { 20 | # Configure invocation line. 21 | # Do not use --prefix here. 22 | configure_line => '--enable-assembler --with-extra-charsets=complex --enable-thread-safe-client --with-big-tables --with-mysqld-ldflags=-static --with-client-ldflags=-static --with-readline --with-debug --with-ssl --with-plugins=max --with-embedded-server --enable-local-infile', 23 | }; 24 | 25 | # This has to be the last line. See "perldoc -f require" for details. 26 | 1; 27 | -------------------------------------------------------------------------------- /sql-bench-mysql/debug/compiler_lu0012.cnf: -------------------------------------------------------------------------------- 1 | # Compile options for debug running sql-bench on host lu0012. 2 | # 3 | # Hakan Kuecuekyilmaz, , 2010-11-20. 4 | 5 | # Configure environment variables. 6 | # Note: You can set ccache in the host specific config file. 7 | # In this case conf/lu0012.cnf. 8 | # 9 | # This configuration is taken from BUILD/compile-pentium64-debug-max --print 10 | # but with --with-debug instead of --with-debug=full. 11 | # 12 | $ENV{'CC'} = "gcc --pipe"; 13 | $ENV{'CFLAGS'} = "-Wall -Wextra -Wunused -Wwrite-strings -mtune=native -m64 -DUNIV_MUST_NOT_INLINE -DEXTRA_DEBUG -DFORCE_INIT_OF_VARS -DSAFEMALLOC -DPEDANTIC_SAFEMALLOC"; 14 | 15 | $ENV{'CXX'} = "g++"; 16 | $ENV{'CXXFLAGS'} = "-Wall -Wextra -Wunused -Wwrite-strings -Wno-unused-parameter -Wnon-virtual-dtor -felide-constructors -fno-exceptions -fno-rtti -mtune=native -m64 -DUNIV_MUST_NOT_INLINE -DEXTRA_DEBUG -DFORCE_INIT_OF_VARS -DSAFEMALLOC -DPEDANTIC_SAFEMALLOC"; 17 | $ENV{'CXXLDFLAGS'} = ""; 18 | 19 | $config = { 20 | # Configure invocation line. 21 | # Do not use --prefix here. 22 | configure_line => '--enable-assembler --with-extra-charsets=complex --enable-thread-safe-client --with-big-tables --with-mysqld-ldflags=-static --with-client-ldflags=-static --with-readline --with-debug --with-ssl --with-plugins=max --with-embedded-server --enable-local-infile', 23 | }; 24 | 25 | # This has to be the last line. See "perldoc -f require" for details. 26 | 1; 27 | -------------------------------------------------------------------------------- /sql-bench-mysql/debug/compiler_pitbull.cnf: -------------------------------------------------------------------------------- 1 | # Compile options for debug running sql-bench on host pitbull. 2 | # 3 | # Hakan Kuecuekyilmaz, , 2010-11-20. 4 | 5 | # Configure environment variables. 6 | # Note: You can set ccache in the host specific config file. 7 | # In this case conf/pitbull.cnf. 8 | # 9 | # This configuration is taken from BUILD/compile-pentium64-debug-max --print 10 | # but with --with-debug instead of --with-debug=full. 11 | # 12 | $ENV{'CC'} = "gcc --pipe"; 13 | $ENV{'CFLAGS'} = "-Wall -Wextra -Wunused -Wwrite-strings -mtune=native -m64 -DUNIV_MUST_NOT_INLINE -DEXTRA_DEBUG -DFORCE_INIT_OF_VARS -DSAFEMALLOC -DPEDANTIC_SAFEMALLOC"; 14 | 15 | $ENV{'CXX'} = "g++"; 16 | $ENV{'CXXFLAGS'} = "-Wall -Wextra -Wunused -Wwrite-strings -Wno-unused-parameter -Wnon-virtual-dtor -felide-constructors -fno-exceptions -fno-rtti -mtune=native -m64 -DUNIV_MUST_NOT_INLINE -DEXTRA_DEBUG -DFORCE_INIT_OF_VARS -DSAFEMALLOC -DPEDANTIC_SAFEMALLOC"; 17 | $ENV{'CXXLDFLAGS'} = ""; 18 | 19 | $config = { 20 | # Configure invocation line. 21 | # Do not use --prefix here. 22 | configure_line => '--enable-assembler --with-extra-charsets=complex --enable-thread-safe-client --with-big-tables --with-mysqld-ldflags=-static --with-client-ldflags=-static --with-readline --with-debug --with-ssl --with-plugins=max --with-embedded-server --enable-local-infile', 23 | }; 24 | 25 | # This has to be the last line. See "perldoc -f require" for details. 26 | 1; 27 | -------------------------------------------------------------------------------- /faust/tools/screenrecord: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env bash 2 | 3 | set -o nounset 4 | set -o pipefail 5 | 6 | err() { 7 | echo >&2 "ERROR: $*" 8 | exit 1 9 | } 10 | 11 | usage() { 12 | cat >&2 <<-EOF 13 | Usage : $0 14 | -s also record sound 15 | -h help 16 | EOF 17 | } 18 | 19 | typeset VAR_OPTIONAL_ARGS="" 20 | 21 | while getopts "hs" OPTION; do 22 | case $OPTION in 23 | s) 24 | VAR_OPTIONAL_ARGS="with-sound" 25 | ;; 26 | h) 27 | usage 28 | exit 0 29 | ;; 30 | *) 31 | usage 32 | exit 1 33 | ;; 34 | esac 35 | done 36 | 37 | typeset -r OUTPUT="$HOME/screenrecord_$(date +'%Y-%m-%dT%H:%M:%S').mkv" 38 | 39 | # necessary commands 40 | for cmd in slop ffmpeg; do 41 | command -v $cmd >/dev/null || err "$cmd not found" 42 | done 43 | 44 | # get the area for recording from slop 45 | read -p "Select zone to capture" \ 46 | -r XOFFSET YOFFSET WEIGHT HIGHT < <(slop -f "%x %y %w %h") 47 | 48 | # see https://trac.ffmpeg.org/wiki/Capture/Desktop 49 | if [[ $VAR_OPTIONAL_ARGS == "with-sound" ]]; then 50 | ffmpeg \ 51 | -video_size "${WEIGHT}x${HIGHT}" \ 52 | -framerate 25 \ 53 | -f x11grab \ 54 | -i :0.0+"$XOFFSET","$YOFFSET" \ 55 | -f pulse -ac 2 -i default \ 56 | "$OUTPUT" || err "ffmpeg encoding" 57 | else 58 | ffmpeg \ 59 | -video_size "${WEIGHT}x${HIGHT}" \ 60 | -framerate 25 \ 61 | -f x11grab \ 62 | -i :0.0+"$XOFFSET","$YOFFSET" \ 63 | "$OUTPUT" || err "ffmpeg encoding" 64 | fi 65 | -------------------------------------------------------------------------------- /sql-bench/debug-full/compiler_lu0012.cnf: -------------------------------------------------------------------------------- 1 | # Compile options for debug-full running sql-bench on host lu0012. 2 | # 3 | # Hakan Kuecuekyilmaz, , 2010-11-20. 4 | 5 | # Configure environment variables. 6 | # Note: You can set ccache in the host specific config file. 7 | # In this case conf/lu0012.cnf. 8 | # 9 | # This configuration is taken from BUILD/compile-pentium64-debug-max --print. 10 | # 11 | $ENV{'CC'} = "gcc --pipe"; 12 | $ENV{'CFLAGS'} = "-Wall -Wextra -Wunused -Wwrite-strings -mtune=native -m64 -DUNIV_MUST_NOT_INLINE -DEXTRA_DEBUG -DFORCE_INIT_OF_VARS -DSAFEMALLOC -DPEDANTIC_SAFEMALLOC"; 13 | 14 | $ENV{'CXX'} = "g++"; 15 | $ENV{'CXXFLAGS'} = "-Wall -Wextra -Wunused -Wwrite-strings -Wno-unused-parameter -Wnon-virtual-dtor -felide-constructors -fno-exceptions -fno-rtti -mtune=native -m64 -DUNIV_MUST_NOT_INLINE -DEXTRA_DEBUG -DFORCE_INIT_OF_VARS -DSAFEMALLOC -DPEDANTIC_SAFEMALLOC"; 16 | $ENV{'CXXLDFLAGS'} = ""; 17 | 18 | $config = { 19 | # Configure invocation line. 20 | # Do not use --prefix here. 21 | configure_line => '--enable-assembler --with-extra-charsets=complex --enable-thread-safe-client --with-big-tables --with-plugin-aria --with-aria-tmp-tables --without-plugin-innodb_plugin --with-mysqld-ldflags=-static --with-client-ldflags=-static --with-readline --with-debug=full --with-ssl --with-plugins=max --with-embedded-server --with-libevent --enable-local-infile', 22 | }; 23 | 24 | # This has to be the last line. See "perldoc -f require" for details. 25 | 1; 26 | -------------------------------------------------------------------------------- /sql-bench/debug-full/compiler_pitbull.cnf: -------------------------------------------------------------------------------- 1 | # Compile options for debug-full running sql-bench on host pitbull. 2 | # 3 | # Hakan Kuecuekyilmaz, , 2010-11-20. 4 | 5 | # Configure environment variables. 6 | # Note: You can set ccache in the host specific config file. 7 | # In this case conf/pitbull.cnf. 8 | # 9 | # This configuration is taken from BUILD/compile-pentium64-debug-max --print. 10 | # 11 | $ENV{'CC'} = "gcc --pipe"; 12 | $ENV{'CFLAGS'} = "-Wall -Wextra -Wunused -Wwrite-strings -mtune=native -m64 -DUNIV_MUST_NOT_INLINE -DEXTRA_DEBUG -DFORCE_INIT_OF_VARS -DSAFEMALLOC -DPEDANTIC_SAFEMALLOC"; 13 | 14 | $ENV{'CXX'} = "g++"; 15 | $ENV{'CXXFLAGS'} = "-Wall -Wextra -Wunused -Wwrite-strings -Wno-unused-parameter -Wnon-virtual-dtor -felide-constructors -fno-exceptions -fno-rtti -mtune=native -m64 -DUNIV_MUST_NOT_INLINE -DEXTRA_DEBUG -DFORCE_INIT_OF_VARS -DSAFEMALLOC -DPEDANTIC_SAFEMALLOC"; 16 | $ENV{'CXXLDFLAGS'} = ""; 17 | 18 | $config = { 19 | # Configure invocation line. 20 | # Do not use --prefix here. 21 | configure_line => '--enable-assembler --with-extra-charsets=complex --enable-thread-safe-client --with-big-tables --with-plugin-aria --with-aria-tmp-tables --without-plugin-innodb_plugin --with-mysqld-ldflags=-static --with-client-ldflags=-static --with-readline --with-debug=full --with-ssl --with-plugins=max --with-embedded-server --with-libevent --enable-local-infile', 22 | }; 23 | 24 | # This has to be the last line. See "perldoc -f require" for details. 25 | 1; 26 | -------------------------------------------------------------------------------- /robert/sighup_test.sh: -------------------------------------------------------------------------------- 1 | #! /bin/bash 2 | 3 | # The test assumes MariaDB 10.4+ 4 | 5 | # Change the paths to point to your local installation 6 | #export PATH=$MARIAI/bin/:$MARIAI/scripts:$PATH 7 | client_bin=$MARIAI/bin/mysql 8 | server_bin=$MARIAI/bin/mysqld 9 | install_bin=$MARIAI/scripts/mysql_install_db 10 | set -x 11 | 12 | echo '----Setup new datadir----' 13 | datadir_path='/tmp/test_datadir' 14 | mkdir -p $datadir_path 15 | $install_bin --datadir=$datadir_path 16 | 17 | echo '----Start the server in a new login-shell terminal----' 18 | xterm -ls -e $server_bin --datadir=$datadir_path & 19 | xterm_pid=$! 20 | 21 | echo '----Wait for server to get ready----' 22 | sleep 3 23 | 24 | echo '----Create new user----' 25 | sudo $client_bin -e 'create user test_user@localhost;' 26 | 27 | echo '----Delete guest user----' 28 | sudo $client_bin -e 'drop user if exists ""@localhost;' 29 | 30 | echo '----The new user should be able to connect----' 31 | sudo $client_bin -utest_user -e 'select 1;' 32 | 33 | echo '----Delete the user from the system tables, but ACL user should still exist----' 34 | sudo $client_bin -e 'truncate table mysql.global_priv;' 35 | 36 | echo '----Kill the terminal parent of mysqld----' 37 | kill $xterm_pid 38 | sleep 2 39 | 40 | echo '----When killing the terminal sends a SIGHUP to mysqld, mysqld shouldnt reload the user table, thus the next login should work----' 41 | sudo $client_bin -utest_user -e 'select 1;' 42 | 43 | echo '----Cleanup----' 44 | pkill mysqld 45 | sleep 2 46 | rm -rf $datadir_path 47 | 48 | -------------------------------------------------------------------------------- /dbt3_benchmark/tests/queries_conf/queries-p.conf: -------------------------------------------------------------------------------- 1 | [queries_settings] 2 | QUERIES_HOME = $QUERIES_HOME/s$SCALE_FACTOR-p 3 | 4 | [1] 5 | QUERY=1.sql 6 | EXPLAIN_QUERY=1_explain.sql 7 | 8 | [2] 9 | QUERY=2.sql 10 | EXPLAIN_QUERY=2_explain.sql 11 | 12 | [3] 13 | QUERY=3.sql 14 | EXPLAIN_QUERY=3_explain.sql 15 | 16 | [4] 17 | QUERY=4.sql 18 | EXPLAIN_QUERY=4_explain.sql 19 | 20 | [5] 21 | QUERY=5.sql 22 | EXPLAIN_QUERY=5_explain.sql 23 | 24 | [6] 25 | QUERY=6.sql 26 | EXPLAIN_QUERY=6_explain.sql 27 | 28 | [7] 29 | QUERY=7.sql 30 | EXPLAIN_QUERY=7_explain.sql 31 | 32 | [8] 33 | QUERY=8.sql 34 | EXPLAIN_QUERY=8_explain.sql 35 | 36 | [9] 37 | QUERY=9.sql 38 | EXPLAIN_QUERY=9_explain.sql 39 | 40 | [10] 41 | QUERY=10.sql 42 | EXPLAIN_QUERY=10_explain.sql 43 | 44 | [11] 45 | QUERY=11.sql 46 | EXPLAIN_QUERY=11_explain.sql 47 | 48 | [12] 49 | QUERY=12.sql 50 | EXPLAIN_QUERY=12_explain.sql 51 | 52 | [13] 53 | QUERY=13.sql 54 | EXPLAIN_QUERY=13_explain.sql 55 | 56 | [14] 57 | QUERY=14.sql 58 | EXPLAIN_QUERY=14_explain.sql 59 | 60 | [15] 61 | QUERY=15.sql 62 | EXPLAIN_QUERY=15_explain.sql 63 | 64 | [16] 65 | QUERY=16.sql 66 | EXPLAIN_QUERY=16_explain.sql 67 | 68 | [17] 69 | QUERY=17.sql 70 | EXPLAIN_QUERY=17_explain.sql 71 | 72 | [18] 73 | QUERY=18.sql 74 | EXPLAIN_QUERY=18_explain.sql 75 | 76 | [19] 77 | QUERY=19.sql 78 | EXPLAIN_QUERY=19_explain.sql 79 | 80 | [20] 81 | QUERY=20.sql 82 | EXPLAIN_QUERY=20_explain.sql 83 | 84 | [21] 85 | QUERY=21.sql 86 | EXPLAIN_QUERY=21_explain.sql 87 | 88 | [22] 89 | QUERY=22.sql 90 | EXPLAIN_QUERY=22_explain.sql -------------------------------------------------------------------------------- /sql-bench/debug/compiler_au0013.cnf: -------------------------------------------------------------------------------- 1 | # Compile options for debug running sql-bench on host au0013. 2 | # 3 | # Hakan Kuecuekyilmaz, , 2011-05-06. 4 | 5 | # Configure environment variables. 6 | # Note: You can set ccache in the host specific config file. 7 | # In this case conf/au0013.cnf. 8 | # 9 | # This configuration is taken from BUILD/compile-pentium64-debug-max --print 10 | # but with --with-debug instead of --with-debug=full. 11 | # 12 | $ENV{'CC'} = "gcc --pipe"; 13 | $ENV{'CFLAGS'} = "-Wall -Wextra -Wunused -Wwrite-strings -mtune=native -m64 -DUNIV_MUST_NOT_INLINE -DEXTRA_DEBUG -DFORCE_INIT_OF_VARS -DSAFEMALLOC -DPEDANTIC_SAFEMALLOC"; 14 | 15 | $ENV{'CXX'} = "g++"; 16 | $ENV{'CXXFLAGS'} = "-Wall -Wextra -Wunused -Wwrite-strings -Wno-unused-parameter -Wnon-virtual-dtor -felide-constructors -fno-exceptions -fno-rtti -mtune=native -m64 -DUNIV_MUST_NOT_INLINE -DEXTRA_DEBUG -DFORCE_INIT_OF_VARS -DSAFEMALLOC -DPEDANTIC_SAFEMALLOC"; 17 | $ENV{'CXXLDFLAGS'} = ""; 18 | 19 | $config = { 20 | # Configure invocation line. 21 | # Do not use --prefix here. 22 | configure_line => '--enable-assembler --with-extra-charsets=complex --enable-thread-safe-client --with-big-tables --with-plugin-aria --with-aria-tmp-tables --without-plugin-innodb_plugin --with-mysqld-ldflags=-static --with-client-ldflags=-static --with-readline --with-debug --with-ssl --with-plugins=max --with-embedded-server --with-libevent --enable-local-infile', 23 | }; 24 | 25 | # This has to be the last line. See "perldoc -f require" for details. 26 | 1; 27 | -------------------------------------------------------------------------------- /sql-bench/debug/compiler_lu0012.cnf: -------------------------------------------------------------------------------- 1 | # Compile options for debug running sql-bench on host lu0012. 2 | # 3 | # Hakan Kuecuekyilmaz, , 2010-11-20. 4 | 5 | # Configure environment variables. 6 | # Note: You can set ccache in the host specific config file. 7 | # In this case conf/lu0012.cnf. 8 | # 9 | # This configuration is taken from BUILD/compile-pentium64-debug-max --print 10 | # but with --with-debug instead of --with-debug=full. 11 | # 12 | $ENV{'CC'} = "gcc --pipe"; 13 | $ENV{'CFLAGS'} = "-Wall -Wextra -Wunused -Wwrite-strings -mtune=native -m64 -DUNIV_MUST_NOT_INLINE -DEXTRA_DEBUG -DFORCE_INIT_OF_VARS -DSAFEMALLOC -DPEDANTIC_SAFEMALLOC"; 14 | 15 | $ENV{'CXX'} = "g++"; 16 | $ENV{'CXXFLAGS'} = "-Wall -Wextra -Wunused -Wwrite-strings -Wno-unused-parameter -Wnon-virtual-dtor -felide-constructors -fno-exceptions -fno-rtti -mtune=native -m64 -DUNIV_MUST_NOT_INLINE -DEXTRA_DEBUG -DFORCE_INIT_OF_VARS -DSAFEMALLOC -DPEDANTIC_SAFEMALLOC"; 17 | $ENV{'CXXLDFLAGS'} = ""; 18 | 19 | $config = { 20 | # Configure invocation line. 21 | # Do not use --prefix here. 22 | configure_line => '--enable-assembler --with-extra-charsets=complex --enable-thread-safe-client --with-big-tables --with-plugin-aria --with-aria-tmp-tables --without-plugin-innodb_plugin --with-mysqld-ldflags=-static --with-client-ldflags=-static --with-readline --with-debug --with-ssl --with-plugins=max --with-embedded-server --with-libevent --enable-local-infile', 23 | }; 24 | 25 | # This has to be the last line. See "perldoc -f require" for details. 26 | 1; 27 | -------------------------------------------------------------------------------- /sql-bench/debug/compiler_pitbull.cnf: -------------------------------------------------------------------------------- 1 | # Compile options for debug running sql-bench on host pitbull. 2 | # 3 | # Hakan Kuecuekyilmaz, , 2010-11-20. 4 | 5 | # Configure environment variables. 6 | # Note: You can set ccache in the host specific config file. 7 | # In this case conf/pitbull.cnf. 8 | # 9 | # This configuration is taken from BUILD/compile-pentium64-debug-max --print 10 | # but with --with-debug instead of --with-debug=full. 11 | # 12 | $ENV{'CC'} = "gcc --pipe"; 13 | $ENV{'CFLAGS'} = "-Wall -Wextra -Wunused -Wwrite-strings -mtune=native -m64 -DUNIV_MUST_NOT_INLINE -DEXTRA_DEBUG -DFORCE_INIT_OF_VARS -DSAFEMALLOC -DPEDANTIC_SAFEMALLOC"; 14 | 15 | $ENV{'CXX'} = "g++"; 16 | $ENV{'CXXFLAGS'} = "-Wall -Wextra -Wunused -Wwrite-strings -Wno-unused-parameter -Wnon-virtual-dtor -felide-constructors -fno-exceptions -fno-rtti -mtune=native -m64 -DUNIV_MUST_NOT_INLINE -DEXTRA_DEBUG -DFORCE_INIT_OF_VARS -DSAFEMALLOC -DPEDANTIC_SAFEMALLOC"; 17 | $ENV{'CXXLDFLAGS'} = ""; 18 | 19 | $config = { 20 | # Configure invocation line. 21 | # Do not use --prefix here. 22 | configure_line => '--enable-assembler --with-extra-charsets=complex --enable-thread-safe-client --with-big-tables --with-plugin-aria --with-aria-tmp-tables --without-plugin-innodb_plugin --with-mysqld-ldflags=-static --with-client-ldflags=-static --with-readline --with-debug --with-ssl --with-plugins=max --with-embedded-server --with-libevent --enable-local-infile', 23 | }; 24 | 25 | # This has to be the last line. See "perldoc -f require" for details. 26 | 1; 27 | -------------------------------------------------------------------------------- /dbt3_benchmark/tests/innodb_test_mariadb_5_3_mysql_5_5_mysql_5_6.conf: -------------------------------------------------------------------------------- 1 | [common] 2 | RESULTS_DB_CONFIG = $PROJECT_HOME/mariadb-tools/dbt3_benchmark/tests/results_db_conf/results_db.conf 3 | TEST_CONFIG = $PROJECT_HOME/mariadb-tools/dbt3_benchmark/tests/test_conf/test_innodb.conf 4 | 5 | # The benchmark will be executed in the order below. 6 | # The first test serves as a baseline against which we compute the ratio of all remaining tests. 7 | 8 | [mariadb_5_3] 9 | QUERIES_CONFIG = $PROJECT_HOME/mariadb-tools/dbt3_benchmark/tests/queries_conf/queries-mariadb.conf 10 | DB_CONFIG = $PROJECT_HOME/mariadb-tools/dbt3_benchmark/tests/db_conf/db_mariadb_5_3_innodb.conf 11 | 12 | [mariadb_5_5] 13 | QUERIES_CONFIG = $PROJECT_HOME/mariadb-tools/dbt3_benchmark/tests/queries_conf/queries-mariadb.conf 14 | DB_CONFIG = $PROJECT_HOME/mariadb-tools/dbt3_benchmark/tests/db_conf/db_mariadb_5_5_innodb.conf 15 | 16 | [mysql_5_6] 17 | QUERIES_CONFIG = $PROJECT_HOME/mariadb-tools/dbt3_benchmark/tests/queries_conf/queries-mysql.conf 18 | DB_CONFIG = $PROJECT_HOME/mariadb-tools/dbt3_benchmark/tests/db_conf/db_mysql_5_6_innodb.conf 19 | 20 | [mysql_5_5] 21 | QUERIES_CONFIG = $PROJECT_HOME/mariadb-tools/dbt3_benchmark/tests/queries_conf/queries-mysql.conf 22 | DB_CONFIG = $PROJECT_HOME/mariadb-tools/dbt3_benchmark/tests/db_conf/db_mysql_5_5_innodb.conf 23 | 24 | #[postgres] 25 | #QUERIES_CONFIG = $PROJECT_HOME/mariadb-tools/dbt3_benchmark/tests/queries_conf/queries-p.conf 26 | #DB_CONFIG = $PROJECT_HOME/mariadb-tools/dbt3_benchmark/tests/db_conf/postgres_9_1.conf 27 | -------------------------------------------------------------------------------- /anel/k8s/mariadb/mariadb-deployment-pvc.yaml: -------------------------------------------------------------------------------- 1 | apiVersion: v1 2 | kind: PersistentVolumeClaim 3 | metadata: 4 | name: mariadb-pv-claim 5 | labels: 6 | app: mariadb 7 | spec: 8 | accessModes: 9 | - ReadWriteOnce 10 | resources: 11 | requests: 12 | storage: 300M 13 | --- 14 | apiVersion: v1 15 | kind: Service 16 | metadata: 17 | name: mariadb-internal-service 18 | spec: 19 | selector: 20 | app: mariadb 21 | ports: 22 | - protocol: TCP 23 | port: 3306 24 | targetPort: 3306 25 | clusterIP: None 26 | --- 27 | apiVersion: apps/v1 28 | kind: Deployment 29 | metadata: 30 | name: mariadb-deployment 31 | spec: # specification for deployment resource 32 | replicas: 1 33 | selector: 34 | matchLabels: 35 | app: mariadb 36 | template: # blueprint for pods 37 | metadata: 38 | labels: 39 | app: mariadb # service will look for this label 40 | spec: # specification for pods 41 | containers: 42 | - name: mariadb 43 | image: mariadb 44 | ports: 45 | - containerPort: 3306 #default one 46 | env: 47 | - name: MARIADB_ROOT_PASSWORD 48 | valueFrom: 49 | secretKeyRef: 50 | name: mariadb-secret 51 | key: mariadb-root-password 52 | - name: MARIADB_DATABASE 53 | value: wordpress 54 | volumeMounts: 55 | - name: mariadb-pv 56 | mountPath: /var/lib/mysql 57 | volumes: 58 | - name: mariadb-pv 59 | persistentVolumeClaim: 60 | claimName: mariadb-pv-claim 61 | 62 | -------------------------------------------------------------------------------- /sysbench/conf/lu0012.inc: -------------------------------------------------------------------------------- 1 | # Configuration file for host: lu0012 2 | # 3 | # OS: Ubuntu 9.10 4 | # Platform: x86_64 5 | # CPU: Dual-core Intel Core 2 Duo @ 2.80GHz 6 | # RAM: 4GB 7 | # Disk(s): 1 x HITACHI HTS722016K9SA00 S-ATA 8 | 9 | # 10 | # Adjust the following paths according to your installation. 11 | # 12 | 13 | # Base directory where SysBench files are found. 14 | BASE="${HOME}/work" 15 | TEST_DIR="${BASE}/monty_program/sysbench/sysbench/tests/db" 16 | 17 | # We need SysBench >= v0.5. 18 | SYSBENCH='/usr/local/bin/sysbench' 19 | 20 | # We need bzr >= 1.18.1. 21 | BZR='/usr/bin/bzr' 22 | 23 | # OProfile binaries. 24 | OPCONTROL='/usr/bin/opcontrol' 25 | 26 | # System statistic binaries. 27 | IOSTAT='/usr/bin/iostat' 28 | IOSTAT_DEVICE='/dev/sda' 29 | # For CPU utilization statistics. 30 | MPSTAT='/usr/bin/mpstat' 31 | 32 | # Other binaries. 33 | SUDO=/usr/bin/sudo 34 | 35 | # Directories. 36 | TEMP_DIR='/tmp' 37 | DATA_DIR="${TEMP_DIR}/data" 38 | 39 | # Where to compile the sources. 40 | WORK_DIR='/tmp' 41 | 42 | # Which concurrency level(s) we want to profile with OProfile. 43 | # 44 | # Example: profile 8 and 32. 45 | # DO_OPROFILE='8 32' 46 | DO_OPROFILE='1' 47 | 48 | # SysBench tests to run. 49 | SYSBENCH_TESTS[0]="delete.lua" 50 | SYSBENCH_TESTS[1]="insert.lua" 51 | SYSBENCH_TESTS[2]="oltp_complex_ro.lua" 52 | SYSBENCH_TESTS[3]="oltp_complex_rw.lua" 53 | SYSBENCH_TESTS[4]="oltp_simple.lua" 54 | SYSBENCH_TESTS[5]="select.lua" 55 | 56 | # Default option is --random-points=10. 57 | SYSBENCH_TESTS[6]="select_random_points.lua" 58 | 59 | # Default options are 60 | # --number-of-ranges=10 61 | # --random-ranges-delta=5. 62 | SYSBENCH_TESTS[7]="select_random_ranges.lua" 63 | SYSBENCH_TESTS[8]="update_index.lua" 64 | SYSBENCH_TESTS[9]="update_non_index.lua" 65 | -------------------------------------------------------------------------------- /sysbench/conf/pitbull.inc: -------------------------------------------------------------------------------- 1 | # Configuration file for host: pitbull 2 | # 3 | # OS: Ubuntu 10.10 4 | # Platform: x86_64 5 | # CPU: Two socket hexa-core Intel Xeon X5660 @ 2.80GHz 6 | # RAM: 23GB 7 | # Disk(s): 1 x ST3500320NS S-ATA 8 | 9 | # 10 | # Adjust the following paths according to your installation. 11 | # 12 | 13 | # Base directory where SysBench files are found. 14 | BASE="${HOME}/work" 15 | TEST_DIR="${BASE}/monty_program/sysbench/sysbench/tests/db" 16 | 17 | # We need SysBench >= v0.5. 18 | SYSBENCH='/usr/local/bin/sysbench' 19 | 20 | # We need bzr >= 1.18.1. 21 | BZR='/usr/bin/bzr' 22 | 23 | # OProfile binaries. 24 | OPCONTROL='/usr/bin/opcontrol' 25 | 26 | # System statistic binaries. 27 | IOSTAT='/usr/bin/iostat' 28 | IOSTAT_DEVICE='/dev/sda' 29 | # For CPU utilization statistics. 30 | MPSTAT='/usr/bin/mpstat' 31 | 32 | # Other binaries. 33 | SUDO=/usr/bin/sudo 34 | 35 | # Directories. 36 | TEMP_DIR="${HOME}/tmp" 37 | DATA_DIR="${TEMP_DIR}/data" 38 | 39 | # Where to compile the sources. 40 | WORK_DIR='/tmp' 41 | 42 | # Which concurrency level(s) we want to profile with OProfile. 43 | # 44 | # Example: profile 8 and 32. 45 | # DO_OPROFILE='8 32' 46 | DO_OPROFILE='64' 47 | 48 | # SysBench tests to run. 49 | SYSBENCH_TESTS[0]="delete.lua" 50 | SYSBENCH_TESTS[1]="insert.lua" 51 | SYSBENCH_TESTS[2]="oltp_complex_ro.lua" 52 | SYSBENCH_TESTS[3]="oltp_complex_rw.lua" 53 | SYSBENCH_TESTS[4]="oltp_simple.lua" 54 | SYSBENCH_TESTS[5]="select.lua" 55 | 56 | # Default option is --random-points=10. 57 | SYSBENCH_TESTS[6]="select_random_points.lua" 58 | 59 | # Default options are 60 | # --number-of-ranges=10 61 | # --random-ranges-delta=5. 62 | SYSBENCH_TESTS[7]="select_random_ranges.lua" 63 | SYSBENCH_TESTS[8]="update_index.lua" 64 | SYSBENCH_TESTS[9]="update_non_index.lua" 65 | -------------------------------------------------------------------------------- /sysbench/conf/perro.inc: -------------------------------------------------------------------------------- 1 | # Configuration file for host: perro 2 | # 3 | # OS: openSUSE 11.1 (x86_64) 4 | # Platform: x86_64 5 | # CPU: Quad-core Intel @ 3.20GHz 6 | # RAM: 2GB 7 | # Disk(s): 2 x ST31000528AS S-ATA as software RAID 0 8 | 9 | # 10 | # Adjust the following paths according to your installation. 11 | # 12 | 13 | # Base directory where SysBench files are found. 14 | BASE="${HOME}/work" 15 | TEST_DIR="${BASE}/monty_program/sysbench/sysbench/tests/db" 16 | 17 | # We need SysBench >= v0.5. 18 | SYSBENCH='/usr/local/bin/sysbench' 19 | 20 | # We need bzr >= 1.18.1. 21 | BZR='/usr/bin/bzr' 22 | 23 | # OProfile binaries. 24 | OPCONTROL='/usr/bin/opcontrol' 25 | 26 | # System statistic binaries. 27 | IOSTAT='/usr/bin/iostat' 28 | IOSTAT_DEVICE='/dev/md0' 29 | # For CPU utilization statistics. 30 | MPSTAT='/usr/bin/mpstat' 31 | 32 | # Other binaries. 33 | SUDO=/my/local/bin/sur 34 | 35 | # Directories. 36 | TEMP_DIR='/mnt/data/sysbench' 37 | DATA_DIR="${TEMP_DIR}/data" 38 | 39 | # Where to compile the sources. 40 | WORK_DIR='/tmp' 41 | 42 | # Which concurrency level(s) we want to profile with OProfile. 43 | # 44 | # Example: profile 8 and 32. 45 | # DO_OPROFILE='8 32' 46 | DO_OPROFILE='64' 47 | 48 | # SysBench tests to run. 49 | SYSBENCH_TESTS[0]="delete.lua" 50 | SYSBENCH_TESTS[1]="insert.lua" 51 | SYSBENCH_TESTS[2]="oltp_complex_ro.lua" 52 | SYSBENCH_TESTS[3]="oltp_complex_rw.lua" 53 | SYSBENCH_TESTS[4]="oltp_simple.lua" 54 | SYSBENCH_TESTS[5]="select.lua" 55 | 56 | # Default option is --random-points=10. 57 | SYSBENCH_TESTS[6]="select_random_points.lua" 58 | 59 | # Default options are 60 | # --number-of-ranges=10 61 | # --random-ranges-delta=5. 62 | SYSBENCH_TESTS[7]="select_random_ranges.lua" 63 | SYSBENCH_TESTS[8]="update_index.lua" 64 | SYSBENCH_TESTS[9]="update_non_index.lua" 65 | -------------------------------------------------------------------------------- /sysbench/conf/work.inc: -------------------------------------------------------------------------------- 1 | # Configuration file for host: work 2 | # 3 | # OS: openSUSE 11.1 (x86_64) 4 | # Platform: x86_64 5 | # CPU: Two socket quad-core Intel Xeon @ 3.00GHz 6 | # RAM: 8GB 7 | # Disk(s): 1 x WDC WD2500JS-00NCB1 S-ATA 8 | 9 | # 10 | # Adjust the following paths according to your installation. 11 | # 12 | 13 | # Base directory where SysBench files are found. 14 | BASE="${HOME}/work" 15 | TEST_DIR="${BASE}/monty_program/sysbench/sysbench/tests/db" 16 | 17 | # We need SysBench >= v0.5. 18 | SYSBENCH='/usr/local/bin/sysbench' 19 | 20 | # We need bzr >= 1.18.1. 21 | BZR='/usr/local/bin/bzr' 22 | 23 | # OProfile binaries. 24 | OPCONTROL='/usr/bin/opcontrol' 25 | 26 | # System statistic binaries. 27 | IOSTAT='/usr/bin/iostat' 28 | IOSTAT_DEVICE='/dev/sda' 29 | # For CPU utilization statistics. 30 | MPSTAT='/usr/bin/mpstat' 31 | 32 | # Other binaries. 33 | SUDO=/my/local/bin/sur 34 | 35 | # Directories. 36 | TEMP_DIR="${HOME}/tmp" 37 | DATA_DIR="${TEMP_DIR}/data" 38 | 39 | # Where to compile the sources. 40 | WORK_DIR='/tmp' 41 | 42 | # Which concurrency level(s) we want to profile with OProfile. 43 | # 44 | # Example: profile 8 and 32. 45 | # DO_OPROFILE='8 32' 46 | DO_OPROFILE='64' 47 | 48 | # SysBench tests to run. 49 | SYSBENCH_TESTS[0]="delete.lua" 50 | SYSBENCH_TESTS[1]="insert.lua" 51 | SYSBENCH_TESTS[2]="oltp_complex_ro.lua" 52 | SYSBENCH_TESTS[3]="oltp_complex_rw.lua" 53 | SYSBENCH_TESTS[4]="oltp_simple.lua" 54 | SYSBENCH_TESTS[5]="select.lua" 55 | 56 | # Default option is --random-points=10. 57 | SYSBENCH_TESTS[6]="select_random_points.lua" 58 | 59 | # Default options are 60 | # --number-of-ranges=10 61 | # --random-ranges-delta=5. 62 | SYSBENCH_TESTS[7]="select_random_ranges.lua" 63 | SYSBENCH_TESTS[8]="update_index.lua" 64 | SYSBENCH_TESTS[9]="update_non_index.lua" 65 | -------------------------------------------------------------------------------- /daniel/spider/web/app.py: -------------------------------------------------------------------------------- 1 | from flask import Flask, stream_with_context 2 | import mariadb 3 | import os 4 | import time 5 | import socket 6 | 7 | app = Flask(__name__) 8 | 9 | cname = socket.gethostbyname_ex("self.metadata.compute.edgeengine.io")[0] 10 | 11 | print(cname) 12 | 13 | (instance, deployment, target, workload, stack, rootdomain) = cname.split(".", 5) 14 | 15 | alldeployments = os.getenv("DEPLOYMENTS").lower().split(",") 16 | 17 | def db_connection(host): 18 | # Connect to MariaDB Platform 19 | conn = mariadb.connect( 20 | user=os.getenv("MARIADB_USER"), 21 | password=os.getenv("MARIADB_PASSWORD"), 22 | host=host, 23 | port=3306, 24 | database=os.getenv("MARIADB_DATABASE"), 25 | ) 26 | cur = conn.cursor() 27 | start = time.perf_counter() 28 | cur.execute( 29 | "SELECT SUM(quantity * value) FROM sales where `date` > date_sub(now(), interval 1 day)" 30 | ) 31 | end = time.perf_counter() 32 | return {"sales": cur.fetchone()[0], "time": end - start} 33 | 34 | 35 | @app.route("/") 36 | def hello_world(): 37 | def generate(): 38 | yield f"

Sales for branch at {deployment} for the last day

" 39 | 40 | for dep in alldeployments: 41 | try: 42 | result = db_connection("db-" + target + "-" + dep + "-0") 43 | yield """ 44 |

Current sales connecting to {}:

45 |

{}

46 |

47 |

Time for request {}

48 | """.format( 49 | dep, result["sales"], result["time"] 50 | ) 51 | 52 | except mariadb.Error as e: 53 | return f"

Database error {e}

", 400 54 | 55 | return stream_with_context(generate()) 56 | 57 | 58 | @app.route("/ping") 59 | def ping(): 60 | return "All is well" 61 | -------------------------------------------------------------------------------- /dbt3_benchmark/tests/test_conf/test_myisam.conf: -------------------------------------------------------------------------------- 1 | #If set to 1, then all the queries are executed sequentially without restarting the server between queries. 2 | QUERIES_AT_ONCE = 0 3 | 4 | #Clearing server caches 5 | CLEAR_CACHES = 1 6 | 7 | #perform a warm-up before running the tests 8 | WARMUP = 0 9 | 10 | #run an Explain command prior the run of the test 11 | EXPLAIN = 1 12 | 13 | #perform the actual test 14 | RUN = 1 15 | 16 | 17 | #Choose a result extraction mechanism (only one of the three could be enabled) 18 | ANALYZE_EXPLAIN = 0 19 | MIN_MAX_OUT_OF_N = 0 20 | SIMPLE_AVERAGE = 1 21 | 22 | 23 | #how many times will the same query be executed in order to calculate the average run time 24 | NUM_TESTS = 1 25 | 26 | #when more than $MAX_SKIPPED_TESTS tests have been skipped, then move to the next query. The current query is obvously timed out and there are no other execution plans. 27 | MAX_SKIPPED_TESTS = 5 28 | 29 | #how many times will the query be warmed up before taking the results into account 30 | WARMUPS_COUNT = 0 31 | 32 | #how big is one cluster with test results 33 | CLUSTER_SIZE = 3 34 | 35 | #What is the maximum time allowed for testing one query. 36 | MAX_QUERY_TIME = 7300 37 | 38 | #What is the timeout of running one query, Currently works only with MariaDB/MySQL 39 | TIMEOUT = 7200 40 | 41 | #what the interval between each statistics extract will be 42 | OS_STATS_INTERVAL = 5 43 | 44 | 45 | 46 | 47 | 48 | #OS commands that will be executed before each run 49 | PRE_RUN_OS = 50 | 51 | #OS commands that will be executed after each run 52 | POST_RUN_OS = 53 | 54 | #Cannot be overridden in the different configurations. OS commands are run prior the whole test 55 | PRE_TEST_OS = 56 | 57 | #Cannot be overridden in the different configurations. OS commands are run after the whole test 58 | POST_TEST_OS = -------------------------------------------------------------------------------- /release/create_package_tarballs/rhel_files/README: -------------------------------------------------------------------------------- 1 | MariaDB Server 2 | 3 | This package contains a number of .rpm files that together comprise the MariaDB 4 | Server distribution. 5 | 6 | The packages included in this archive may vary depending on the OS you're using 7 | and its release version, as different components may require libraries or 8 | functionality available only in newer releases. 9 | 10 | The .rpm files can be installed individually, but there are complex 11 | interdependencies that are difficult to resolve using rpm alone. For that 12 | reason, this package is distributed as a ready-to-use Yum archive, so that you 13 | can use yum to install the packages in it. 14 | 15 | In order for the package manager to be able to install these packages, you will 16 | need to place them in a location that the package manager has privileges to 17 | access. You may find that /opt is a good location where you can unpack the 18 | archive and the package manager will be able to read it. 19 | 20 | To use the archive with yum, create a mariadb.repo file in /etc/yum.repos.d/ 21 | that points to the directory where you've extracted the files. A helpful script 22 | called setup_repository is included in this archive to do this for you. 23 | 24 | You'll need to do this work as root, so that you can write files to these 25 | locations. 26 | 27 | cd /opt 28 | tar -xf ~/filename.tar 29 | filename/setup_repository 30 | 31 | After the repository is set up, you should install the MariaDB-server package. 32 | 33 | yum install -y MariaDB-server 34 | 35 | For more information about installing MariaDB .rpm files, visit: 36 | https://mariadb.com/kb/en/installing-mariadb-rpm-files/ 37 | 38 | For more information about MariaDB products, visit https://mariadb.com/products 39 | and for help using MariaDB, please contact MariaDB Corporation: 40 | https://mariadb.com/contact 41 | -------------------------------------------------------------------------------- /anel/k8s/mariadb/integrated-mariadb-deployment-with-phpmyadmin.yaml: -------------------------------------------------------------------------------- 1 | apiVersion: v1 2 | kind: ConfigMap 3 | metadata: 4 | name: mariadb-configmap 5 | data: 6 | database_url: mariadb-internal-service #name of service 7 | 8 | --- 9 | apiVersion: v1 10 | kind: Service 11 | metadata: 12 | name: mariadb-internal-service 13 | spec: 14 | selector: 15 | app: mariadb 16 | ports: 17 | - protocol: TCP 18 | port: 3306 19 | targetPort: 3306 20 | 21 | 22 | --- 23 | apiVersion: v1 24 | kind: Service 25 | metadata: 26 | name: phpmyadmin-service 27 | spec: 28 | selector: 29 | app: mariadb 30 | type: LoadBalancer # port type 31 | ports: 32 | - protocol: TCP 33 | port: 8080 # same port of a service as for a pods 34 | targetPort: 8080 # targeting containerPort 35 | nodePort: 30100 # external IP port from 30000 till 32767 range 36 | --- 37 | apiVersion: apps/v1 38 | kind: Deployment # what to create? 39 | metadata: 40 | name: mariadb-deployment 41 | spec: # specification for deployment resource 42 | replicas: 2 # how many replicas of pods we want to create 43 | selector: 44 | matchLabels: 45 | app: mariadb 46 | template: # blueprint for pods 47 | metadata: 48 | labels: 49 | app: mariadb # service will look for this label 50 | spec: # specification for Pods 51 | containers: 52 | - name: mariadb 53 | image: mariadb 54 | ports: 55 | - containerPort: 3306 56 | env: 57 | - name: MARIADB_ROOT_PASSWORD 58 | value: anel 59 | - name: phpmyadmin 60 | image: bitnami/phpmyadmin:latest 61 | ports: 62 | - containerPort: 8080 63 | env: 64 | - name: DATABASE_HOST 65 | valueFrom: 66 | configMapKeyRef: 67 | name: mariadb-configmap 68 | key: database_url -------------------------------------------------------------------------------- /dbt3_benchmark/dbt3_mysql/flush.c: -------------------------------------------------------------------------------- 1 | /* Copyright Monty Program KB */ 2 | /* Flush all file-buffers pages for easyer timeing */ 3 | 4 | #include 5 | #include 6 | 7 | static int get_options(int *argc,char **argv[]); 8 | 9 | static char *progname; 10 | static int memory=28,verbose=0; 11 | 12 | int main(argc, argv) 13 | int argc; 14 | char *argv[]; 15 | { 16 | if (get_options(&argc,&argv)) 17 | exit(1); 18 | 19 | if (verbose) 20 | printf("Syncing filesystem...\n"); 21 | sync(); sleep(1); sync(); 22 | if (verbose) 23 | printf("Allocating %d meg memory\n",memory); 24 | while (memory-- >0) 25 | VOID(my_malloc((uint) 1024*1024-MALLOC_OVERHEAD, 26 | MYF(MY_WME | MY_ZEROFILL))); 27 | exit(0); 28 | return 0; 29 | } 30 | 31 | static int get_options(argc,argv) 32 | register int *argc; 33 | register char **argv[]; 34 | { 35 | int version; 36 | char *pos; 37 | 38 | progname= (*argv)[0]; 39 | 40 | while (--*argc >0 && *(pos = *(++*argv)) == '-' ) { 41 | while (*++pos) 42 | { 43 | version=0; 44 | switch (*pos) { 45 | case 'v': 46 | verbose=1; 47 | break; 48 | case 'V': 49 | version=1; 50 | case 'I': 51 | case '?': 52 | printf("%s Ver 1.0 for %s at %s\n",progname,SYSTEM_TYPE,MACHINE_TYPE); 53 | puts("TCX Datakonsult AB, by Monty, for your professional use\n"); 54 | if (version) 55 | break; 56 | puts("Flush all disk-buffers by allocating all memory."); 57 | puts(""); 58 | printf("Usage: %s [-?vIV] memory\n",progname); 59 | puts(""); 60 | puts("Options: -? or -I \"Info\" -v \"verbose\" -V \"Version\""); 61 | break; 62 | default: 63 | fprintf(stderr,"illegal option: -%c\n",*pos); 64 | return(1); 65 | break; 66 | } 67 | } 68 | } 69 | if (*argc) 70 | memory=atoi(**argv); 71 | return(0); 72 | } /* get_options */ 73 | -------------------------------------------------------------------------------- /release/create_package_tarballs/sles_files/README: -------------------------------------------------------------------------------- 1 | MariaDB Server 2 | 3 | This package contains a number of .rpm files that together comprise the MariaDB 4 | Server distribution. 5 | 6 | The packages included in this archive may vary depending on the OS you're using 7 | and its release version, as different components may require libraries or 8 | functionality available only in newer releases. 9 | 10 | The .rpm files can be installed individually, but there are complex 11 | interdependencies that are difficult to resolve using rpm alone. For that 12 | reason, this package is distributed as a ready-to-use ZYpp archive, so that you 13 | can use zypper to install the packages in it. 14 | 15 | In order for the package manager to be able to install these packages, you will 16 | need to place them in a location that the package manager has privileges to 17 | access. You may find that /opt is a good location where you can unpack the 18 | archive and the package manager will be able to read it. 19 | 20 | To use the archive with zypper, create a mariadb.repo file in 21 | /etc/zypp/repos.d/ that points to the directory where you've extracted the 22 | files. A helpful script called setup_repository is included in this archive to 23 | do this for you. 24 | 25 | You'll need to do this work as root, so that you can write files to these 26 | locations. 27 | 28 | cd /opt 29 | tar -xf ~/filename.tar 30 | filename/setup_repository 31 | 32 | After the repository is set up, you should install the MariaDB-server package. 33 | 34 | yum install -y MariaDB-server 35 | 36 | For more information about installing MariaDB .rpm files, visit: 37 | https://mariadb.com/kb/en/installing-mariadb-rpm-files/ 38 | 39 | For more information about MariaDB products, visit https://mariadb.com/products 40 | and for help using MariaDB, please contact MariaDB Corporation: 41 | https://mariadb.com/contact 42 | -------------------------------------------------------------------------------- /sysbench/conf/au0013.inc: -------------------------------------------------------------------------------- 1 | # Configuration file for host: au0013 2 | # 3 | # OS: Mac OS X 10.6.2 4 | # Platform: x86_64 5 | # CPU: Dual-core Intel Core 2 Duo @ 2.8GHz 6 | # RAM: 4GB 7 | # Disk(s): 1 x ST9500420ASG S-ATA 8 | 9 | # 10 | # Adjust the following paths according to your installation. 11 | # 12 | 13 | # Base directory where SysBench files are found. 14 | BASE="${HOME}/work" 15 | TEST_DIR="${BASE}/monty_program/sysbench/sysbench/tests/db" 16 | 17 | # We need SysBench >= v0.5. 18 | SYSBENCH='/usr/local/bin/sysbench' 19 | 20 | # We need bzr >= 1.18.1. 21 | BZR='/usr/local/bin/bzr' 22 | 23 | # OProfile binaries. 24 | # There is no OProfile on Mac OS X. 25 | # TODO: Find OProfile equivalent for Mac OS X. 26 | OPCONTROL='' 27 | 28 | # System statistic binaries. 29 | IOSTAT='/usr/sbin/iostat' 30 | IOSTAT_DEVICE='disk0' 31 | # Note: sar works different on Mac OS X. 32 | SAR='/usr/bin/sar' 33 | 34 | # Other binaries. 35 | SUDO=/usr/bin/sudo 36 | 37 | # Directories. 38 | TEMP_DIR='/tmp' 39 | DATA_DIR="${TEMP_DIR}/data" 40 | 41 | # Where to compile the sources. 42 | WORK_DIR='/tmp' 43 | 44 | # Which concurrency level(s) we want to profile with OProfile. 45 | # 46 | # Example: profile 8 and 32. 47 | # DO_OPROFILE='8 32' 48 | #DO_OPROFILE='64' 49 | # There is no OProfile on Mac OS X. 50 | DO_OPROFILE='' 51 | 52 | # SysBench tests to run. 53 | SYSBENCH_TESTS[0]="delete.lua" 54 | SYSBENCH_TESTS[1]="insert.lua" 55 | SYSBENCH_TESTS[2]="oltp_complex_ro.lua" 56 | SYSBENCH_TESTS[3]="oltp_complex_rw.lua" 57 | SYSBENCH_TESTS[4]="oltp_simple.lua" 58 | SYSBENCH_TESTS[5]="select.lua" 59 | 60 | # Default option is --random-points=10. 61 | SYSBENCH_TESTS[6]="select_random_points.lua" 62 | 63 | # Default options are 64 | # --number-of-ranges=10 65 | # --random-ranges-delta=5. 66 | SYSBENCH_TESTS[7]="select_random_ranges.lua" 67 | SYSBENCH_TESTS[8]="update_index.lua" 68 | SYSBENCH_TESTS[9]="update_non_index.lua" 69 | -------------------------------------------------------------------------------- /dbt3_benchmark/tests/db_conf/db_mariadb_5_3_innodb.conf: -------------------------------------------------------------------------------- 1 | [db_settings] 2 | #Where the instalation folder of MariaDB / MySQL / PostgreSQL is located 3 | DBMS_HOME = $PROJECT_HOME/bin/mariadb-5.3.2-beta-linux-x86_64 4 | DBMS_USER = root 5 | 6 | #The config file that mysqld or postgres will use when starting 7 | CONFIG_FILE = $PROJECT_HOME/mariadb-tools/dbt3_benchmark/config/s$SCALE_FACTOR/mariadb_innodb_my.cnf 8 | SOCKET = $PROJECT_HOME/temp/mysql.sock 9 | PORT = 12340 10 | HOST = 127.0.0.1 11 | 12 | #Where is the datadir for mysqld or postgres 13 | DATADIR = $DATADIR_HOME/mariadb_5_3_innodb-s$SCALE_FACTOR 14 | 15 | #Where the temp tables will be created while sorting and grouping. 16 | TMPDIR = $PROJECT_HOME/temp 17 | 18 | #The database name that will be used for the test 19 | DBNAME = dbt3 20 | 21 | #This text will be stored into the results database as a keyword. Also will be used as a name for a subfolder with results and statistics. 22 | KEYWORD = mariadb-5-3-2-innodb 23 | 24 | #Database Management System that will be used. Possible values: "MySQL", "MariaDB" and "PostgreSQL" 25 | DBMS = MariaDB 26 | 27 | #The storage engine that was used 28 | STORAGE_ENGINE = XtraDB 29 | 30 | #Any startup parameters that will be used while starting the mysqld process or postgres process 31 | STARTUP_PARAMS = 32 | 33 | #The heading of the graphic 34 | GRAPH_HEADING = MariaDB 5.3.2 + XtraDB 35 | 36 | 37 | #This only executes if $RUN is set to 1 38 | PRE_RUN_SQL = flush status; set global userstat=on; 39 | 40 | #This only executes if $RUN is set to 1 41 | POST_RUN_SQL = show status; select * from information_schema.TABLE_STATISTICS; 42 | 43 | #SQL commands that are run prior the whole test 44 | PRE_TEST_SQL = use dbt3; select version(); show variables; show engines; show table status; 45 | 46 | #Cannot be overridden in the different configurations. SQL commands are run after the whole test 47 | POST_TEST_SQL = 48 | -------------------------------------------------------------------------------- /dbt3_benchmark/tests/db_conf/db_mysql_5_6_innodb.conf: -------------------------------------------------------------------------------- 1 | [db_settings] 2 | #Where the instalation folder of MariaDB / MySQL / PostgreSQL is located 3 | DBMS_HOME = $PROJECT_HOME/bin/mysql-5.6.4-m7-linux-x86_64 4 | DBMS_USER = root 5 | 6 | #The config file that mysqld or postgres will use when starting 7 | CONFIG_FILE = $PROJECT_HOME/mariadb-tools/dbt3_benchmark/config/s$SCALE_FACTOR/mysql_5_6_innodb_my.cnf 8 | SOCKET = $PROJECT_HOME/temp/mysql.sock 9 | PORT = 12340 10 | HOST = 127.0.0.1 11 | 12 | #Where is the datadir for mysqld or postgres 13 | DATADIR = $DATADIR_HOME/mysql_5_6_innodb-s$SCALE_FACTOR 14 | 15 | #Where the temp tables will be created while sorting and grouping. 16 | TMPDIR = $PROJECT_HOME/temp 17 | 18 | #The database name that will be used for the test 19 | DBNAME = dbt3 20 | 21 | #This text will be stored into the results database as a keyword. Also will be used as a name for a subfolder with results and statistics. 22 | KEYWORD = mysql-5-6-4-innodb 23 | 24 | #Database Management System that will be used. Possible values: "MySQL", "MariaDB" and "PostgreSQL" 25 | DBMS = MySQL 26 | 27 | #The storage engine that was used 28 | STORAGE_ENGINE = InnoDB 29 | 30 | #Any startup parameters that will be used while starting the mysqld process or postgres process 31 | STARTUP_PARAMS = 32 | 33 | #The heading of the graphic 34 | GRAPH_HEADING = MySQL 5.6.4 + InnoDB 35 | 36 | 37 | #This only executes if $RUN is set to 1 38 | PRE_RUN_SQL = flush status; 39 | 40 | #This only executes if $RUN is set to 1 41 | POST_RUN_SQL = show status; select * from information_schema.STATISTICS; 42 | 43 | #Cannot be overridden in the different configurations. SQL commands are run prior the whole test 44 | PRE_TEST_SQL = use dbt3; select version(); show variables; show engines; show table status; 45 | 46 | #Cannot be overridden in the different configurations. SQL commands are run after the whole test 47 | POST_TEST_SQL = 48 | -------------------------------------------------------------------------------- /dbt3_benchmark/tests/db_conf/postgres_9_1.conf: -------------------------------------------------------------------------------- 1 | [db_settings] 2 | #Where the instalation folder of MariaDB / MySQL / PostgreSQL is located 3 | DBMS_HOME = $PROJECT_HOME/bin/PostgreSQL_bin 4 | DBMS_USER = root 5 | 6 | #The config file that mysqld or postgres will use when starting 7 | CONFIG_FILE = $PROJECT_HOME/mariadb-tools/dbt3_benchmark/config/s$SCALE_FACTOR/postgresql.conf 8 | SOCKET = $PROJECT_HOME/temp/postgres.sock 9 | PORT = 12340 10 | HOST = 127.0.0.1 11 | 12 | #Where is the datadir for mysqld or postgres 13 | DATADIR = $DATADIR_HOME/postgre-s$SCALE_FACTOR 14 | 15 | #Where the temp tables will be created while sorting and grouping. 16 | TMPDIR = $PROJECT_HOME/temp 17 | 18 | #The database name that will be used for the test 19 | DBNAME = dbt3 20 | 21 | #This text will be stored into the results database as a keyword. Also will be used as a name for a subfolder with results and statistics. 22 | KEYWORD = postgres 23 | 24 | #Database Management System that will be used. Possible values: "MySQL", "MariaDB" and "PostgreSQL" 25 | DBMS = PostgreSQL 26 | 27 | #The storage engine that was used 28 | STORAGE_ENGINE = PostgreSQL 29 | 30 | #Any startup parameters that will be used while starting the mysqld process or postgres process 31 | STARTUP_PARAMS = 32 | 33 | #The heading of the graphic 34 | GRAPH_HEADING = PostgreSQL 35 | 36 | 37 | 38 | 39 | #This only executes if $RUN is set to 1 40 | #PRE_RUN_SQL = flush status; 41 | PRE_RUN_SQL = 42 | 43 | #This only executes if $RUN is set to 1 44 | #POST_RUN_SQL = show status; select * from information_schema.STATISTICS; 45 | POST_RUN_SQL = 46 | 47 | #Cannot be overridden in the different configurations. SQL commands are run prior the whole test 48 | #PRE_TEST_SQL = use dbt3; select version(); show variables; show engines; show table status; 49 | PRE_TEST_SQL = 50 | 51 | #Cannot be overridden in the different configurations. SQL commands are run after the whole test 52 | POST_TEST_SQL = -------------------------------------------------------------------------------- /dbt3_benchmark/tests/test_conf/test_innodb.conf: -------------------------------------------------------------------------------- 1 | #If set to 1, then all the queries are executed sequentially without restarting the server between queries. 2 | QUERIES_AT_ONCE = 0 3 | 4 | #Clearing server caches 5 | CLEAR_CACHES = 1 6 | 7 | #perform a warm-up before running the tests 8 | WARMUP = 0 9 | #how many times will the query be warmed up before taking the results into account 10 | WARMUPS_COUNT = 0 11 | 12 | #run an Explain command prior the run of the test 13 | EXPLAIN = 1 14 | 15 | #perform the actual test 16 | RUN = 1 17 | 18 | #Choose a result extraction mechanism (only one of the three could be enabled) 19 | ANALYZE_EXPLAIN = 0 20 | MIN_MAX_OUT_OF_N = 1 21 | SIMPLE_AVERAGE = 0 22 | 23 | #how many times will the same query be executed in order to calculate the average run time 24 | NUM_TESTS = 4 25 | 26 | #when more than $MAX_SKIPPED_TESTS tests have been skipped, then move to the next query. The current query is obvously timed out and there are no other execution plans. 27 | #valid only for ANALYZE_EXPLAIN above 28 | MAX_SKIPPED_TESTS = 5 29 | 30 | #how big is one cluster with test results 31 | #valid only for ANALYZE_EXPLAIN above 32 | CLUSTER_SIZE = 3 33 | 34 | #What is the maximum time allowed for testing one query. 35 | #valid only for ANALYZE_EXPLAIN above 36 | MAX_QUERY_TIME = 7300 37 | 38 | #What is the timeout of running one query, Currently works only with MariaDB/MySQL 39 | TIMEOUT = 3000 40 | 41 | # the interval between each OS performance statistics extraction 42 | OS_STATS_INTERVAL = 5 43 | 44 | 45 | 46 | 47 | 48 | #OS commands that will be executed before each run 49 | PRE_RUN_OS = 50 | 51 | #OS commands that will be executed after each run 52 | POST_RUN_OS = 53 | 54 | #Cannot be overridden in the different configurations. OS commands are run prior the whole test 55 | PRE_TEST_OS = 56 | 57 | #Cannot be overridden in the different configurations. OS commands are run after the whole test 58 | POST_TEST_OS = 59 | -------------------------------------------------------------------------------- /dbt3_benchmark/tests/db_conf/db_mysql_5_6_myisam.conf: -------------------------------------------------------------------------------- 1 | [db_settings] 2 | #Where the instalation folder of MariaDB / MySQL / PostgreSQL is located 3 | DBMS_HOME = $PROJECT_HOME/bin/mysql-5.6.4-m7-linux-x86_64 4 | DBMS_USER = root 5 | 6 | #The config file that mysqld or postgres will use when starting 7 | CONFIG_FILE = $PROJECT_HOME/mariadb-tools/dbt3_benchmark/config/s$SCALE_FACTOR/mysql_5_6_myisam_my.cnf 8 | SOCKET = $PROJECT_HOME/temp/mysql.sock 9 | PORT = 12340 10 | HOST = 127.0.0.1 11 | 12 | #Where is the datadir for mysqld or postgres 13 | DATADIR = $DATADIR_HOME/mysql_5_6_myisam-s$SCALE_FACTOR 14 | 15 | #Where the temp tables will be created while sorting and grouping. 16 | TMPDIR = $PROJECT_HOME/temp 17 | 18 | #The database name that will be used for the test 19 | DBNAME = dbt3 20 | 21 | #This text will be stored into the results database as a keyword. Also will be used as a name for a subfolder with results and statistics. 22 | KEYWORD = mysql-5-6-4-myisam 23 | 24 | #Database Management System that will be used. Possible values: "MySQL", "MariaDB" and "PostgreSQL" 25 | DBMS = MySQL 26 | 27 | #The storage engine that was used 28 | STORAGE_ENGINE = MyISAM 29 | 30 | #Any startup parameters that will be used while starting the mysqld process or postgres process 31 | STARTUP_PARAMS = 32 | 33 | #The heading of the graphic 34 | GRAPH_HEADING = MySQL 5.6.4 + MyISAM 35 | 36 | READ_ONLY = 1 37 | MYSQL_SYSTEM_DIR= 38 | 39 | 40 | 41 | 42 | 43 | #This only executes if $RUN is set to 1 44 | PRE_RUN_SQL = flush status; 45 | 46 | #This only executes if $RUN is set to 1 47 | POST_RUN_SQL = show status; select * from information_schema.STATISTICS; 48 | 49 | #Cannot be overridden in the different configurations. SQL commands are run prior the whole test 50 | PRE_TEST_SQL = use dbt3; select version(); show variables; show engines; show table status; 51 | 52 | #Cannot be overridden in the different configurations. SQL commands are run after the whole test 53 | POST_TEST_SQL = -------------------------------------------------------------------------------- /dbt3_benchmark/tests/myisam_test_mariadb_5_3_mysql_5_5_mysql_5_6.conf: -------------------------------------------------------------------------------- 1 | [common] 2 | RESULTS_DB_CONFIG = $PROJECT_HOME/mariadb-tools/dbt3_benchmark/tests/results_db_conf/results_db.conf 3 | TEST_CONFIG = $PROJECT_HOME/mariadb-tools/dbt3_benchmark/tests/test_conf/test_myisam.conf 4 | 5 | #[mariadb_5_3_per_test] 6 | #QUERIES_CONFIG = $PROJECT_HOME/mariadb-tools/dbt3_benchmark/tests/queries_conf/queries-mariadb.conf 7 | #DB_CONFIG = $PROJECT_HOME/mariadb-tools/dbt3_benchmark/tests/db_conf/db_mariadb_5_3_myisam.conf 8 | 9 | 10 | [mariadb_5_3_per_test_icp] 11 | QUERIES_CONFIG = $PROJECT_HOME/mariadb-tools/dbt3_benchmark/tests/queries_conf/queries-mariadb.conf 12 | DB_CONFIG = $PROJECT_HOME/mariadb-tools/dbt3_benchmark/tests/db_conf/db_mariadb_5_3_myisam_icp.conf 13 | 14 | 15 | #[mariadb_5_3_per_query] 16 | #QUERIES_CONFIG = $PROJECT_HOME/mariadb-tools/dbt3_benchmark/tests/queries_conf/queries-mariadb_igor_hdd_s30.conf 17 | #DB_CONFIG = $PROJECT_HOME/mariadb-tools/dbt3_benchmark/tests/db_conf/db_mariadb_5_3_myisam_igor.conf 18 | 19 | 20 | #[mariadb_5_5_igor] 21 | #QUERIES_CONFIG = $PROJECT_HOME/mariadb-tools/dbt3_benchmark/tests/queries_conf/queries-mariadb_igor_hdd_s30.conf 22 | #DB_CONFIG = $PROJECT_HOME/mariadb-tools/dbt3_benchmark/tests/db_conf/db_mariadb_5_5_myisam_igor.conf 23 | 24 | 25 | [mariadb_5_5_icp] 26 | QUERIES_CONFIG = $PROJECT_HOME/mariadb-tools/dbt3_benchmark/tests/queries_conf/queries-mariadb.conf 27 | DB_CONFIG = $PROJECT_HOME/mariadb-tools/dbt3_benchmark/tests/db_conf/db_mariadb_5_5_myisam_icp.conf 28 | 29 | 30 | [mysql_5_5] 31 | QUERIES_CONFIG = $PROJECT_HOME/mariadb-tools/dbt3_benchmark/tests/queries_conf/queries-mysql.conf 32 | DB_CONFIG = $PROJECT_HOME/mariadb-tools/dbt3_benchmark/tests/db_conf/db_mysql_5_5_myisam.conf 33 | 34 | 35 | [mysql_5_6] 36 | QUERIES_CONFIG = $PROJECT_HOME/mariadb-tools/dbt3_benchmark/tests/queries_conf/queries-mysql.conf 37 | DB_CONFIG = $PROJECT_HOME/mariadb-tools/dbt3_benchmark/tests/db_conf/db_mysql_5_6_myisam.conf -------------------------------------------------------------------------------- /dbt3_benchmark/tests/db_conf/db_mariadb_5_3_innodb_igor.conf: -------------------------------------------------------------------------------- 1 | [db_settings] 2 | #Where the instalation folder of MariaDB / MySQL / PostgreSQL is located 3 | DBMS_HOME = $PROJECT_HOME/bin/mariadb-5.3.2-beta-linux-x86_64 4 | DBMS_USER = root 5 | 6 | #The config file that mysqld or postgres will use when starting 7 | CONFIG_FILE = $PROJECT_HOME/mariadb-tools/dbt3_benchmark/config/s$SCALE_FACTOR/mariadb_innodb_no_optimizations_my.cnf 8 | SOCKET = $PROJECT_HOME/temp/mysql.sock 9 | PORT = 12340 10 | HOST = 127.0.0.1 11 | 12 | #Where is the datadir for mysqld or postgres 13 | DATADIR = $DATADIR_HOME/innodb-s$SCALE_FACTOR 14 | 15 | #Where the temp tables will be created while sorting and grouping. 16 | TMPDIR = $PROJECT_HOME/temp 17 | 18 | #The database name that will be used for the test 19 | DBNAME = dbt3 20 | 21 | #This text will be stored into the results database as a keyword. Also will be used as a name for a subfolder with results and statistics. 22 | KEYWORD = mariadb-5-3-2-innodb-igor 23 | 24 | #Database Management System that will be used. Possible values: "MySQL", "MariaDB" and "PostgreSQL" 25 | DBMS = MariaDB 26 | 27 | #The storage engine that was used 28 | STORAGE_ENGINE = InnoDB 29 | 30 | #Any startup parameters that will be used while starting the mysqld process or postgres process 31 | STARTUP_PARAMS = 32 | 33 | #The heading of the graphic 34 | GRAPH_HEADING = MariaDB 5.3.2 + InnoDB with Igor optimizations 35 | 36 | 37 | 38 | 39 | #This only executes if $RUN is set to 1 40 | PRE_RUN_SQL = flush status; set global userstat=on; 41 | 42 | #This only executes if $RUN is set to 1 43 | POST_RUN_SQL = show status; select * from information_schema.TABLE_STATISTICS; 44 | 45 | #Cannot be overridden in the different configurations. SQL commands are run prior the whole test 46 | PRE_TEST_SQL = use dbt3; select version(); show variables; show engines; show table status; 47 | 48 | #Cannot be overridden in the different configurations. SQL commands are run after the whole test 49 | POST_TEST_SQL = -------------------------------------------------------------------------------- /dbt3_benchmark/tests/db_conf/db_mysql_5_5_myisam.conf: -------------------------------------------------------------------------------- 1 | [db_settings] 2 | #Where the instalation folder of MariaDB / MySQL / PostgreSQL is located 3 | DBMS_HOME = $PROJECT_HOME/bin/mysql-5.5.19-linux-x86_64 4 | DBMS_USER = root 5 | 6 | #The config file that mysqld or postgres will use when starting 7 | CONFIG_FILE = $PROJECT_HOME/mariadb-tools/dbt3_benchmark/config/s$SCALE_FACTOR/mysql_5_5_myisam_my.cnf 8 | SOCKET = $PROJECT_HOME/temp/mysql.sock 9 | PORT = 12340 10 | HOST = 127.0.0.1 11 | 12 | #Where is the datadir for mysqld or postgres 13 | DATADIR = $DATADIR_HOME/myisam-s$SCALE_FACTOR 14 | 15 | #Where the temp tables will be created while sorting and grouping. 16 | TMPDIR = $PROJECT_HOME/temp 17 | 18 | #The database name that will be used for the test 19 | DBNAME = dbt3 20 | 21 | #This text will be stored into the results database as a keyword. Also will be used as a name for a subfolder with results and statistics. 22 | KEYWORD = mysql-5-5-19-myisam 23 | 24 | #Database Management System that will be used. Possible values: "MySQL", "MariaDB" and "PostgreSQL" 25 | DBMS = MySQL 26 | 27 | #The storage engine that was used 28 | STORAGE_ENGINE = MyISAM 29 | 30 | #Any startup parameters that will be used while starting the mysqld process or postgres process 31 | STARTUP_PARAMS = 32 | 33 | #The heading of the graphic 34 | GRAPH_HEADING = MySQL 5.5.19 + MyISAM 35 | 36 | READ_ONLY = 1 37 | MYSQL_SYSTEM_DIR= $DATADIR_HOME/myisam-s$SCALE_FACTOR/mysql_mysql_5_5/ 38 | 39 | 40 | 41 | 42 | 43 | #This only executes if $RUN is set to 1 44 | PRE_RUN_SQL = flush status; 45 | 46 | #This only executes if $RUN is set to 1 47 | POST_RUN_SQL = show status; select * from information_schema.STATISTICS; 48 | 49 | #Cannot be overridden in the different configurations. SQL commands are run prior the whole test 50 | PRE_TEST_SQL = use dbt3; select version(); show variables; show engines; show table status; 51 | 52 | #Cannot be overridden in the different configurations. SQL commands are run after the whole test 53 | POST_TEST_SQL = -------------------------------------------------------------------------------- /dbt3_benchmark/tests/db_conf/db_mysql_5_5_innodb.conf: -------------------------------------------------------------------------------- 1 | [db_settings] 2 | #Where the instalation folder of MariaDB / MySQL / PostgreSQL is located 3 | DBMS_HOME = $PROJECT_HOME/bin/mysql-5.5.19-linux-x86_64 4 | DBMS_USER = root 5 | 6 | #The config file that mysqld or postgres will use when starting 7 | CONFIG_FILE = $PROJECT_HOME/mariadb-tools/dbt3_benchmark/config/s$SCALE_FACTOR/mysql_5_5_innodb_my.cnf 8 | SOCKET = $PROJECT_HOME/temp/mysql.sock 9 | PORT = 12340 10 | HOST = 127.0.0.1 11 | 12 | #Where is the datadir for mysqld or postgres 13 | DATADIR = $DATADIR_HOME/mariadb_5_5_innodb-s$SCALE_FACTOR 14 | 15 | #Where the temp tables will be created while sorting and grouping. 16 | TMPDIR = $PROJECT_HOME/temp 17 | 18 | #The database name that will be used for the test 19 | DBNAME = dbt3 20 | 21 | #This text will be stored into the results database as a keyword. Also will be used as a name for a subfolder with results and statistics. 22 | KEYWORD = mysql-5-5-19-innodb 23 | 24 | #Database Management System that will be used. Possible values: "MySQL", "MariaDB" and "PostgreSQL" 25 | DBMS = MySQL 26 | 27 | #The storage engine that was used 28 | STORAGE_ENGINE = InnoDB 29 | 30 | #Any startup parameters that will be used while starting the mysqld process or postgres process 31 | STARTUP_PARAMS = 32 | 33 | #The heading of the graphic 34 | GRAPH_HEADING = MySQL 5.5.19 + InnoDB 35 | 36 | READ_ONLY = 1 37 | MYSQL_SYSTEM_DIR= $DATADIR_HOME/mariadb_5_5_innodb-s$SCALE_FACTOR/mysql_mysql_5_5/ 38 | 39 | #This only executes if $RUN is set to 1 40 | PRE_RUN_SQL = flush status; 41 | 42 | #This only executes if $RUN is set to 1 43 | POST_RUN_SQL = show status; select * from information_schema.STATISTICS; 44 | 45 | #Cannot be overridden in the different configurations. SQL commands are run prior the whole test 46 | PRE_TEST_SQL = use dbt3; select version(); show variables; show engines; show table status; 47 | 48 | #Cannot be overridden in the different configurations. SQL commands are run after the whole test 49 | POST_TEST_SQL = 50 | -------------------------------------------------------------------------------- /dbt3_benchmark/tests/db_conf/db_mariadb_5_5_innodb.conf: -------------------------------------------------------------------------------- 1 | [db_settings] 2 | #Where the instalation folder of MariaDB / MySQL / PostgreSQL is located 3 | DBMS_HOME = $PROJECT_HOME/bin/mariadb-5.5.18-linux-x86_64 4 | DBMS_USER = root 5 | 6 | #The config file that mysqld or postgres will use when starting 7 | CONFIG_FILE = $PROJECT_HOME/mariadb-tools/dbt3_benchmark/config/s$SCALE_FACTOR/mariadb_innodb_my.cnf 8 | SOCKET = $PROJECT_HOME/temp/mysql.sock 9 | PORT = 12340 10 | HOST = 127.0.0.1 11 | 12 | #Where is the datadir for mysqld or postgres 13 | DATADIR = $DATADIR_HOME/mariadb_5_5_innodb-s$SCALE_FACTOR 14 | 15 | #Where the temp tables will be created while sorting and grouping. 16 | TMPDIR = $PROJECT_HOME/temp 17 | 18 | #The database name that will be used for the test 19 | DBNAME = dbt3 20 | 21 | #This text will be stored into the results database as a keyword. Also will be used as a name for a subfolder with results and statistics. 22 | KEYWORD = mariadb-5-5-18-innodb 23 | 24 | #Database Management System that will be used. Possible values: "MySQL", "MariaDB" and "PostgreSQL" 25 | DBMS = MariaDB 26 | 27 | #The storage engine that was used 28 | STORAGE_ENGINE = XtraDB 29 | 30 | #Any startup parameters that will be used while starting the mysqld process or postgres process 31 | STARTUP_PARAMS = 32 | 33 | #The heading of the graphic 34 | GRAPH_HEADING = MariaDB 5.5.18 + XtraDB 35 | 36 | READ_ONLY = 1 37 | MYSQL_SYSTEM_DIR= $DATADIR_HOME/mariadb_5_5_innodb-s$SCALE_FACTOR/mysql_mariadb_5_5/ 38 | 39 | #This only executes if $RUN is set to 1 40 | PRE_RUN_SQL = flush status; set global userstat=on; 41 | 42 | #This only executes if $RUN is set to 1 43 | POST_RUN_SQL = show status; select * from information_schema.TABLE_STATISTICS; 44 | 45 | #Cannot be overridden in the different configurations. SQL commands are run prior the whole test 46 | PRE_TEST_SQL = use dbt3; select version(); show variables; show engines; show table status; 47 | 48 | #Cannot be overridden in the different configurations. SQL commands are run after the whole test 49 | POST_TEST_SQL = -------------------------------------------------------------------------------- /dbt3_benchmark/tests/db_conf/db_mariadb_5_5_myisam.conf: -------------------------------------------------------------------------------- 1 | [db_settings] 2 | #Where the instalation folder of MariaDB / MySQL / PostgreSQL is located 3 | DBMS_HOME = $PROJECT_HOME/bin/mariadb-5.5.18-linux-x86_64 4 | DBMS_USER = root 5 | 6 | #The config file that mysqld or postgres will use when starting 7 | CONFIG_FILE = $PROJECT_HOME/mariadb-tools/dbt3_benchmark/config/s$SCALE_FACTOR/mariadb_myisam_my.cnf 8 | SOCKET = $PROJECT_HOME/temp/mysql.sock 9 | PORT = 12340 10 | HOST = 127.0.0.1 11 | 12 | #Where is the datadir for mysqld or postgres 13 | DATADIR = $DATADIR_HOME/myisam-s$SCALE_FACTOR 14 | 15 | #Where the temp tables will be created while sorting and grouping. 16 | TMPDIR = $PROJECT_HOME/temp 17 | 18 | #The database name that will be used for the test 19 | DBNAME = dbt3 20 | 21 | #This text will be stored into the results database as a keyword. Also will be used as a name for a subfolder with results and statistics. 22 | KEYWORD = mariadb-5-5-18-myisam 23 | 24 | #Database Management System that will be used. Possible values: "MySQL", "MariaDB" and "PostgreSQL" 25 | DBMS = MariaDB 26 | 27 | #The storage engine that was used 28 | STORAGE_ENGINE = MyISAM 29 | 30 | #Any startup parameters that will be used while starting the mysqld process or postgres process 31 | STARTUP_PARAMS = 32 | 33 | #The heading of the graphic 34 | GRAPH_HEADING = MariaDB 5.5.18 + MyISAM 35 | 36 | READ_ONLY = 1 37 | MYSQL_SYSTEM_DIR= $DATADIR_HOME/myisam-s$SCALE_FACTOR/mysql_mariadb_5_5/ 38 | 39 | 40 | 41 | 42 | 43 | #This only executes if $RUN is set to 1 44 | PRE_RUN_SQL = flush status; set global userstat=on; 45 | 46 | #This only executes if $RUN is set to 1 47 | POST_RUN_SQL = show status; select * from information_schema.TABLE_STATISTICS; 48 | 49 | #Cannot be overridden in the different configurations. SQL commands are run prior the whole test 50 | PRE_TEST_SQL = use dbt3; select version(); show variables; show engines; show table status; 51 | 52 | #Cannot be overridden in the different configurations. SQL commands are run after the whole test 53 | POST_TEST_SQL = -------------------------------------------------------------------------------- /dbt3_benchmark/tests/db_conf/db_mariadb_5_3_myisam.conf: -------------------------------------------------------------------------------- 1 | [db_settings] 2 | #Where the instalation folder of MariaDB / MySQL / PostgreSQL is located 3 | DBMS_HOME = $PROJECT_HOME/bin/mariadb-5.3.2-beta-linux-x86_64 4 | DBMS_USER = root 5 | 6 | #The config file that mysqld or postgres will use when starting 7 | CONFIG_FILE = $PROJECT_HOME/mariadb-tools/dbt3_benchmark/config/s$SCALE_FACTOR/mariadb_myisam_my.cnf 8 | SOCKET = $PROJECT_HOME/temp/mysql.sock 9 | PORT = 12340 10 | HOST = 127.0.0.1 11 | 12 | #Where is the datadir for mysqld or postgres 13 | DATADIR = $DATADIR_HOME/myisam-s$SCALE_FACTOR 14 | 15 | #Where the temp tables will be created while sorting and grouping. 16 | TMPDIR = $PROJECT_HOME/temp 17 | 18 | #The database name that will be used for the test 19 | DBNAME = dbt3 20 | 21 | #This text will be stored into the results database as a keyword. Also will be used as a name for a subfolder with results and statistics. 22 | KEYWORD = mariadb-5-3-2-myisam 23 | 24 | #Database Management System that will be used. Possible values: "MySQL", "MariaDB" and "PostgreSQL" 25 | DBMS = MariaDB 26 | 27 | #The storage engine that was used 28 | STORAGE_ENGINE = MyISAM 29 | 30 | #Any startup parameters that will be used while starting the mysqld process or postgres process 31 | STARTUP_PARAMS = 32 | 33 | #The heading of the graphic 34 | GRAPH_HEADING = MariaDB 5.3.2 + MyISAM 35 | 36 | READ_ONLY = 1 37 | MYSQL_SYSTEM_DIR= $DATADIR_HOME/myisam-s$SCALE_FACTOR/mysql_mariadb_5_3/ 38 | 39 | 40 | 41 | 42 | 43 | #This only executes if $RUN is set to 1 44 | PRE_RUN_SQL = flush status; set global userstat=on; 45 | 46 | #This only executes if $RUN is set to 1 47 | POST_RUN_SQL = show status; select * from information_schema.TABLE_STATISTICS; 48 | 49 | #Cannot be overridden in the different configurations. SQL commands are run prior the whole test 50 | PRE_TEST_SQL = use dbt3; select version(); show variables; show engines; show table status; 51 | 52 | #Cannot be overridden in the different configurations. SQL commands are run after the whole test 53 | POST_TEST_SQL = -------------------------------------------------------------------------------- /dbt3_benchmark/tests/db_conf/db_mariadb_5_3_myisam_icp.conf: -------------------------------------------------------------------------------- 1 | [db_settings] 2 | #Where the instalation folder of MariaDB / MySQL / PostgreSQL is located 3 | DBMS_HOME = $PROJECT_HOME/bin/mariadb-5.3.2-beta-linux-x86_64 4 | DBMS_USER = root 5 | 6 | #The config file that mysqld or postgres will use when starting 7 | CONFIG_FILE = $PROJECT_HOME/mariadb-tools/dbt3_benchmark/config/s$SCALE_FACTOR/mariadb_myisam_my_icp.cnf 8 | SOCKET = $PROJECT_HOME/temp/mysql.sock 9 | PORT = 12340 10 | HOST = 127.0.0.1 11 | 12 | #Where is the datadir for mysqld or postgres 13 | DATADIR = $DATADIR_HOME/myisam-s$SCALE_FACTOR 14 | 15 | #Where the temp tables will be created while sorting and grouping. 16 | TMPDIR = $PROJECT_HOME/temp 17 | 18 | #The database name that will be used for the test 19 | DBNAME = dbt3 20 | 21 | #This text will be stored into the results database as a keyword. Also will be used as a name for a subfolder with results and statistics. 22 | KEYWORD = mariadb-5-3-2-myisam-icp 23 | 24 | #Database Management System that will be used. Possible values: "MySQL", "MariaDB" and "PostgreSQL" 25 | DBMS = MariaDB 26 | 27 | #The storage engine that was used 28 | STORAGE_ENGINE = MyISAM 29 | 30 | #Any startup parameters that will be used while starting the mysqld process or postgres process 31 | STARTUP_PARAMS = 32 | 33 | #The heading of the graphic 34 | GRAPH_HEADING = MariaDB 5.3.2 (ICP) + MyISAM 35 | 36 | READ_ONLY = 1 37 | MYSQL_SYSTEM_DIR= $DATADIR_HOME/myisam-s$SCALE_FACTOR/mysql_mariadb_5_3/ 38 | 39 | 40 | 41 | 42 | 43 | #This only executes if $RUN is set to 1 44 | PRE_RUN_SQL = flush status; set global userstat=on; 45 | 46 | #This only executes if $RUN is set to 1 47 | POST_RUN_SQL = show status; select * from information_schema.TABLE_STATISTICS; 48 | 49 | #Cannot be overridden in the different configurations. SQL commands are run prior the whole test 50 | PRE_TEST_SQL = use dbt3; select version(); show variables; show engines; show table status; 51 | 52 | #Cannot be overridden in the different configurations. SQL commands are run after the whole test 53 | POST_TEST_SQL = -------------------------------------------------------------------------------- /dbt3_benchmark/tests/db_conf/db_mariadb_5_5_myisam_icp.conf: -------------------------------------------------------------------------------- 1 | [db_settings] 2 | #Where the instalation folder of MariaDB / MySQL / PostgreSQL is located 3 | DBMS_HOME = $PROJECT_HOME/bin/mariadb-5.5.18-linux-x86_64 4 | DBMS_USER = root 5 | 6 | #The config file that mysqld or postgres will use when starting 7 | CONFIG_FILE = $PROJECT_HOME/mariadb-tools/dbt3_benchmark/config/s$SCALE_FACTOR/mariadb_myisam_my_icp.cnf 8 | SOCKET = $PROJECT_HOME/temp/mysql.sock 9 | PORT = 12340 10 | HOST = 127.0.0.1 11 | 12 | #Where is the datadir for mysqld or postgres 13 | DATADIR = $DATADIR_HOME/myisam-s$SCALE_FACTOR 14 | 15 | #Where the temp tables will be created while sorting and grouping. 16 | TMPDIR = $PROJECT_HOME/temp 17 | 18 | #The database name that will be used for the test 19 | DBNAME = dbt3 20 | 21 | #This text will be stored into the results database as a keyword. Also will be used as a name for a subfolder with results and statistics. 22 | KEYWORD = mariadb-5-5-18-myisam-icp 23 | 24 | #Database Management System that will be used. Possible values: "MySQL", "MariaDB" and "PostgreSQL" 25 | DBMS = MariaDB 26 | 27 | #The storage engine that was used 28 | STORAGE_ENGINE = MyISAM 29 | 30 | #Any startup parameters that will be used while starting the mysqld process or postgres process 31 | STARTUP_PARAMS = 32 | 33 | #The heading of the graphic 34 | GRAPH_HEADING = MariaDB 5.5.18 (ICP) + MyISAM 35 | 36 | READ_ONLY = 1 37 | MYSQL_SYSTEM_DIR= $DATADIR_HOME/myisam-s$SCALE_FACTOR/mysql_mariadb_5_5/ 38 | 39 | 40 | 41 | 42 | 43 | #This only executes if $RUN is set to 1 44 | PRE_RUN_SQL = flush status; set global userstat=on; 45 | 46 | #This only executes if $RUN is set to 1 47 | POST_RUN_SQL = show status; select * from information_schema.TABLE_STATISTICS; 48 | 49 | #Cannot be overridden in the different configurations. SQL commands are run prior the whole test 50 | PRE_TEST_SQL = use dbt3; select version(); show variables; show engines; show table status; 51 | 52 | #Cannot be overridden in the different configurations. SQL commands are run after the whole test 53 | POST_TEST_SQL = -------------------------------------------------------------------------------- /dbt3_benchmark/config/s10/mysql_5_5_myisam_my.cnf: -------------------------------------------------------------------------------- 1 | # The following options will be passed to all MySQL clients 2 | [client] 3 | 4 | # Here follows entries for some specific programs 5 | 6 | # The MySQL server 7 | [mysqld] 8 | tmpdir = mysql 9 | net_read_timeout = 300 10 | net_write_timeout = 600 11 | 12 | key_buffer_size = 1G 13 | 14 | skip-external-locking 15 | key_buffer = 16M 16 | max_allowed_packet = 16M 17 | table_open_cache = 1024 18 | thread_cache = 512 19 | sort_buffer_size = 512K 20 | net_buffer_length = 8K 21 | read_buffer_size = 256K 22 | myisam_sort_buffer_size = 8M 23 | max_connections = 256 24 | query_cache_size = 0 25 | query_cache_type = 0 26 | sql-mode = NO_ENGINE_SUBSTITUTION 27 | 28 | join_buffer_size = 512M 29 | tmp_table_size = 32M 30 | max_heap_table_size = 32M 31 | read_rnd_buffer_size = 32M 32 | 33 | 34 | # Don't listen on a TCP/IP port at all. This can be a security enhancement, 35 | # if all processes that need to connect to mysqld run on the same host. 36 | # All interaction with mysqld must be made via Unix sockets or named pipes. 37 | # Note that using this option without enabling named pipes on Windows 38 | # (via the "enable-named-pipe" option) will render mysqld useless! 39 | # 40 | #skip-networking 41 | 42 | # Disable other storage engines 43 | 44 | # required unique id between 1 and 2^32 - 1 45 | # defaults to 1 if master-host is not set 46 | # but will not function as a master if omitted 47 | server-id = 1 48 | 49 | default-storage-engine=MyISAM 50 | 51 | # The safe_mysqld script 52 | [safe_mysqld] 53 | log-error = mysql/mysqld.err 54 | nice = 0 55 | 56 | [mysqldump] 57 | quick 58 | max_allowed_packet = 16M 59 | 60 | [mysql] 61 | #no-auto-rehash 62 | # Remove the next comment character if you are not familiar with SQL 63 | #safe-updates 64 | prompt=[\R:\m] \u@\d> 65 | 66 | [isamchk] 67 | key_buffer = 20M 68 | sort_buffer_size = 20M 69 | read_buffer = 2M 70 | write_buffer = 2M 71 | 72 | [myisamchk] 73 | key_buffer = 20M 74 | sort_buffer_size = 20M 75 | read_buffer = 2M 76 | write_buffer = 2M 77 | 78 | [mysqlhotcopy] 79 | interactive-timeout 80 | -------------------------------------------------------------------------------- /dbt3_benchmark/config/s30/mysql_5_5_myisam_my.cnf: -------------------------------------------------------------------------------- 1 | # The following options will be passed to all MySQL clients 2 | [client] 3 | 4 | # Here follows entries for some specific programs 5 | 6 | # The MySQL server 7 | [mysqld] 8 | tmpdir = mysql 9 | net_read_timeout = 300 10 | net_write_timeout = 600 11 | 12 | key_buffer_size = 3G 13 | 14 | skip-external-locking 15 | key_buffer = 16M 16 | max_allowed_packet = 16M 17 | table_open_cache = 1024 18 | thread_cache = 512 19 | sort_buffer_size = 512K 20 | net_buffer_length = 8K 21 | read_buffer_size = 256K 22 | myisam_sort_buffer_size = 8M 23 | max_connections = 256 24 | query_cache_size = 0 25 | query_cache_type = 0 26 | sql-mode = NO_ENGINE_SUBSTITUTION 27 | 28 | join_buffer_size = 1536M 29 | tmp_table_size = 96M 30 | max_heap_table_size = 96M 31 | read_rnd_buffer_size = 96M 32 | 33 | 34 | # Don't listen on a TCP/IP port at all. This can be a security enhancement, 35 | # if all processes that need to connect to mysqld run on the same host. 36 | # All interaction with mysqld must be made via Unix sockets or named pipes. 37 | # Note that using this option without enabling named pipes on Windows 38 | # (via the "enable-named-pipe" option) will render mysqld useless! 39 | # 40 | #skip-networking 41 | 42 | # Disable other storage engines 43 | 44 | # required unique id between 1 and 2^32 - 1 45 | # defaults to 1 if master-host is not set 46 | # but will not function as a master if omitted 47 | server-id = 1 48 | 49 | default-storage-engine=MyISAM 50 | 51 | # The safe_mysqld script 52 | [safe_mysqld] 53 | log-error = mysql/mysqld.err 54 | nice = 0 55 | 56 | [mysqldump] 57 | quick 58 | max_allowed_packet = 16M 59 | 60 | [mysql] 61 | #no-auto-rehash 62 | # Remove the next comment character if you are not familiar with SQL 63 | #safe-updates 64 | prompt=[\R:\m] \u@\d> 65 | 66 | [isamchk] 67 | key_buffer = 20M 68 | sort_buffer_size = 20M 69 | read_buffer = 2M 70 | write_buffer = 2M 71 | 72 | [myisamchk] 73 | key_buffer = 20M 74 | sort_buffer_size = 20M 75 | read_buffer = 2M 76 | write_buffer = 2M 77 | 78 | [mysqlhotcopy] 79 | interactive-timeout 80 | -------------------------------------------------------------------------------- /dbt3_benchmark/tests/db_conf/db_mariadb_5_5_myisam_igor.conf: -------------------------------------------------------------------------------- 1 | [db_settings] 2 | #Where the instalation folder of MariaDB / MySQL / PostgreSQL is located 3 | DBMS_HOME = $PROJECT_HOME/bin/mariadb-5.5.18-linux-x86_64 4 | DBMS_USER = root 5 | 6 | #The config file that mysqld or postgres will use when starting 7 | CONFIG_FILE = $PROJECT_HOME/mariadb-tools/dbt3_benchmark/config/s$SCALE_FACTOR/mariadb_myisam_no_optimizations_my.cnf 8 | SOCKET = $PROJECT_HOME/temp/mysql.sock 9 | PORT = 12340 10 | HOST = 127.0.0.1 11 | 12 | #Where is the datadir for mysqld or postgres 13 | DATADIR = $DATADIR_HOME/myisam-s$SCALE_FACTOR 14 | 15 | #Where the temp tables will be created while sorting and grouping. 16 | TMPDIR = $PROJECT_HOME/temp 17 | 18 | #The database name that will be used for the test 19 | DBNAME = dbt3 20 | 21 | #This text will be stored into the results database as a keyword. Also will be used as a name for a subfolder with results and statistics. 22 | KEYWORD = mariadb-5-5-18-myisam-igor 23 | 24 | #Database Management System that will be used. Possible values: "MySQL", "MariaDB" and "PostgreSQL" 25 | DBMS = MariaDB 26 | 27 | #The storage engine that was used 28 | STORAGE_ENGINE = MyISAM 29 | 30 | #Any startup parameters that will be used while starting the mysqld process or postgres process 31 | STARTUP_PARAMS = 32 | 33 | #The heading of the graphic 34 | GRAPH_HEADING = MariaDB 5.5.18 + MyISAM with Igor optimizations 35 | 36 | READ_ONLY = 1 37 | MYSQL_SYSTEM_DIR= $DATADIR_HOME/myisam-s$SCALE_FACTOR/mysql_mariadb_5_5/ 38 | 39 | 40 | 41 | 42 | 43 | #This only executes if $RUN is set to 1 44 | PRE_RUN_SQL = flush status; set global userstat=on; 45 | 46 | #This only executes if $RUN is set to 1 47 | POST_RUN_SQL = show status; select * from information_schema.TABLE_STATISTICS; 48 | 49 | #Cannot be overridden in the different configurations. SQL commands are run prior the whole test 50 | PRE_TEST_SQL = use dbt3; select version(); show variables; show engines; show table status; 51 | 52 | #Cannot be overridden in the different configurations. SQL commands are run after the whole test 53 | POST_TEST_SQL = --------------------------------------------------------------------------------