getting started guide - fujitsusoftware.fujitsu.com/jp/manual/manualfiles/m120017/j2ul...nic2....

22
J2UL-1648-01ENZ0(00) Linux(64) Interstage eXtreme Transaction Processing Server V1.0.0 Getting Started Guide

Upload: others

Post on 19-Jan-2020

8 views

Category:

Documents


0 download

TRANSCRIPT

Page 1: Getting Started Guide - Fujitsusoftware.fujitsu.com/jp/manual/manualfiles/m120017/j2ul...NIC2. Additionally, since the Web application must also be accessed, NIC3 of Client01 connects

J2UL-1648-01ENZ0(00)

Linux(64)

Interstage eXtreme Transaction Processing Server V1.0.0

Getting Started Guide

Page 2: Getting Started Guide - Fujitsusoftware.fujitsu.com/jp/manual/manualfiles/m120017/j2ul...NIC2. Additionally, since the Web application must also be accessed, NIC3 of Client01 connects

Preface

Purpose of this DocumentThis document explains the basic use of this product using a simple sample application and system configuration.

In this document, "Interstage eXtreme Transaction Processing Server" is abbreviated as "Interstage XTP Server".

Organization of this Document

This guide is organized as shown below:

Chapter 1 Overview

Provides an overview of the tutorial.

Chapter 2 Prerequisites

Explains the preparation required to run the sample application.

Chapter 3 Tutorial

Explains the tutorial for this product.

Trademarks

- Red Hat, RPM and all the trademarks and logos based on Red Hat are trademarks or registered trademarks of Red Hat, Inc. in theUnited States and other countries.

- Linux is a trademark or registered trademark of Linus Torvalds in the United States and other countries.

- Oracle and Java are registered trademarks of Oracle Corporation and its subsidiaries and affiliated companies in the United States andother countries. Company names and product names in this document may be trademarks or registered trademarks of their respectivecompanies.

- VMware is a trademark or registered trademark of VMware, Inc. in the United States and other countries.

- Microsoft, Windows, and other Microsoft product terms and names are trademarks or registered trademarks of Microsoft Corporationin the United States and other countries.

- Other trademarks and registered trademarks are generally trademarks or registered trademarks of their respective companies.

Export Restrictions

Exportation/release of this document may require necessary procedures in accordance with the regulations of the Foreign Exchange andForeign Trade Control Law of Japan and/or US export control laws.

Copyrights

Copyright 2012 FUJITSU LIMITED

August 2012 First Edition

- i -

Page 3: Getting Started Guide - Fujitsusoftware.fujitsu.com/jp/manual/manualfiles/m120017/j2ul...NIC2. Additionally, since the Web application must also be accessed, NIC3 of Client01 connects

ContentsChapter 1 Overview..................................................................................................................................................................1

Chapter 2 Prerequisites............................................................................................................................................................42.1 Hardware Environments......................................................................................................................................................................42.2 Software Environments........................................................................................................................................................................42.3 Network Settings..................................................................................................................................................................................4

2.3.1 Network Connection.....................................................................................................................................................................42.3.2 IP Address Settings.......................................................................................................................................................................52.3.3 Disabling the Firewall...................................................................................................................................................................52.3.4 Checking the Network..................................................................................................................................................................6

2.4 Kernel Parameter Settings...................................................................................................................................................................62.5 Node Control Mechanism Settings......................................................................................................................................................7

Chapter 3 Tutorial.....................................................................................................................................................................83.1 Task Flow............................................................................................................................................................................................83.2 Setting up Interstage XTP Server........................................................................................................................................................9

3.2.1 Create the Working Directory.......................................................................................................................................................93.2.2 Environment Variable Settings.....................................................................................................................................................93.2.3 Create the ix-environment.xml File..............................................................................................................................................93.2.4 Generate the ix-operation.def File..............................................................................................................................................103.2.5 Distribute the ix-operation.def File.............................................................................................................................................113.2.6 Start the XTP Service.................................................................................................................................................................113.2.7 Start the Node Group..................................................................................................................................................................113.2.8 Start the UAP Service.................................................................................................................................................................12

3.3 Deploying and Executing the Application.........................................................................................................................................123.3.1 Environment Variable Settings...................................................................................................................................................123.3.2 Start the Various Interstage Application Server Services...........................................................................................................133.3.3 Create the IJServer Cluster.........................................................................................................................................................133.3.4 Deploy the Application...............................................................................................................................................................133.3.5 Class Path Settings......................................................................................................................................................................133.3.6 Start the IJServer Cluster............................................................................................................................................................133.3.7 Execute the Application..............................................................................................................................................................14

Index.......................................................................................................................................................................................19

- ii -

Page 4: Getting Started Guide - Fujitsusoftware.fujitsu.com/jp/manual/manualfiles/m120017/j2ul...NIC2. Additionally, since the Web application must also be accessed, NIC3 of Client01 connects

Chapter 1 OverviewThis chapter provides an overview of the tutorial.

So that the flow for running the applications of this product can be understood, the tutorial uses a simple sample application to explain theprocess from the environment settings, to the actual operation.

The sample application described in this document is a simple Java EE application that manages user account information entered in theWeb browser, in an XTP server node cache.

As shown in the figure below, JSP in the Web application deployed to the Application Server receives requests from the Web browserand requests reference/update processing to the cache on the XTP server node.

The tutorial is based on the assumption that the system comprises two XTP server nodes and one XTP client node. Note that the XTPAdministration Server (XTP admin server) runs on one of these XTP server nodes.

The table below shows the node names used in this tutorial, with the product functions installed on each of these nodes.

Node Name Installed Functions Role

Server01 Server and Admin Server XTP server node and XTP admin server

Server02 Server XTP server node

Client01 Client XTP client node

The sample application is stored under the following directory:

/opt/FJSVixsvr/sample/application/javaee

Additionally, the directory structure of the sample application is as follows:

File or directory Resource content

account.ear Sample application

src/java/Account.java Source for the Value class

src/java/AccountManager.java Class that executes the cache operation using theValue class

src/web/index.jsp JSP file for the Welcome! page

src/web/AccountView.jsp JSP file that performs the cache operation

Data under the "src/web/WEB-INF"directory

Configuration file, etc.

- 1 -

Page 5: Getting Started Guide - Fujitsusoftware.fujitsu.com/jp/manual/manualfiles/m120017/j2ul...NIC2. Additionally, since the Web application must also be accessed, NIC3 of Client01 connects

To check which part of the source code performs the cache operation, refer to the "src/java/AccountManager.java" file. TheAccountManager class has the following methods that insert, update, delete, and reference the data.

Method Name Cache operation

createAccount() Insert

updateAccount() Update

deleteAccount() Delete

referAccount() Reference

Obtaining and operating the cache are performed using each of these methods.The sections of the source code for obtaining and operating the cache in the createAccount() method are shown below.

Obtaining the cache

try{

cacheManager = Caching.getCacheManager();

cache = cacheManager.getCache(CACHE_NAME);

utx = cacheManager.getUserTransaction();

}catch(Exception e){

FacesMessage message = new FacesMessage(FacesMessage.SEVERITY_ERROR,

"Failed in creating account." + e.getMessage(),

e.toString());

context.addMessage(null, message);

return;

}

Operating the cache

The cache.putIfAbsent(userid, account) method is the operation for the insertion to the cache.

try {

Account account = new Account(userid,password,fname,lname,email,company) ;

utx.begin();

result = cache.putIfAbsent(userid, account);

if(result){

utx.commit();

FacesMessage message = new FacesMessage(FacesMessage.SEVERITY_INFO,

"Succeeded in creating account.",

"Created UserID[" + userid + "] account.");

context.addMessage(null, message);

}else{

utx.rollback();

FacesMessage message = new FacesMessage(FacesMessage.SEVERITY_ERROR,

"Specified UserID already exists. userID=",

userid);

context.addMessage(null, message);

}

}catch (Exception e) {

e.printStackTrace() ;

try {

utx.rollback() ;

} catch( Exception ex ) {

e.printStackTrace() ;

}

FacesMessage message = new FacesMessage(FacesMessage.SEVERITY_ERROR,

"Failed in creating account." + e.getMessage(),

e.toString());

- 2 -

Page 6: Getting Started Guide - Fujitsusoftware.fujitsu.com/jp/manual/manualfiles/m120017/j2ul...NIC2. Additionally, since the Web application must also be accessed, NIC3 of Client01 connects

context.addMessage(null, message);

}

- 3 -

Page 7: Getting Started Guide - Fujitsusoftware.fujitsu.com/jp/manual/manualfiles/m120017/j2ul...NIC2. Additionally, since the Web application must also be accessed, NIC3 of Client01 connects

Chapter 2 PrerequisitesThis chapter explains the system environment required to run the sample application referred to in this guide.

2.1 Hardware EnvironmentsFor details about the hardware environments required to use Interstage XTP Server, refer to "Hardware Requirements" in the "OperatingEnvironments" chapter of the Installation Guide.

2.2 Software EnvironmentsThe following software is assumed to be installed on each node:

- Red Hat Enterprise Linux 6(for Intel64) (common to each node)

- PRIMECLUSTER Clustering Base 4.3A10 (Server01, Server02) (*1)

- This product: Interstage XTP Server

- Admin Server and Server (Server01)

- Server (Server02)

- Client (Client01)

- Interstage Application Server Enterprise Edition V10.0 (Linux for Intel64) standard installation configuration (Client01)

*1) For details on the points that should be noted when installing PRIMECLUSTER, refer to the XTP Server Installation Guide.

For details on how to install these software products, refer to the Installation Guide for each product.

2.3 Network SettingsThis section explains how to build the network that is required to run this product.

2.3.1 Network ConnectionThe service LAN, mirror LAN, and admin LAN must be built to run this product. Of these, the service LAN and the mirror LAN can bebuilt on the same network, and in this tutorial, that is the case. When building the network, note the following:

- The service LAN/mirror LAN and admin LAN are not connected to the Internet

- The service LAN/mirror LAN and admin LAN are mutually independent networks

Additionally, a network for accessing the Web applications on Interstage Application Server is also built.

The system network build is assumed to be as shown in the following figure.

- 4 -

Page 8: Getting Started Guide - Fujitsusoftware.fujitsu.com/jp/manual/manualfiles/m120017/j2ul...NIC2. Additionally, since the Web application must also be accessed, NIC3 of Client01 connects

In this figure, the service/mirror LAN is made up of connections between NIC1, and the admin LAN is made up of connections betweenNIC2. Additionally, since the Web application must also be accessed, NIC3 of Client01 connects to an intranet. The numbers assignedfor each NIC are examples of the IP addresses that are set for each NIC. For details on the IP address settings, refer to "2.3.2 IP AddressSettings" below.

Information

To connect to the intranet from Server01 or Server02, add a NIC where necessary.

2.3.2 IP Address SettingsAs an example, the IP addresses used in the service LAN/mirror LAN and admin LAN are assigned as shown below. In the network thatis connected to the Internet, set an IP address that is appropriate for the environment.

Node NIC1(Service/Mirror LAN) NIC2 (Admin LAN) NIC3 (Intranet)

Server01 192.168.246.11 192.168.247.11 -

Server02 192.168.246.12 192.168.247.12 -

Client01 192.168.246.51 - 192.168.248.51

2.3.3 Disabling the FirewallIn this product, the firewall must be disabled. To disable the firewall, execute the following command on all nodes:

/etc/rc.d/init.d/iptables stop

- 5 -

Page 9: Getting Started Guide - Fujitsusoftware.fujitsu.com/jp/manual/manualfiles/m120017/j2ul...NIC2. Additionally, since the Web application must also be accessed, NIC3 of Client01 connects

2.3.4 Checking the NetworkThis section explains how to check that the network that was built is connected to correctly. To do this, check the packet flow using thetcpdump command. In this example, the service LAN/mirror LAN are checked to see whether they are set up correctly. It is assumed thatNIC1 and NIC2 of each node in the "2.3.1 Network Connection" figure above are recognized as eth1 and eth2 respectively, by the OS.

In the "2.3.1 Network Connection" figure above, the service LAN/mirror LAN of each node is made up of connections between NIC1(eth1).For this reason, use the tcpdump command to check that a NIC1 is connected to another NIC1 and not connected to other types of NIC.

Confirming the flow of the Server01 eth1 and Client01 eth1 packets

- Server01

Execute the following command to monitor the packets that are sent/received from eth1 of Server01.

tcpdump -nn -i eth1 icmp

- Client01

Specify eth1 in the output interface and execute the ping command.

ping -I eth1 192.168.246.11

At this time, if both 'request' and 'reply' are output to Server01 and a reply is displayed in Client01, as shown below, it means that thenetwork build was successful.

- Server01 output result

15:30:51.988453 IP 192.168.246.51 > 192.168.246.11: ICMP echo request, id 44601, seq 1,

length 64

15:30:51.988484 IP 192.168.246.11 > 192.168.246.51: ICMP echo reply, id 44601, seq 1,

length 64

- Client01 output result

PING 192.168.246.11 (192.168.246.11) from 192.168.246.51 eth1: 56(84) bytes of data.

64 bytes from 192.168.246.11: icmp_seq=1 ttl=64 time=0.469 ms

If only one of 'request' or 'reply' is displayed in the Server01 output result and a reply is displayed in Client01, it means there is a possibilitythat another interface has also been used for communication and that the mirror LAN is connected to another network. In this case, executetcpdump for the other interface, check whether a request has been received from eth1 of Client01, then review the connection or IP addresssettings.

Perform the above tasks for Server02 eth1 and Client01 eth1 as well. If the same result is obtained, it means that the service LAN/mirrorLAN build was successful.

Information

The flow of packets between Server01 and eth2, and Server02 and eth2, can also be checked for the admin LAN using the above method.

2.4 Kernel Parameter SettingsSet the kernel parameters that are required to run this sample application.For details on the values that are set for the kernel parameters, refer to "Kernel Parameter Settings " in the Setup and Operation Guide and"System Tuning" in the Interstage Application Server/Interstage Web Server Tuning Guide.

Examples of the kernel parameter values that are set to run this sample application are shown below.

- 6 -

Page 10: Getting Started Guide - Fujitsusoftware.fujitsu.com/jp/manual/manualfiles/m120017/j2ul...NIC2. Additionally, since the Web application must also be accessed, NIC3 of Client01 connects

Server01and Server02 Kernel Parameters (when the installed memory size is 8GB)

Resource Name Parameter Name Type Value that is set

Shared memory shmall Maximumvalue

1968445

shmmax Maximumvalue

8062752000

shmmni Additionalvalue

70

OMM killer vm.panic_on_oom Maximumvalue

1

Client01 Kernel Parameters (when the installed memory size is 4GB)

Resource Name Parameter Name Type Value that is set

Shared memory shmall Maximumvalue

958507

shmmax Maximumvalue

3926048000

shmmni Additionalvalue

118

Semaphore para1 Settingsvalue

567

para2 Additionalvalue

6095

para3 Settingsvalue

514

para4 Additionalvalue

1165

Message queue msgmax Settingsvalue

16384

msgmnb Settingsvalue

32768

msgmni Additionalvalue

526

The kernel resources are set by updating the kernel configuration file (/etc/sysctl.conf).

When the kernel configuration file (/etc/sysctl.conf) is updated, the settings will be enabled.

An example of the command that enables the kernel parameter configuration file information is shown below.

/sbin/sysctl -p

2.5 Node Control Mechanism SettingsTo run this product, an appropriate node control mechanism must be set in the environment in which this product is installed, and the nodecontrol mechanism information must be set in Interstage XTP Server using the ixsetupndg command. Refer to "Hardware Related Setup"in the Setup and Operation Guide before setting the node control mechanism.

- 7 -

Page 11: Getting Started Guide - Fujitsusoftware.fujitsu.com/jp/manual/manualfiles/m120017/j2ul...NIC2. Additionally, since the Web application must also be accessed, NIC3 of Client01 connects

Chapter 3 TutorialThis tutorial explains the tasks required to run the sample cache access application—from setting up the Interstage XTP Server environmentthrough to deploying and executing the application.

The sample application, named "Account Management Tool", is stored under the following directory.

/opt/FJSVixsvr/sample/application/javaee

This sample application is implemented as a Java EE application and runs on an application server.

Note that the tasks explained in this chapter must be executed by the system administrator.

3.1 Task FlowThe following outlines the task flow for setting up the application environment and for application deployment.

Interstage XTP Server Setup Tasks

Step Task Server01 Server02 Client01

1 Create the working directory Y Y Y

2 Environment variable settings Y Y Y

3 Create the ix-environment.xml file Y - -

4 Generate the ix-operation.def file Y - -

5 Distribute the ix-operation.def file Y Y Y

6 Start the XTP service Y Y Y

7 Start the node group Y (Note) Y (Note) -

8 Start the UAP service Y (Note) Y (Note) -

Y: Perform the task at this location.

-: Do not perform the task at this location.

Note) Execute this once only on either Server01 or Server02.

Application Deployment Tasks

Step Task Client01 Web browser

1 Environment variable settings Y -

2 Start the various Interstage ApplicationServer services

Y -

3 Create the IJServer cluster Y -

4 Deploy the application Y -

5 Class path settings Y -

6 Start the IJServer cluster Y -

7 Execute the application - Y

Y: Perform the task at this location.

-: Do not perform the task at this location.

- 8 -

Page 12: Getting Started Guide - Fujitsusoftware.fujitsu.com/jp/manual/manualfiles/m120017/j2ul...NIC2. Additionally, since the Web application must also be accessed, NIC3 of Client01 connects

3.2 Setting up Interstage XTP ServerSet up Interstage XTP Server according to the following procedure:

- Create the working directory

- Environment variable settings

- Create the ix-environment.xml file

- Generate the ix-operation.def file

- Distribute the ix-operation.def file

- Start the XTP service

- Start the node group

- Start the UAP service

3.2.1 Create the Working DirectoryFirst, prepare the working directory that is to be used in this tutorial, on each node. Use "/tmp" as the working directory. If the workingdirectory does not exist, create it by executing the following command:

mkdir /tmp

3.2.2 Environment Variable SettingsSet the path for executing the Interstage XTP Server commands. Set the PATH environment variable on each node. (The example shownbelow is for "Bash".)

export PATH=/opt/FJSVixsvr/bin:$PATH

3.2.3 Create the ix-environment.xml FileCopy the ix-environment.xml file under "/opt/FJSVixsvr/sample/envdef/simple/" to the working directory.

cp /opt/FJSVixsvr/sample/envdef/simple/ix-environment.xml /tmp

Then, open the ix-environment.xml file that was copied, and then set the IP address of each node under the <node> tag as follows:

Node Name Item Value that is set

Server01 <service-lan1> tag Server01 service/mirror LAN IP address

<admin-lan> tag Server01 admin LAN IP address

Server02 <service-lan1> tag Server02 service/mirror LAN IP address

<admin-lan> tag Server02 admin LAN IP address

Client01 <service-lan1> tag Client01 service/mirror LAN IP address

The following is an example of creating the ix-environment.xml file:

<?xml version="1.0" encoding="UTF-8"?>

<!--

# Copyright(C) 2012 FUJITSU LIMITED

# Interstage XTP Creating Environment Definition file

-->

- 9 -

Page 13: Getting Started Guide - Fujitsusoftware.fujitsu.com/jp/manual/manualfiles/m120017/j2ul...NIC2. Additionally, since the Web application must also be accessed, NIC3 of Client01 connects

<ixsvr-environment>

<service>

<node-group>

<node-group-name>NodeGroup01</node-group-name>

<node>

<node-name>Server01</node-name>

<service-lan1>192.168.246.11</service-lan1>

<admin-lan>192.168.247.11</admin-lan>

</node>

<node>

<node-name>Server02</node-name>

<service-lan1>192.168.246.12</service-lan1>

<admin-lan>192.168.247.12</admin-lan>

</node>

</node-group>

<client-group>

<node>

<node-name>Client01</node-name>

<service-lan1>192.168.246.51</service-lan1>

</node>

</client-group>

</service>

<cache>

<cache-name>Cache001</cache-name>

</cache>

</ixsvr-environment>

The system that is built using the ix-environment.xml file shown above is as follows. (Note: The intranet has been omitted.)

3.2.4 Generate the ix-operation.def FileGenerate the ix-operation.def file that is required when the XTP service is started, to the working directory.To generate the ix-operation.def file, execute the following command on Server01:

- 10 -

Page 14: Getting Started Guide - Fujitsusoftware.fujitsu.com/jp/manual/manualfiles/m120017/j2ul...NIC2. Additionally, since the Web application must also be accessed, NIC3 of Client01 connects

ixcreatedef -f /tmp/ix-environment.xml -o /tmp/

With option -o, the directory where the ix-operation.def file is output can be specified. If the above command has been executed, checkthat a file with the name "ix-operation.def" is output to the "/tmp" directory.

3.2.5 Distribute the ix-operation.def FileStore the generated ix-operation.def file under the "/etc/opt/FJSVixsvr/envdef" directory of each node. In the following command executionexample, the command distributes the file from Server01 to Server02:

scp -p /tmp/ix-operation.def 192.168.246.12:/etc/opt/FJSVixsvr/envdef

3.2.6 Start the XTP ServiceExecute the ixstart command to start the XTP service. The ixstart command must be executed on all XTP nodes. Execute the commandsshown below on each node.

Executing the command on Server01: ixstart -n Server01

Executing the command on Server02: ixstart -n Server02

Executing the command on Client01: ixstart -n Client01

If a message similar to the one that follows is displayed on the node on which the command was executed, it means that the attempt tostart the XTP service has succeeded.

# ixstart -n Server01

FSP_IXSVR_PSSVR: INFO: 01001: XTP Service - started.

Information

The default directory from which the ixstart command reads the ix-operation.def files is "/etc/opt/FJSVixsvr/envdef". However, byspecifying the -f option, any path can be specified as the ix-operation.def file path.To store the ix-operation.def file in a location other than the "/etc/opt/FJSVixsvr/envdef" directory, specify the -f option.In the following example, the ixstart command is executed on Server01 when the ix-operation.def file has been stored under /tmp:

ixstart -n Server01 -f /tmp/ix-operation.def

3.2.7 Start the Node GroupIf the XTP service has started successfully, execute the following command on either the Server01 or the Server02 node to start the nodegroup:

ixstartndg

If a message similar to the one that follows is displayed, it means that the attempt to start the node group has succeeded:

- 11 -

Page 15: Getting Started Guide - Fujitsusoftware.fujitsu.com/jp/manual/manualfiles/m120017/j2ul...NIC2. Additionally, since the Web application must also be accessed, NIC3 of Client01 connects

# ixstartndg

FSP_IXSVR_PSSVR: INFO: 11000: Node group started : NODEGROUP='NodeGroup01'

NODE='Server01,Server02' STATE='Active,Active'

3.2.8 Start the UAP ServiceIf the node group has started successfully, execute the following command on either the Server01 or the Server02 node to start the UAPservice:There are two UAP services that are started: UAP01 and UAP02.

ixstartuap -u UAP01

ixstartuap -u UAP02

If a message similar to the one that follows is displayed, it means that the attempt to start the specified UAP service has succeeded:

# ixstartuap -u UAP01

FSP_IXSVR_PSSVR: INFO: 11002: UAP service started : UAP='UAP01' NODE='Server01,Server02'

STATE='Active,Standby1'

If the ixdisplay -w command is executed on either the Server01 or the Server02 node and an output result similar to the one that followsis obtained, it means that the setup of Interstage XTP Server that is required to run the sample application is complete.

# ixdisplay -w

Date: 2012/04/09 18:49:40 JST

NodeName: Server01

NodeGroupName: NodeGroup01

NodeName Server01 Server02

------------------------------------------------------------------------------

(Status) Active Active

UAP01 Active Standby1

UAP02 Standby1 Active

3.3 Deploying and Executing the ApplicationSet up the application server that is used to execute the sample application according to the following procedure:

- Environment variable settings

- Start the various Interstage Application Server services

- Create the IJServer cluster

- Deploy the application

- Class path settings

- Start the IJServer cluster

- Execute the application

In this tutorial, Interstage Application Server Enterprise Edition V10.0 (Linux Interl64) ("Interstage Application Server") is used as theruntime environment for the sample application. Note that the explanation that follows assumes that Interstage Application Server isalready installed (using a standard installation) on Client01.

3.3.1 Environment Variable SettingsSet the path for executing the Interstage Application Server commands.Execute the following command on Client01 to set the PATH environment variable. (The example shown below is for "Bash".)

- 12 -

Page 16: Getting Started Guide - Fujitsusoftware.fujitsu.com/jp/manual/manualfiles/m120017/j2ul...NIC2. Additionally, since the Web application must also be accessed, NIC3 of Client01 connects

export PATH=/opt/FJSVisjee/bin:$PATH

3.3.2 Start the Various Interstage Application Server ServicesIn the sample application, Java EE is used. To use Java EE, check that the following services are already running beforehand:

- Interstage Java EE DAS Service

- Interstage Java EE Node Agent Service

To start these services, execute the following commands on Client01.

- Starting the Interstage Java EE DAS service:

ijdasstart

- Starting the Interstage Java EE Node Agent service:

ijnastart

3.3.3 Create the IJServer ClusterCreate the IJServer cluster and server instance that will run the application.

Here, the IJServer cluster name is "Cluster001", and the server instance name is "Instance001". Execute the following commands onClient01 in the order shown below:

1. Creating the IJServer cluster:

asadmin create-cluster Cluster001

2. Creating the server instance:

asadmin create-instance --cluster Cluster001 Instance001

3.3.4 Deploy the ApplicationDeploy the sample application. The sample application that is executed is /opt/FJSVixsvr/sample/application/javaee/account.ear.

Execute the following command on Client01 to deploy the sample application:

asadmin deploy --target Cluster001 /opt/FJSVixsvr/sample/application/javaee/account.ear

3.3.5 Class Path SettingsTo execute the sample application, the following jar files under /opt/FJSVixsvr/lib must be set in the class path:

- ix-jcache-api-0.5.0.jar

- ix-jcache-impl-0.5.0.jar

Execute the following command on Client01 to set the class path:

asadmin set Cluster001-config.java-config.classpath-suffix=/opt/FJSVixsvr/lib/ix-jcache-impl-0.5.0.jar:/opt/FJSVixsvr/lib/ix-jcache-api-0.5.0.jar

3.3.6 Start the IJServer ClusterStart the IJServer cluster that was created.

- 13 -

Page 17: Getting Started Guide - Fujitsusoftware.fujitsu.com/jp/manual/manualfiles/m120017/j2ul...NIC2. Additionally, since the Web application must also be accessed, NIC3 of Client01 connects

Execute the following command on Client01:

asadmin start-cluster Cluster001

This completes the startup of the IJServer cluster, and the application is now in an executable state.

3.3.7 Execute the ApplicationFirst, check the port number that accesses the application. Execute the following command on Client01:

asadmin list-system-properties Instance001

The system properties will be displayed. HTTP_LISTENER_PORT is the port number that is used to access the application. In the followingoutput example, the port number is 28090.

# /opt/FJSVisjee/bin/asadmin list-system-properties Instance001

HTTP_LISTENER_PORT=28090

IIOP_SSL_LISTENER_PORT=23820

JMS_PROVIDER_PORT=7676

IIOP_LISTENER_PORT=23700

JMX_SYSTEM_CONNECTOR_PORT=28686

IIOP_SSL_MUTUALAUTH_PORT=23920

Command list-system-properties executed successfully.

Then, open the web browser and go to the URL shown below to access the application. In this tutorial, to access the web application onClient01 via the intranet the IP address is 192.168.248.51 and the port number is 28090.

http://192.168.248.51:28090/account

The following webpage will be displayed. Click Account Management Tool to run the sample application.

The following webpage will be displayed:

- 14 -

Page 18: Getting Started Guide - Fujitsusoftware.fujitsu.com/jp/manual/manualfiles/m120017/j2ul...NIC2. Additionally, since the Web application must also be accessed, NIC3 of Client01 connects

Perform the cache operation shown below. Scroll the window to the "Refer an Account" section displayed at the bottom of the webpage.Type "00001" in the UserID text box, and then click Refer.

Initially, there is no data for UserID "00001" in the cache, therefore the attempt to reference the data will fail and the error message shownbelow will be displayed:

- 15 -

Page 19: Getting Started Guide - Fujitsusoftware.fujitsu.com/jp/manual/manualfiles/m120017/j2ul...NIC2. Additionally, since the Web application must also be accessed, NIC3 of Client01 connects

The next step is to store data in the cache.First, navigate to the "Create an Account" section displayed at the top of the webpage. Type the values shown below in the text boxes,and then click Create. At this time, type "00001" for the UserID.Additionally, type identical values for "Password" and "Password (verify)". Although not displayed in the screenshot below, the passwordentered is "bar".

If the data was stored in the cache successfully, the following message will be displayed:

- 16 -

Page 20: Getting Started Guide - Fujitsusoftware.fujitsu.com/jp/manual/manualfiles/m120017/j2ul...NIC2. Additionally, since the Web application must also be accessed, NIC3 of Client01 connects

Scroll the window to the "Refer an Account" section displayed at the bottom of the webpage again, type "00001" in the UserID text box,and then click Refer.

If the attempt to reference the data for this member in the cache was successful, the following message will be displayed:

- 17 -

Page 21: Getting Started Guide - Fujitsusoftware.fujitsu.com/jp/manual/manualfiles/m120017/j2ul...NIC2. Additionally, since the Web application must also be accessed, NIC3 of Client01 connects

Scroll the window to the "Refer an Account" section again. The data that was entered in the "Create an Account" section is displayed.

- 18 -

Page 22: Getting Started Guide - Fujitsusoftware.fujitsu.com/jp/manual/manualfiles/m120017/j2ul...NIC2. Additionally, since the Web application must also be accessed, NIC3 of Client01 connects

Index[O]

Overview....................................................................................1

[P]Prerequisites................................................................................4

[T]Tutorial.......................................................................................8

- 19 -