Websydian v6.1 online documentationOnline documentation - Websydian v6.1

Deploying Websydian Server on iSeries

Introduction

This document describes how to deploy, tune, and troubleshoot the Websydian server on the iSeries.

It is required that the user deploying the Websydian Server has knowledge of the iSeries. Especially with reference to job management.

Prerequisites

Before starting the Websydian Server please make sure the following prerequisites have been performed or verified.

OS/400 software

Make sure that the following software are available on the IBM i:

Websydian runtime objects

Make sure the Websydian runtime objects are installed, including the latest PTFs on the IBM i including the java runtime files for the DWA environment which are to be placed in the integrated file system (IFS).

For further information on installing the Websydian runtime on the IBM i read this document.

Starting the Websydian Server

The Websydian Server is started by issuing the command STRWS that is located in the Websydian runtime library.

Add the Websydian runtime libraries to the library list, making sure that the library WSYD610PTF is located before the library WSYD610.

===>ADDLIBLE WSYD610 [Enter]

 

===>ADDLIBLE WSYD610PTF [Enter]

Submit the Websydian Server using the STRWS command followed by F4.

===>STRWS [F4]

Check each of the parameters, for a description check below. Press PgDn to see all parameters

                      Start Websydian Server (Java) (STRWS)                     
                                                                                
 Type choices, press Enter.                                                     
                                                                                
 Websydian home directory . . . .   '/websydian/wsyd610'                        
                                                                                
                                                                                
 Websydian Server IP Address  . .   *LOCALHOST                                  
                                                                                
                                                                                
 Websydian Server TCP Port  . . .   08189         Number                        
 Websydian Server Password  . . .   SECRET        Character value               
 Log level  . . . . . . . . . . .   ERROR         TRACE, INFO, WARN, ERROR...   
 Log filename . . . . . . . . . .   '/websydian/wsyd610/logs/ws.log'            
                                                                                
                                                                                
 License file path and name . . .   '/websydian/wsyd610/license/license.key'    
                                                                                
                                                                                
 Java version . . . . . . . . . .   1.5           Character value               
                                                                                
 Job name . . . . . . . . . . . .   DWAWSSVR      Character value               
 Job description  . . . . . . . .   WSYDJOBD      Name                          
   Library  . . . . . . . . . . .     WSYD610     Name                          
 Job queue  . . . . . . . . . . .   QINTER        Name                          
   Library  . . . . . . . . . . .     QGPL        Name                          
 Init library list  . . . . . . .   *JOBD         Name, *CURRENT, *JOBD...      
 User . . . . . . . . . . . . . .   *CURRENT      Name, *CURRENT, *JOBD         

Optional press the F10 for Additional parameters 

                            Additional Parameters                               
                                                                                
 DWA Protocol Encoding (WS) . . .   *DFT                                        
                                                                                
 Mail recipient . . . . . . . . .   *NONE                                       
                                                                                
 Mail sender  . . . . . . . . . .   *NONE                                       
                                                                                
                                                                                
 Mail subject . . . . . . . . . .   *NONE                                       
                                                                                
                                                                                
 SMTP host name . . . . . . . . .   *NONE                                       
                                                                                
                                                                                
 Log roll interval  . . . . . . .   *DAILY        Character value, *DAILY...    
 Name of Script to use  . . . . .   STRWS.SH                                     

Parameters described

Parameter Default Value Description
Websydian home directory /websydian/wsyd610 Directory in the IFS where required Websydian runtime objects are located
Websydian Server IP Address *LOCALHOST The IP address of the machine where the Websydian Server is started. This address together with the TCP port is used by the Web Server Component to connect to the Websydian Server.

Valid values are:

  • The host name of the iSeries
  • An IP Address located on the iSeries (IP/v4 or IP/v6)
  • *LOCALHOST indicating local IP Address 127.0.0.1
Websydian Server TCP Port 08189 The TCP port of the Websydian Server. The port is used together with the IP address by the Web Server Component to connect to the Websydian Server.
Websydian Server Password SECRET A password for used in order to operate the Websydian Server e.g. required in case sending the end command to the Websydian Server
Log level ERROR The log level affects how much the Websydian Server will write to the log file. The following values can be used:
  • TRACE
  • INFO
  • WARN
  • ERROR
  • FATAL

Use ERROR in a deployment environment whereas TRACE should be used in debug situations only.

Log filename /websydian/wsyd610/logs/ws.log The file to which the log is written.
License file path and name /websydian/wsyd610/license/license.key The path and file name of the license file.
Java version 1.5 The version of the Java JVM to be used
Job name DWAWSSVR Job name to be used for the Websydian Server
Job description WSYD610/WSYDJOBD Job description used for submitting the Websydian Server to batch
Job queue QGPL/QINTER Job queue used for submitting the Websydian Server to batch
Init library list *JOBD Initial library list to be used
User *CURRENT The user to be used for submitting the Websydian Server to batch
DWA Protocol Encoding (WS) *DFT Encoding used by internal DWA protocols (DO NOT CHANGE)
Mail recipient *NONE The receiver of log mails.
Mail sender *NONE If SMTP host name is specified, this parameter is mandatory and must contain the sender name to use when sending log mails.
Mail subject *NONE The subject of the log mails.
SMTP host name *NONE If this parameter is specified all log messages of type FATAL will be sent in an e-mail to an administrator. This parameter specifies the host name of the SMTP server.
Log roll interval *DAILY The frequency to be used by the log system to roll the log:

Valid values are:

  • NO_ROLL
  • ROLL_HOURLY
  • ROLL_DAILY
  • ROLL_WEEKLY
  • ROLL_MONTHLY
Name of Script to use STRWS.SH The name of the Shell script used to execute the Websydian Server Java runtime. Located in the 'bin' sub directory of the Websydian home directory.

Verifying the Websydian Server

After starting the Websydian Server verify that the Websydian Server is listening on the port specified.

The main location to verify the state of the Websydian Server is in the log.

Using the command WRKLNK you are able to view the log file of the Websydian Server

WRKLNK '/Websydian/WSYD610/logs/*' [Enter]

 

                             Work with Object Links

 Directory  . . . . :   /websydian/WSYD610/logs

 Type options, press Enter.
 2=Edit   3=Copy   4=Remove   5=Display   7=Rename   8=Display attributes
 11=Change current directory ...

 Opt Object link            Type     Attribute     Text
    wsydsrv.log             STMF








                                                                   Slut
 Parameters or command
 ===>                                                                         
 F3=Exit   F4=Prompt   F5=Refresh   F9=Retrieve   F12=Cancel   F17=Position to
 F22=Display entire field   F23=More options
 

 

Select option 5 in front of the wsydsrv.log file for view and press enter.

 Edit File: /websydian/WSYD610/logs/wsydsrv.log                                 
 Record :       1   of       3 by   8            Column :   30     99 by  74    
 Control :                                                                      
                                                                                
CMD 3....+....4....+....5....+....6....+....7....+....8....+....9....+....0.... 
    a**************                                                             
    ead-0:INFO] - License info: Websydian Server Unregistered Basic expires at   
    ead-0:INFO] - DWA protocol: Version 2.1.                                    
    ead-0:INFO] - Waiting for connection on 127.0.0.1:3871...              
    ***************                                                             
                                                                                
                                                                                
                                                                                
                                                                                
                                                                                
                                                                                
                                                                                
                                                                                
                                                                                
                                                                                
                                                                                
 F2=Save   F3=Save/Exit   F12=Exit   F15=Services   F16=Repeat find             
 F17=Repeat change  F19=Left  F20=Right                                          

Input 30 in column and press enter.

The log file shows all communication with the Websydian Server, note this is only the case when log level is set to TRACE. Make sure that the statement "Waiting for connection on xxx.xxx.xxx.xxx:yyyy" is located in the log. xxx.xxx.xxx.xxx is the IP address used by the Websydian Server and the yyyy is the port tn which the Websydian Server is listening.

If the information is not in the log file or the log file is not available please proceed to the Troubleshooting Websydian Server section of this document.

Stopping the Websydian Server

The Websydian Server is stopped by issuing the command ENDWS which is located in the Websydian runtime library.

Add the Websydian runtime libraries to the library list, making sure that the library WSYD610PTF is located before the library WSYD610.

===>ADDLIBLE WSYD610 [Enter]
 
===>ADDLIBLE WSYD610PTF [Enter]

Submit the Websydian Server using the STRWS command followed by F4.

===>ENDWS [F4]

Check each of the parameters, for a description check below.

                      End Websydian Server (Java) (ENDWS)                     
                                                                                
 Type choices, press Enter.                                                     
                                                                                
 Websydian home directory . . . .   '/websydian/wsyd610'                        
                                                                                
                                                                                
 Websydian Server IP Address  . .   *LOCALHOST                                  
                                                                                
                                                                                
 Websydian Server TCP Port  . . .   08189         Number                        
 Websydian Server Password  . . .   SECRET        Character value               

Parameters described

Parameter Default Value Description
Websydian home directory /websydian/wsyd610 Directory in the IFS where required Websydian runtime objects are located
Websydian Server IP Address *LOCALHOST The IP address of the machine where the Websydian Server is started.

Valid values are:

  • The host name of the iSeries
  • An IP Address located on the iSeries (IP/v4 or IP/v6)
  • *LOCALHOST indicating local IP Address 127.0.0.1
Websydian Server TCP Port 08189 The TCP port of the Websydian Server.
Websydian Server Password SECRET The password as specified when issuing the STRWS command.

Troubleshooting the Websydian Server

First step in order to troubleshoot the deployment of the Websydian Server is trying to use the command RUNWS.

The RUNWS will start the Websydian Server interactively enabling the user to view any error messages produced by the java environment. The command interface of the RUNWS command differs only with regards to submit job information.

Next step in Troubleshooting the start of Websydian Server on the iSeries is primarily based on information found in the log file.

If the log file is not created make sure the path is correct and that the user starting the Websydian Server, specified on the job description, has the correct authority to the directory where the log file is to be located.

Errors pertaining the start of the Websydian Server which is based on job description problems or other iSeries related problems can be identified by doing the following.

  1. Check the output queue QEZJOBLOG for any spool files that are related to the iSeries job servicing the Websydian Server.
     

    Use the command WRKOUTQ to view the contents of the output queue QEZJOBLOG

    ===>WRKOUTQ QEZJOBLOG [Enter]

     

  2. Check for the existents of a QPRINT spool file created for the user starting the Websydian Server using the command WRKSPLF.
     
    ===>WRKSPLF <username> [Enter]

     

The most common errors found in the log file and their solutions are:

Error creating socket - [IO error]:ServerFactory(): Error creating stream (java.net.BindException: Address already in use.)

The error indicates that the port to which the Websydian Server is trying to listen is already used by another program. Change the port number used and try starting the Websydian Server again..

Using the iSeries NETSTAT command

Use the command NETSTAT to view the list of used IP addresses on the iSeries and select the menu option 3 - Work with TCP/IP connection status

===>NETSTAT [Enter]

 

                       Work with TCP/IP Connection Status                       
                                                             System:   DKSOFT00 
 Type options, press Enter.                                                     
   3=Enable debug   4=End   5=Display details   6=Disable debug                 
   8=Display jobs                                                               
                                                                                
      Remote           Remote     Local                                         
 Opt  Address          Port       Port       Idle Time  State                   
      *                *          ftp-con >  000:52:39  Listen                  
      *                *          telnet     000:29:57  Listen                  
      *                *          smtp       238:56:17  Listen                  
      *                *          www-http   002:36:49  Listen                  
      *                *          pop3       238:56:19  Listen                  
      *                *          netbios >  238:56:19  Listen                  
      *                *          netbios >  000:00:36  *UDP                    
      *                *          netbios >  000:00:21  *UDP                    
      *                *          netbios >  000:29:07  Listen                  
      *                *          cifs       001:27:59  Listen                  
      *                *          drda       238:57:26  Listen                  
      *                *          ddm        238:57:26  Listen                  
                                                                   Mere...      
 F3=Exit   F5=Refresh   F9=Command line   F11=Display byte counts   F12=Cancel  
 F15=Subset   F22=Display entire field    F24=More keys                         
Error creating socket - [IO error]:ServerFactory(): Error creating stream (java.net.BindException: Address not available.).

The error indicates that the IP address specified does not exist on the iSeries. Change the IP address and try starting the Websydian Server again.

Use the command CFGTCP followed by selection of the menu option 1 - Work with TCP/IP interfaces to view a list of available IP addresses on the iSeries.

CFGTCP [Enter]

 

                          Work with TCP/IP Interfaces                           
                                                             System:   DKSOFT00 
 Type options, press Enter.                                                     
   1=Add   2=Change   4=Remove   5=Display   9=Start   10=End                   
                                                                                
      Internet         Subnet              Line      Line                       
 Opt  Address          Mask             Description  Type                       
                                                                                
      127.0.0.1        255.0.0.0        *LOOPBACK    *NONE                      
      192.168.1.1      255.255.255.0    ETHLAN1      *ELAN                      
      192.168.1.2      255.255.255.0    ETHLAN2      *ELAN                      
      192.168.100.1    255.255.255.0    ETHLAN3      *ELAN                      
                                                                                
                                                                                
                                                                                
                                                                                
                                                                                
                                                                                
                                                                                
                                                                                
                                                                   Slut         
 F3=Exit      F5=Refresh   F6=Print list   F11=Display interface status         
 F12=Cancel   F17=Top      F18=Bottom