source: fedkit/federate.sh @ 61f19e0

axis_examplecompt_changesinfo-opsversion-1.30version-2.00version-3.01version-3.02
Last change on this file since 61f19e0 was 61f19e0, checked in by Ted Faber <faber@…>, 17 years ago

client SMB and account scripts

  • Property mode set to 100755
File size: 915 bytes
Line 
1#!/bin/sh
2
3BOSSNODE="/usr/local/etc/emulab/bossnode"
4# GATEWAY="detertunnel"
5
6if [ -f $BOSSNODE ]
7then
8        rm -f $BOSSNODE
9fi
10
11EMUDIR="/usr/local/etc/emulab/"
12GATEWAY=`$EMUDIR/tmcc -b syncserver | awk ' { match($0, /SERVER=[^[:space:]]+/); print substr($0,RSTART+8,RLENGTH-9);}'`
13
14PORTS="139 7777"
15NC="/usr/bin/nc"
16RCDIR="/usr/local/etc/emulab/rc"
17
18RCACCT="rc.accounts"
19SMBMOUNT="smbmount.pl"
20
21#
22# Spin on our gateway!
23#
24
25echo "Waiting for the tunnel to come online."
26
27for port in $PORTS
28do
29        until $NC -z $GATEWAY $port
30        do
31                sleep 5
32        done
33done
34
35#
36# Setup TMCC to use our gateway
37#
38
39echo "Configuring TMCC."
40
41$EMUDIR/sethostname
42
43echo $GATEWAY > $BOSSNODE
44
45#
46# Unmount stuff before messing with accounts
47#
48umount -A -f -t nfs,smbfs
49
50
51#
52# Setup new accounts
53#
54$RCDIR/rc.accounts reconfig
55
56#
57# Copy and exec the smbmount perl script
58#
59
60echo "Mounting via SMB."
61
62exec $EMUDIR/$SMBMOUNT
Note: See TracBrowser for help on using the repository browser.