The installsamples script
The installsamples script installs the sample applications into an instance. This script is located in the /QIBM/ProdData/WebAS5/Base/samples/bin directory.
Note: If you are running WebSphere Application Server Network Deployment, and you want to install the samples on a federated application server instance, see Install the samples on a federated application server in the Application development topic.
Product
The installsamples script is available in the WebSphere Application Server product only.
Authority
To run this script, your user profile must have *ALLOBJ authority.
Syntax
The syntax of the installsamples script is:
installsamples [ -instance instance [ -server servername ] ] [ -srcdir sourcedir ] [ -allsamples ] [ -samplename [ -collection collection ] ] [ -help | -? ]Parameters
The parameters of the installsamples script are:
-instance
Optional. The value instance specifies the name of the instance that contains the application server on which you want to install the samples. The default value is default.-server
This an optional parameter. The value server specifies the name of the application server on which you want to install the samples. The default value is the default server for the specified instance.-srcdir
Optional. The value sourcedir specifies the directory where the samples were built. The script installs samples from the first location where it finds them, using this search order:
- The -srcdir location, if specified
- /QIBM/UserData/WebAS5/Base/instance/samples/lib
- /QIBM/ProdData/WebAS5/Base/samples/lib
-allsamples
Optional. If you specify this parameter, the script installs all of the samples.-samplename
Optional. The value samplename specifies the sample that you want to install. Valid values are MessageDrivenBeans, Petstore, PlantsByWebSphere, TechnologySamples, and WebServicesSample. You can specify more than one of these samples.
- If you do not specify this parameter, the script installs all of the samples into their default collections.
- If you specify this parameter and do not specify the -allsamples parameter, the script installs only the specified samples.
- If you specify this parameter and the -allsamples parameter, the script installs the specified samples into the specified collection, and the unspecified samples into their default collections.
-collection
Optional. If you specify the -samplename parameter, you can also specify a collection name for the sample data. The default values are:
- TechnologySamples: TECHSAMP50
- PlantsbyWebSphere: PLANTSDB50
- PetStore samples: PETSDB50 and CATALOG50
-help or -?
This optional paramter prints the usage statement for the script.
Examples
These examples demonstrate correct syntax:
installsamplesThis example installs all samples with their default collections. The samples are installed from the default source directory to the default application server (server1) in the default instance.
installsamples -instance myinst -PetStore -TechnologySamples -collection WASTECHLIBThis example installs the PetStore sample with the default collection and TechnologySamples with the WASTECHLIB collection. The samples are installed from the default source directory to the default application server in the myinst instance.
installsamples -PetStore -collection WASPETSTOR -allsamplesThis example installs the PetStore sample with the WASPETSTOR collection and all of the other samples with their default collections. The samples are installed from the default source directory to the default application server in the default instance.