From: Shawn Routhier Date: Tue, 20 Sep 2011 16:59:54 +0000 (+0000) Subject: Update description and comments for macos client script. X-Git-Tag: v4_3_0a1~145 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=394c505d2336f81e71e0f8d904332e6b46440ad6;p=thirdparty%2Fdhcp.git Update description and comments for macos client script. [ISC-Bugs #18891] --- diff --git a/README b/README index e026956ee..a1340c0b5 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 ad8d60202..8373820b1 100755 --- a/client/scripts/macos +++ b/client/scripts/macos @@ -1,6 +1,6 @@ #!/bin/sh # -# $Id: macos,v 1.3 2011/05/18 19:55:44 sar Exp $ +# $Id: macos,v 1.4 2011/09/20 16:59:54 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