Table 1. STAF Service Command Reference
Command | Syntax |
---|---|
CONFIG | Provides a way to save the current STAF configuration to a file,
reflecting any changes made since STAFProc was started
SAVE [FILE <Name>] [VARS <Current | Startup>] HELP |
DELAY | Delay (or sleep) for a specified amount of time.
DELAY <Number>[s|m|h|d|w] HELP |
DIAG | Allows diagnostics to be recorded, listed, enabled, disabled, and reset.
RECORD TRIGGER <Trigger> SOURCE <Source> LIST < [TRIGGER <Trigger> | SOURCE <Source> | TRIGGERS | SOURCES] [SORTBYCOUNT | SORTBYTRIGGER | SORTBYSOURCE] > | SETTINGS RESET FORCE ENABLE DISABLE HELP |
ECHO | Echo a return string from other STAF clients.
ECHO <Message> HELP |
FS | Allows you to manipulate files and directories and get information about file system entries.
COPY FILE <Name> [TOFILE <Name> | TODIRECTORY <Name>] [TOMACHINE <Machine>] [TEXT [FORMAT <Format>]] [FAILIFEXISTS | FAILIFNEW] COPY DIRECTORY <Name> [TODIRECTORY <Name>] [TOMACHINE <Machine>] [NAME <Pattern>] [EXT <Pattern>] [CASESENSITIVE | CASEINSENSITIVE] [TEXTEXT <Pattern>... [FORMAT <Format>]] [RECURSE [KEEPEMPTYDIRECTORIES | ONLYDIRECTORIES]] [IGNOREERRORS] [FAILIFEXISTS | FAILIFNEW] MOVE FILE <Name> <TOFILE <Name> | TODIRECTORY <Name>> MOVE DIRECTORY <Name> TODIRECTORY <Name> GET FILE <Name> [[TEXT | BINARY] [FORMAT <Format>]] GET ENTRY <Name> <TYPE | SIZE | MODTIME | LINKTARGET | CHECKSUM [<Algorithm>]> QUERY ENTRY <Name> CREATE DIRECTORY <Name> [FULLPATH] [FAILIFEXISTS] LIST DIRECTORY <Name> [RECURSE] [LONG [DETAILS] | SUMMARY] [TYPE <Types>] [NAME <Pattern>] [EXT <Pattern>] [CASESENSITIVE | CASEINSENSITIVE] [SORTBYNAME | SORTBYSIZE | SORTBYMODTIME] LIST COPYREQUESTS [LONG] [INBOUND] [OUTBOUND] [FILE [[BINARY] [TEXT]]] [DIRECTORY] LIST SETTINGS DELETE ENTRY <Name> CONFIRM [RECURSE] [IGNOREERRORS] [ CHILDREN [TYPE <Types>] [NAME <Pattern>] [EXT <Pattern>] [CASESENSITIVE | CASEINSENSITIVE] ] SET STRICTFSCOPYTRUST <Enabled | Disabled> HELP |
HANDLE | Allows you to query information on various process handles and to manage static handles.
CREATE HANDLE NAME <Handle Name> DELETE HANDLE <Number> QUERY HANDLE <Handle> LIST [ HANDLES <[NAME <Handle Name>] [LONG] [PENDING] [REGISTERED] [INPROCESS] [STATIC]> | [SUMMARY] ] LIST NOTIFICATIONS [HANDLE <Handle> | MACHINE <Machine>] [LONG] AUTHENTICATE USER <User Identifier> CREDENTIALS <Credentials> [AUTHENTICATOR <Authenticator Name>] UNAUTHENTICATE HELP |
HELP | List and query STAF return codes. Allows services to register their own
return codes.
REGISTER SERVICE <Name> ERROR <Number> INFO <String> DESCRIPTION <String> UNREGISTER SERVICE <Name> ERROR <Number> [SERVICE <Name>] ERROR <Number> LIST SERVICES | [SERVICE <Name>] ERRORS HELP |
LIFECYCLE | Allows STAF service requests to be submitted automatically when STAFProc starts
up or shuts down. Also, allows managing registration of the STAF service requests
to be submitted.
REGISTER PHASE <Startup | Shutdown> MACHINE <Machine> SERVICE <Service> REQUEST <Request> [ONCE] [PRIORITY <Priority>] [DESCRIPTION <Description>] UNREGISTER ID <Registration ID> UPDATE ID <Registration ID> [PRIORITY <Priority>] [ONCE <True | False>] [MACHINE <Machine>] [SERVICE <Service>] [REQUEST <Request>] [PHASE <Startup | Shutdown>] [DESCRIPTION <Description>] LIST [PHASE <Startup | Shutdown>] [LONG] QUERY ID <Registration ID> TRIGGER <ID <Registration ID> | PHASE <Startup | Shutdown>> CONFIRM ENABLE ID <Registration ID> DISABLE ID <Registration ID> HELP |
LOG | Allows for robust data-logging and log file querying and manipulation.
LOG <GLOBAL | MACHINE | HANDLE> LOGNAME <Logname> LEVEL <Level> MESSAGE <Message> [RESOLVEMESSAGE | NORESOLVEMESSAGE] QUERY <GLOBAL | MACHINE <Machine> [HANDLE <Handle>]> LOGNAME <Logname> [LEVELMASK <Mask>] [QMACHINE <Machine>]... [QHANDLE <Handle>]... [NAME <Name>]... [USER <User>]... [ENDPOINT <Endpoint>]... [CONTAINS <String>]... [CSCONTAINS <String>]... [STARTSWITH <String>]... [CSSTARTSWITH <String>]... [FROM <Timestamp> | AFTER <Timestamp>] [BEFORE <Timestamp> | TO <Timestamp>] [FROMRECORD <Num>] [TORECORD <Num>] [FIRST <Num> | LAST <Num> | ALL] [TOTAL | STATS | LONG] [LEVELBITSTRING] LIST GLOBAL | MACHINES | MACHINE <Machine> [HANDLE <Handle> | HANDLES] | SETTINGS DELETE <GLOBAL | MACHINE <Machine> [HANDLE <Handle>]> LOGNAME <Logname> CONFIRM PURGE <GLOBAL | MACHINE <Machine> [HANDLE <Handle>]> LOGNAME <Logname> CONFIRM | CONFIRMALL [LEVELMASK <Mask>] [QMACHINE <Machine>]... [QHANDLE <Handle>]... [NAME <Name>]... [USER <User>]... [ENDPOINT <Endpoint>]... [CONTAINS <String>]... [CSCONTAINS <String>]... [STARTSWITH <String>]... [CSSTARTSWITH <String>]... [FROM <Timestamp> | AFTER <Timestamp>] [BEFORE <Timestamp> | TO <Timestamp>] [FROMRECORD <Num>] [TORECORD <Num>] [FIRST <Num> | LAST <Num>] SET [MAXRECORDSIZE <Size>] [DEFAULTMAXQUERYRECORDS <Number>] [ENABLERESOLVEMESSAGEVAR | DISABLERESOLVEMESSAGEVAR] [RESOLVEMESSAGE | NORESOLVEMESSAGE] VERSION HELP |
MISC | Provides miscellaneous services such as VERSION, WHOAMI, and WHOAREYOU
information, allows for listing and querying enabled interfaces, allows
you to set operational parameters for STAF and show their settings,
and allows you to list and purge the endpoint cache used by automatic
interface cycling.
VERSION WHOAMI WHOAREYOU LIST INTERFACES | SETTINGS | ENDPOINTCACHE QUERY INTERFACE <Name> SET [CONNECTATTEMPTS <Number>] [CONNECTRETRYDELAY <Number>[s|m|h|d|w]] [MAXQUEUESIZE <Number>] [HANDLEGCINTERVAL <Number>[s|m|h|d]] [INTERFACECYCLING <Enabled | Disabled>] [DEFAULTINTERFACE <Name>] [DEFAULTAUTHENTICATOR <Name>] [RESULTCOMPATIBILITYMODE <Verbose | None>] PURGE ENDPOINTCACHE <ENDPOINT <Endpoint>... | CONFIRM> HELP |
MONITOR | Allows test cases the ability to log and query status messages.
LOG MESSAGE <Message> [NAME <Name>] [RESOLVEMESSAGE | NORESOLVEMESSAGE] QUERY MACHINE <Machine> < HANDLE <Handle> | NAME <Name> > LIST <MACHINES | MACHINE <Machine> [NAMES] | SETTINGS> DELETE [BEFORE <Timestamp>] CONFIRM SET [RESOLVEMESSAGE | NORESOLVEMESSAGE] [OLDRETURNCODES | NEWRETURNCODES] [MAXRECORDSIZE <Size>] [ENABLERESOLVEMESSAGEVAR | DISABLERESOLVEMESSAGEVAR] VERSION HELP |
PING | Allows you to ping other STAF clients.
PING [MACHINE <Machine>] HELP |
PROCESS | Allows you to start, stop, and manage processes.
START [SHELL [<Shell>]] COMMAND <Command> [PARMS <Parms>] [WORKDIR <Directory>] [VAR <Variable>=<Value>]... [ENV <Variable>=<Value>]... [USEPROCESSVARS] [WORKLOAD <Name>] [TITLE <Title>] [WAIT [<Number>[s|m|h|d|w]] | ASYNC] [STOPUSING <Method>] [STATICHANDLENAME <Name>] [NEWCONSOLE | SAMECONSOLE] [FOCUS <Background | Foreground | Minimized>] [USERNAME <User name> [PASSWORD <Password>]] [DISABLEDAUTHISERROR | IGNOREDISABLEDAUTH] [STDIN <File>] [STDOUT <File> | STDOUTAPPEND <File>] [STDERR <File> | STDERRAPPEND <File> | STDERRTOSTDOUT] [RETURNSTDOUT] [RETURNSTDERR] [RETURNFILE <File>]... [NOTIFY ONEND [HANDLE <Handle> | NAME <Name>] [MACHINE <Machine>] [PRIORITY <Priority>] [KEY <Key>]] STOP <ALL CONFIRM | WORKLOAD <Name> | HANDLE <Handle>> [USING <Method>] KILL PID <Pid> CONFIRM [USING <Method>] LIST [HANDLES] [RUNNING] [COMPLETED] [WORKLOAD <Name>] [LONG] LIST SETTINGS QUERY HANDLE <Handle>> FREE <ALL | WORKLOAD <Name> | HANDLE <Handle>> NOTIFY REGISTER ONENDOFHANDLE <Handle> [HANDLE <Handle> | NAME <Name>] [MACHINE <Machine>] [PRIORITY <Priority>] NOTIFY UNREGISTER ONENDOFHANDLE <Handle> [HANDLE <Handle> | NAME <Name>] [MACHINE <Machine>] [PRIORITY <Priority>] NOTIFY LIST ONENDOFHANDLE <Handle> SET [DEFAULTSTOPUSING <Method>] [DEFAULTCONSOLE <New | Same>] [DEFAULTFOCUS <Background | Foreground | Minimized>] [PROCESSAUTHMODE <Auth Mode>] [DEFAULTAUTHUSERNAME <User Name>] [DEFAULTAUTHPASSWORD <Password>] [DEFAULTAUTHDISABLEDACTION <Error | Ignore>] [DEFAULTSHELL <Shell>] [DEFAULTNEWCONSOLESHELL <Shell>] [DEFAULTSAMECONSOLESHELL <Shell>] HELP |
QUEUE | Allows you to manipulate and manage queues.
QUEUE MESSAGE <Message> [HANDLE <Handle>] | [NAME <Name>] [PRIORITY <Priority>] [TYPE <Type>] GET [PRIORITY <Priority>]... [MACHINE <Endpoint>]... [NAME <Name>]... [HANDLE <Handle>]... [USER <User>]... [TYPE <Type>]... [CONTAINS <String>]... [ICONTAINS <String>]... [FIRST <Number> | ALL] [WAIT [<Number>[s|m|h|d|w]]] PEEK [PRIORITY <Priority>]... [MACHINE <Endpoint>]... [NAME <Name>]... [HANDLE <Handle>]... [USER <User>]... [TYPE <Type>]... [CONTAINS <String>]... [ICONTAINS <String>]... [FIRST <Number> | ALL] [WAIT [<Number>[s|m|h|d|w]]] DELETE [PRIORITY <Priority>]... [MACHINE <Endpoint>]... [NAME <Name>]... [HANDLE <Handle>]... [USER <User>]... [TYPE <Type>]... [CONTAINS <String>]... [ICONTAINS <String>]... LIST [HANDLE <Handle>] HELP |
RESPOOL | Allows you to manage exclusive access to entries within resource pools.
CREATE POOL <PoolName> DESCRIPTION <Pooltext> DELETE POOL <PoolName> CONFIRM [FORCE] QUERY POOL <PoolName> REQUEST POOL <PoolName> [FIRST | RANDOM | ENTRY <Value> [RELEASE]] [PRIORITY <Number>] [TIMEOUT <Number>[s|m|h|d|w]] [GARBAGECOLLECT <Yes | No>] RELEASE POOL <PoolName> ENTRY <Value> [FORCE] CANCEL POOL <PoolName> [FORCE [MACHINE <Machine>] [HANDLE <Handle #> | NAME <Handle Name>]] [ENTRY <Entry>] [PRIORITY <Number>] [FIRST | LAST] ADD POOL <PoolName> ENTRY <Value> [ENTRY <Value>]... REMOVE POOL <PoolName> ENTRY <Value> [ENTRY <Value>]... CONFIRM [FORCE] LIST [POOLS | SETTINGS] VERSION HELP |
SEM | Allows you to manipulate and manage mutex and event semaphores.
REQUEST MUTEX <Name> [TIMEOUT <Number>[s|m|h|d|w]] [GARBAGECOLLECT <Yes | No>] RELEASE MUTEX <Name> [FORCE] CANCEL MUTEX <Name> [FORCE [MACHINE <Machine>] [HANDLE <Handle #> | NAME <Handle Name>]] [FIRST | LAST] POST EVENT <Name> RESET EVENT <Name> PULSE EVENT <Name> WAIT EVENT <Name> [TIMEOUT <Number>[s|m|h|d|w]] DELETE MUTEX <Name> | EVENT <Name> QUERY MUTEX <Name> | EVENT <Name> LIST MUTEX | EVENT HELP |
SERVICE | Allows you to manage STAF services and requests.
LIST [ SERVICES | SERVICELOADERS | AUTHENTICATORS | REQUESTS <[PENDING] [COMPLETE] [LONG]> | [SUMMARY] ] QUERY SERVICE <Service Name> | SERVICELOADER <ServiceLoader Name> | AUTHENTICATOR <Authenticator Name> | REQUEST <Request Number> ADD SERVICE <Service Name> LIBRARY <Library Name> [EXECUTE <Executable>] [OPTION <Name=[=Value]>]... [PARMS <Parameters>] REMOVE SERVICE <Service Name> FREE REQUEST <Request Number> [FORCE] HELP |
SHUTDOWN | Allows you to manage the STAFProc daemon process.
SHUTDOWN NOTIFY REGISTER [MACHINE <Machine>] [HANDLE <Handle> | NAME <Name>] [PRIORITY <Priority>] NOTIFY UNREGISTER [MACHINE <Machine>] [HANDLE <Handle> | NAME <Name>] [PRIORITY <Priority>] NOTIFY LIST HELP |
TRACE | Allows you to turn tracing on and off at the service and tracepoint level.
ENABLE ALL [ TRACEPOINTS | SERVICES ] ENABLE TRACEPOINTS <Trace point list> | SERVICES <Service list> ENABLE TRACEPOINT <Trace point> [TRACEPOINT <Trace point>]... ENABLE SERVICE <Service> [SERVICE <Service>]... DISABLE ALL [ TRACEPOINTS | SERVICES ] DISABLE TRACEPOINTS <Trace point list> | SERVICES <Service list> DISABLE TRACEPOINT <Trace point> [TRACEPOINT <Trace point>]... DISABLE SERVICE <Service> [SERVICE <Service>]... SET DESTINATION TO < [STDOUT | STDERR] [FILE <File name> [APPEND]] > SET DEFAULTSERVICESTATE < Enabled | Disabled > LIST [SETTINGS] PURGE HELP |
TRUST | Allows you to manipulate and manage trust levels (security).
SET < MACHINE <Machine> | USER <User> | DEFAULT > LEVEL <Level> GET MACHINE <Machine> [USER <User>] DELETE MACHINE <Machine> | USER <User> LIST HELP |
VAR | Allows you to manipulate and manage system, shared and process specific variable pools.
SET [SYSTEM | SHARED | HANDLE <Handle>] [FAILIFEXISTS] VAR <Name=Value> [VAR <Name=Value>]... GET [SYSTEM | SHARED | HANDLE <Handle>] VAR <Name> DELETE [SYSTEM | SHARED | HANDLE <Handle>] VAR <Name> [VAR <Name>]... LIST [SYSTEM | SHARED | HANDLE <Handle> | ASHANDLE <Handle> | REQUEST [<Number>]] RESOLVE [SYSTEM | SHARED | HANDLE <Handle> | ASHANDLE <Handle> | REQUEST [<Number>]] STRING <String> [STRING <String>]... HELP |
ZIP | Allows for unzipping, listing, and adding/deleting entries in Zip archives which are
PKZip, WinZip and Jar compatible.
UNZIP ZIPFILE <Name> TODIRECTORY <Name> [FILE <Name>]... [DIRECTORY <Name>]... [RESTOREPERMISSION] [REPLACE] ADD ZIPFILE <Name> < FILE <Name> | DIRECTORY <Name> [RECURSE] > [RELATIVETO <Directory>] DELETE ZIPFILE <Name> FILE <Name> [FILE <Name>]... CONFIRM LIST ZIPFILE <Name> VERSION HELP |