ASNA DataGate® 5.0 for iSeries/400®


    Contents

What the Installation Will Do

Transferring and Installing DataGate/400

Installing DataGate/400 onto the AS/400 from the PC

Installing DataGate/400 using FTP

Installing DataGate/400 onto the AS/400 from the AS/400

Installing DataGate/400 from AS/400 Tape Media

Installing DataGate/400 using an AS/400 CD-ROM drive

Licensing DataGate/400

Entering the License Code on the AS/400

Entering the License Code on the PC

Authority of the User Profile used to Register DataGate

Configuring DataGate/400

Configuring TCP/IP on Windows 98

Configuring DataGate/400 for TCP/IP Access

Verifying that TCP/IP is Installed Correctly

Naming an AS/400 Database

Configuring Multiple Versions of DataGate/400

Using TCP/IP

Troubleshooting

Troubleshooting AS/400 TCP/IP Connectivity

Troubleshooting DataGate Service

Troubleshooting a DataGate Job that is Not Terminating

Setting up a Subsystem

Troubleshooting Manually Ending Users Jobs

Finding an AS/400 IP address

Upgrading OS/400 Level

Uninstalling DataGate

 

 

You will achieve fast, record-level DB2/400 database access from Windows with DataGate/400. Whether you are developing your client applications in Visual Basic, C, C++ , ASNA Visual RPG, ASNA Database Toolbox for Java, DataGate/400 provides the direct file access needed for efficient Client/Server processing - without SQL and ODBC.

AS/400 connectivity is supported for TCP/IP.

DataGate/400 retains all AS/400 object authority and object locking. Its Remote Program Call support features automatic program initiation and activation, and allows character, numeric and indicator (boolean) parameter data types.

DataGate/400 provides full object control for the AS/400 including: creating files; accessing file definitions; adding, deleting and initializing file members; renaming and copying files. It provides full access to CL commands and data areas, and it utilizes all AS/400 CPF error messaging.

This chapter contains the installation procedures for installing, configuring and troubleshooting DataGate/400.

Contents

·         What the Installation Will Do

·         Transferring and Installing DataGate/400

·         Installing DataGate/400 from the PC

·         Installing DataGate/400 from the AS/400

- Using AS/400 tape media

- Using AS/400 CD-Rom drive

·         Configuring DataGate/400

- For TCP/IP access

·         Naming an AS/400 Database

·         Configuring Multiple Versions of DataGate/400

·         Setting up a Subsystem

·         Troubleshooting


What the Installation Will Do

On the AS/400

·         Restore the temporary library, ASNADLVR onto the AS/400 either directly from AS/400 media. 

·         Restore the library ASNATEMP from the Save file in ASNADLVR.

·         Install DataGate/400 to library DG8_40.

On the PC

·         Restore PC programs, by default, to the \Datagate\FTP folder.

Prior to installation, if DataGate is running on the AS/400, you must first stop the service (e.g., DG8_40/ENDDG8SVR) and all DataGate sessions.
DO NOT delete or rename the DG8_40 library.  It is required for all versions of DataGate even though you may be installing into different library names.

Back To Top

Transferring and Installing DataGate/400

The procedure to install DataGate/400 on the AS/400 consists of 2 parts.  The first is to transfer DataGate/400 to the AS/400, either from a PC or AS/400 media, and the second is to actually install DataGate/400 onto the AS/400. 

There is 1 way in which you can transfer DataGate/400 to the AS/400 from the PC

·         FTP

There are 2 ways in which you can transfer DataGate/400 to the AS/400 from the AS/400

·         AS/400 Tape Media

·         A CD-Rom on the AS/400

Refer to the appropriate installation procedure below consisting of the desired transfer method.  Each procedure will have a subheading noting whether the steps are done on the AS/400 or the PC.

The last step in each procedure will be to run the command that actually installs DataGate/400 onto the AS/400.

Back To Top

Installing DataGate/400 onto the AS/400 from the PC

Installing DataGate/400 using FTP

In order to install DataGate/400 on the AS/400 from a Save file (obtained from the Installation CD), you must have TCP/IP installed on both your PC and on the AS/400. (You must also have FTP installed on your AS/400).

Installing TCP/IP and FTP on the AS/400 is beyond the scope of this document.  If you do not know whether your AS/400 has TCP/IP and/or FTP, please check with your network manager or system provider.

On the AS/400       

1.       Sign onto the AS/400 using an account with *SECOFR authority. 

2.       On the AS/400, create a library (temporary) called ASNADLVR.  (Note: QTEMP must not be used).

CRTLIB ASNADLVR

3.       Add this library to the library list:

ADDLIBLE ASNADLVR

4.   Create a Save file in the same library as the physical file:

CRTSAVF FILE(ASNADLVR/DG8SF)

On the PC

5.   To upload the Save file from the CD or PC, an FTP session must be started to the AS/400. 

From Windows, click on the START button, select RUN and enter the following command:

FTP as400tcpipaddress

where as400tcpipaddress is either a TCP/IP address such as 198.176.129.35, or a machine name that is registered either in a DNS or a HOSTS file. 

6.   When prompted for a user name and password, enter the appropriate information that will give you privileges to upload data to the AS/400.

7.   Once FTP has been started, upload the Save file to the AS/400 by entering the following commands:

a)    binary

b)   put   x:\Datagate\FTP\ASNATEMP  ASNADLVR/DG8SF

where x is the CD-ROM drive or PC disk drive

c)     quit

On the AS/400

8.       Restore the library called ASNATEMP from the Save file in ASNADLVR.

RSTLIB SAVLIB(ASNATEMP) DEV(*SAVF) SAVF(ASNADLVR/DG8SF)

9.   To install DataGate/400, execute the following command:

ASNATEMP/LODDG8  library name

·         where library name is optional.  If a library name is not specified, DataGate/400 will be installed to the library DG8_40. 

When DataGate/400 is installed, it is automatically authorized for one user license. If you wish to authorize more than one license to DataGate for the AS/400, obtain a code from ASNA and enter it using ASNA's Registration Assistant from Start - Programs - ASNA Product Suite on the PC.

10.   Once the installation has completed, the library ASNADLVR is no longer needed, and may be deleted.  (The ASNATEMP library is automatically deleted).

11.    If accessing the AS/400 via TCP/IP, the DataGate server will have to be configured for TCPIP access.  See Configuring TCP/IP on Windows for more information.

12.   You must name the AS/400 Database in Acceler8DB Database Manager using Work with Database Names.  See Naming an AS/400 Database for more information.

Back To Top

Installing DataGate/400 onto the AS/400 from the AS/400

The following installation processes have two steps.

·         The first step is to restore a temporary installation library and can be done by anyone with *USER authority or higher. 

·         The second step does the actual installation and initialization of the product and requires *SECOFR authority to run it.

Installing DataGate/400 from AS/400 Tape Media

To Install from AS/400 Tape Media

1.   Load the Installation tape.  Enter the following command to restore the Install program to the ASNATEMP library:

RSTLIB ASNATEMP TAP01

TAP01 refers to the device name from which the object will be restored.  If an alternative tape drive is being used, enter the appropriate device name.

2.   Once the library is restored, sign onto the AS/400 with *SECOFR authority and execute the following command:

ASNATEMP/LODDG8  library name

·         where library name is optional.  If a library name is not specified, DataGate/400 will be installed  to the library DG8_40. 

Once the installation is completed, the ASNATEMP library is automatically deleted.

When DataGate/400 is installed, it is automatically authorized for one user license. If you wish to authorize more than one license to DataGate for the AS/400, obtain a code from ASNA and enter it using ASNA's Registration Assistant from Start - Programs - ASNA Product Suite on the PC.

3.       If accessing the AS/400 via TCP/IP, the DataGate server will have to be configured for TCPIP access.  See Configuring TCP/IP on Windows 98 for more information.

4.       You must name the AS/400 Database in Acceler8DB Database Manager using Work with Database Names.  See Naming an AS/400 Database for more information.

Back To Top

Installing DataGate/400 using an AS/400 CD-ROM drive

To Install from AS/400 CD-Rom Drive

1.   To restore the installation library, load the CD, then enter the following command:

RSTLIB ASNATEMP OPT01 OPTFILE('DATAGATE/RSTLIB/ASNATEMP')

(where OPT01 refers to the device name from which the object will be restored)

2.   Then enter the following command:

ASNATEMP/LODDG8 

When DataGate/400 is installed, it is automatically authorized for one user license. If you wish to authorize more than one license to DataGate for the AS/400, obtain a code from ASNA and enter it using ASNA's Registration Assistant from Start - Programs - ASNA Product Suite on the PC.

If accessing the AS/400 via TCP/IP, the DataGate server will have to be configured for TCPIP access.  See Configuring TCP/IP on Windows 98 for more information.

3.       You must name the AS/400 Database in Acceler8DB Database Manager using Work with Database Names.  See Naming an AS/400 Database for more information.

Back To Top

Licensing DataGate/400

Before DataGate/400 may be used on any AS/400, a valid license code, issued by ASNA, must be entered.  For new trials, this code will be sent with the product if the machine serial number and model type are known at the time of shipping.

The code issued with a trial of DataGate/400 will license, or register the product to be used on a specified machine up to a specified date.  If it is required to move the product onto another machine, upgrade the model type, or extend the trial period, please contact your Distributor or ASNA for a new license code.

Once the product has been purchased, a new license code will be issued to register the product on a permanent basis.  This code will be based on either unlimited users, or on a per-user basis.

Back To Top

Entering the License Code on the AS/400

A new license code is entered, or a current license can be viewed or changed by using the product’s Registration Assistant program.

When installing the product for the first time, or when an upgrade is installed, the Registration Assistant screen is displayed with the bottom of the screen displaying whether the current License Code is valid or not.   If the License Code is valid, press F3 to continue.   If not, call ASNA or your Distributor to get a new License Code.

Note: You can not use the product without a proper License Code.

To Enter, Display, or Change a License Code on the AS/400

1.       If you are not already at the Registration Assistant Screen, enter the following:

a.      ADDLIBLE LIB(DG8_40) POSITION(*FIRST)

b.      DG8_40/REGISTER

Enter or verify the information as detailed below.

System Name

The name of the AS/400 will automatically display. 

Model

The model of the AS/400 will automatically display.

Serial Number

The serial number of the AS/400 will automatically display.

License Key

For a new license, enter the 16-digit license code acquired from ASNA exactly as it is given.

License Type

License Type specifies if the licensing is for an individual machine, or for the entire company. 

·         To license, or register the current machine, use *MACH, which is the default.

·         To license, or register the entire company, enter *SITE.

Customer Name

The name of the user that was entered when the product was installed will automatically display.  However, you can change this name as needed.

The customer name is case-sensitive and must match the customers name exactly as ASNA's account shows.

Company Name

The name of the company that was entered when the product was installed will automatically display.  However, you can change this name as needed.

If you are entering a Site License, the name of the company must be spelled exactly as determined by you and ASNA.   This name is also case-sensitive, so capitalization must match exactly.   

Start Date

The Start Date specifies if the product has been purchased, in which you have a Permanent code, or if the product is a ‘Trial’, which is only valid for a specified period.

·         If the product has been purchased, use *PERM, which is the default.

·         For a ‘Trial’ of the product, enter the starting date in the format MM/DD/YYYY.

Expiration Date

The Expiration Date indicates the date in which the license code will expire. 

·         If the product has been purchased, use *PERM, which is the default.

·         For a ‘Trial’ of the product, enter the ending date of the trial as specified by ASNA in the format MM/DD/YYYY.

User Count

User Count specifies the number of concurrent users that can access the product, as a per-user-basis, or as unlimited.

·         For unlimited users, use *UNLIM, which is the default.

·         For a specified number of users, enter the user count as a positive integer.

3.       Acceptance of a valid licensing code is confirmed at the bottom of the screen.  Press F3 to continue.

If the message “The License is Invalid” displays, recheck all entries.  If no errors were made in any of the entries, call ASNA or your National Distributor for further assistance.

If the message “Couldn't create license data area, check authority and try again" displays, you do not have the proper authority to register DataGate/400.  See Authority of the User Profile used to Register DataGate for more information.

Back To Top

Entering the License Code on the PC

To register a DataGate/400 license code, the user profile used must have *CHANGE authority to the DG8_40 library.  Additionally, it must have *ALL authority to the DGPCODE data area in DG8_40.  See Authority of the User Profile used to Register DataGate for additional information.

To Enter a License Code on the PC

1.       After installing DataGate/400, contact ASNA to obtain a License Key. 

2.       Open Registration Assistant by selecting Start - Programs - ASNA Product Suite - ASNA Registration Assistant and select DataGate/400 as the product by clicking on the arrow to the right.

3.       Select the database nameDatabase_Name that points to the database on the AS/400 in which you are registering a license for.

The database name for the AS/400 to be licensed must already exist on the system running Registration Assistant.  Use Acceler8DB Database Manager to register a database name by selecting Work with Database Names… from the File menu. 

Once a database name is selected, the Model and Serial number of the AS/400 will automatically display.

4.       Enter the License Key that you received from ASNA, along with the rest of the information as listed below.  Select the Register Product button when finished.

Machine Code

Machine Code is a unique number that represents a “signature” of your system and will automatically display.  The code is separated into groups of 4-digit numbers.  It will contain 16 numbers (except for AVR 2.2 and earlier).  The Machine Code can not be changed.

If for any reason you lose your machine code, please contact ASNA.

AS/400 Model

The model of the AS/400 will automatically display after selecting a database name to license.

Serial Number

The serial number of the AS/400 will automatically display after selecting a database name to license.

License Key

A 16-digit license key acquired from ASNA.  You may enter the License Key as a single, large number.  However, for easier readability, it is recommended to enter one or more spaces between each set of 4 digits.  Note that this is not necessary, and spaces will not affect the License Key.

Database Name

Select the database name on the AS/400 in which you are registering a license for.

Name

The name of the user that was entered when the product was installed will automatically display.  However, you can change this name as needed.

Company

The name of the company that was entered when the product was installed will automatically display.  However, you can change this name as needed.

If you are entering a Site LicenseSite_License, the name of the company must be spelled exactly as determined by you and ASNA.  This name is also case-sensitive, so capitalization must match. 

Version

The version (and build number) of the selected product will automatically display. 

Full Version

A full version indicates that you have full use of the product, i.e., you can compile and make .EXE’s, DLL’s, and OCX’s.  The full version can be set as either permanent or temporary.

Trial Version

A trial version indicates that you do not have full use of the product, i.e., you can not compile and make .EXE’s, DLL’s, and OCX’s.

When you install Visual RPG 3.x on a system in which Visual RPG has never been installed before, you are automatically given a “trial” version of AVR.  A trial version is good for approximately 30 days, so you do not need to enter a license key until the product is purchased and you have received a permanent license key from ASNA.

Site License

Check this box if your company is set up with a Site License, in which multiple licenses have been acquired that will all use the same License Key.

Unlimited

Select Unlimited if the number of users that can access Acceler8DB Engine or DataGate/400 is not limited to a particular number.

Limited

Select Limited if there is a limit to the number of users that can access Acceler8DB Engine or DataGate/400.  If limited is selected, enter the number of concurrent users that can access Acceler8DB Engine or DataGate/400 in User CountUser_Count.

User Count

Enter the number of concurrent users that can access Acceler8DB Engine of DataGate/400.  This option will only display if a user type of LimitedLimited was selected.

Date format

Select the date format in which you will enter the StartingStart and EndingEnd date for the license.  The two formats are:

mm/dd/yyyy   (USA)

dd/mm/yyyy   (UK)

Permanent

The license period is permanent for this system.  There is no startStart or endEnd date. 

You will not need to contact ASNA for another license unless there is a changeASNA_Registration_Assistant to your system. 

Temporary

The license period is temporary.  You must specify a startStart and endEnd date.

Start

Enter the starting date of the licensing of the specified product according to the date formatDate_format you have selected.  This is the date in which the product was installed.

End

Enter the ending date of the licensing of the specified product according to the date formatDate_format you have selected.  This should be approximately 30 days in which the product was installed.  However, if you need an extension to the trial period, please contact ASNA.  ASNA_Registration_Assistant

5.       Acceptance of a valid licensing code is displayed.  Select OK to clear the message, then select Exit to close Registration Assistant.

If you receive Acceler8DB error number 654 - “Not authorized to Object" after selecting the Register button, you do not have the proper authority to register DataGate/400.  See Authority of the User Profile used to Register DataGateAuthority_of_the_User_Profile_used_to_Register_Datagate below for more information.

Back To Top

Authority of the User Profile used to Register DataGate

The user profile used to register DataGate software must have *CHANGE authority to the DG8_40 library.  Additionally, it must have *ALL authority to the DGPCODE data area in DG8_40, if it already exists (say, from a previous registration of the product). 

The user profile must have these authorities regardless of the method used to register the program, such as the AS/400 REGISTER command or the Windows PC Registration Assistant program.

As an example, suppose user profile ADBUSER is to be used to register DataGate.  The successful execution of the following two AS/400 commands prior to registration will insure that the required object authorities will be available to ADBUSER:

GRTOBJAUT OBJ(QSYS/DG8_40) OBJTYPE(*LIB) USER(ADBUSER) AUT(*CHANGE)

GRTOBJAUT OBJ(DG8_40/DGPCODE) OBJTYPE(*DTAARA) USER(ADBUSER) AUT(*ALL)

Remember that the DGPCODE data area may not exist yet if DataGate has never been registered on the machine.  If so, the second command is not necessary.

·         If the Registration Assistant is used, the user profile is the "Username" specified on the Work With Database Names dialog box of Acceler8DB File Manager, and other tools. 

·         If the REGISTER command is used, the user profile in question is the one used to log on to the AS/400 interactive session.

Back To Top

Configuring DataGate/400

Configuring TCP/IP on Windows 98

This process assumes that your machine is on a TCP/IP Network.  If you are unsure of the type of Network, or do not understand any of the steps, please contact your Network Administrator.

To install the protocol, you must have your Windows Operating System CD!

To Configure TCP/IP on Windows 98

1.   Open the Control Panel from the Start MenuSettingsControl Panel.

2.   Double-click the Network Icon to open the Network settings.

3.   Verify that TCP/IP is listed in the configuration dialog box. 

·         If TCP/IP is listed, follow the procedure to verify that TCP/IP is installed correctly.

·         If it is not, click the Add button to install the TCP/IP protocol.

4.  Select the Protocol component and press the Add… button.

5.   Select Microsoft under Manufactures.  Select the TCP/IP protocol under Network Protocols, then select the OK button.

6.   You should now see that the TCP/IP protocol is installed.  Once it is finished installing, you will need to restart your computer.

7.  The default TCP/IP properties are as follows.

DHCP enabled, WINS disabled, DNS disabled

If these differ from your configuration or you are not sure of the network configuration, please contact your Network administrator!

8.       Follow the procedure to verify that TCP/IP is installed correctly.

Back To Top


Configuring DataGate/400 for TCP/IP Access

1.   To access DataGate/400 via TCP/IP, you will need to configure the AS/400 with the following commands:

ADDJOBQE  SBSD(QINTER)  JOBQ(DG8_40/DG8_SVC)  MAXACT(*nomax)  SEQNBR(11)

·         where QINTER is the name of the subsystem where DataGate/400 service will run.  QINTER is highly recommended, however, other subsystems may be used.  The subsystem that is used for the job queries must be set up with a proper routing entry in order for DataGate service to start.  This routing entry must run the program QCMD in Library QSYS and have the compare value of ‘QCMDB’ or ‘*ANY’.  If the subsystem has one of these routing entries, it may be used for DataGate.

·         where Sequence Number, if not 11, must be the first available number for the Subsystem.

ADDJOBQE  SBSD(QINTER)  JOBQ(DG8_40/DATAGATE) MAXACT(*nomax) SEQNBR(12)

·         where QINTER is the name of the subsystem where DataGate/400 jobs will run.  This must be the same subsystem name as in the first ADDJOBQE command above.

·         where the Sequence Number, if not 12, must be the next available number for the Subsystem.

2.   To enable access to DataGate/400 via TCP/IP, the DataGate/400 service program must be started.  To start the service program, enter the command:

DG8_40/STRDG8SVR

3.   Similarly, to block access to DataGate/400 via TCP/IP, enter the command:

DG8_40/ENDDG8SVR

4.       You must name the AS/400 Database in Acceler8DB Database Manager using Work with Database Names.  See Naming an AS/400 Database for more information.

Back To Top

Verifying that TCP/IP is Installed Correctly

To verify that TCP/IP is installed correctly and can communicate with the AS400, you will need to know the AS400’s TCP/IP address and Full domain name.  If you do not know, please contact your Network Administrator!

To Verify that TCP/IP is Installed Correctly

1.   Open an MS-DOS prompt by selecting Start Menu - Programs–MS-DOS Prompt.

2.   Type the command ping followed by the TCP/IP address of the AS400.

3.   If TCP/IP is functioning correctly, you should receive four reply’s.

Back To Top

Naming an AS/400 Database

To Name an AS/400 Database For TCP/IP Connectivity

1.       Select Work with Database Names… from the Database menu. The Work with Database Names dialog box will display.

2.       Select the browse button in the Database section to select the database server.  The Select Database dialog box will display.

3.       In Additional TCP/IP server, enter the Host name or IP address of the AS/400.

4.       Select the Add button to add the TCP/IP server.  The Host name or IP Address will be added to the list of available servers. 

5.       Click on the plus sign button next to the Host name or IP Address (or double-click on the name).  After the TCP/IP connection is made, the database label for the AS/400 is displayed.

- If you see a label (typically DB2), then you have made a successful connection.

 - If you don't see a label, then there is an error and we recommend you review the "Troubleshooting" Section.

6.       Click on the database label, and the server and label fields will be set to your selection.

7.       Select the OK button to continue and return to the Work with Database Names dialog.

8.       In Name, enter the name your programs will use to access this AS/400. 

9.       For Example, you can use *REMOTEDFT, if your existing applications have been referenced with this name.

10.   Enter your user name, password, and password confirmation in the Account to Use on server section.

11.   Select the Add button to complete adding a database name.  A dialog box will display stating that the database name has been added.

You can also easily name a database by selecting Database Wizard from the Database menu.

Back To Top

Configuring Multiple Versions of DataGate/400

Using TCP/IP

To Configure an Additional DataGate/400 on the same AS/400 using TCP/IP

1.       End the DataGate service – ENDDG8SVR.

2.       Create a new installation library.

3.       Install DataGate into the newly created library following the steps found in the Release Notes in the section entitled "Installing to the AS400".

4.       To access DataGate/400 via TCP/IP, you will need to configure the AS/400 with the following commands:

ADDJOBQE  SBSD(QINTER)  JOBQ(xxx/DG8_SVC)  MAXACT(*NOMAX) SEQNBR(13)

·         where QINTER is the name of the subsystem where DataGate/400 service will run.  QINTER is highly recommended, however, other subsystems may be used.  The subsystem that is used for the job queries must be set up with a proper routing entry in order for DataGate service to start.  This routing entry must run the program QCMD in Library QSYS and have the compare value of ‘QCMDB’ or ‘*ANY’.  If the subsystem has one of these routing entries, it may be used for DataGate.

·         where xxx is the name of the library where DataGate was installed in.

·         where Sequence Number, if not 13, must be the first available number for the Subsystem.  Enter the command WRKSBSD QINTER to determine the sequence numbers already used.  Select option 6. Job queue entries.  Use the next entry after the existing DataGate sequence number.  Do not use the subsystem QCMN or QSERVICE.

ADDJOBQE  SBSD(QINTER)  JOBQ(xxx/DATAGATE)  MAXACT(*NOMAX) SEQNBR(14)

·         where QINTER is the name of the subsystem where DataGate/400 jobs will run.  This must be the same subsystem name as in the first ADDJOBQE command above.

·         where xxx is the name of the library where DataGate was installed in.

·         where the Sequence Number, if not 14, must be the next available number for the Subsystem.

CHGDTAARA xxx/TCPSERVICE   NewValue('Acceler8DBServiceNum2')

·         where xxx is the name of the library where DataGate was installed in. It is essential that the NewValue information be entered in quotes.

ADDSRVTBLE  SERVICE('Acceler8DBServiceNum2')  PORT(5045) PROTOCOL('tcp') TEXT('ASNA Datagate/400 Service Table Entry #2')

It is essential that the text information be entered in quotes exactly as the NewValue information in the data area TCPSERVICE.  The Protocol must also be entered in quotes.

Display the service table with command WRKSRVTBLE to determine the next unused port number for DataGate.

Back To Top

Troubleshooting

Troubleshooting AS/400 TCP/IP Connectivity

If you are unable to connect to the AS/400 database from ASNA’s Acceler8DB Database Manager, the following information may help identify possible incorrect setups on the AS/400. 

It is assumed that TCP/IP configuration has been completed correctly on the PC side.  If you are unsure whether TCP/IP is installed or correctly configured on your PC, contact your network administrator for assistance.

TCP/IP names are a combination of host names (machine names) and domain names. A machine name for TCP/IP does not have to match the AS/400 machine name; however, it will be a unique name - and it can be the same as the AS/400 machine name. 

Throughout this example, the machine name used is ‘machine’, and the AS/400 name is actually ‘S1037242’.  The domain name used throughout this example is  ‘domain.com’.  Together the machine name and the domain name make a ‘complete’ TCP/IP name - ‘machine.domain.com’.  At your site, you should use your own domain name and own machine name.

1.   First check to see if you are able to ping the AS/400 by name from your PC.  For example, if the TCP/IP name of the AS/400 is  machine.domain.com,’ then the following command should be issued from your machine from a DOS Box:

ping machine.domain.com

·         If you do not get a ‘reply’ from the machine that was pinged, then TCP/IP may not be configured correctly,  either on your machine or on the AS/400.  If you receive a “Bad command or filename” error message when typing the ping command, your machine may not have TCP/IP installed.  Please check with your network administrator to make sure your machine has TCP/IP capability.

·         If you do get a response from the AS/400 when the ping command is issued, then it is still possible some settings on the AS/400 may be incorrect.  From a command line on the AS/400, issue the following command: cfgtcp.

2.   From the Configure TCP/IP menu screen that appears, select the Work with TCP/IP Interfaces (option 1).

3.   The following menu screen will appear.

You should see something similar to this screen.  If you do not, then TCP/IP is probably not configured on the AS/400 properly, or it may not be completely installed.  Check with your AS/400 administrator to make sure the AS/400 has TCP/IP installed.

4.   If there is an internet address other than 127.0.0.1 listed, select that address and enter an option 5 command to display the setting for that IP address.

·         The Interface status should indicate Active.  If it does not, then the TCP/IP services, although installed, may not be started, or it may have terminated.  The TCP/IP services should be started. 

·         Try re-connecting to the AS/400 database after restarting the TCP/IP services.  (To start the TCP/IP services you must have sufficient authority rights and issue the following command from a menu prompt:  STRTCP).  After you have done this, then issue another ping command to see if you get a reply.

5.   If you reach this point and are still having problems accessing the AS/400 via TCP/IP, then F12 back to the main configuration screen for TCP/IP (Configure TCP/IP) and enter option 21 (Configure Related Tables) from the main TCP/IP configuration menu.

·         On the Configure Related Tables menu screen that appears next, select option 1, Work with Service Table Entries.  You will then see the Work with Service Table Entries menu screen. Scroll through the list of services to find the Acceler8DBServer entry. 

·         If there is no entry here, then that is the problem.  Make sure you perform the installation section for the AS/400 as stated earlier in this chapter.

·         If the Acceler8DBServer entry is found, then the default port will be 5042 (unless it was installed with a different port).  It is strongly suggested to use Port 5042.

Note:  The protocol listed in the service table entry for the ‘Acceler8DBServer’ service should be ‘tcp’.  It is case sensitive, so if the letters are uppercase, you will need to remove the service and re-add the service with lower case letters.

Back To Top

Troubleshooting DataGate Service

If you are unable to start the DataGate Service, the following steps will assist in trouble shooting the possible causes.

When the DataGate service job is submitted for execution, the job is submitted under the user profile of DG8SVCPRF.  This user profile is created during the installation and the system value for the Printer option will be assigned to this user profile.  If the DataGate service job has trouble starting, a one page report outlining the possible cause of the problem will be generated for the user DG8SVCPRF and printed to the assigned printer.  This report will not print unless the Output Queue associated with this printer automatically prints the generated reports.  Otherwise, to view the list of reports that have not printed for this user, enter the following command:

WRKSPLF SELECT(DG8SVCPRF)

At this point you will need to contact ASNA for further assistance.

The most probable cause for the DataGate service job not starting is if the current DataGate service job is terminated with an ENDJOB command, subsequent attempts to start the service will not be successful.


1.       If the DataGate service job is not currently running and it won't start by issuing the STRDG8SVR command, enter the following command:             

NETSTAT

2.       Select Option 3.  Work with TCP/IP Connection Status.

3.       Select F14 to Display Port Numbers In the Local Port column, locate the Port Number you assigned as the Port for the DataGate Service (The default Port Number is 5042).

4.       You will need to end this connection by selecting Option 4.

5.       When this connection is ended successfully, you may now execute the STRDG8SVR command.

Back To Top

Troubleshooting a DataGate Job that is Not Terminating

If you notice that a DataGate Job is still running after a client connection is lost, this is due to a TCP/IP feature called "Keep-Alive".  Refer to the following to change the system's default Keep-Alive value.

When the database connection is TCP/IP, the server machine utilizes a TCP/IP feature called "Keep-Alive".  Keep-Alive packets are used to probe a connection that has been inactive for a long time.  The server initiates a disconnect when the probes do not get through. 

This means that if the client connection is lost for a prescribed length of time, the server sends a disconnect message to its server job (usually the result of a system crash or power-down). 

The default Keep-Alive setting for Windows NT and AS/400 is two hours, meaning that an Acceler8DB thread or DataGate job would remain active for 2 hours after connection was lost with the client.  The 2-hour default may be an unsatisfactory period of time for you, as files would continue to remain open, etc. on an abnormal disconnection until the Keep-Alive time had elapsed.

Refer to the following to modify the server machines' respective Keep-Alive period.

AS/400

1.       Request the Configure TCP/IP menu by executing the command: cfgtcp  

2.       Select menu item 3 - Change TCP/IP Attributes.

3.       Set TCP/IP Keep-Alive to the number of minutes desired. (Note: 2 to 5 minutes should work well in most cases).

Windows NT 4.0

WARNING:  Using Registry Editor incorrectly can cause serious, system-wide problems that may require you to reinstall Windows NT to correct them.  Microsoft cannot guarantee that any problems resulting from the use of Registry Editor can be solved.  Use this tool at your own risk.  The following was derived from Article ID Q120642.

To Change these parameters, use the following procedure:

1.       Run Registry Editor (REGEDT32.EXE).

2.       From the HKEY_LOCAL_MACHINE subtree, go to the following key:

\SYSTEM\CurrentControlSet\Services\Tcpip\Parameters

3.       The Value is "KeepAliveTime". 
If present (usually not), double click on it to edit in milliseconds as noted below.  Otherwise, continue with Step 4.

4.       Select  "Edit -> Add Value". 

5.       For Value name, enter KeepAliveTime.

6.       From the Data Type drop down list, select REG_DWORD.

7.       Press OK.

8.       In the DWORD Editor dialog, enter the number of milliseconds.  Select the Radix Decimal option.

9.       Select OK.

10.   Enter the Keep-Alive value in milliseconds; e.g.  5 minutes = 300000 msec.

·         Valid Range: 1 - 0xFFFFFFFF

·         Default: 7,200,000 (two hours)

The parameter controls how often TCP attempts to verify that an idle connection is still intact by sending a Keep-Alive packet. If the remote system is still reachable and functioning, it will acknowledge the Keep-Alive transmission. Keep-Alive packets are not sent by default. This feature may be enabled on a connection by an application.

11.   After typing in the value, use the "Data Type" checkbox to set the value type.

12.   Select OK.

13.   Exit the Registry Editor.

14.   Reboot the system to make the change take effect.

Back To Top

Setting up a Subsystem

Basically, to set up a subsystem, you need to have a routing entry with a compare value of “QCMDB” that runs the program QCMD in QSYS.

The subsystem that is used for the job queries must be set up with a proper routing entry in order for DataGate service to start.  This routing entry must run the program QCMD in Library QSYS and have the compare value of ‘QCMDB’ or ‘*ANY’.  If the subsystem has one of these routing entries, it may be used for DataGate.

Back To Top

Troubleshooting Manually Ending Users Jobs

If DataGate is shut down and there are users connected, their jobs will still be out there and you have to manually end them.  However, after manually ending the users jobs, DataGate may not start for about 5 minutes.  It will start the first DG8SVC job and then end it until the 5 minutes (or so) is up.

It is likely that OS/400 is not reclaiming the DataGate TCP/IP port (5042) in a timely manner when the service and connection jobs are ended.  When you "manually end" connections to DataGate, it may not have a chance to properly shut down TCP/IP resources.  The system typically does not realize that those resources are no longer in use for some quantum. 

The best way to avoid this is to let the connections and service end normally, though in abnormal situations this isn't always possible. 

When you must use ENDJOB, etc., to end the connections and/or the service, you can sometimes use the WRKTCPSTS command to view the outstanding socket connections and end them.  In such a case, if you find a socket in the "listening" state using the DataGate port, you can end this connection (but only if you are absolutely sure the service isn't running) using WRKTCPSTS.  Likewise, if you find sockets connected to the DataGate port from external ports, you can end those (if you are sure that there are no jobs using the connection).  The system will then reclaim the port, and a new instance of the DataGate service can use it immediately.

Back To Top

Finding an AS/400 IP address

If the user does not know the IP address of the AS/400 to which they are trying to Name a database, do the following.  Note however, that most users should never have to do this, and you may want to "call your Network Manager” instead of performing the steps below.

1.       On the PC, open a DOS window and enter:  

arp -a

Note the IP addresses that appear.  You will compare this list with the list generated in step 4.  (Normally, there will be only one difference, and it will be the addition of the AS/400's IP address).

2.       For Windows 9x:          On the PC, click Start - Run the enter:

WINIPCFG 

For NT/2000:     At a DOS prompt, enter:

IPCONFIG

The IP address of the PC will display.  Note this IP address, since you will use it in step 3.

3.       On the AS/400 on a command line enter:  

PING 'xxx.xxx.xxx.xxx'

where xxx.xxx.xxx.xxx is the IP addresses of the PC noted in step 2.

In the Configuration dialog, there's a drop down list box of adapters.  Note that in most cases you will only have one ethernet adapter, so the only challenge is to distinguish the ethernet adapter from a dial-up adapter.  This is usually easy, because dial-up adapters usually have a name like "NdisWan4".

It is also wise to NOT attempt to ping a PC that is also running 5250 emulation, etc., to the object AS/400.  That's because that AS/400 will already be in the arp sorted "list", so one would not be able to know which is the target AS/400 because the list would be the same in steps 1 and 4.

4.       On the PC in the DOS window, enter:

arp -a

The IP addresses are sorted.  Compare the list with the list in step 1 and note the new IP address, this is the AS/400's IP address.

Back To Top

Upgrading OS/400 Level

If you are upgrading the OS/400 to a new level, please contact ASNA to ensure you have a compatible version of DataGate.

Note that you will also need to reconfigure DataGate for TCP/IP access (i.e., the ADDJOBQE and ADDSRVTBLE commands).

Back To Top

Uninstalling DataGate

If you are running multiple versions of DataGate and wish to uninstall a single version; please note the following:

DO NOT delete or rename the DG8_40 library.  It is required for all versions of DataGate even though you may be installing into different library names.

For TCPIP access, you will need to remove the service table entry for the version of DataGate that you wish to uninstall. To verify the Service Table entry, display data area TCPSERVICE in the library that you are uninstalling.  This data area contains the name of the Service Table entry that you will remove.

To uninstall a version of DataGate that was not installed in the default installation library DG8_40, follow the steps below. 

To Uninstall DataGate

1.       Remove the job queue entries for the Jobq Datagate and the Jobq DG8_SVC using the RMVJOBQE command.  These Job Queues reside in the installation library. (Most commonly called DG8_40).

If you have installed DataGate into a library other than DG8_40, your job queues will reside in the library where DataGate is installed.

2.       Delete the Job Queues Datagate and DG8_SVC using the DLTJOBQ command.

3.       Remove Service Table Entry for TCPIP access using the following command. 

RMVSRVTBLE  SERVICE('Acceler8DBService')  PORT(5042) PROTOCOL('tcp') TEXT('ASNA Datagate/400')

4.       Delete the DataGate installation library using the DLTLIB command.

DataGate is now uninstalled.

Back To Top

 04/29/2007          © 2007. Amalgamated Software of North America. All rights reserved.