Commit a5386a06 authored by Mike Hibler's avatar Mike Hibler

Forgot half of the previous client-side change for disabled interfaces.

parent 30cbf0df
......@@ -511,6 +511,8 @@ fixone() {
export SLICEFIX_CONSOLE=`getvar CONSOLE "$iline" unknown`
export SLICEFIX_BIOSDISK=`getvar BIOSDISK "$iline"`
export SLICEFIX_DOM0MEM=`getvar DOM0MEM "$iline" unknown`
export SLICEFIX_DISABLEIF=`getvar DISABLEIF "$iline" unknown`
$BINDIR/slicefix $PART $DISK
return $?
}
......
......@@ -457,6 +457,8 @@ fixone() {
export SLICEFIX_CONSOLE=`getvar CONSOLE "$iline" unknown`
export SLICEFIX_BIOSDISK=`getvar BIOSDISK "$iline"`
export SLICEFIX_DOM0MEM=`getvar DOM0MEM "$iline" unknown`
export SLICEFIX_DISABLEIF=`getvar DISABLEIF "$iline" unknown`
$BINDIR/slicefix $PART $DISK
return $?
}
......
#!/bin/sh
#
# Copyright (c) 2000-2014 University of Utah and the Flux Group.
# Copyright (c) 2000-2015 University of Utah and the Flux Group.
#
# {{{EMULAB-LICENSE
#
......@@ -136,6 +136,22 @@ if [ -n "$BIOSDISK" ]; then
esac
fi
#
# See if we need to exclude the management interface.
# If an interface is specified and we can parse, create the "hint"
# line for loader.conf.
#
DISABLEIF=$SLICEFIX_DISABLEIF
DISABLEHINT=
if [ -n "$DISABLEIF" ]; then
_str=`echo $DISABLEIF | sed -E -e 's/^([a-zA-Z0-9]*[a-zA-Z])([0-9]+)/hint.\1.\2.disabled/'`
if [ "$_str" = "$DISABLEIF" ]; then
echo "WARNING: unparsable define name \"$DISABLEIF\" ignored"
else
DISABLEHINT=$_str
fi
fi
#
# Find out what our console should be:
# if $CONSOLE is set and valid, use that
......@@ -320,6 +336,11 @@ dofreebsd() {
fixit=1
fi
# Disable mgmt interface?
if [ -n "$DISABLEHINT" ]; then
fixit=1
fi
# If our disk/part does not appear anywhere in fstab, we need to fix it
grep "^/dev/${freebsd_disk}s${part}" /mnt/etc/fstab >/dev/null 2>&1
case $? in
......@@ -640,6 +661,16 @@ EOF2
fi
fi
#
# Disable the management interface in the OS.
#
if [ -n "$DISABLEHINT" ]; then
cat <<EOF0
# disable dedicated management interface
$DISABLEHINT="1"
EOF0
fi
#
# Fix up console.
# null and vga are easy, just set console={null,vid}console
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment