xref: /titanic_41/usr/src/cmd/svc/milestone/net-svc (revision 3cf1b3e03f3c18d36c14b13bfe147921475eecb1)
17c478bd9Sstevel@tonic-gate#!/sbin/sh
27c478bd9Sstevel@tonic-gate#
37c478bd9Sstevel@tonic-gate# CDDL HEADER START
47c478bd9Sstevel@tonic-gate#
57c478bd9Sstevel@tonic-gate# The contents of this file are subject to the terms of the
66927f468Sdp# Common Development and Distribution License (the "License").
76927f468Sdp# You may not use this file except in compliance with the License.
87c478bd9Sstevel@tonic-gate#
97c478bd9Sstevel@tonic-gate# You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
107c478bd9Sstevel@tonic-gate# or http://www.opensolaris.org/os/licensing.
117c478bd9Sstevel@tonic-gate# See the License for the specific language governing permissions
127c478bd9Sstevel@tonic-gate# and limitations under the License.
137c478bd9Sstevel@tonic-gate#
147c478bd9Sstevel@tonic-gate# When distributing Covered Code, include this CDDL HEADER in each
157c478bd9Sstevel@tonic-gate# file and include the License file at usr/src/OPENSOLARIS.LICENSE.
167c478bd9Sstevel@tonic-gate# If applicable, add the following below this CDDL HEADER, with the
177c478bd9Sstevel@tonic-gate# fields enclosed by brackets "[]" replaced with your own identifying
187c478bd9Sstevel@tonic-gate# information: Portions Copyright [yyyy] [name of copyright owner]
197c478bd9Sstevel@tonic-gate#
207c478bd9Sstevel@tonic-gate# CDDL HEADER END
217c478bd9Sstevel@tonic-gate#
227c478bd9Sstevel@tonic-gate#
23*3cf1b3e0Sokie# Copyright 2008 Sun Microsystems, Inc.  All rights reserved.
247c478bd9Sstevel@tonic-gate# Use is subject to license terms.
257c478bd9Sstevel@tonic-gate#
267c478bd9Sstevel@tonic-gate# ident	"%Z%%M%	%I%	%E% SMI"
277c478bd9Sstevel@tonic-gate
287c478bd9Sstevel@tonic-gate#
297c478bd9Sstevel@tonic-gate# This is third phase of TCP/IP startup/configuration.  This script
307c478bd9Sstevel@tonic-gate# runs after the NIS/NIS+ startup script.  We run things here that may
317c478bd9Sstevel@tonic-gate# depend on NIS/NIS+ maps.
327c478bd9Sstevel@tonic-gate#
337c478bd9Sstevel@tonic-gate
346927f468Sdp. /lib/svc/share/smf_include.sh
356927f468Sdp
367c478bd9Sstevel@tonic-gatecase "$1" in
377c478bd9Sstevel@tonic-gate'start')
387c478bd9Sstevel@tonic-gate	#
39f4b3ec61Sdh155122	# In a shared-IP zone we need this service to be up, but all of the
40f4b3ec61Sdh155122	# work it tries to do is irrelevant (and will actually lead to the
41f4b3ec61Sdh155122	# service failing if we try to do it), so just bail out.
42f4b3ec61Sdh155122	# In the global zone and exclusive-IP zones we proceed.
437c478bd9Sstevel@tonic-gate	#
44f4b3ec61Sdh155122	smf_configure_ip || exit 0
457c478bd9Sstevel@tonic-gate	;; # Fall through -- rest of script is the initialization code
467c478bd9Sstevel@tonic-gate
477c478bd9Sstevel@tonic-gate'stop')
487c478bd9Sstevel@tonic-gate	exit 0
497c478bd9Sstevel@tonic-gate	;;
507c478bd9Sstevel@tonic-gate
517c478bd9Sstevel@tonic-gate*)
527c478bd9Sstevel@tonic-gate	echo "Usage: $0 { start | stop }"
537c478bd9Sstevel@tonic-gate	exit 1
547c478bd9Sstevel@tonic-gate	;;
557c478bd9Sstevel@tonic-gateesac
567c478bd9Sstevel@tonic-gate
57*3cf1b3e0SokieNWAM_FMRI="svc:/network/physical:nwam"
58*3cf1b3e0SokieNETSVC_FMRI="svc:/network/service:default"
59*3cf1b3e0Sokie
60d71dbb73Sjbeckinterface=$2
617c478bd9Sstevel@tonic-gate
627c478bd9Sstevel@tonic-gate# If boot variables are not set, set variables we use
637c478bd9Sstevel@tonic-gate[ -z "$_INIT_UTS_NODENAME" ] && _INIT_UTS_NODENAME=`/usr/bin/uname -n`
647c478bd9Sstevel@tonic-gate
657c478bd9Sstevel@tonic-gate#
66*3cf1b3e0Sokie# This function removes the instance portion of the passed-in FMRI; for
67*3cf1b3e0Sokie# example, 'svc:/network/service:default' becomes 'svc:/network/service'.
68*3cf1b3e0Sokie#
69*3cf1b3e0Sokieremove_fmri_inst () {
70*3cf1b3e0Sokie	echo $1 | awk -F: ' { printf "%s:%s", $1, $2 } '
71*3cf1b3e0Sokie}
72*3cf1b3e0Sokie
73*3cf1b3e0Sokie#
74*3cf1b3e0Sokie# This function returns true if this script was *not* invoked
75*3cf1b3e0Sokie# by an instance of svc:/network/service.
76*3cf1b3e0Sokie#
77*3cf1b3e0Sokiefmri_is_not_netsvc () {
78*3cf1b3e0Sokie	FMRI_1=`remove_fmri_inst $SMF_FMRI`
79*3cf1b3e0Sokie	FMRI_2=`remove_fmri_inst $NETSVC_FMRI`
80*3cf1b3e0Sokie	[ "$FMRI_1" = "$FMRI_2" ] && return 1
81*3cf1b3e0Sokie	return 0
82*3cf1b3e0Sokie}
83*3cf1b3e0Sokie
84*3cf1b3e0Sokie#
85*3cf1b3e0Sokie# This function returns true if this script was *not* invoked
86*3cf1b3e0Sokie# by the nwam instance of the network/physical service.
87*3cf1b3e0Sokie#
88*3cf1b3e0Sokiefmri_is_not_nwam () {
89*3cf1b3e0Sokie	[ "&SMF_FMRI" = "$NWAM_FMRI" ] && return 1
90*3cf1b3e0Sokie	return 0
91*3cf1b3e0Sokie}
92*3cf1b3e0Sokie
93*3cf1b3e0Sokie#
94*3cf1b3e0Sokie# This function returns true if the nwam service is not running, false
95*3cf1b3e0Sokie# if it is.  "running" is defined as "current state is online or next
96*3cf1b3e0Sokie# state is online".
97*3cf1b3e0Sokie#
98*3cf1b3e0Sokienwam_is_not_running() {
99*3cf1b3e0Sokie	state=`/usr/bin/svcprop -p restarter/state $NWAM_FMRI`
100*3cf1b3e0Sokie	nstate=`/usr/bin/svcprop -p restarter/next_state $NWAM_FMRI`
101*3cf1b3e0Sokie
102*3cf1b3e0Sokie	[ "$state" = "online" -o "$nextstate" = "online" ] && return 1
103*3cf1b3e0Sokie	return 0
104*3cf1b3e0Sokie}
105*3cf1b3e0Sokie
106*3cf1b3e0Sokie#
1077c478bd9Sstevel@tonic-gate# wait_nis
1087c478bd9Sstevel@tonic-gate# Wait up to 5 seconds for ypbind to obtain a binding.
1097c478bd9Sstevel@tonic-gate#
1107c478bd9Sstevel@tonic-gatewait_nis ()
1117c478bd9Sstevel@tonic-gate{
1127c478bd9Sstevel@tonic-gate	for i in 1 2 3 4 5; do
1137c478bd9Sstevel@tonic-gate		server=`/usr/bin/ypwhich 2>/dev/null`
1147c478bd9Sstevel@tonic-gate		[ $? -eq 0 -a -n "$server" ] && return 0 || sleep 1
1157c478bd9Sstevel@tonic-gate	done
1167c478bd9Sstevel@tonic-gate	return 1
1177c478bd9Sstevel@tonic-gate}
1187c478bd9Sstevel@tonic-gate
1197c478bd9Sstevel@tonic-gate#
1207c478bd9Sstevel@tonic-gate# This function takes two file names and the file mode as input. The two
1217c478bd9Sstevel@tonic-gate# files are compared for differences (using cmp(1)) and if different, the
1227c478bd9Sstevel@tonic-gate# second file is over written with the first. A chmod is done with the file
1237c478bd9Sstevel@tonic-gate# mode passed in. If the files are equal, the first file passed
1247c478bd9Sstevel@tonic-gate# in (the /tmp file) is deleted.
1257c478bd9Sstevel@tonic-gate#
1267c478bd9Sstevel@tonic-gatemv_file ()
1277c478bd9Sstevel@tonic-gate{
1287c478bd9Sstevel@tonic-gate	/usr/bin/cmp -s $1 $2
1297c478bd9Sstevel@tonic-gate	if [ $? -eq 1 ]; then
1307c478bd9Sstevel@tonic-gate		/usr/bin/mv $1 $2
1317c478bd9Sstevel@tonic-gate		#
1327c478bd9Sstevel@tonic-gate		# The umask during boot is configurable, which requires
1337c478bd9Sstevel@tonic-gate		# explicit setting of file permission modes when we
1347c478bd9Sstevel@tonic-gate		# create files.
1357c478bd9Sstevel@tonic-gate		#
1367c478bd9Sstevel@tonic-gate		/usr/bin/chmod $3 $2
1377c478bd9Sstevel@tonic-gate	else
1387c478bd9Sstevel@tonic-gate		/usr/bin/rm $1
1397c478bd9Sstevel@tonic-gate	fi
1407c478bd9Sstevel@tonic-gate}
1417c478bd9Sstevel@tonic-gate
1427c478bd9Sstevel@tonic-gate#
143*3cf1b3e0Sokie# This function takes a DHCP parameter (as defined in /etc/dhcp/inittab)
144*3cf1b3e0Sokie# and returns the value for that parameter returned by the DHCP server.
145*3cf1b3e0Sokie# If the global 'interface' is defined, it will request the value learned
146*3cf1b3e0Sokie# on that interface, else it will request the value learned on the primary
147*3cf1b3e0Sokie# interface.
148*3cf1b3e0Sokie#
149*3cf1b3e0Sokieget_dhcp_var ()
150*3cf1b3e0Sokie{
151*3cf1b3e0Sokie	if [ -n "$interface" ]; then
152*3cf1b3e0Sokie		/sbin/dhcpinfo -i $interface $1
153*3cf1b3e0Sokie	else
154*3cf1b3e0Sokie		/sbin/dhcpinfo $1
155*3cf1b3e0Sokie	fi
156*3cf1b3e0Sokie}
157*3cf1b3e0Sokie
158*3cf1b3e0Sokie#
159*3cf1b3e0Sokie# This function returns true if the string "# Added by DHCP$" occurs in
160*3cf1b3e0Sokie# the passed-in file, false otherwise.
161*3cf1b3e0Sokie#
162*3cf1b3e0Sokiedhcp_edits ()
163*3cf1b3e0Sokie{
164*3cf1b3e0Sokie	/usr/bin/grep '# Added by DHCP$' $1 >/dev/null 2>&1
165*3cf1b3e0Sokie	return $?
166*3cf1b3e0Sokie}
167*3cf1b3e0Sokie
168*3cf1b3e0Sokie#
169*3cf1b3e0Sokie# update_resolv()
170*3cf1b3e0Sokie# Go through /etc/resolv.conf and replace any existing domain or
171*3cf1b3e0Sokie# nameserver entries with new ones derived from DHCP.  Note that
172*3cf1b3e0Sokie# it is important to preserve order of domain entries vs. search
173*3cf1b3e0Sokie# entries; the search entries are reserved for administrator
174*3cf1b3e0Sokie# customization and if placed after the domain entry will override
175*3cf1b3e0Sokie# it.  See resolv.conf(4).
176*3cf1b3e0Sokie#
177*3cf1b3e0Sokie# The first arg should be the dns servers string, the second
178*3cf1b3e0Sokie# should be the dns domain.
179*3cf1b3e0Sokie#
180*3cf1b3e0Sokieupdate_resolv ()
181*3cf1b3e0Sokie{
182*3cf1b3e0Sokie	dnsservers=$1
183*3cf1b3e0Sokie	dnsdomain=$2
184*3cf1b3e0Sokie
185*3cf1b3e0Sokie	if [ ! -f /etc/resolv.conf ]; then
186*3cf1b3e0Sokie		/usr/bin/touch /etc/resolv.conf
187*3cf1b3e0Sokie	fi
188*3cf1b3e0Sokie	export dnsservers dnsdomain
189*3cf1b3e0Sokie	/usr/bin/nawk </etc/resolv.conf >/tmp/resolv.conf.$$ '
190*3cf1b3e0Sokie		function writedomain() {
191*3cf1b3e0Sokie			if (updated == 0) {
192*3cf1b3e0Sokie			    	# Use only first domain, not a search list
193*3cf1b3e0Sokie			    	split(ENVIRON["dnsdomain"], d)
194*3cf1b3e0Sokie				if(length(d[1]) != 0)
195*3cf1b3e0Sokie					printf("domain %s\n", d[1])
196*3cf1b3e0Sokie			}
197*3cf1b3e0Sokie			++updated
198*3cf1b3e0Sokie		}
199*3cf1b3e0Sokie		$1 == "domain" { writedomain(); next }
200*3cf1b3e0Sokie		$1 != "nameserver" { print $0 }
201*3cf1b3e0Sokie		END {
202*3cf1b3e0Sokie			writedomain()
203*3cf1b3e0Sokie			n = split(ENVIRON["dnsservers"], s)
204*3cf1b3e0Sokie			for (i = 1; i <= n; ++i)
205*3cf1b3e0Sokie				printf("nameserver %s\n", s[i])
206*3cf1b3e0Sokie		}'
207*3cf1b3e0Sokie	unset dnsservers dnsdomain
208*3cf1b3e0Sokie	mv_file /tmp/resolv.conf.$$ /etc/resolv.conf 644
209*3cf1b3e0Sokie}
210*3cf1b3e0Sokie
211*3cf1b3e0Sokie#
2127c478bd9Sstevel@tonic-gate# update_nss
2137c478bd9Sstevel@tonic-gate# This routine takes as a parameter, the name of the respective policy
2147c478bd9Sstevel@tonic-gate# to change in the nsswitch.conf (hosts or ipnodes) to update with dns.
2157c478bd9Sstevel@tonic-gate#
2167c478bd9Sstevel@tonic-gateupdate_nss ()
2177c478bd9Sstevel@tonic-gate{
2187c478bd9Sstevel@tonic-gate	policy=$1;
2197c478bd9Sstevel@tonic-gate	# Add dns to the nsswitch file, if it isn't already there.
2207c478bd9Sstevel@tonic-gate	/usr/bin/awk ' $1 ~ /^'${policy}':/ {
2217c478bd9Sstevel@tonic-gate		n = split($0, a);
2227c478bd9Sstevel@tonic-gate		newl = a[1];
2237c478bd9Sstevel@tonic-gate		if ($0 !~ /dns/) {
2247c478bd9Sstevel@tonic-gate			printf("#%s # Commented out by DHCP\n", $0);
2257c478bd9Sstevel@tonic-gate			updated = 0;
2267c478bd9Sstevel@tonic-gate			for (i = 2; i <= n; i++) {
2277c478bd9Sstevel@tonic-gate				if (updated == 0 && index(a[i], "[") == 1) {
2287c478bd9Sstevel@tonic-gate					newl = newl" dns";
2297c478bd9Sstevel@tonic-gate					updated++;
2307c478bd9Sstevel@tonic-gate				}
2317c478bd9Sstevel@tonic-gate				newl = newl" "a[i];
2327c478bd9Sstevel@tonic-gate			}
2337c478bd9Sstevel@tonic-gate			if (updated == 0) {
2347c478bd9Sstevel@tonic-gate				newl = newl" dns";
2357c478bd9Sstevel@tonic-gate				updated++;
2367c478bd9Sstevel@tonic-gate			}
2377c478bd9Sstevel@tonic-gate			if (updated != 0)
2387c478bd9Sstevel@tonic-gate				newl = newl" # Added by DHCP";
2397c478bd9Sstevel@tonic-gate			else
2407c478bd9Sstevel@tonic-gate				newl = $0;
2417c478bd9Sstevel@tonic-gate			printf("%s\n", newl);
2427c478bd9Sstevel@tonic-gate		} else
2437c478bd9Sstevel@tonic-gate			printf("%s\n", $0);
2447c478bd9Sstevel@tonic-gate	} $1 !~ /^'${policy}':/ { printf("%s\n", $0); }' /etc/nsswitch.conf \
2457c478bd9Sstevel@tonic-gate	    >/tmp/nsswitch.conf.$$
2467c478bd9Sstevel@tonic-gate
2477c478bd9Sstevel@tonic-gate	mv_file /tmp/nsswitch.conf.$$ /etc/nsswitch.conf 644
2487c478bd9Sstevel@tonic-gate}
2497c478bd9Sstevel@tonic-gate
2507c478bd9Sstevel@tonic-gate#
251*3cf1b3e0Sokie# Remove any lines with the "# Added by DHCP" tag from /etc/nsswitch.conf;
252*3cf1b3e0Sokie# also uncomment hosts and ipnodes entries which were previously commented
253*3cf1b3e0Sokie# out by this script.
2547c478bd9Sstevel@tonic-gate#
255*3cf1b3e0Sokiecleanup_nss ()
256*3cf1b3e0Sokie{
2577c478bd9Sstevel@tonic-gate	/usr/bin/sed \
2587c478bd9Sstevel@tonic-gate	    -e '/# Added by DHCP$/d' \
2597c478bd9Sstevel@tonic-gate	    -e 's/^\(#hosts:\)\(.*[^#]\)\(#.*\)$/hosts: \2/' \
2607c478bd9Sstevel@tonic-gate	    -e 's/^\(#ipnodes:\)\(.*[^#]\)\(#.*\)$/ipnodes: \2/' \
2617c478bd9Sstevel@tonic-gate	    /etc/nsswitch.conf >/tmp/nsswitch.conf.$$
2627c478bd9Sstevel@tonic-gate
2637c478bd9Sstevel@tonic-gate	mv_file /tmp/nsswitch.conf.$$ /etc/nsswitch.conf 644
264*3cf1b3e0Sokie}
2657c478bd9Sstevel@tonic-gate
266*3cf1b3e0Sokie#
267*3cf1b3e0Sokie# Remove any lines with the "# Added by DHCP" tag from /etc/inet/hosts.
268*3cf1b3e0Sokie#
269*3cf1b3e0Sokiecleanup_hosts ()
270*3cf1b3e0Sokie{
271d71dbb73Sjbeck	/usr/bin/nawk '{
272d71dbb73Sjbeck		if (index($0, "# Added by DHCP") == 0 ||
273d71dbb73Sjbeck		    $1 == "127.0.0.1" || $1 == "::1") {
274d71dbb73Sjbeck			print $0
275d71dbb73Sjbeck		}
276d71dbb73Sjbeck	}' /etc/inet/hosts > /tmp/hosts.$$
2777c478bd9Sstevel@tonic-gate	mv_file /tmp/hosts.$$ /etc/inet/hosts 444
278*3cf1b3e0Sokie}
279*3cf1b3e0Sokie
280*3cf1b3e0Sokie#
281*3cf1b3e0Sokie# We now need to reset the netmask and broadcast address for our network
282*3cf1b3e0Sokie# interfaces.  Since this may result in a name service lookup, we want to
283*3cf1b3e0Sokie# now wait for NIS to come up if we previously started it.
284*3cf1b3e0Sokie#
285*3cf1b3e0Sokie# Only do this in the non-nwam case.
286*3cf1b3e0Sokie#
287*3cf1b3e0Sokieif fmri_is_not_nwam; then
288*3cf1b3e0Sokie	domain=`/usr/bin/domainname 2>/dev/null`
289*3cf1b3e0Sokie
290*3cf1b3e0Sokie	[ -z "$domain" ] || [ ! -d /var/yp/binding/$domain ] || wait_nis || \
291*3cf1b3e0Sokie    		echo "WARNING: Timed out waiting for NIS to come up" >& 2
292*3cf1b3e0Sokie
293*3cf1b3e0Sokie	#
294*3cf1b3e0Sokie	# Re-set the netmask and broadcast addr for all IP interfaces.  This
295*3cf1b3e0Sokie	# ifconfig is run here, after waiting for name services, so that
296*3cf1b3e0Sokie	# "netmask +" will find the netmask if it lives in a NIS map. The 'D'
297*3cf1b3e0Sokie	# in -auD tells ifconfig NOT to mess with the interface if it is
298*3cf1b3e0Sokie	# under DHCP control
299*3cf1b3e0Sokie	#
300*3cf1b3e0Sokie	/usr/sbin/ifconfig -auD4 netmask + broadcast +
3017c478bd9Sstevel@tonic-gatefi
302d71dbb73Sjbeck
303*3cf1b3e0Sokie# Uncomment these lines to print complete network interface configuration
304*3cf1b3e0Sokie# echo "network interface configuration:"
305*3cf1b3e0Sokie# /usr/sbin/ifconfig -a
306*3cf1b3e0Sokie
307*3cf1b3e0Sokie#
308*3cf1b3e0Sokie# If our network configuration strategy is DHCP, check for DNS
309*3cf1b3e0Sokie# configuration parameters obtained from the DHCP server.
310*3cf1b3e0Sokie#
311*3cf1b3e0Sokie# If NWAM is enabled, it will invoke this script to do this configuration
312*3cf1b3e0Sokie# whenever a DHCP lease is obtained; in that case, this configuration
313*3cf1b3e0Sokie# should *not* happen when svc:network/service is starting, as it will
314*3cf1b3e0Sokie# interfere with the configuration performed by NWAM.
315*3cf1b3e0Sokie#
316*3cf1b3e0Sokieif nwam_is_not_running || fmri_is_not_netsvc; then
317*3cf1b3e0Sokie
318*3cf1b3e0Sokie	smf_netstrategy
319*3cf1b3e0Sokie
320*3cf1b3e0Sokie	if [ "$_INIT_NET_STRATEGY" = "dhcp" ]; then
321*3cf1b3e0Sokie		dnsservers=`get_dhcp_var DNSserv`
322*3cf1b3e0Sokie		dnsdomain=`get_dhcp_var DNSdmain`
323*3cf1b3e0Sokie	else
324*3cf1b3e0Sokie		dnsservers=""
325*3cf1b3e0Sokie		dnsdomain=""
326*3cf1b3e0Sokie	fi
327*3cf1b3e0Sokie
328*3cf1b3e0Sokie	if [ -n "$dnsservers" ]; then
329*3cf1b3e0Sokie		#
330*3cf1b3e0Sokie		# add settings retrieved from dhcp server to /etc/resolv.conf
331*3cf1b3e0Sokie		#
332*3cf1b3e0Sokie		update_resolv "$dnsservers" "$dnsdomain"
333*3cf1b3e0Sokie
334*3cf1b3e0Sokie		#
335*3cf1b3e0Sokie		# Add dns to the nsswitch file, if it isn't already there.
336*3cf1b3e0Sokie		#
337*3cf1b3e0Sokie		update_nss hosts
338*3cf1b3e0Sokie		update_nss ipnodes
339*3cf1b3e0Sokie
340*3cf1b3e0Sokie	elif dhcp_edits /etc/nsswitch.conf; then
341*3cf1b3e0Sokie		# If we added DNS to the hosts and ipnodes
342*3cf1b3e0Sokie		# policy in the nsswitch, remove it.
343*3cf1b3e0Sokie		cleanup_nss
344*3cf1b3e0Sokie	fi
345*3cf1b3e0Sokiefi
346*3cf1b3e0Sokie
347*3cf1b3e0Sokieif dhcp_edits /etc/inet/hosts; then
348*3cf1b3e0Sokie	# Clean up any old DHCP-added entries
349*3cf1b3e0Sokie	# (except loopback) in the hosts file.
350*3cf1b3e0Sokie	cleanup_hosts
351*3cf1b3e0Sokiefi
352*3cf1b3e0Sokie
353*3cf1b3e0Sokie#
354*3cf1b3e0Sokie# If we were invoked by NWAM, can exit now (skipping the ipqos config)
355*3cf1b3e0Sokie#
356*3cf1b3e0Sokieif [ -z "$SMF_FMRI" ] || [ "$SMF_FMRI" = "$NWAM_FMRI" ]; then
357032ae3d9Samaguire        exit 0
358032ae3d9Samaguirefi
359032ae3d9Samaguire
360032ae3d9Samaguire#
361032ae3d9Samaguire# Load the IPQoS configuration.
362032ae3d9Samaguire# This is backgrounded so that any remote hostname lookups it performs
363032ae3d9Samaguire# don't unduely delay startup. Any messages go via syslog.
364032ae3d9Samaguire#
365032ae3d9Samaguire
366032ae3d9Samaguireif [ -f /usr/sbin/ipqosconf -a -f /etc/inet/ipqosinit.conf ]; then
367032ae3d9Samaguire        /usr/sbin/ipqosconf -s -a /etc/inet/ipqosinit.conf &
368032ae3d9Samaguirefi
369