scripts/setup/read_plus.zsh
Anna Schumaker 3428879918 Move setup-* and run-* scripts into subdirectories
The common prefixes in these scripts indicate that they should really be
in directories and not the toplevel. I also provide a helper script in
$BIN to assist in calling them on the target VMs

Signed-off-by: Anna Schumaker <Anna.Schumaker@Netapp.com>
2022-04-26 10:33:01 -04:00

23 lines
420 B
Bash
Executable File

#!/bin/zsh
SERVER=$1
EXPORT=$2
MOUNTPOINT=$3/read_plus
USER=$4
SIZE=$5
CHUNKS=$6
if [ "$#" -ne 6 ]; then
echo "Usage: $0 {server} {export} {mountpoint} {user} {size} {chunks}"
exit 1
fi
mkdir -p $MOUNTPOINT
mount -o sec=sys $SERVER:$EXPORT $MOUNTPOINT
TRAPEXIT() {
sudo umount -f $MOUNTPOINT
}
mkdir -p -m 777 $MOUNTPOINT/$USER/read_plus
bin/setup/read_plus-files.py $MOUNTPOINT/$USER/read_plus $SIZE $CHUNKS
sync