#!/bin/sh
# Copyright 2008 Sun Microsystems, Inc.  All rights reserved.
# Use is subject to license terms.
#
#pragma ident	"@(#)postpatch	1.1	08/07/30 SMI"
#

bind8_message() {
cat <<EOF

    ------------------------------------------------------------------

    This patchinstall script has detected that the system being
    patched is NOT configured to run BIND 9 name server; reference to
    "/usr/lib/dns/named" not found in "$rc".

    If you are running BIND 8 then you SHOULD convert to using BIND 9
    as delivered with this patch.  However the reconfiguration to use
    BIND 9 must be carried out manually.  For further details refer to
    the instructions in 
    $ROOTDIR/usr/lib/dns/migration.txt

    ------------------------------------------------------------------

EOF
}

# Start

rc=$ROOTDIR/etc/init.d/inetsvc
if [ -f $ROOTDIR/etc/named.conf -a -f $rc ]; then
    if /usr/bin/grep '/usr/lib/dns/named' $rc >/dev/null; then
	:
    else
	bind8_message
    fi
fi

exit 0
