xref: /illumos-gate/usr/src/cmd/svc/milestone/net-ipqos (revision 6ba597c5)
1*6ba597c5SAnurag S. Maskey#!/sbin/sh
2b00044a2SJames Carlson#
3b00044a2SJames Carlson# CDDL HEADER START
4b00044a2SJames Carlson#
5b00044a2SJames Carlson# The contents of this file are subject to the terms of the
6b00044a2SJames Carlson# Common Development and Distribution License (the "License").
7b00044a2SJames Carlson# You may not use this file except in compliance with the License.
8b00044a2SJames Carlson#
9b00044a2SJames Carlson# You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
10b00044a2SJames Carlson# or http://www.opensolaris.org/os/licensing.
11b00044a2SJames Carlson# See the License for the specific language governing permissions
12b00044a2SJames Carlson# and limitations under the License.
13b00044a2SJames Carlson#
14b00044a2SJames Carlson# When distributing Covered Code, include this CDDL HEADER in each
15b00044a2SJames Carlson# file and include the License file at usr/src/OPENSOLARIS.LICENSE.
16b00044a2SJames Carlson# If applicable, add the following below this CDDL HEADER, with the
17b00044a2SJames Carlson# fields enclosed by brackets "[]" replaced with your own identifying
18b00044a2SJames Carlson# information: Portions Copyright [yyyy] [name of copyright owner]
19b00044a2SJames Carlson#
20b00044a2SJames Carlson# CDDL HEADER END
21b00044a2SJames Carlson#
22*6ba597c5SAnurag S. Maskey#
23*6ba597c5SAnurag S. Maskey# Copyright 2010 Sun Microsystems, Inc.  All rights reserved.
24b00044a2SJames Carlson# Use is subject to license terms.
25b00044a2SJames Carlson#
26b00044a2SJames Carlson
27*6ba597c5SAnurag S. Maskey#
28*6ba597c5SAnurag S. Maskey# Load the IPQoS configuration.
29*6ba597c5SAnurag S. Maskey#
30b00044a2SJames Carlson
31*6ba597c5SAnurag S. Maskey. /lib/svc/share/smf_include.sh
32b00044a2SJames Carlson
33*6ba597c5SAnurag S. Maskey#
34*6ba597c5SAnurag S. Maskey# In a shared-IP zone we need this service to be up, but all of the
35*6ba597c5SAnurag S. Maskey# work it tries to do is irrelevant (and will actually lead to the
36*6ba597c5SAnurag S. Maskey# service failing if we try to do it), so just bail out.
37*6ba597c5SAnurag S. Maskey# In the global zone and exclusive-IP zones we proceed.
38*6ba597c5SAnurag S. Maskey#
39*6ba597c5SAnurag S. Maskeysmf_configure_ip || exit $SMF_EXIT_OK
40b00044a2SJames Carlson
41*6ba597c5SAnurag S. Maskey#
42*6ba597c5SAnurag S. Maskey# This is backgrounded so that any remote hostname lookups it performs
43*6ba597c5SAnurag S. Maskey# don't unduely delay startup. Any messages go via syslog.
44*6ba597c5SAnurag S. Maskey#
45b00044a2SJames Carlson
46*6ba597c5SAnurag S. Maskeyif [ -f /usr/sbin/ipqosconf -a -f /etc/inet/ipqosinit.conf ]; then
47*6ba597c5SAnurag S. Maskey        /usr/sbin/ipqosconf -s -a /etc/inet/ipqosinit.conf &
48*6ba597c5SAnurag S. Maskeyfi
49