2N/A * The contents of this file are subject to the terms of the 2N/A * Common Development and Distribution License (the "License"). 2N/A * You may not use this file except in compliance with the License. 2N/A * See the License for the specific language governing permissions 2N/A * and limitations under the License. 2N/A * When distributing Covered Code, include this CDDL HEADER in each 2N/A * If applicable, add the following below this CDDL HEADER, with the 2N/A * fields enclosed by brackets "[]" replaced with your own identifying 2N/A * information: Portions Copyright [yyyy] [name of copyright owner] 2N/A * Copyright (c) 2006, 2011, Oracle and/or its affiliates. All rights reserved. 2N/A * Service Management Facility (SMF) interfaces. 2N/A * Enable the specified SVM services through the SMF. 2N/A * Disable the specified SVM services through the SMF. 2N/A * Determine if desired services are online. If all services in the 2N/A * classes specified by flags are online, 1 is returned. Otherwise 2N/A * Return a bitmask of the META_SMF_* flags indicating which services should be 2N/A * online given the current SVM configuration. 2N/A * If there are any local metadbs configured then the core services 2N/A * If any disksets configured then the diskset services are needed. 2N/A * Also check for multi-node sets. 2N/A * metad rpc program not registered 2N/A * can't get diskset info 2N/A * we don't have to check the 2N/A * rest of the disksets at this 2N/A * There can be a delay while the RPC services get going. Try to 2N/A * make sure the RPC daemons are ready to run before we return. 2N/A * Check 15 times (15 seconds total wait time) and then just 2N/A for (i = 0; i <
15; i++) {
2N/A * Check to see if all services in the svc_names are online. If they are 2N/A * all online 1 is returned, otherwise 0 is returned. 2N/A * Need space for the name, the new line, the 2N/A * tab and the null terminator. 2N/A /* Add space for existing names */ 2N/A * Return 1 if the specified service is online. Otherwise, return 0. 2N/A * Determine if desired service is disabled. If so, 1 is returned. 2N/A * Otherwise 0 is returned.