[转帖]Automated MySQL cluster DBT2 testing_MySQL, Oracle及数据库讨论区_Weblogic技术|Tuxedo技术|中间件技术|Oracle论坛|JAVA论坛|Linux/Unix技术|hadoop论坛_联动北方技术论坛  
网站首页 | 关于我们 | 服务中心 | 经验交流 | 公司荣誉 | 成功案例 | 合作伙伴 | 联系我们 |
联动北方-国内领先的云技术服务提供商
»  游客             当前位置:  论坛首页 »  自由讨论区 »  MySQL, Oracle及数据库讨论区 »
总帖数
1
每页帖数
101/1页1
返回列表
0
发起投票  发起投票 发新帖子
查看: 2529 | 回复: 0   主题: [转帖]Automated MySQL cluster DBT2 testing        下一篇 
fendy
注册用户
等级:新兵
经验:51
发帖:58
精华:0
注册:2011-7-21
状态:离线
发送短消息息给fendy 加好友    发送短消息息给fendy 发消息
发表于: IP:您无权察看 2014-12-16 15:27:12 | [全部帖] [楼主帖] 楼主

Here is a lot of issues with the DBT2 which is downloaded from mysql's website.
I still got error after I have fixed 8 bugs:
./configure --prefix=$HOME/dbt2 --with-mysql=/mysql/mysqlc/
fix bug 1:path is incorrect
vi create_dbt2_files.sh
line 160: change path 'scr' to 'bin'
fix bug 2:default user is root
vi start_ndb.sh
line 255: change MYSQL_USER='root' MYSQL_USER=$USER
fix bug 3:remove the support of postgresql
vi configure.ac
Remove the lines 434~443
fix bug 4:ERROR: ld.so: object 'libtcmalloc_minimal.so.0' from LD_PRELOAD cannot be preloaded: ignored.
remove the definition of MALLOC_LIB
grep -n libtcmalloc_minimal *
bench_prepare.sh:1429:MALLOC_LIB="/usr/lib64/libtcmalloc_minimal.so.0"
run_oltp.sh:865:MALLOC_LIB="/usr/lib64/libtcmalloc_minimal.so.0"
start_ndb.sh:279:MALLOC_LIB="/usr/lib64/libtcmalloc_minimal.so"
tar cvf dbt2-0.37.50.tar dbt2-0.37.50
rm -f dbt2-0.37.50.tar.gz; gizp dbt2-0.37.50.tar
fix bug:ERROR 157 (HY000) at line 1: Could not connect to storage engine
fix bug 4:missing errmsg.sys
tar -zxf mysql-cluster-gpl-7.1.18-linux-x86_64-glibc23.tar.gz
(cd mysql-cluster-gpl-7.1.18-linux-x86_64-glibc23/share;cp -R english mysql)
tar cf mysql-cluster-gpl-7.1.18-linux-x86_64-glibc23.tar mysql-cluster-gpl-7.1.18-linux-x86_64-glibc23
rm mysql-cluster-gpl-7.1.18-linux-x86_64-glibc23.tar.gz
gzip mysql-cluster-gpl-7.1.18-linux-x86_64-glibc23.tar
fix bug 5: default configure location
mkdir -p /usr/local/mysql/mysql-cluster
chown vincenthe.mysql /usr/local/mysql/mysql-cluster
chmod 775 /usr/local/mysql/mysql-cluster
fix bug 6: numactl: command not found
yum install numactl
numactl --show
numactl --hardware
TASKSET="numactl"
SERVER_CPUS="0,2,4,6,8,10" #CPU bind, the range should be in the list of 'numactl --show'
SERVER_BIND="0" #node bind, #bind the CPUs, the range should be in the list of 'numactl --show'
SERVER_MEM_POLICY="interleaved"
BENCHMARK_CPUS="1,3,5,7,9,11"
BENCHMARK_BIND="1"
BENCHMARK_MEM_POLICY="local"
fix bug 7: automake: command not found
yum install automake
Try running a 2 data node cluster on 'localhost'/one server first and see if you can make it run.
$ mkdir bench; cd bench
$ mkdir tarballs dbt2_data ndb_data
wget
$ cp mysql-cluster-gpl-7.1.18-linux-x86_64-glibc23.tar.gz tarballs/
$ cp dbt2-0.37.50.tar.gz tarballs/
$ tar -zvf dbt2-0.37.50.tar.gz
$ cp dbt2-0.37.50/scripts/bench_prepare.sh .
$ cp dbt2-0.37.50/examples/autobench.conf .
Edit autobench.conf
*********
BENCHMARK_TO_RUN="dbt2"
TARBALL_DIR="/home/vincent/bench/tarballs"
MYSQL_VERSION="mysql-cluster-gpl-7.1.18-linux-x86_64-glibc23"
#You must add this line if the mysql tarball is not binary
USE_BINARY_MYSQL_TARBALL="no"
#DRIZZLE_VERSION="drizzle-2009.11.1208"
#LIBDRIZZLE_VERSION="libdrizzle-0.5"
#SYSBENCH_VERSION="sysbench-0.4.13"
DBT2_VERSION="dbt2-0.37.50"
SERVER_HOST="127.0.0.1"
SERVER_PORT="3306"
DATA_DIR_BASE="/home/vincent/bench/ndb_data"
#WINDOWS_REMOTE="no"
#BUILD_REMOTE="no"
#REMOTE_BIN_INSTALL_DIR="/data1/bench/mysql"
#REMOTE_SRC_INSTALL_DIR="/data1/bench/src_build"
ENGINE="ndb"
MYSQL_BASE="5.1"
TEST_DESCRIPTION="mysql-cluster-7.1.18"
USE_NDBMTD="yes"
#On some systems it's hard to use pid files on the file system (e.g. NFS)
NDB_MGMD_NODES="127.0.0.1"
NDBD_NODES="127.0.0.1;127.0.0.1"
SERVER_HOST="127.0.0.1"
NDB_MULTI_CONNECTION="2"
NDB_REPLICAS="2"
NDB_DATA_MEMORY="3G"
NDB_INDEX_MEMORY="300M"
#TASKSET="numactl"
#SERVER_CPUS=""
#SERVER_BIND="2-7"
#SERVER_MEM_POLICY="interleaved"
#BENCHMARK_CPUS=""
#BENCHMARK_BIND="0-1"
#BENCHMARK_MEM_POLICY="local"
*********
Leave other params commented out for now/use defaults.
$ cp autobench.conf dbt2_data/
Build the dbt2 binaries so that you can create the dbt2 dataset.
mkdir $HOME/dbt2
$ dbt2-0.37.50/scripts/create_dbt2_files.sh --base_dir /home/vincenthe/dbt2 \
--data_dir ~/bench/dbt2_data --num_warehouses 10
Run the test
======================================
./bench_prepare.sh --skip-build-remote --default-directory /home/vincenthe/bench/dbt2_data
./bench_prepare.sh --help
There are 5 stages in this execution:
1) Create config files for the various scripts used
2) Build sysbench, DBT2 and MySQL locally
3) Build MySQL remotely
4) Execute test
5) Cleanup after test
Parameters:
-----------
--default-directory : Directory where autobench.conf is placed, this
directory is also used to place builds, results
and other temporary storage needed to run the
test.
--skip-build-local : Skip building locally
--skip-build-remote : Skip building remotely
--skip-test : Skip running test completely
--skip-run : Skip execute test
--skip-start : Skip start/stop MySQL Server/Cluster
--skip-stop : Skip stop MySQL Server/Cluster
--skip-cleanup : Skip cleanup phase
--generate-dbt2-data : Generate load files for DBT2 benchmark, can only
be done in conjunction with build locally
======================================
I think these scripts have been primarily tested with building mysql binaries from source as part of the test. You
might have less issues if you use the mysql source instead of the binary package.
Using the mysql binary package there is at least on difference in where some localization files are stored
compared the source build.
Check if you have 'mysql-cluster-gpl-7.1.18-linux-x86_64-glibc23/share/english/error.msg'. If you do you might
need to create this directory structure instead: mysql-cluster-gpl-7.1.18-linux-x86_64-
glibc23/share/mysql/english/error.msg
And then create a new mysql-cluster-gpl-7.1.18-linux-x86_64-glibc23.tar.gz and put it into the 'tarballs' folder.
I hope this will help you get further in your efforts to run these dbt2 tests and that you are able to engage our
PS as soon as possible.
tar -zxf mysql-cluster-gpl-7.1.18-linux-x86_64-glibc23.tar.gz
(cd mysql-cluster-gpl-7.1.18-linux-x86_64-glibc23/share;cp -R english mysql)
tar cf mysql-cluster-gpl-7.1.18-linux-x86_64-glibc23.tar mysql-cluster-gpl-7.1.18-linux-x86_64-glibc23
rm mysql-cluster-gpl-7.1.18-linux-x86_64-glibc23.tar.gz
gzip mysql-cluster-gpl-7.1.18-linux-x86_64-glibc23.tar
================================
Failed to create directory '/usr/local/mysql/mysql-cluster', error: 2
-- Could not create directory '/usr/local/mysql/mysql-cluster'
Either create it manually or specify a different directory with --configdir=<path>
Failed with script
/home/vincenthe/bench/dbt2_data/src/dbt2-0.37.50/scripts/start_ndb.sh\
--default-directory /home/vincenthe/bench/dbt2_data --ssh_port 22 --cluster_id 1 \
--home-base /home/vincenthe --ndb_mgmd --nodeid 1 --initial 127.0.0.1
using parameters
mkdir -p /usr/local/mysql/mysql-cluster
chown vincenthe.mysql /usr/local/mysql/mysql-cluster
chmod 775 /usr/local/mysql/mysql-cluster


这个是mysql官方发布的那个dbt2,我拿来测试cluster,没用自动化,只用的run_mysql.sh这个脚本去压,但 只能看到连接建立了,show processlist 看不到sql执行,最后结果也都是0. 你遇到过么

--转自 北京联动北方科技有限公司




赞(0)    操作        顶端 
总帖数
1
每页帖数
101/1页1
返回列表
发新帖子
请输入验证码: 点击刷新验证码
您需要登录后才可以回帖 登录 | 注册
技术讨论