3 trap 'echo "$0:$LINENO:error: \"$BASH_COMMAND\" returned $?" >&2' ERR
6 [[ $EUID == 0 ]] ||
exec sudo
-E "$BASH_SOURCE" "$@"
11 ip
=$
(host demohost |
sed -rn 's/^\S+ has address //p;T;q')/32
12 cedit demohost
/etc
/exports
<<EOF || exportfs -ra
13 /a $ip(async,rw,no_subtree_check,no_root_squash)
14 /q $ip(async,rw,no_subtree_check,no_root_squash)
18 ssh root@demohost bash
-s <<'EOFOUTER'
21 apt-get install -y nfs-common
23 sed -ri '\%^(faiserver:/[aq]|/q/p)\s%d' /etc/fstab
24 cat >>/etc/fstab <<'EOF'
25 faiserver:/a /a nfs defaults 0 0
26 faiserver:/q /q nfs defaults 0 0