Fifth article, WebSphere8.5 installation

Source: Internet
Author: User
Tags to domain websphere application server

First, preface

WebSphere Application Server is an IBM Enterprise Application server, and in contrast to WAS6,WAS7, WAS8 has undergone significant changes, and its installation media is very different from the previous one, in which the various installation procedures are detailed

Description, the content may be a bit long, but basically it's something of a process.

II. Installation Manager Installation 2.1 installation

Since WAS8 the installation package no longer distinguishes the OS, pointers to installation Manager are differentiated from the operating system, into IBM's official website http://www.ibm.com/us/en/to download

Download the installation package for the corresponding OS and unzip it

Click Install.exe to install

Select Next

Configuring the installation directory

Click Install to start the installation

This process waits for a period of time for the installation to appear after success

See in the Start menu

Iii. installation of was

Download was installation package

There are three compressed files in the installation package

Unzip to the J:\was directory

After extracting the directory as follows

Start Installation Manager (IM)

Select Files--Preferences

Add repositories

  Note that this selection is repository.config (which is different from the WAS6 7 installation double-click EXE) in the WAS decompression path

Test connection

After successful OK back to IM interface click Install

Select the check box

Next

Continue Next,

Note Modify the installation path

Select Voice installation package

Do not select the sample application, we do not use

Click to start the installation

Installation in ...

After the installation is successful, select None and complete the completion.

In the Start menu, see

2.2 Configuration Profiles

The profile in was is similar to domain in WebLogic and is the service in was.

Click on "Profile Management tools"

Click "Create" to set up a profile

After selecting "Application Server" next

Select "Advanced Profile Creation"

Configure the "Profile file name" already corresponds to the directory, the default walk can

Note here that the "hostname" configuration is the local computer rank (guaranteed to ping) The IP address of the server is configured in the actual production

Enter user name and password admin/admin

Default Go

Default port information Note that I need to use the information in the red circle.

Remove the tick from the check box without adding it to the system service

By default, this Web service is created manually at a later time.

Finally preview the configuration and click "Create"

Profile Start creation

Remove the hook after the point is complete

The profile configuration is now complete.

After the profile configuration is complete, its directory structure is as follows:

2.3 Running was

The command line enters the bin directory under the profile directory and executes Startserver-help to see the Help for that command ( the use of other commands can also be obtained by the same action )

Execute command Start was

StartServer Server1-profilename APPSRV01

Indicates was successfully started (can be stopped by Stopserver command)

Open Browser Input Http://localhost:9060/ibm/console

Enter user name and password log in to the admin console

Compared to the Tomcat console, the was console was a tall one.

III. Release Application 3.1 configuration data source

Was configures the data source procedure:

⊙ establishing a JDBC Provider

⊙ Create a data source

3.1.1 Establishing a JDBC Provider

Click on the "JDBC provider" link

Select the scope and click the New button

Here you need to modify the location of the drive jar:

Get

Remember to save the operation when you finish

View List

3.1.2 Configuring a data source

New after selecting scopes

Input data source name and Jndi name

Select an existing JDBC provider (just created)

Next

Save configuration after completion

Click the dataSource you just configured

Select "JAAS-J2C Certified data" below the relevance

Save configuration back to DataSource interface

In security settings-authentication aliases for component management Select the authentication alias you just configured. Test connection back to list interface when operation is complete

When selected, the test connection gets

The above indicates that the data source configuration is complete.

Optimization of 3.1.3 Data sources

Remove the hook, then click Connection Pool Properties

· Connection Timeout 180 seconds can be reduced appropriately

· The maximum number of connections and the minimum number of connections is consistent to prevent the number of database connections ups and downs, according to server performance adjustment corresponding values

· Other can go by default

Go back to the DataSource interface and click on "WebSphere Application Server Data Source Properties"

Statement Cache Size: The size should not exceed the maximum number of cursors/maximum connections for the database.

To view the maximum number of cursors for a database:

The maximum number of connections set here is 10, and the share statement cache size can be set to 300/10 = 30;

The number of database cursors on the production machine is definitely not more than 300, but do not adjust too much when setting the cache size.

Resize cursor size ALTER system SET open_cursors= cursor number Scope=both;

For testing purposes locally, data is left by default.

3.2 Publishing Apps

Modify the previous Webdemo project to Connect to the WebSphere data source to manipulate the database , and its core code is modified as follows:

    /** * * * @return Get Data source * @throws Exception*/    Private intGetwebspheredatasource () throws exception{System. out. println ("---------getwebspheredatasource------"); intresult =0 ; Context CTX=NewInitialContext (); DataSource DS= (DataSource) ctx.lookup ("Jndi/demo") ; Connection Conn=ds.getconnection (); System. out. println ("conn:="+conn); PreparedStatement pstmt= Conn.preparestatement ("Select COUNT (1) from EMP") ; ResultSet RS=Pstmt.executequery (); if(Rs.next ()) {result= Rs.getint (1) ; }         returnresult; }    

Connect to the data source through Jndi.

Click Install

Select the war package or ear package to install

Next

Go down By default

Configure the context root

Click Finish to start publishing the war package

After saving, the app publishes successfully and then launches the app

After the application has successfully started, enter Http://localhost:9080/WebDemo to access

Click Connect

Compare it with the database

Correct access.

The app finishes on was published ... So is this the end of the story?

No no ... There is one other thing that has not been said about the tuning of was itself.

V. was tuning 5.1

Enter Server1

Click on "Session Management"

|-Maximum number of sessions in memory needs to be determined by the performance of the production machine, not the bigger the better

|-session Timeout: Default is 30 minutes, can be adjusted by customer, can also be configured in Web. xml

5.2

Go to the Web container

Tick "Enable servlet and command cache"

5.3 Thread Pool

Select Webcontainer after entering the thread pool

Adjust the minimum and maximum size values to 40, and uncheck the box below to check

5.4 JVM

Select "Java virtual machine" after entering

Both the initial heap size and the maximum heap size are set to 1400m by

To test its value.

The generic JVM parameter is set to: -XGCPOLICY:GENCON–XNOCLASSGC.

The next section expands the WebSphere cluster operation ...

Fifth article, WebSphere8.5 installation

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.