SunOS man pages : smcconf (1)
Maintenance Commands smcconf(1M)
NAME
smcconf - configure the Solaris Management Console
SYNOPSIS
/usr/sadm/bin/smcconf [ -h ] [ -v ] toolbox [ action ] [
target ] [ parameters ] [ options ]
/usr/sadm/bin/smcconf [ -h ] [ -v ] repository [ action ]
[ target ] [ parameters ] [ options ]
DESCRIPTION
The smcconf command configures the Solaris Management Con-
sole. See smc(1M). This command enables you to add to,
remove from, and list the contents of the toolboxes and bean
repository.
Using smcconf to edit toolboxes is not as feature-rich as
using the Solaris Management Console's graphical editor. The
command line interface is intended for use in packaging
scripts that do not require user interaction. To edit all
the properties of a toolbox or to modify the hierarchy of
folders in a toolbox, you must use the specialized graphical
editor, that is, smc edit. See smc(1M).
OPTIONS
The following options are supported:
-h Prints out a usage summary for the command.
-v Verbose option. Displays the debugging output at any
time.
Toolbox Configuration
action
Legal values are:
add Adds a target to the toolbox. Specify the path
to the toolbox using the -B toolboxpath option
and, optionally, provide locale information with
the -L locale option.
remove
Removes a target from the toolbox. Specify the
path to the toolbox using the -B toolboxpath
option and, optionally, provide locale informa-
tion with the -L locale option.
create
Creates a new toolbox with no tools in it. The
only target recognized is toolbox.
list
SunOS 5.8 Last change: 16 Jun 2000 1
Maintenance Commands smcconf(1M)
Lists the contents of the toolbox. No target is
recognized. If you specify a parameter, it is
taken as the path to a toolbox and the contents
of that toolbox are listed. If you do not
specify a parameter, the contents of the default
toolbox are listed.
target
Legal values are:
tool If the action is specified as add, this target
adds a native Solaris Management Console tool
from the toolbox. The required parameter is the
full Java classname of the tool you are adding.
If you specify a folder name with the -F option,
the tool is placed inside that folder (the
folder will not be created if it does not
already exist). Otherwise, the tool is appended
to the end of the toolbox and not placed inside
any folder.
If the action is specified as remove, this tar-
get removes a native Solaris Management Console
tool from the toolbox. The required parameter is
the full Java classname of the tool you wish to
remove. If you specify a folder name with the -F
option, any tool with the given name in that
folder will be removed. If no folder name is
specified, all tools with the given name in the
toolbox will be removed.
For the tool to show up in the console, the tool
must also be registered in the repository. See
the repository configuration section below for
more information. If a tool is referenced in a
toolbox but is not registered, it will not
appear in the console when the toolbox is
loaded.
Removing a tool from a toolbox does not remove
the tool from the server repository.
tbxURL
If the action is specified as add or remove,
this target adds to or removes from the toolbox
a link to another toolbox. The required parame-
ter is the URL to the other toolbox.
The properties of addition and removal are the
same as for the tool target.
SunOS 5.8 Last change: 16 Jun 2000 2
Maintenance Commands smcconf(1M)
toolbox
If the action is specified as create, this tar-
get creates a skeleton toolbox with no tools.
There are four required parameters: the toolbox
name, description, and small and large icon
paths. These must be followed by the -B toolbox-
path and -D scope options.
legacy
If the action is specified as add or remove,
this target adds or removes legacy applications
(command-line, X-windows, and web-based) to or
from the toolbox. The -N, -T, -E, and -B options
are required, and the -A option is optional.
Placement in the toolbox with the -F option fol-
lows the same rules as for the tool and tbxURL
targets. See NOTES for more information about
legacy applications.
folder
If the action is specified as add, this target
adds a folder to the toolbox. There are four
required parameters: the folder name, descrip-
tion, and small and large icon paths.
If the action is specified as remove, this tar-
get removes a folder from the toolbox. If the
folder to be removed is itself inside a folder,
the containing folder must be specified with the
-F option.
parameters
Specifies values that may be required depending on the
combination of action and target.
options
Supported options for various action and target combi-
nations for the toolbox configuration are:
- A parameters
Specifies the parameters to pass to the legacy
application. This option is available only for
the legacy target.
-B toolboxpath
Specifies the path of the toolbox that is being
modified. If this option is not given, the
modifications will be performed on the default
toolbox, "This Computer".
-D scope
SunOS 5.8 Last change: 16 Jun 2000 3
Maintenance Commands smcconf(1M)
Specifies the scope (domain) in which the tool
should be run. The legal values for scope are
file, nis, nisplus, dns, and ldap. This may also
be specified for a folder or a toolbox. In the
former case, all tools in that folder and its
subfolders will be run in that scope; in the
latter, all tools in the toolbox will be run in
that scope.
-E appPath
Specifies the absolute executable path of the
legacy application. This option is available
only for the legacy target.
-F folder
Specifies the full path of the container folder.
If this option is not given, the default folder
is the `root' folder of the toolbox.
-H [host_name][:port]
Specifies the host and port from which a tool
should be loaded. If host_name is not given, the
default host (localhost, if the toolbox is
loaded from the local filesystem, or the host
from which the toolbox is loaded if loaded from
a remote Solaris Management Console server) will
be used. If :port is not given, the default port
will be used. If this option is not given at
all, both the default host and the default port
will be used.
-L locale
Specifies the locale of the toolbox which is
being modified. The default is the C locale.
-N appName
Specifies the name of the legacy application
being registered. This is the name that will
appear in the console. This option is available
only for the legacy target.
-P key:value
Specifies the key/value pairs that define param-
eters to a tool. Multiple key/value pairs can be
specified at a time.
-T appType
Specifies the legacy application type. Legal
values are CLI, XAPP, or HTML. This option is
available only for the legacy target.
SunOS 5.8 Last change: 16 Jun 2000 4
Maintenance Commands smcconf(1M)
Repository Configuration
The Solaris Management Console repository stores information
about the registered tools and services, as well as
libraries (for instance, resource jars) and properties
attached to tools or services.
action
Legal values are:
add Adds information to the repository. If the -f
option is given to add, the information will
overwrite any information of the same name
already in the repository. If the -f option is
not given, an error may be returned if the
information is already in the repository.
remove
Removes information from the repository.
list
Lists the contents of the repository:
o all registered tools
o all registered services
o all libraries attached to all tools
o all libraries attached to all services
o all libraries attached to all tools and
services
target
Legal values are:
bean If the action is specified as add, this target
will add a tool or service bean (which kind is
determined by the contents of the bean) to the
repository. The required parameter is the path
to the jar file that contains the bean to be
added.
If the action is specified as remove, this tar-
get will remove a tool or service bean from the
repository. The required parameter is the full
Java classname of the desired bean.
library
If the action is specified as add, this target
SunOS 5.8 Last change: 16 Jun 2000 5
Maintenance Commands smcconf(1M)
adds a "library" jar file to a tool or service
bean. The two required parameters are the full
Java classname of the desired bean and the path
to the jar file to be attached. The bean name
can also be one of the "pseudo-beans", ALL,
ALLTOOL, or ALLSERVICE, in which case the
library will be attached, respectively, to all
beans, all tools, or all services in the reposi-
tory.
If the action is specified as remove, this tar-
get detaches a "library" jar file from a tool or
service bean. The two required parameters are
the full Java classname of the desired bean and
the name of the jar file that is attached. As
with the add action, the three "pseudo-beans"
ALL, ALLTOOL, or ALLSERVICE can be used.
property
If the action is specified as add, this target
defines a property on a tool or service. One or
more key/value pairs must be specified in the
form,
-P key=value
Following this property list is a "pseudo-bean
name", pseudoBeanName, as defined for the
library target, on which the properties will be
defined. Optionally, a library name may follow
the "pseudo-bean" name, in which case the pro-
perties are defined on the library that is
attached to the named bean.
If the action is specified as remove, this tar-
get undefines a property on a tool or service.
The key/value pairs, "pseudo-bean" name, and
optional library are specified as for the add
action.
EXAMPLES
Example 1: Adding Legacy Applications to a Toolbox
The following command adds to the default toolbox the Com-
mand Line Interface (CLI) application, /usr/bin/ls with
arguments -al -R, giving it the name, Directory Listing:
SunOS 5.8 Last change: 16 Jun 2000 6
Maintenance Commands smcconf(1M)
/usr/sadm/bin/smcconf toolbox add legacy -N "Directory Listing" \
-T CLI -E /usr/bin/ls -A "-al -R"
Example 2: Adding a Folder to a Toolbox
The following command adds to the standard "Management
Tools" toolbox a folder with the name, New Folder, the
description, This is a new folder, and the small and large
icons, folder_s.gif and folder_l.gif:
/usr/sadm/bin/smcconf toolbox add folder "New Folder" \
"This is a new folder" folder_s.gif folder _l.gif \
-B /var/sadm/smc/toolboxes/smc/smc.tbx
Example 3: Adding a Native Solaris Management Console Tool
to a Toolbox
The following command adds a native Solaris Management Con-
sole tool to the default toolbox. The Java classname of the
tool is HelloWorld.client.HelloTool (the name, description,
and icons visible in the console are provided by the tool
itself). When loaded, it will be run in the NIS domain,
syrinx, which is hosted by the machine, temple, and will be
retrieved from port 2112 on the machine from which the tool-
box was loaded.
/usr/sadm/bin/smcconf toolbox add tool HelloWorld.client.HelloTool \
-D nis:/temple/syrinx -H :2112
Example 4: Adding a Solaris Management Console Tool to the
Repository
The following command adds the Java bean found in
HelloWorld.jar to the repository. The jar file contains
information that the bean is a tool.
/usr/sadm/bin/smcconf repository add bean HelloWorld.jar
Example 5: Removing a Solaris Management Console Service
from the Repository
The following command removes a Java bean from the reposi-
tory. Although the name of the bean implies that it is a
service, that is merely convention; the repository knows
whether a particular registered bean is a tool or a service.
SunOS 5.8 Last change: 16 Jun 2000 7
Maintenance Commands smcconf(1M)
/usr/sadm/bin/smcconf repository remove bean \
HelloWorld.server.HelloService
Example 6: Attaching a Library to a Tool
The following command adds the library jar file,
HelloWorld_fr.jar (probably a French localized version of
the HelloTool's resources) to the bean,
HelloWorld.client.HelloTool:
/usr/sadm/bin/smcconf repository add library \
HelloWorld.client.HelloTool HelloWorld_fr.jar
Example 7: Attaching a Library to all Tools
The following command adds the library jar file,
widgets.jar, to all tools in the repository. The library
probably contains a widget set which might be useful to any
registered tools.
/usr/sadm/bin/smcconf repository add library ALLTOOL widgets.jar
ENVIRONMENT VARIABLES
See environ(5) for descriptions of the following environment
variables that affect the execution of the smcconf command:
JAVA_HOME
If you do not specify this environment variable, the
/usr/java1.2 location is used.
DISPLAY
If you do not set this environment variable, set it to
null, or set it to an X(7) display to which you are
not authorized to connect, the Solaris Management Con-
sole starts in terminal mode instead of graphical
mode.
EXIT STATUS
The following exit values are returned:
0 Successful completion.
1 An error occurred.
ATTRIBUTES
See attributes(5) for descriptions of the following attri-
butes:
SunOS 5.8 Last change: 16 Jun 2000 8
Maintenance Commands smcconf(1M)
____________________________________________________________
| ATTRIBUTE TYPE | ATTRIBUTE VALUE |
|_____________________________|_____________________________|
| Availability | SUNWmc |
|_____________________________|_____________________________|
SEE ALSO
jar(1), java(1), javac(1), smc(1M), attributes(5),
environ(5)
NOTES
All standard shell quoting rules apply.
Legacy applications (X-windows, command-line, and web-based
applications) are handled differently from "native" Solaris
Management Console tools. Legacy tools are handled by an
instantiation of a native Solaris Management Console tool,
LegacyAppLauncher, which, through the toolbox, is given the
necessary information to run the legacy application: path,
options, and so forth. Thus, you do not register a legacy
application into the repository as you would a native
Solaris Management Console tool. Instead, legacy applica-
tions appear only in toolboxes.
SunOS 5.8 Last change: 16 Jun 2000 9
|
 |
|
|