open-src/app/xfs/fsadmin
author X gate hg captive account <xhg@xserver.us.oracle.com>
Wed, 19 Aug 2015 13:48:41 -0700
changeset 1484 bc8922b8e1d2
parent 943 294f64612d23
permissions -rw-r--r--
Added tag s11u3_30 for changeset 221e9d9cc9cb
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
729
d654a217cd7e 6852798 Xorg modularization: xfs 1.1.0 [LSARC 2008/009]
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents:
diff changeset
     1
#! /usr/bin/ksh93
d654a217cd7e 6852798 Xorg modularization: xfs 1.1.0 [LSARC 2008/009]
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents:
diff changeset
     2
#
943
294f64612d23 6948254 Mass update of X gate sources to Oracle copyright format
Alan Coopersmith <Alan.Coopersmith@Oracle.COM>
parents: 919
diff changeset
     3
# Copyright (c) 1997, 2009, Oracle and/or its affiliates. All rights reserved.
729
d654a217cd7e 6852798 Xorg modularization: xfs 1.1.0 [LSARC 2008/009]
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents:
diff changeset
     4
#
d654a217cd7e 6852798 Xorg modularization: xfs 1.1.0 [LSARC 2008/009]
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents:
diff changeset
     5
# Permission is hereby granted, free of charge, to any person obtaining a
919
425233ae7236 6931307 Standardize Sun copyright & license notices in X gate on current format
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents: 907
diff changeset
     6
# copy of this software and associated documentation files (the "Software"),
425233ae7236 6931307 Standardize Sun copyright & license notices in X gate on current format
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents: 907
diff changeset
     7
# to deal in the Software without restriction, including without limitation
425233ae7236 6931307 Standardize Sun copyright & license notices in X gate on current format
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents: 907
diff changeset
     8
# the rights to use, copy, modify, merge, publish, distribute, sublicense,
425233ae7236 6931307 Standardize Sun copyright & license notices in X gate on current format
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents: 907
diff changeset
     9
# and/or sell copies of the Software, and to permit persons to whom the
425233ae7236 6931307 Standardize Sun copyright & license notices in X gate on current format
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents: 907
diff changeset
    10
# Software is furnished to do so, subject to the following conditions:
425233ae7236 6931307 Standardize Sun copyright & license notices in X gate on current format
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents: 907
diff changeset
    11
#
425233ae7236 6931307 Standardize Sun copyright & license notices in X gate on current format
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents: 907
diff changeset
    12
# The above copyright notice and this permission notice (including the next
425233ae7236 6931307 Standardize Sun copyright & license notices in X gate on current format
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents: 907
diff changeset
    13
# paragraph) shall be included in all copies or substantial portions of the
425233ae7236 6931307 Standardize Sun copyright & license notices in X gate on current format
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents: 907
diff changeset
    14
# Software.
425233ae7236 6931307 Standardize Sun copyright & license notices in X gate on current format
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents: 907
diff changeset
    15
#
425233ae7236 6931307 Standardize Sun copyright & license notices in X gate on current format
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents: 907
diff changeset
    16
# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
425233ae7236 6931307 Standardize Sun copyright & license notices in X gate on current format
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents: 907
diff changeset
    17
# IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
425233ae7236 6931307 Standardize Sun copyright & license notices in X gate on current format
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents: 907
diff changeset
    18
# FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.  IN NO EVENT SHALL
425233ae7236 6931307 Standardize Sun copyright & license notices in X gate on current format
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents: 907
diff changeset
    19
# THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
425233ae7236 6931307 Standardize Sun copyright & license notices in X gate on current format
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents: 907
diff changeset
    20
# LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
425233ae7236 6931307 Standardize Sun copyright & license notices in X gate on current format
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents: 907
diff changeset
    21
# FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
425233ae7236 6931307 Standardize Sun copyright & license notices in X gate on current format
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents: 907
diff changeset
    22
# DEALINGS IN THE SOFTWARE.
729
d654a217cd7e 6852798 Xorg modularization: xfs 1.1.0 [LSARC 2008/009]
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents:
diff changeset
    23
#
d654a217cd7e 6852798 Xorg modularization: xfs 1.1.0 [LSARC 2008/009]
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents:
diff changeset
    24
#
d654a217cd7e 6852798 Xorg modularization: xfs 1.1.0 [LSARC 2008/009]
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents:
diff changeset
    25
# fsadmin - script to enable/disable X font server
d654a217cd7e 6852798 Xorg modularization: xfs 1.1.0 [LSARC 2008/009]
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents:
diff changeset
    26
d654a217cd7e 6852798 Xorg modularization: xfs 1.1.0 [LSARC 2008/009]
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents:
diff changeset
    27
PATH=/usr/bin:/usr/sbin
d654a217cd7e 6852798 Xorg modularization: xfs 1.1.0 [LSARC 2008/009]
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents:
diff changeset
    28
USAGE='usage: fsadmin [-e | -d | -usage]'
d654a217cd7e 6852798 Xorg modularization: xfs 1.1.0 [LSARC 2008/009]
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents:
diff changeset
    29
FMRI='svc:/application/x11/xfs:default'
d654a217cd7e 6852798 Xorg modularization: xfs 1.1.0 [LSARC 2008/009]
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents:
diff changeset
    30
d654a217cd7e 6852798 Xorg modularization: xfs 1.1.0 [LSARC 2008/009]
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents:
diff changeset
    31
if (( $# == 0 )) ; then
d654a217cd7e 6852798 Xorg modularization: xfs 1.1.0 [LSARC 2008/009]
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents:
diff changeset
    32
    # No arguments - report current status
d654a217cd7e 6852798 Xorg modularization: xfs 1.1.0 [LSARC 2008/009]
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents:
diff changeset
    33
    /usr/bin/svcs $FMRI
d654a217cd7e 6852798 Xorg modularization: xfs 1.1.0 [LSARC 2008/009]
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents:
diff changeset
    34
else 
d654a217cd7e 6852798 Xorg modularization: xfs 1.1.0 [LSARC 2008/009]
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents:
diff changeset
    35
    case "$1" in
d654a217cd7e 6852798 Xorg modularization: xfs 1.1.0 [LSARC 2008/009]
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents:
diff changeset
    36
	'-e'|'-d')
d654a217cd7e 6852798 Xorg modularization: xfs 1.1.0 [LSARC 2008/009]
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents:
diff changeset
    37
	    /usr/sbin/inetadm $1 $FMRI
d654a217cd7e 6852798 Xorg modularization: xfs 1.1.0 [LSARC 2008/009]
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents:
diff changeset
    38
	    ;;
d654a217cd7e 6852798 Xorg modularization: xfs 1.1.0 [LSARC 2008/009]
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents:
diff changeset
    39
	*)
d654a217cd7e 6852798 Xorg modularization: xfs 1.1.0 [LSARC 2008/009]
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents:
diff changeset
    40
	    print "$USAGE"
d654a217cd7e 6852798 Xorg modularization: xfs 1.1.0 [LSARC 2008/009]
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents:
diff changeset
    41
	    ;;
d654a217cd7e 6852798 Xorg modularization: xfs 1.1.0 [LSARC 2008/009]
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents:
diff changeset
    42
    esac 
d654a217cd7e 6852798 Xorg modularization: xfs 1.1.0 [LSARC 2008/009]
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents:
diff changeset
    43
fi
d654a217cd7e 6852798 Xorg modularization: xfs 1.1.0 [LSARC 2008/009]
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents:
diff changeset
    44
d654a217cd7e 6852798 Xorg modularization: xfs 1.1.0 [LSARC 2008/009]
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents:
diff changeset
    45
exit 0