5 # The contents of this file are subject to the terms of the
6 # Common Development and Distribution License (the "License").
7 # You may not use this file except in compliance with the License.
9 # You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
10 # or http://www.opensolaris.org/os/licensing.
11 # See the License for the specific language governing permissions
12 # and limitations under the License.
14 # When distributing Covered Code, include this CDDL HEADER in each
15 # file and include the License file at usr/src/OPENSOLARIS.LICENSE.
16 # If applicable, add the following below this CDDL HEADER, with the
17 # fields enclosed by brackets "[]" replaced with your own identifying
18 # information: Portions Copyright [yyyy] [name of copyright owner]
23 # Copyright 2003 Sun Microsystems, Inc. All rights reserved.
24 # Use is subject to license terms.
27 # First read the /etc/dat/dat.conf file to see if it has already been
28 # populated by the service provider entry. If so, simply return. If not,
29 # run datadm to populate the dat.conf file
30 if [ -r /etc
/dat
/dat.conf
]; then
31 pattern
="driver_name="
32 [ `/usr/bin/grep -c "$pattern" /etc/dat/dat.conf` -ge 1 ] && exit 0
34 echo "WARNING: /etc/dat/dat.conf is missing or unreadable" >& 2
38 # Now /etc/dat/dat.conf is readable but does not contain an entry for the
39 # service provider. So, run datadm -a /usr/share/dat/SUNWudaplt.conf to
41 if [ -x /usr
/sbin
/datadm
]; then
42 if [ -r /usr
/share
/dat
/SUNWudaplt.conf
]; then
43 /usr
/sbin
/datadm
-a /usr
/share
/dat
/SUNWudaplt.conf
45 echo "WARNING: SUNWudaplt.conf is missing or unreadable" >& 2
49 echo "WARNING: /usr/sbin/datadm is missing or not executable" >& 2