blob: ffb6c3705842113efb3aaa9e749331c32d34371a [file] [log] [blame]
type=page
status=published
title=remove-library
next=restart-domain.html
prev=redeploy.html
~~~~~~
remove-library
==============
[[remove-library-1]][[GSRFM00820]][[remove-library]]
remove-library
--------------
removes one or more library JAR files from \{product---name}
[[sthref1970]]
Synopsis
[source,oac_no_warn]
----
asadmin [asadmin-options] remove-library [--help]
[--type={common|ext|app}]
library-name [library-name ... ]
----
[[sthref1971]]
Description
The `remove-library` subcommand removes one or more library JAR files
from \{product---name}.
The `--type` option specifies the library type and the \{product---name}
directory from which the library is removed.
The library-name operand is the name of the JAR file that contains the
library to be removed. To specify multiple libraries, specify multiple
names separated by spaces.
[NOTE]
=======================================================================
The library archive file is removed from the DAS. For common and
extension libraries, you must restart the DAS so the library removals
are picked up by the server runtime. To remove the libraries from other
server instances, synchronize the instances with the DAS by restarting
them.
This command is not supported on the Windows operating system.
=======================================================================
This subcommand is supported in remote mode only.
[[sthref1972]]
Options
asadmin-options::
Options for the `asadmin` utility. For information about these
options, see the link:asadmin.html#asadmin-1m[`asadmin`(1M)] help page.
`--help`::
`-?`::
Displays the help text for the subcommand.
`--type`::
Specifies the library type and the \{product---name} directory from
which the library is removed. Valid values are as follows: +
`common`;;
Removes the library files from the Common class loader directory,
domain-dir`/lib`. This is the default.
`ext`;;
Removes the library files from the Java optional package directory,
domain-dir`/lib/ext`.
`app`;;
Removes the library files from the application-specific class loader
directory, domain-dir`/lib/applibs`. +
For more information about these directories, see
"link:../application-development-guide/class-loaders.html#GSDVG00003[Class Loaders]" in GlassFish Server Open Source
Edition Application Development Guide.
[[sthref1973]]
Operands
library-name::
The names of the JAR files that contain the libraries that are to be
removed.
[[sthref1974]]
Examples
[[GSRFM832]][[sthref1975]]
Example 1   Removing Libraries
This example removes the library in the archive file `mylib.jar` from
the application-specific class loader directory on the default server
instance.
[source,oac_no_warn]
----
asadmin> remove-library --type app mylib.jar
Command remove-library executed successfully.
----
[[sthref1976]]
Exit Status
0::
subcommand executed successfully
1::
error in executing the subcommand
[[sthref1977]]
See Also
link:asadmin.html#asadmin-1m[`asadmin`(1M)]
link:add-library.html#add-library-1[`add-library`(1)],
link:list-libraries.html#list-libraries-1[`list-libraries`(1)]
"link:../application-development-guide/class-loaders.html#GSDVG00003[Class Loaders]" in GlassFish Server Open Source
Edition Application Development Guide