1#! /bin/sh
2#
3# Build the configuration file for multithreaded tests --
4#	We do this work in the shell script because we have to fill in
5#	lots of shell variables.
6#
7# Usage: ./multi_tuxconfig.sh <IPCKEY>
8
9if test $# -ne 1; then
10    echo "Usage: ./multi_1thr_tuxconfig.sh <IPCKEY>\n"
11    exit 1
12fi
13
14
15	IPCKEY=$1
16	MACHINE_NAME=`uname -n`
17	cat > $RUN/config/ubb.cfg << END_OF_UBB_FILE
18*RESOURCES
19IPCKEY		$IPCKEY
20DOMAINID	domain3
21MASTER		cluster3
22MAXACCESSERS	16
23MAXSERVERS	6
24MAXSERVICES	16
25MODEL		SHM
26LDBAL		N
27
28*MACHINES
29DEFAULT:
30		APPDIR="$APPDIR"
31		TUXCONFIG="$TUXCONFIG"
32		TLOGDEVICE="$TLOGDEVICE"
33		TUXDIR="$TUXDIR"
34# Machine name is 30 characters max
35"$MACHINE_NAME"	LMID=cluster3
36
37*GROUPS
38# Group name is 30 characters max
39group_tm	LMID=cluster3 GRPNO=1 TMSNAME=DBRM TMSCOUNT=2 OPENINFO="BERKELEY-DB:$RUN/data"
40
41*SERVERS
42DEFAULT:
43		CLOPT="-A"
44		MINDISPATCHTHREADS=1
45		MAXDISPATCHTHREADS=8
46
47# Server name is 78 characters max (same for any pathname)
48server1		SRVGRP=group_tm SRVID=1 MAXGEN=3 RESTART=Y
49
50*SERVICES
51DEFAULT:
52		SVCTIMEOUT=20
53# Service name is 15 characters max
54# server1
55read_db1
56write_db1
57
58END_OF_UBB_FILE
59	tmloadcf -y $RUN/config/ubb.cfg
60