diff options
-rw-r--r-- | distrib/miniroot/install.sub | 8 | ||||
-rw-r--r-- | sbin/dhclient/clparse.c | 12 |
2 files changed, 11 insertions, 9 deletions
diff --git a/distrib/miniroot/install.sub b/distrib/miniroot/install.sub index 65ca20c753b..028a9ee9a1d 100644 --- a/distrib/miniroot/install.sub +++ b/distrib/miniroot/install.sub @@ -1,5 +1,5 @@ #!/bin/ksh -# $OpenBSD: install.sub,v 1.1146 2020/01/26 10:47:07 krw Exp $ +# $OpenBSD: install.sub,v 1.1147 2020/02/02 20:33:52 krw Exp $ # # Copyright (c) 1997-2015 Todd Miller, Theo de Raadt, Ken Westerback # Copyright (c) 2015, Robert Peichaer <rpe@openbsd.org> @@ -892,11 +892,7 @@ dhcp_request() { ifconfig $_if group dhcp >/dev/null 2>&1 if [[ -x /sbin/dhclient ]]; then - /sbin/dhclient -c /dev/stdin $_if <<__EOT -backoff-cutoff 2; -reboot 5; -timeout 10; -__EOT + /sbin/dhclient $_if else echo "DHCP leases not available during install - no /sbin/dhclient." fi diff --git a/sbin/dhclient/clparse.c b/sbin/dhclient/clparse.c index 917c815e2bf..76f8e5682f4 100644 --- a/sbin/dhclient/clparse.c +++ b/sbin/dhclient/clparse.c @@ -1,4 +1,4 @@ -/* $OpenBSD: clparse.c,v 1.194 2019/12/17 14:21:54 krw Exp $ */ +/* $OpenBSD: clparse.c,v 1.195 2020/02/02 20:33:52 krw Exp $ */ /* Parser for dhclient config and lease files. */ @@ -95,11 +95,17 @@ init_config(void) /* Set some defaults. */ config->link_timeout = 10; /* secs before going daemon w/o lease */ - config->timeout = 30; /* secs to wait for an OFFER */ config->select_interval = 0; /* secs to wait for other OFFERs */ - config->reboot_timeout = 1; /* secs before giving up on reboot */ config->retry_interval = 1; /* secs before asking for OFFER */ +#ifdef SMALL + config->backoff_cutoff = 2; /* max secs between packet retries */ + config->reboot_timeout = 5; /* secs before giving up on reboot */ + config->timeout = 10; /* secs to wait for an OFFER */ +#else config->backoff_cutoff = 10; /* max secs between packet retries */ + config->reboot_timeout = 1; /* secs before giving up on reboot */ + config->timeout = 30; /* secs to wait for an OFFER */ +#endif config->initial_interval = 1; /* secs before 1st retry */ /* All leases must supply a subnet mask. Classful defaults are dead, Jim. */ |