5864N/A# The contents of this file are subject to the terms of the 5864N/A# Common Development and Distribution License (the "License"). 5864N/A# You may not use this file except in compliance with the License. 5864N/A# See the License for the specific language governing permissions 5864N/A# and limitations under the License. 5864N/A# When distributing Covered Code, include this CDDL HEADER in each 5864N/A# If applicable, add the following below this CDDL HEADER, with the 5864N/A# fields enclosed by brackets "[]" replaced with your own identifying 5864N/A# information: Portions Copyright [yyyy] [name of copyright owner] 5864N/A# Copyright (c) 2016, Oracle and/or its affiliates. All rights reserved. 5864N/A echo "One or more packages failed to install" 5864N/Atrap "echo 'A command failed, aborting.'; exit 1" ERR 5864N/Atrap -
ERR # in kdcmgr destroy fails, run it again 5864N/Aprint "Existing KDC config destroyed." 5864N/Atrap "echo 'A command failed, aborting.'; exit 1" ERR 5864N/A# Note, this next section is adding various service principals local to 5864N/A# this system. If you have servers running on other systems, edit this 5864N/A# section to add the services using the FQDN hostnames of those systems 5864N/A# and ouput the keytab to a non-default filename. 5864N/A# You will then either copy the non-default filename created on the 5864N/A# system you ran this script on or login to the other system and do a 5864N/A# addprincs if not in slave mode 5864N/A # add service to KDC's keytab 5864N/A # add service to $host's keytab 5864N/A # Optional, Add service principals on KDC 5864N/A # randomizes the key anyway so use the -randkey option for addprinc). 5864N/A # "tester" needed for setup 5864N/Afi # addprincs if not in slave mode 5864N/A# turn off err trap because svcadm below may return an unimportant error 5864N/AError, the gss service did not start. You will not be able to do nfssec with sec=krb5* 5864N/A print -
u2 "Warning, kinit for tester princ failed, kdc setup is not working!" 5864N/A print "\nRun the following commands to transfer generated keytabs:"