.\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
.\" SUCH DAMAGE.
.\"
-.Dd October 15, 2009
+.Dd October 16, 2009
.Dt DHCPCD 8 SMM
.Os
.Sh NAME
.Nd an RFC 2131 compliant DHCP client
.Sh SYNOPSIS
.Nm
-.Op Fl bdgknpqABDEGKLTV
+.Op Fl bdgknpqwABDEGKLTV
.Op Fl c , -script Ar script
.Op Fl e , -env Ar value
.Op Fl f , -config Ar file
.D1 dhcpcd \-v 03,\e"192.168.0.2\e" eth0
Set un-encapulated vendor option to hello world.
.D1 dhcpcd \-v ,"hello world" eth0
+.It Fl w , -waitip
+Wait for an address to be assigned before forking to the background.
.It Fl x , -exit
This will signal an existing
.Nm
if (iface->carrier != LINK_DOWN)
opt = 1;
}
- if (options & DHCPCD_LINK && opt == 0) {
+ if (opt == 0 &&
+ options & DHCPCD_LINK &&
+ !(options & DHCPCD_WAITIP))
+ {
syslog(LOG_WARNING, "no interfaces have a carrier");
daemonise();
} else if (options & DHCPCD_DAEMONISE && ifo->timeout > 0) {
.\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
.\" SUCH DAMAGE.
.\"
-.Dd October 7, 2009
+.Dd October 16, 2009
.Dt DHCPCD.CONF 5 SMM
.Os
.Sh NAME
.It Ic vendorclassid Ar string
Change the default vendorclassid sent from dhcpcd-version.
If not set then none is sent.
+.It Ic waitip
+Wait for an address to be assigned before forking to the background.
.El
.Sh SEE ALSO
.Xr dhcpcd-run-hooks 8 ,
{"timeout", required_argument, NULL, 't'},
{"userclass", required_argument, NULL, 'u'},
{"vendor", required_argument, NULL, 'v'},
+ {"waitip", no_argument, NULL, 'w'},
{"exit", no_argument, NULL, 'x'},
{"allowinterfaces", required_argument, NULL, 'z'},
{"reboot", required_argument, NULL, 'y'},
ifo->vendor[0] += s + 2;
}
break;
+ case 'w':
+ ifo->options |= DHCPCD_WAITIP;
+ break;
case 'y':
ifo->reboot = atoint(arg);
if (ifo->reboot < 0) {
/* Don't set any optional arguments here so we retain POSIX
* compatibility with getopt */
-#define IF_OPTS "bc:de:f:gh:i:kl:m:no:pqr:s:t:u:v:xy:z:ABC:DEF:GI:KLN:O:Q:TVW:X:Z:"
+#define IF_OPTS "bc:de:f:gh:i:kl:m:no:pqr:s:t:u:v:wxy:z:ABC:DEF:GI:KLN:O:Q:TVW:X:Z:"
#define DEFAULT_TIMEOUT 30
#define DEFAULT_REBOOT 10
#define DHCPCD_BACKGROUND (1 << 22)
#define DHCPCD_VENDORRAW (1 << 23)
#define DHCPCD_TIMEOUT_IPV4LL (1 << 24)
+#define DHCPCD_WAITIP (1 << 25)
extern const struct option cf_options[];