|
Administrator's Guide |
This chapter describes how to perform some typical server maintenance tasks. It has sections on the following:
You can use the SilverStream Management Console (SMC) to remotely administer servers. You can administer as many servers as you want from one SMC console. If you are running a server in a cluster, you can choose additional server clusters to administer. For more information about server clusters, see Server clustering.
Verify that the server you want to administer is up and running.
Type the server name and specify the port if it is not the default 80.
Handling mail received from clients is an important aspect of Web application development. SilverStream developers might write business objects that trigger when mail is received on the server. To implement this type of object, the SilverStream server must be configured to poll for e-mail in one or more mailboxes from one or more POP3 or IMAP servers.
The Mail option on the SMC allows you to set up mailboxes for this purpose. For example, if a developer needs a business object to automate the maintenance of a mailing list in the database, you would first create a mail account for mailing list maintenance. Then the developer could write a business object that looks at e-mail received at that mailbox for subscribe and unsubscribe requests.
NOTE You can configure mail-triggered business objects messages in JavaMail format. The JavaMail format enables you to manipulate received messages and send new messages using the standard J2EE mail API.
Click New and enter data in the fields. You must provide data for all of the fields displayed on this tab.
The new settings take effect immediately.
Once enabled, the SilverStream server acts as a POP3 or IMAP client.
This section describes how to install or delete SilverStream user licenses.
SilverStream uses a license key to administer access to the server. License management is integrated with session management. Each user connection requires a license. The license is held for the duration of the connection.
You receive an initial encrypted license key when you buy your product. Each product you purchase comes with a certain type of license. You use the Installation program to add this license key to your server. This information is stored in the database.
You may only need the initial user-based license key during your application development cycle. However, when it comes time to deploy your application and go live, you will probably want to call SilverStream and purchase CPU-based licenses for your application server.
If you have a user-based license and your application is put into production, when the number of simultaneous users increase you may see a message like Maximum server sessions exceeded.
You should add new licenses through the SilverStream Installation program.
When you have multiple licenses installed, SilverStream will use the least restrictive license it finds. For example, if you have installed both a single-user license and a CPU-based license, SilverStream uses the CPU-based license.
From the Setup Function screen, select Add a new server license.
The License Information screen appears.
Fill in the license serial number.
TIP If you receive this long encrypted number electronically, paste it into the License number field to avoid typing errors.
Specify the requested information for your SilverMaster, where the license information is stored.
SilverStream uses the license number and other information you enter to generate an encrypted license key.
Run the upldlic.sh utility, which is at the root directory on the SilverStream CD.
When prompted, specify where SilverStream is installed and what the license string is.
SilverStream generates an encrypted license key.
To access or delete a license:
The license form displays information about your license.
To delete a license, select it and then select Remove License.
SilverStream supports an environment variable called AGCLASSPATH, which allows you to extend the Java classes used by your application. You can use AGCLASSPATH, for example, when you want to include third-party elements such as database drivers with your application. Use this variable instead of the +cp Java class path option described in Starting the SilverStream server. SilverStream overrides the CLASSPATH variable.
NOTE When deploying business objects using created Java classes, SilverStream developers should create JAR files using the SilverStream Designer, rather than by setting AGCLASSPATH. For more information, see the Programmer's Guide.
In UNIX, set the environment variable AGCLASSPATH following the appropriate procedure for the shell you are using. For NT, use the following procedure.
Choose the System icon, then select the Environment tab.
The following screen appears.
Type AGCLASSPATH in the Variable field, then type a path in the Value field.
The screen above shows AGCLASSPATH with a value of c:\myclasses.
You can use the SMC to view J2EE objects that have been deployed on a server. The only objects that you can enable, disable, or shut down are the EJB JARs that have been deployed in the selected database.
The Deployed Objects panel lists:
For more information, see the J2EE deployment chapter in the Facilities Guide of the server's Core Help.
Expand the database you want to manage.
The only objects you can select and act upon in this panel are the EJB JARs (and the beans in the JARs) that have been deployed in the selected database.
To delete any deployed object (other than EJBs), use the Designer.
Select an EJB JAR and perform one of the following actions.
You can use the SMC to set some administrative properties used by the Fulcrum SearchServer full-text search engine.
For more information about Fulcrum SearchServer and how to enable full text search in SilverStream applications, see the full-text search chapter in the Tools Guide of the server's Classic Development Help.
To set Fulcrum full-text properties:
Specify values as described below.
|
Property |
Description |
|---|---|
Specifies how often Fulcrum SearchServer checks and performs incremental indexing for rows whose full-text-search columns have been modified. NOTE Indexing is forced before a query against a modified table is processed. | |
Maximum number of hits Fulcrum will return for a full text search query. The default is 1000. Set this value to 0 if you don't want any limit to the number of hits returned. | |
If this property is selected, SilverStream will not reindex tables marked for full text search at server startup time.
| |
If this property is selected, SilverStream will not perform any indexing before a full-text-search even if columns have been modified. This property is useful when you have large tables that don't often change that you want to search. By default, this property is not set. |
Indexing full-text-search tables If the Enable partial indexing at startup property is not selected, at startup time the SilverStream server deletes all previous full-text indexing from all tables that have full index search enabled, then reindexes all the tables from scratch. After the initial indexing, the tables are marked for incremental indexing only when updates are made to them within SilverStream.
Full reindexing of tables consumes resources unnecessarily if the tables are never updated outside SilverStream.
You can select the Enable partial indexing at startup property (which is selected by default) to turn off full reindexing when the server starts. This means that at server startup, previous indexes will be maintained, tables will be marked for incremental indexing, and incremental indexing for SilverStream-modified tables will continue.
If Enable partial indexing at startup (or Disable indexing before full-text search) is not selected, full-text search tables will be indexed from scratch each time the server starts.
NOTE If you set Enable partial indexing at startup but still have some tables that are updated outside SilverStream, you can specify full indexing for these tables: open the SilverStream Business Object Designer and create a business object that will fire when the server is started. Add the following line of code for each table that you want to be reindexed:
com.ssw.srv.agents.AgFullText.index("db", "table");
The SMC provides several options that allow you to easily monitor server activity. These options are described in the following sections:
You can display real-time charts of various server statistics.
To display a chart of server activity:
An empty chart displays.
The Add Plot dialog displays, allowing you to choose which statistics you want to chart. The statistics are divided into categories.
Select a statistic you want to chart and click Add. Statistics marked with
are counts; statistics marked with
record changes.
The statistic is added to the table below the chart. The current value of the statistic is shown, as is the color of the plot line that will be generated.
Select additional statistics if you want, clicking Add after each one.
When you have selected all the statistics you are interested in, click Close.
What happens SilverStream plots all the statistics you have specified and displays the exact values in the table below the chart. By default, the values are updated every five seconds.
You can change the scale of the Y-axis by specifying a new value in the Scale field (the default is 100). You can also change how often SilverStream updates the values by changing the value in the Refresh interval field (the default is every five seconds).
It may be that you are plotting different statistics with very different scales but want them to appear clearly in the chart. To do this, you can change the multiplier for particular plots to equalize the values and make the chart easier to read.
Once you have charted a set of statistics that you are interested in, you can save the specification of the statistics set in a file so that you can easily view the set of statistics later.
NOTE The file stores the list of statistics that are plotted. It does not store the statistics' values.
The Save dialog displays.
Specify the file you want to save the statistics set in. If you don't provide an extension, SilverStream gives the file the extension META.
The specifications for the chart are saved in a file. You can view the statistics set later by clicking Load, as described next.
To view a statistics set you saved previously:
The Open dialog displays.
Select the file that defines the statistics set you want to view and click Open.
The chart is updated to show the statistics set that had been saved in the file.
If you have enabled server logging and are using the built-in SilverStream logging class to log to the database, you can display the log(s) in realtime in the SMC. (If you are logging to a file or using a custom class to do the logging, you can't display the log in the SMC.)
For more information about server logging, see
Using server logging.
Select the tab corresponding to the logging you have enabled and which you want to view.
The log displays.
Update the log by clicking Refresh (the log does not update automatically).
Resize a column by placing your mouse pointer on the column's right border and dragging the mouse.
You can display in the SMC tabular views of server statistics related to individual sessions and threads, as well as a summary of server activity.
To access server statistics in a view:
About the statistics The following sections describe the statistics that are displayed.
This tab displays statistics for each current client session.
Viewing statistics in a browser You can also display these statistics in a browser: point your browser at http://server/SilverStream/Sessions.
This tab displays statistics for each server thread.
Following is a description of each of the fields.
|
Thread statistic |
Description |
|---|---|
Non-client threads are used for various internal tasks, such as cleaning up server data structures, indexing full-text tables, and so on. Client threads handle incoming requests. There should be at least as many client threads as there are MAXCLIENTCONNS listed in the SMC Connections panel (see Client connection parameters). ResultBuffer threads are prefetch buffer threads as defined in the SMC (see Setting performance parameters). They are dynamically added as needed, but should not exceed the number defined in the SMC. | |
The start date for the thread. In many cases this date is the same as when the server was started. However, for dynamically allocated threads (such as prefetch buffers) this value will be different. | |
The elapsed time (in seconds) since the thread has been actively working, as opposed to waiting. This value reflects how busy the server is in general. | |
An internal session ID for this thread. See the Sessions tab to determine user/host information. |
This tab provides access to different types of category summaries. The following describes the items for each tab selection.
|
Server statistic |
Description |
|---|---|
The number of HTTP message requests the server has received since it started. | |
The number of bytes returned by the server since it started. |
Request time statistics. The statistics for this tab are enabled only when HTTP logging is enabled. For a description of HTTP logging, see Using server logging.
Memory statistics. The statistics for this option apply to the Java Virtual Machine (JVM).
Thread statistics. This option provides statistics about Client threads, which handle incoming client connections.
|
Thread statistic |
Description |
|---|---|
The current number of threads not associated with a client connection and available for immediate use. | |
The number of threads associated with a client connection, but not currently handling a user request. | |
The total number of client threads allocated. This number should be equal to the Maximum number of client connections in the SMC Connections panel (see Client connection parameters). |
Viewing statistics in a browser You can also display most of these summary statistics in a browser: point your browser at http://server:port/SilverStream/Statistics. The page updates itself automatically every five seconds.
SilverStream provides two techniques that allow you to redirect requests for selected pages served by your Web server to a SilverStream server. The original technique is implemented by SilverJunction, an NSAPI/ISAPI module that can be installed on Microsoft Internet Information Server or Netscape Enterprise/Fast Track Web servers.
The newer technique--using SilverStream Web Server Integration (WSI) modules-- supersedes SilverJunction and addresses limitations found in SilverJunction. You should use the WSI modules instead of SilverJunction to integrate a SilverStream server with your Web server. See Using the Web Server Integration Modules.
If for some reason you want to use SilverJunction, however--read the following section.
For information on installing SilverJunction, see the Installation Guide.
Through the use of HTTP redirect mechanisms, SilverJunction allows for one-time redirects from standard Web servers. SilverStream uses two HTTP redirect calls: 302 for 1.0 implementations and 307 for 1.1 implementations. These implementations are executed at the browser level and are hidden from the user.
The example in this section describes a typical implementation of the SilverJunction plug-in. ABCDE Company has an IIS server that is accessible by clients at the host http://www.ABCDE.com. The company catalog resides at http://www.ABCDE.com/catalog. The catalog has been redesigned and improved using SilverStream, and now runs on a SilverStream server at the following URL:
http://s2.ABCDE.com/productdb/Pages.
ABCDE's Webmaster does not want to break any existing links that may point to the old location of the catalog, so the Webmaster installs a SilverJunction filter (plug-in) for IIS on the original Web server. Then the Webmaster writes a configuration file specifying that all requests that come to the Web server at www.ABCDE.com and whose relative URL portion looks like "/catalog/*" should be redirected to http://s2.ABCDE.com/productdb/Pages/*.
Given this setup, an HTTP 1.1 browser pointed to:
http://www.ABCDE.com/catalog/main.html
receives a temporary redirect (HTTP code 307) to:
http://s2.ABCDE.com/productdb/Pages/main.html
If the SilverStream server is running as part of a cluster, the Dispatcher will redirect the request to an appropriate SilverStream server.
Once the user has been redirected to the SilverStream server, subsequent calls will go directly to the SilverStream server and not to the original Web server. The SilverJunction mechanism may mask the URL on the first redirect; but since the user has been fully redirected to the SilverStream server, the URL may not be masked on subsequent requests.
The following shows how SilverJunction works using a standalone SilverStream server. The initial client request directed at the IIS server is redirected back to the client to be re-sent directly to the SilverStream server.
The following shows how SilverJunction works in a clustered server environment. In this case the client request is redirected twice. The first redirect goes to the Dispatcher, which then redirects the request to an appropriate server. For more information, see Administering a Cluster.
To configure SilverStream as a plug-in:
Open the metadata file called SilverJunction.jdl, located in SilverStream/resources.
By default, the configuration file SilverJunction.jdl is found in the Silverstream/resources directory. The IIS version of SilverJunction will always look for it in this location.
For an NSAPI (NetScape) version, the location of the configuration file is determined by initialization parameters specified in the obj.conf file. This is done by inserting the following lines:
Init fn=init_redirect conf_file="SilverStream/Resources/SilverJunction.jdl"
For more information, see the Netscape Server documentation.
The following is an example of a setup in SilverJunction.jdl:
SILVER_JUNCTION TARGET_SERVER /Host 'machine.domain.com' /Port 8002 endobj MAP /From '/S2/' /To '/' endobj MAP /From '/demo1' /To '/silverstream1/db2/user3' endobj endobj
You must enter a TARGET_SERVER. Both /Host and /Port properties must be defined.
The /Host property indicates the name of the machine to which redirects are sent
The /Port property indicates the port on which a dispatcher (in a cluster environment) or the SilverStream server is running.
Specify at least one MAP. When specifying a MAP, both /From and /To properties must be defined:
Example Given the settings in the preceding file, a request for /demo1/main.htm is redirected to:
http://machine.domain.com:8002/silverstream1/db2/user3/main.htm
|
Administrator's Guide |
Copyright © 2001, SilverStream Software, Inc. All rights reserved.