blob: a85523c15c2a7ba74db772385989d1e429039cc5 [file] [log] [blame]
type=page
status=published
title=create-audit-module
next=create-auth-realm.html
prev=create-application-ref.html
~~~~~~
= create-audit-module
[[create-audit-module-1]][[GSRFM00014]][[create-audit-module]]
== create-audit-module
Adds an audit module
[[sthref131]]
=== Synopsis
[source]
----
asadmin [asadmin-options] create-audit-module [--help]
--classname classname
[--property(name=value)[:name=value]*]
[--target target]
audit_module_name
----
[[sthref132]]
=== Description
The `create-audit-module` subcommand adds the named audit module for the
Java class that implements the audit capabilities. Audit modules collect
and store information on incoming requests (from, for example, servlets
and EJB components) and outgoing responses.
This subcommand is supported in remote mode only.
[[sthref133]]
=== Options
asadmin-options::
Options for the `asadmin` utility. For information about these
options, see the link:asadmin.html#asadmin-1m[`asadmin`(1M)] help page.
`--classname`::
The name of the Java class that implements this audit module. If not
specified, this option defaults to
`com.sun.enterprise.security.Audit`.
`--help`::
`-?`::
Displays the help text for the subcommand.
`--property`::
Optional keyword-value pairs that specify additional properties for
the audit module. +
Audit module properties that are defined by {productName} are as
follows:
`auditOn`;;
If `true`, specifies that the audit module is loaded and called by
the {productName} audit library at audit points.
+
Other available properties are determined by the implementation of the
audit module.
`--target`::
Specifies the target on which you are creating the audit module. Valid
values are as follows:
`server`;;
Creates the audit module for the default server instance `server`
and is the default value.
configuration_name;;
Creates the audit module for the named configuration.
cluster_name;;
Creates the audit module for every server instance in the cluster.
instance_name;;
Creates the audit module for a particular server instance.
[[sthref134]]
=== Operands
audit_module_name::
The name of this audit module.
[[sthref135]]
=== Examples
[[GSRFM459]][[sthref136]]
==== Example 1   Creating an audit module
[source]
----
asadmin> create-audit-module
--classname com.sun.appserv.auditmodule
--property defaultuser=admin:Password=admin sampleAuditModule
Command create-audit-module executed successfully
----
[[sthref137]]
=== Exit Status
0::
command executed successfully
1::
error in executing the command
[[sthref138]]
=== See Also
link:asadmin.html#asadmin-1m[`asadmin`(1M)]
link:delete-audit-module.html#delete-audit-module-1[`delete-audit-module`(1)],
link:list-audit-modules.html#list-audit-modules-1[`list-audit-modules`(1)]