From: Shawn Routhier Date: Tue, 20 Sep 2011 17:04:03 +0000 (+0000) Subject: Update description and comments for macos client script X-Git-Tag: v4_2_3rc1~9 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=b09b92485c078c53f46c26b679618c239af5cabe;p=thirdparty%2Fdhcp.git Update description and comments for macos client script [ISC-Bugs #18891] --- diff --git a/README b/README index 5921344ce..2d0aa2705 100644 --- a/README +++ b/README @@ -523,20 +523,23 @@ this text is only about the DHCPv6 client (``dhclient -6 ...''). The DNS configuration (domain search list and name servers' addresses) is managed by a System Configuration agent, not by /etc/resolv.conf (which is a link to /var/run/resolv.conf, which itself only reflects the internal state; -the System Configuration agent's Dynamic Store). +the System Configuration framework's Dynamic Store). -This means that modifying resolv.conf directly doesn't have the intended -effect, so the macos script sample uses its own resolv.conf.dhclient6 in -/var/run, and inserts the contents of this file into the System -Configuration agent. Because the System Configuration agent expects the -prefix along with the configured address, and a default router, this is -not usable (the DHCPv6 protocol does not today deliver this information). -Instead, ifconfig is directly used for address configuration. +This means that modifying resolv.conf directly doesn't have the +intended effect, instead the macos script sample creates its own +resolv.conf.dhclient6 in /var/run, and inserts the contents of this +file into the Dynamic Store. + +When updating the address configuration the System Configuration +framework expects the prefix and a default router along with the +configured address. As this extra information is not available via +the DHCPv6 protocol the System Configuration framework isn't usable +for address configuration, instead ifconfig is used directly. Note the Dynamic Store (from which /var/run/resolv.conf is built) is -recomputed from scratch when the current location/set is changed, for -instance when a laptop is resumed from sleep. In this case running the -dhclient-script could reinstall the resolv.conf.dhclient6 configuration. +recomputed from scratch when the current location/set is changed. +Running the dhclient-script reinstalls the resolv.conf.dhclient6 +configuration. SUPPORT diff --git a/client/scripts/macos b/client/scripts/macos index 6e5a04cc3..1b887fa8b 100755 --- a/client/scripts/macos +++ b/client/scripts/macos @@ -1,6 +1,6 @@ #!/bin/sh # -# $Id: macos,v 1.2.108.1 2011/05/18 20:01:54 sar Exp $ +# $Id: macos,v 1.2.108.2 2011/09/20 17:04:03 sar Exp $ # # automous run of this script will commit the DNS setting # @@ -49,8 +49,13 @@ make_resolv_conf() { } # Try to commit /var/run/resolv.conf.dhclient6 contents to -# SystemConfiguration Dynamic Store +# System Configuration framework's Dynamic Store. # Note this will be cleared by the next location change +# or preempted by IPv4. +# +# The System Configuration agent "IPMonitor" gets the DNS configuration +# from the IPv4 or IPv6 primary service in the Dynamic Store +# (managed by configd). commit_resolv_conf() { if [ -f /var/run/resolv.conf.dhclient6 ]; then if [ -x /usr/sbin/scutil ]; then