diff --git a/clientside/configure b/clientside/configure
index 529ea8f791f4fc0b2e0d793e8645ceda61a10c3c..08894df33aab63b164b24090bb193e51e5825c00 100755
--- a/clientside/configure
+++ b/clientside/configure
@@ -3858,7 +3858,49 @@ fi
if test -z "$YACC" ; then
- as_fn_error $? "no byacc found in \$PATH" "$LINENO" 5
+ # Extract the first word of "yacc", so it can be a program name with args.
+set dummy yacc; ac_word=$2
+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
+$as_echo_n "checking for $ac_word... " >&6; }
+if ${ac_cv_path_YACC+:} false; then :
+ $as_echo_n "(cached) " >&6
+else
+ case $YACC in
+ [\\/]* | ?:[\\/]*)
+ ac_cv_path_YACC="$YACC" # Let the user override the test with a path.
+ ;;
+ *)
+ as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
+for as_dir in $PATH
+do
+ IFS=$as_save_IFS
+ test -z "$as_dir" && as_dir=.
+ for ac_exec_ext in '' $ac_executable_extensions; do
+ if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
+ ac_cv_path_YACC="$as_dir/$ac_word$ac_exec_ext"
+ $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
+ break 2
+ fi
+done
+ done
+IFS=$as_save_IFS
+
+ ;;
+esac
+fi
+YACC=$ac_cv_path_YACC
+if test -n "$YACC"; then
+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: $YACC" >&5
+$as_echo "$YACC" >&6; }
+else
+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
+$as_echo "no" >&6; }
+fi
+
+
+ if test -z "$YACC" ; then
+ as_fn_error $? "no byacc nor yacc found in \$PATH" "$LINENO" 5
+ fi
fi
# Extract the first word of "tar", so it can be a program name with args.
set dummy tar; ac_word=$2
@@ -4575,6 +4617,7 @@ outfiles="Makeconf GNUmakefile setversion \
tmcc/ubuntu16/GNUmakefile \
tmcc/ubuntu16-ms/GNUmakefile \
tmcc/linux-ms/GNUmakefile \
+ tmcc/archlinux/GNUmakefile \
tmcc/freebsd5/GNUmakefile tmcc/freebsd5/supfile \
tmcc/freebsd6/GNUmakefile tmcc/freebsd6/supfile \
tmcc/freebsd6/netif-emulab \
diff --git a/clientside/configure.ac b/clientside/configure.ac
index 6b26a19c4eeabc087ffc08041f2878dad68c9c4d..2e28806bc291b2a1e29b5dcb5367f5737b8fd353 100644
--- a/clientside/configure.ac
+++ b/clientside/configure.ac
@@ -55,7 +55,10 @@ if test -z "$CP" ; then
fi
AC_PATH_PROG(YACC, byacc)
if test -z "$YACC" ; then
- AC_MSG_ERROR([no byacc found in \$PATH])
+ AC_PATH_PROG(YACC, yacc)
+ if test -z "$YACC" ; then
+ AC_MSG_ERROR([no byacc nor yacc found in \$PATH])
+ fi
fi
AC_PATH_PROG(TAR, tar)
if test -z "$TAR" ; then
@@ -302,6 +305,7 @@ outfiles="Makeconf GNUmakefile setversion \
tmcc/ubuntu16/GNUmakefile \
tmcc/ubuntu16-ms/GNUmakefile \
tmcc/linux-ms/GNUmakefile \
+ tmcc/archlinux/GNUmakefile \
tmcc/freebsd5/GNUmakefile tmcc/freebsd5/supfile \
tmcc/freebsd6/GNUmakefile tmcc/freebsd6/supfile \
tmcc/freebsd6/netif-emulab \
diff --git a/clientside/tmcc/GNUmakefile.in b/clientside/tmcc/GNUmakefile.in
index 99b6694bce2e7f8edc95d63ce9cbfabe4efd53ae..c1f606c910ac57e17f9f10e0659bebf8bc5779fb 100644
--- a/clientside/tmcc/GNUmakefile.in
+++ b/clientside/tmcc/GNUmakefile.in
@@ -109,6 +109,11 @@ endif
ifeq ($(MDSUBDIR),debian8)
MDSUBDIR = ubuntu15
endif
+# We don't want to have a dir named "arch"; that would be confusing.
+# Hence archlinux.
+ifeq ($(MDSUBDIR),arch)
+MDSUBDIR = archlinux
+endif
ifeq ($(findstring fedora,$(MDSUBDIR)),fedora)
ifeq ($(MDREL),15)
MDSUBDIR = fedora15
diff --git a/clientside/tmcc/archlinux/05-emulab-early-dhcpcd-hook b/clientside/tmcc/archlinux/05-emulab-early-dhcpcd-hook
new file mode 100644
index 0000000000000000000000000000000000000000..d950ea026a77a4cc99160032015f829b142994a6
--- /dev/null
+++ b/clientside/tmcc/archlinux/05-emulab-early-dhcpcd-hook
@@ -0,0 +1,138 @@
+#!/bin/sh
+#
+# Copyright (c) 2004-2017 University of Utah and the Flux Group.
+#
+# {{{EMULAB-LICENSE
+#
+# This file is part of the Emulab network testbed software.
+#
+# This file is free software: you can redistribute it and/or modify it
+# under the terms of the GNU Affero General Public License as published by
+# the Free Software Foundation, either version 3 of the License, or (at
+# your option) any later version.
+#
+# This file is distributed in the hope that it will be useful, but WITHOUT
+# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
+# FITNESS FOR A PARTICULAR PURPOSE. See the GNU Affero General Public
+# License for more details.
+#
+# You should have received a copy of the GNU Affero General Public License
+# along with this file. If not, see .
+#
+# }}}
+#
+. /etc/emulab/paths.sh
+
+echo "`date`: ${interface}: ${reason}" >>$LOGDIR/dhclient-enter.log 2>&1
+
+#
+# XXX Hack to force the duplex on interfaces
+#
+setduplex() {
+ _if=$1
+ _rc=0
+
+ if [ -x /sbin/ethtool ]; then
+ _ethtool=/sbin/ethtool
+ else
+ _ethtool=/usr/sbin/ethtool
+ fi
+
+ _out=`$_ethtool $_if`
+ if [ $? -eq 0 ]; then
+ _hmb=`echo $_out | grep -c 'Speed: 100Mb/s'`
+ _fdx=`echo $_out | grep -c 'Duplex: Full'`
+ else
+ _out=`/sbin/mii-tool $_if`
+ _hmb=`echo $_out | grep -c '100 Mbit'`
+ _fdx=`echo $_out | grep -c 'full duplex'`
+ fi
+
+ if [ $_hmb -ne 0 -a $_fdx -ne 0 ]; then
+ echo "$_if: speed/duplex correct"
+ else
+ echo -n "$_if: fixing speed/duplex..."
+ if $_ethtool $_if >/dev/null 2>&1; then
+ $_ethtool -s $_if autoneg off speed 100 duplex full
+ else
+ /sbin/mii-tool --force=100baseTx-FD $_if
+ fi
+ _rc=$?
+ echo "returns $_rc"
+ fi
+ return $_rc
+}
+
+#
+# Since dhcpcd doesn't support hook-based rejection of an offer, we have
+# to handle the elabinelab case differently. We just use iptables to
+# block DHCP offers from the outer emulab boss, and HUP dhcpcd, which
+# should force it to rebind.
+#
+fatal_block_source() {
+ echo "`date`: ${interface}: received bogus offer from $new_dhcp_server_identifier; blocking and forcing rebind in process $pid" >> $LOGDIR/dhclient-enter.log
+
+ iptables -A INPUT -p udp -s $new_dhcp_server_identifier --sport 67 -j DROP
+
+ kill -HUP $pid &
+
+ # This will exit the entire script execution, since we are just
+ # source'd into the hook script runner.
+ exit 1
+}
+
+#
+# Only do our checks and duplex-forcing if the interface is up and we're
+# in the right protocol state.
+#
+if [ ! $if_up ]
+then
+ # do nothing if the interface isn't coming up
+ echo "`date`: ${interface}: ${reason}: interface not up, ignoring" >>$LOGDIR/dhclient-enter.log 2>&1
+ true
+elif [ x$reason != xREBOOT -a x$reason != xBOUND -a x$reason != xRENEW -a x$reason != xREBIND ]
+then
+ # do nothing
+ echo "`date`: ${interface}: ${reason}: ignoring" >>$LOGDIR/dhclient-enter.log 2>&1
+ true
+elif [ x"$new_domain_name_servers" = "x1.1.1.1" ]; then
+ #
+ # ElabinElab support.
+ #
+ # XXX oh so hacky. Real boss is set to return 1.1.1.1 as a name server
+ # for nodes in inner elabs. This is the hack de jour for determining
+ # who has responded to our DHCP request. If it is outer boss and we are
+ # an inner node, we want to decline this offer and not configure the
+ # interface
+ #
+
+ #
+ # XXX since we now know that we are in an inner elab and we know which
+ # interface is the real control net, we force 100Mb full-duplex on all
+ # other (experimental) interfaces. This is necessary to ensure a
+ # response from the inner control net.
+ #
+ for _if in `ifconfig -s | awk '{ print $1 }' | grep -v Iface`
+ do
+ if [ $_if != "lo" -a x$_if != x$interface ]; then
+ setduplex $_if >>$LOGDIR/dhclient-enter.log 2>&1
+ fi
+ done
+
+ #
+ # Ignore the offer.
+ #
+ fatal_block_source
+elif [ "$new_network_number" = "10.200.1.0" ]; then
+ #
+ # XXX sometime we can get a reply even if the duplex is wrong.
+ # If we get such a reply and we are inside an inner elab, again
+ # force 100Mb full-duplex to make sure we continue to communicate
+ # with the server.
+ #
+ setduplex $interface >>$LOGDIR/dhclient-enter.log 2>&1
+fi
+
+echo "`date`: ${interface}: ${reason}: done" >>$LOGDIR/dhclient-enter.log 2>&1
+
+
diff --git a/clientside/tmcc/archlinux/99-emulab-late-dhcpcd-hook b/clientside/tmcc/archlinux/99-emulab-late-dhcpcd-hook
new file mode 100644
index 0000000000000000000000000000000000000000..17fc3cf52d4e5bed9b27c90f7db7e1417b3e310e
--- /dev/null
+++ b/clientside/tmcc/archlinux/99-emulab-late-dhcpcd-hook
@@ -0,0 +1,135 @@
+#!/bin/sh
+#
+# Copyright (c) 2000-2017 University of Utah and the Flux Group.
+#
+# {{{EMULAB-LICENSE
+#
+# This file is part of the Emulab network testbed software.
+#
+# This file is free software: you can redistribute it and/or modify it
+# under the terms of the GNU Affero General Public License as published by
+# the Free Software Foundation, either version 3 of the License, or (at
+# your option) any later version.
+#
+# This file is distributed in the hope that it will be useful, but WITHOUT
+# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
+# FITNESS FOR A PARTICULAR PURPOSE. See the GNU Affero General Public
+# License for more details.
+#
+# You should have received a copy of the GNU Affero General Public License
+# along with this file. If not, see .
+#
+# }}}
+#
+. /etc/emulab/paths.sh
+
+update_emulab_state() {
+ #
+ # Remember our server IP, real hostname, router IP, etc.
+ #
+ echo $new_dhcp_server_identifier > $BOOTDIR/bossip
+ echo $new_host_name > $BOOTDIR/realname
+ echo $new_routers > $BOOTDIR/routerip
+ echo $new_ip_address > $BOOTDIR/myip
+ echo $new_subnet_mask > $BOOTDIR/mynetmask
+ echo $new_domain_name > $BOOTDIR/mydomain
+ if [ -n "$interface" ]; then
+ echo $interface > $BOOTDIR/controlif
+ fi
+
+ #
+ # For Xen-based vnodes we record the vnode name where the scripts expect it.
+ # XXX this works because only Xen-based vnodes DHCP.
+ #
+ case "$new_host_name" in
+ pcvm*)
+ echo $new_host_name > $BOOTDIR/vmname
+ ;;
+ esac
+
+ #
+ # If this is a newnode boot, boss (inner or outer) will have returned with
+ # no hostname. We don't need to record anything in this case, so skip it.
+ #
+ if [ x"$new_host_name" = x ]; then
+ return
+ fi
+
+ #
+ # We have observed problems where changing the speed/duplex of a link
+ # leaves DNS a little wonky. So we whack on it til it responds so that
+ # the sethostname script won't fail.
+ #
+ if [ "$new_network_number" = "10.200.1.0" ]; then
+ for i in 0 1 2; do
+ if `$BINDIR/tmcc bossinfo >/dev/null 2>&1`; then
+ break
+ fi
+ echo "`date`: ${interface}: waiting for DNS.." >>$LOGDIR/dhclient-exit.log 2>&1
+ sleep $i
+ done
+ fi
+
+ #
+ # resolvconf on Linux also breaks DNS momentarily via dhclient exit
+ # hook, or something. On Ubuntu 16, resolvconf is setup to run via
+ # dhclient enter hook (the hook redefines make_resolv_conf, which
+ # dhclient-script eventually executes prior to the exit hook execution).
+ # For whatever reason, though, sometimes when our exit hook (this
+ # script) runs, /etc/resolv.conf is a dangling symlink. I was not able
+ # to find the source of the asynch behavior, so I can't say for sure.
+ # But sethostname.dhclient is an immediate casualty, because it calls
+ # tmcc bossinfo(), and the tmcc binary attempts to use res_init and read
+ # the resolver and use that as boss. If there is no /etc/resolv.conf
+ # (or it is a broken symlink into /run, as it is on resolvconf systems
+ # before resolvconf runs for the first time on boot), res_init will
+ # return localhost, and there is no way for us in tmcc to know that is
+ # inappropriate (taking the res_init resolver might not be the best
+ # choice, but we do not dare to add a special-case rejection of
+ # localhost in tmcc... you never know what crazy proxy schemes might
+ # arise in the future).
+ #
+ if [ -x /sbin/resolvconf ]; then
+ rcwaittime=0
+ while [ ! -f `readlink -f /etc/resolv.conf` -a $rcwaittime -lt 5 ]; do
+ echo "`date`: waiting for /etc/resolv.conf to exist..." >>$LOGDIR/dhclient-exit.log 2>&1
+ sleep 1
+ rcwaittime=`expr $rcwaittime + 1`
+ done
+ if [ ! -f `readlink -f /etc/resolv.conf` ]; then
+ echo "*** WARNING: /etc/resolv.conf does not exist; this will likely cause problems!" >>$LOGDIR/dhclient-exit.log 2>&1
+ fi
+ fi
+
+ #
+ # See if the Testbed configuration software wants to change the hostname.
+ #
+ $BINDIR/sethostname.dhclient >>$LOGDIR/dhclient.log 2>&1
+
+ #
+ # Let the ifup-wait-emulab-cnet.service systemd service know that
+ # the control net is up.
+ #
+ touch /var/run/cnet
+}
+
+echo "`date`: ${interface}: ${reason}" >>$LOGDIR/dhclient-exit.log 2>&1
+
+#
+# Only update our state for an up interface in the right protocol state.
+#
+if [ ! $if_up ]
+then
+ # do nothing if the interface isn't coming up
+ echo "`date`: ${interface}: ${reason}: interface not up, ignoring" >>$LOGDIR/dhclient-exit.log 2>&1
+ true
+elif [ x$reason != xREBOOT -a x$reason != xBOUND -a x$reason != xRENEW -a x$reason != xREBIND ]
+then
+ # do nothing
+ echo "`date`: ${interface}: ${reason}: ignoring" >>$LOGDIR/dhclient-enter.log 2>&1
+ true
+else
+ update_emulab_state
+fi
+
+echo "`date`: ${interface}: ${reason}: done" >>$LOGDIR/dhclient-exit.log 2>&1
diff --git a/clientside/tmcc/archlinux/GNUmakefile.in b/clientside/tmcc/archlinux/GNUmakefile.in
new file mode 100644
index 0000000000000000000000000000000000000000..cc297eccee4ee60ca1cea661353bad5a3b10601c
--- /dev/null
+++ b/clientside/tmcc/archlinux/GNUmakefile.in
@@ -0,0 +1,140 @@
+#
+# Copyright (c) 2000-2012, 2015, 2016, 2017 University of Utah and the Flux Group.
+#
+# {{{EMULAB-LICENSE
+#
+# This file is part of the Emulab network testbed software.
+#
+# This file is free software: you can redistribute it and/or modify it
+# under the terms of the GNU Affero General Public License as published by
+# the Free Software Foundation, either version 3 of the License, or (at
+# your option) any later version.
+#
+# This file is distributed in the hope that it will be useful, but WITHOUT
+# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
+# FITNESS FOR A PARTICULAR PURPOSE. See the GNU Affero General Public
+# License for more details.
+#
+# You should have received a copy of the GNU Affero General Public License
+# along with this file. If not, see .
+#
+# }}}
+#
+
+#
+# XXX ONLY RUN THIS INSTALL ON AN UBUNTU LINUX TESTBED NODE!
+#
+# Trivial. These things just need to be installed into the right place
+# on a testbed node before cutting an image.
+#
+#
+SRCDIR = @srcdir@
+TESTBED_SRCDIR = @top_srcdir@
+OBJDIR = @top_builddir@
+SUBDIR = $(subst $(TESTBED_SRCDIR)/,,$(SRCDIR))
+
+include $(OBJDIR)/Makeconf
+
+SCRIPTS =
+
+#
+# Force dependencies on the scripts so that they will be rerun through
+# configure if the .in file is changed.
+#
+all: supfile ifcfgs
+
+include $(TESTBED_SRCDIR)/GNUmakerules
+
+SYSETCDIR = $(DESTDIR)/etc
+ETCDIR = $(DESTDIR)$(CLIENT_ETCDIR)
+BINDIR = $(DESTDIR)$(CLIENT_BINDIR)
+VARDIR = $(DESTDIR)$(CLIENT_VARDIR)
+RCDIR = $(SYSETCDIR)
+RRCDIR = /etc
+INSTALL = /usr/bin/install -c
+COMMON = $(SRCDIR)/../common
+DEFRUNLVLDIR ?= $(SYSETCDIR)/rc3.d
+# group to use for directories (dir-install)
+DIRGROUP ?= root
+
+install client-install: common-install etc-install \
+ script-install bin-install sysetc-fixup sysetc-install \
+ systemd-install
+ @echo "Remember to install the PEM files if necessary"
+
+simple-install: common-install script-install bin-install
+
+dir-install:
+ $(INSTALL) -m 755 -o root -g root -d $(SYSETCDIR)
+ $(INSTALL) -m 755 -o root -g root -d \
+ $(DESTDIR)/usr/lib/dhcpcd/dhcpcd-hooks
+ #$(INSTALL) -m 755 -o root -g root -d $(SYSETCDIR)/rsyslog.d
+ $(INSTALL) -m 755 -o root -g root -d $(SYSETCDIR)/sudoers.d
+ $(INSTALL) -m 755 -o root -g root -d $(SYSETCDIR)/systemd
+ $(INSTALL) -m 755 -o root -g root -d $(SYSETCDIR)/systemd/system
+ $(INSTALL) -m 755 -o root -g root -d $(SYSETCDIR)/systemd/system/network-online.target.wants
+ #$(INSTALL) -m 755 -o root -g root -d $(SYSETCDIR)/systemd/system/networking.service.wants
+ #$(INSTALL) -m 755 -o root -g root -d $(SYSETCDIR)/systemd/system/multi-user.target.wants
+
+common-install: dir-install
+ (cd ../common; $(MAKE) DESTDIR=$(DESTDIR) local-install)
+
+bin-install: dir-install
+ (cd ../linux; $(MAKE) DESTDIR=$(DESTDIR) RCDIR=$(RCDIR) USES_SYSTEMD=1 NOPASSWD=1 NOHOSTS=1 bin-install)
+
+etc-install: dir-install common-sysetc-install
+ # No point to having passwd files for a rolling distro!
+ #$(INSTALL) -m 644 $(SRCDIR)/group $(ETCDIR)/group
+ #$(INSTALL) -m 644 $(SRCDIR)/passwd $(ETCDIR)/passwd
+ #$(INSTALL) -m 600 $(SRCDIR)/shadow $(ETCDIR)/shadow
+ #$(INSTALL) -m 600 $(SRCDIR)/gshadow $(ETCDIR)/gshadow
+ if [ "$(NOHOSTS)" != "1" ]; then \
+ $(INSTALL) -m 644 $(SRCDIR)/hosts $(ETCDIR)/hosts ; \
+ fi
+
+common-sysetc-install: dir-install
+ # Tell ../linux/GNUMakefile.in that we want systemd files, not SYSV
+ (cd ../linux; $(MAKE) DESTDIR=$(DESTDIR) RCDIR=$(RCDIR) RRCDIR=$(RRCDIR) USES_SYSTEMD=1 NOPASSWD=1 NOHOSTS=1 sysetc-install)
+
+sysetc-fixup:
+ rm -rf $(SYSETCDIR)/modules.conf $(SYSETCDIR)/cron.pend \
+ $(SYSETCDIR)/sysconfig $(SYSETCDIR)/init.d/ntpd
+ rm -f $(SYSETCDIR)/ntp.drift
+ rm -f $(SYSETCDIR)/rc.local
+
+sysetc-install: dir-install
+ $(INSTALL) -m 755 $(SRCDIR)/dhcpcd.conf $(SYSETCDIR)/dhcpcd.conf
+ $(INSTALL) -m 755 $(SRCDIR)/05-emulab-early-dhcpcd-hook \
+ $(DESTDIR)/usr/lib/dhcpcd/dhcpcd-hooks/05-emulab-early-dhcpcd-hook
+ $(INSTALL) -m 755 $(SRCDIR)/99-emulab-late-dhcpcd-hook \
+ $(DESTDIR)/usr/lib/dhcpcd/dhcpcd-hooks/99-emulab-late-dhcpcd-hook
+ #$(INSTALL) -m 644 $(SRCDIR)/rsyslog-emulab.conf $(SYSETCDIR)/rsyslog.d/40-emulab.conf
+ $(INSTALL) -m 644 $(SRCDIR)/sudoers $(SYSETCDIR)/sudoers.d/99-emulab
+ @if [ -z "$(NONTP)" ]; then \
+ $(INSTALL) -m 644 $(SRCDIR)/ntp.conf $(SYSETCDIR)/ntp.conf; \
+ $(INSTALL) -m 644 -o ntp -g ntp /dev/null /var/lib/ntp/ntp.drift ; \
+ fi
+
+systemd-install: dir-install
+ $(INSTALL) -m 644 $(SRCDIR)/ifup-wait-emulab-cnet.service \
+ $(SYSETCDIR)/systemd/system/ifup-wait-emulab-cnet.service
+ ln -sf ../ifup-wait-emulab-cnet.service \
+ $(SYSETCDIR)/systemd/system/network-online.target.wants/ifup-wait-emulab-cnet.service
+ #$(INSTALL) -m 644 $(SRCDIR)/networking-emulab.service \
+ # $(SYSETCDIR)/systemd/system/networking-emulab.service
+ #ln -sf ../networking-emulab.service \
+ # $(SYSETCDIR)/systemd/system/networking.service.wants/networking-emulab.service
+ #ln -sf ../networking-emulab.service \
+ # $(SYSETCDIR)/systemd/system/network-online.target.wants/networking-emulab.service
+ # Kick the init process to read our newly-installed unit files
+ # (i.e., so an immediate tbprepare will work...)
+ @if [ -z "$(DESTDIR)" ]; then \
+ systemctl daemon-reload; \
+ fi
+
+script-install: dir-install $(SCRIPTS)
+ (cd ../linux; $(MAKE) DESTDIR=$(DESTDIR) RCDIR=$(RCDIR) USES_SYSTEMD=1 NOPASSWD=1 NOHOSTS=1 script-install)
+
+genirack-install:
+
+sfs-install:
diff --git a/clientside/tmcc/archlinux/dhcpcd.conf b/clientside/tmcc/archlinux/dhcpcd.conf
new file mode 100644
index 0000000000000000000000000000000000000000..579233b7fe90726513b629d79736edad8b28b836
--- /dev/null
+++ b/clientside/tmcc/archlinux/dhcpcd.conf
@@ -0,0 +1,56 @@
+# A sample configuration for dhcpcd.
+# See dhcpcd.conf(5) for details.
+
+# Allow users of this group to interact with dhcpcd via the control socket.
+#controlgroup wheel
+
+# Inform the DHCP server of our hostname for DDNS.
+hostname
+
+# Use the hardware address of the interface for the Client ID.
+clientid
+# or
+# Use the same DUID + IAID as set in DHCPv6 for DHCPv4 ClientID as per RFC4361.
+# Some non-RFC compliant DHCP servers do not reply with this set.
+# In this case, comment out duid and enable clientid above.
+#duid
+
+# Persist interface configuration when dhcpcd exits.
+persistent
+
+# Rapid commit support.
+# Safe to enable by default because it requires the equivalent option set
+# on the server to actually work.
+option rapid_commit
+
+# A list of options to request from the DHCP server.
+option domain_name_servers, domain_name, domain_search, host_name
+option classless_static_routes
+option subnet_mask, broadcast_address, time-offset, routers
+# Most distributions have NTP support.
+option ntp_servers
+# Respect the network MTU. This is applied to DHCP routes.
+option interface_mtu
+
+# A ServerID is required by RFC2131.
+require dhcp_server_identifier
+
+# Generate Stable Private IPv6 Addresses instead of hardware based ones
+slaac private
+noipv4ll
+
+# In an Emulab env, we need resolv.conf updated.
+#nohook resolv.conf
+
+# In an Emulab env, may as well save the 5 seconds required for ARP probing.
+noarp
+
+# I don't think it's very useful for dhcpcd to deconfigure the iface
+# when it exits.
+persistent
+
+# No point in an initial random delay.
+nodelay
+
+# Wait a long time; DHCP is our only option.
+timeout 300
diff --git a/clientside/tmcc/archlinux/hosts b/clientside/tmcc/archlinux/hosts
new file mode 100644
index 0000000000000000000000000000000000000000..1747f919698477ae63d438012993005baf7d783e
--- /dev/null
+++ b/clientside/tmcc/archlinux/hosts
@@ -0,0 +1,9 @@
+#
+# /etc/hosts: static lookup table for host names
+#
+
+#
+127.0.0.1 localhost.localdomain localhost
+::1 localhost.localdomain localhost
+
+# End of file
diff --git a/clientside/tmcc/archlinux/ifup-wait-emulab-cnet.service b/clientside/tmcc/archlinux/ifup-wait-emulab-cnet.service
new file mode 100644
index 0000000000000000000000000000000000000000..5559d9da763ca0e4078ce799dc34b4052242aea5
--- /dev/null
+++ b/clientside/tmcc/archlinux/ifup-wait-emulab-cnet.service
@@ -0,0 +1,14 @@
+[Unit]
+Description=Wait for the Emulab control network interface to come up for network-online.target
+DefaultDependencies=no
+After=local-fs.target
+Before=network-online.target
+
+[Service]
+Type=oneshot
+RemainAfterExit=yes
+TimeoutStartSec=2min
+ExecStart=/bin/sh -ec 'while [ ! -e /var/run/cnet ]; do sleep 1; done; exit 0'
+
+[Install]
+WantedBy=network-online.target
diff --git a/clientside/tmcc/archlinux/ntp.conf b/clientside/tmcc/archlinux/ntp.conf
new file mode 100644
index 0000000000000000000000000000000000000000..4db6f92a461986868fc371226bcc39e6297deacc
--- /dev/null
+++ b/clientside/tmcc/archlinux/ntp.conf
@@ -0,0 +1,13 @@
+#
+# Generic Emulab NTP client configuration.
+#
+
+driftfile /var/lib/ntp/ntp.drift
+
+# disallow most accesses, most importantly 'monlist' queries
+# XXX again, not ideal but works with really old ntpds
+restrict default nomodify nopeer noquery notrap
+restrict 127.0.0.1
+restrict ::1
+
+server ntp1 iburst
diff --git a/clientside/tmcc/archlinux/sudoers b/clientside/tmcc/archlinux/sudoers
new file mode 100644
index 0000000000000000000000000000000000000000..752628eb9f64191cb28d4f7c69b2e3ba19ce743f
--- /dev/null
+++ b/clientside/tmcc/archlinux/sudoers
@@ -0,0 +1,5 @@
+Defaults !env_reset
+Defaults !mail_badpass
+
+%admin ALL=(ALL) NOPASSWD: ALL
+%root ALL=(ALL) NOPASSWD: ALL
diff --git a/configure b/configure
index 316fdf0546387fce596fbf9106b30c20e7e96513..80915a5aed2b26aeeae3dab39e6274fc764fef82 100755
--- a/configure
+++ b/configure
@@ -7176,6 +7176,7 @@ outfiles="$outfiles clientside/GNUmakefile clientside/setversion \
clientside/tmcc/ubuntu16/GNUmakefile \
clientside/tmcc/ubuntu16-ms/GNUmakefile \
clientside/tmcc/linux-ms/GNUmakefile \
+ clientside/tmcc/archlinux/GNUmakefile \
clientside/tmcc/freebsd5/GNUmakefile clientside/tmcc/freebsd5/supfile \
clientside/tmcc/freebsd6/GNUmakefile clientside/tmcc/freebsd6/supfile \
clientside/tmcc/freebsd6/netif-emulab \
diff --git a/configure.ac b/configure.ac
index c7276d50fabdb01db81175aef36b19f251c54107..ee48a6e978b9848e7f82362aeb3119276cc7c196 100644
--- a/configure.ac
+++ b/configure.ac
@@ -1508,6 +1508,7 @@ outfiles="$outfiles clientside/GNUmakefile clientside/setversion \
clientside/tmcc/ubuntu16/GNUmakefile \
clientside/tmcc/ubuntu16-ms/GNUmakefile \
clientside/tmcc/linux-ms/GNUmakefile \
+ clientside/tmcc/archlinux/GNUmakefile \
clientside/tmcc/freebsd5/GNUmakefile clientside/tmcc/freebsd5/supfile \
clientside/tmcc/freebsd6/GNUmakefile clientside/tmcc/freebsd6/supfile \
clientside/tmcc/freebsd6/netif-emulab \