summaryrefslogtreecommitdiff
path: root/rt/bin/initacls.mysql
blob: 17e63f837bb270dd209658870305f9339415ced1 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
#!/bin/sh

DATABASEHOME=$1
HOSTNAME=$2
PORT=$3
DATABASEADMIN=$4
DBAPASSWD=$5
DATABASENAME=$6
DATABASEACLS=$7

BINDIR=${DATABASEHOME}/bin

PATH=$PATH:$BINDIR
export PATH

echo "Enter the mysql administrator's database password to create a new user for RT"
$BINDIR/mysql --host=${HOSTNAME} --port=${PORT} --user=${DATABASEADMIN} -p${DBAPASSWD} mysql < $DATABASEACLS

echo "Enter the mysql administrator's database password to nondestructively reload the database"
$BINDIR/mysqladmin --host=${HOSTNAME} --port=${PORT} --user=${DATABASEADMIN} -p${DBAPASSWD} reload