summaryrefslogtreecommitdiffstats
path: root/release
diff options
context:
space:
mode:
authorluigi <luigi@FreeBSD.org>2001-09-27 16:47:45 +0000
committerluigi <luigi@FreeBSD.org>2001-09-27 16:47:45 +0000
commit244185f0058d6d0175de21e0f0264ab95c980086 (patch)
tree00003c1f1f47f6d19b21d405ccb2a8f6950d0742 /release
parent0523beb4c1c8a29a42379367f852eafce4dc70c9 (diff)
downloadFreeBSD-src-244185f0058d6d0175de21e0f0264ab95c980086.zip
FreeBSD-src-244185f0058d6d0175de21e0f0264ab95c980086.tar.gz
Enable the use of wildcards in the #ethertable section of
/etc/hosts to map MAC addresses to hostnames. Main use is to get addresses for vmware interfaces.
Diffstat (limited to 'release')
-rw-r--r--release/picobsd/floppy.tree/etc/rc.conf11
1 files changed, 7 insertions, 4 deletions
diff --git a/release/picobsd/floppy.tree/etc/rc.conf b/release/picobsd/floppy.tree/etc/rc.conf
index d597aa8..1e854f6 100644
--- a/release/picobsd/floppy.tree/etc/rc.conf
+++ b/release/picobsd/floppy.tree/etc/rc.conf
@@ -47,10 +47,13 @@ hostname=""
while read a b c ; do
if [ "$a" = "#ethertable" ] ; then
hostname="."
- elif [ "X$hostname" = "X." -a "X$a" = "X#" -a "X$b" = "X$main_ether" ]
- then
- hostname=$c
- break
+ elif [ "X$hostname" = "X." -a "X$a" = "X#" ] ; then
+ case X${main_ether} in
+ X${b} ) # so we can use wildcards
+ hostname=$c
+ break
+ ;;
+ esac
fi
done < /etc/hosts
if [ "X$hostname" = "X" -o "X$hostname" = "X." ] ; then
OpenPOWER on IntegriCloud