1 / 27

WebSphere Administration

Basic DB2 Connectivity Checking From WAS server (client). Before installing/starting the websphere application, we have to make sure the corresponding relational database is catalogued on the client (WAS server). WAS client machine contains entry of DB2 client catalogue path (/home/caeadmin/sqllib

elisa
Download Presentation

WebSphere Administration

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


    1. WebSphere Administration

    2. Basic DB2 Connectivity Checking From WAS server (client) Before installing/starting the websphere application, we have to make sure the corresponding relational database is catalogued on the client (WAS server). WAS client machine contains entry of DB2 client catalogue path (/home/caeadmin/sqllib/java12/db2java.zip) in admin.config file.

    3. Basic DB2 Connectivity Checking From WAS server (client) [/usr/WebSphere/AppServer/bin]$ more admin.config com.ibm.ejs.sm.adminServer.earFile=/usr/WebSphere/AppServer/config/admin.ear com.ibm.ejs.sm.adminserver.classpath=/usr/WebSphere/AppServer/properties:/usr/WebSphere/AppServer/lib/bootstrap.jar com.ibm.ejs.sm.adminServer.traceFile=/usr/WebSphere/AppServer/logs/tracefile com.ibm.ws.jdkexe.path=/usr/WebSphere/AppServer/java/jre/bin/java com.ibm.ejs.sm.util.process.Nanny.adminServerJvmArgs=-Xmx128m -Xminf0.15 -Xmaxf0.25 -Xms17M -Djavax.rmi.CORBA.UtilClass=com.ibm.CORBA.iiop.Util -Dcom.ibm.CORBA.iiop.noLocalCopies=true -Dws.ext.dirs=/usr/WebSphere/AppServer/java/lib:/usr/WebSphere/AppServer/classes:/usr/WebSphere/AppServer/lib:/usr/WebSphere/AppServer/lib/ext:/home/caeadmin//sqllib/java12/db2java.zip com.ibm.ejs.sm.adminServer.bootstrapPort=xxxx ( 4 digit port number one used to open console)

    4. Basic DB2 Connectivity Checking From WAS server (client) Following command(db2profile) will execute the DB2 profile info: [/home/caeadmin/sqllib]$ . ./db2profile Following command(db2profile) will display the DB's catalogue on WAS server: [/home/caeadmin/sqllib]$db2 list db directory

    5. Basic DB2 Connectivity Checking From WAS server (client) DBs catalogue on the server is displayed as: System Database Directory Number of entries in the directory = 10 Database 1 entry: Database alias = abc Database name = abc Node name = xxxx(not actual hostname ) - do db2 list node directory to get actual hostname Database release level = 9.00 Comment = Directory entry type = Remote Authentication = SERVER Catalog node number = -1 Node 1 entry: Node name = xxxx Comment = Protocol = TCPIP Hostname = aaa.bbb.ccc.com Service name = 3700

    6. Basic DB2 Connectivity Checking From WAS server (client) DB2 connect to dbname userid xxxx using password, is the command used to connect to database. [/home/caeadmin/sqllib]$ db2 connect to dbname userid xxxx using password Database Connection Information Database server = DB2/6000 7.2.6 SQL authorization ID = xxxx Local database alias = dbname

    7. Updating JVM/data Source Properties To update JVM/data source properties: Using xmlconfig Use the following command to update the data source: XMLConfig -import updateDataSource.xml -adminNodeName itsohost. To modify resources in your WebSphere configuration, use the update action. For example, to update an existing data source with new timeout values: updateDataSource.xml <?xml version="1.0"?> <!DOCTYPE websphere-sa-config SYSTEM "file:///$XMLConfigDTDLocation$$dsep$xmlconfig.dtd" > <websphere-sa-config> <jdbc-driver action="locate" name="Sample DB Driver"> <data-source action="update" name="sample"> <connection-timeout>10</connection-timeout> <idle-timeout>600</idle-timeout> <orphan-timeout>900</orphan-timeout>

    8. Updating JVM/data Source Properties Using Admin Console: Open admin console using command /usr/WebSphere/AppServer/bin/adminclient.sh localhost portnumber. Click under resources on the admin console to update data source values.

    9. Updating JVM/data Source Properties

    10. Installing Application on WAS Server To Install an application on WAS server: Create an application server. To create an application server, use xmlconfig or console. For example, use the following command to create the application server: XMLConfig -import createAppServer.xml -adminNodeName itsohost. createAppServer.xml <?xml version="1.0"?> <!DOCTYPE websphere-sa-config SYSTEM "file:///$XMLConfigDTDLocation$$dsep$xmlconfig.dtd" > <websphere-sa-config> <node action="locate" name="itsohost"> <application-server action="create" name="newas01"> <jvm-config> <initial-heap-size>128</initial-heap-size> <max-heap-size>256</max-heap-size> </jvm-config> </application-server> </node> </websphere-sa-config>

    11. Installing Application on WAS Server Install application on that application server using any one of these methods: XMLConfig EARExpander Using console. XMLConfig is mainly designed to support automated tasks, such as changing multiple resources in the WebSphere configuration. It is very useful and powerful for creating a whole environment and for installing multiple enterprise applications in one action. You can use XMLConfig tool for the following tasks: Export and import your WebSphere configuration. Make multiple changes to your WebSphere configuration without the console Start and stop resources. To install the enterprise application using XMLConfig, use the following command: XMLConfig -import createEntApp.xml -adminNodeName itsohost.

    12. Installing Application on WAS Server To install the enterprise application using EARExpander, use the following command: [/usr/WebSphere/AppServer/bin]$ ./EARExpander.(bat|sh) -ear /tmp/sample.ear expandDir /codedir -operation expand -expansionFlags war

    13. Installing Application on WAS Server

    14. WebSphere Control Program (WSCP) The WebSphere Control Program (WSCP) is a command-line and scripting interface for administering resources in WebSphere Application Server Advanced Edition. It is based on Tcl(tool command language). Tcl is a portable command language that provides programming facilities such as, variables, procedures, conditionals, list-processing functions, and looping constructs. The WSCP interface extends Tcl, providing a set of commands for manipulating websphere objects. Command-line administration in WebSphere Application Server: The administrative server tracks the contents and activities of a domain by maintaining an administrative database. The administrative server allows the administration of a domain from any machine, and all information is stored in a central location. The administrative database contains information about the applications that are configured to run in the domain. For example, it contains the names of all application servers, EJB containers, Web containers, servlets and enterprise beans, and their current state (running, defined, or stopped). All administration takes place through the manipulation of objects in the administrative database. Each resource in a domain corresponds to an object in the administrative database. For example, when you create an application server, a corresponding application server object is created in the administrative database.

    15. WebSphere Control Program (WSCP) The command-line WSCP interface and the administrative console are compatible. The results of actions performed with the WSCP tool are reflected in the console interface, and vice versa, although an explicit refresh is required to display the changes. Both the administrative console and the WSCP tool can be used to do the following: Define, configure, and manage application servers, enterprise applications and other WebSphere resources from any node in the network. Install enterprise applications (using wizards in the administrative console and scripts in the WSCP tool). Perform daily administrative operations, such as starting and stopping enterprise applications and making changes to their configuration.

    16. WebSphere Control Program (WSCP) Starting the WebSphere Control Program: The WebSphere Control Program tool is started from the command line on Windows platforms by running: <WAS_HOME>\bin\wscp.bat. On UNIX platforms use: <WAS_HOME>/bin/wscp.sh. If the <WAS_HOME>\bin directory is in your PATH, then you can invoke the WSCP command without including this directory.

    17. WebSphere Control Program (WSCP) Executing <WAS_HOME>\bin\wscp.bat will give you the WSCP prompt. wscp> Help To start and stop the previously created application server from within WSCP, use the following command: wscp> ApplicationServer start /Node:itsohost/ApplicationServer:newas01/ wscp> ApplicationServer stop /Node:itsohost/ApplicationServer:newas01/ To export the whole configuration use the following command: wscp> XMLConfig export wasconfig.xml To import an XML configuration file that contains the variable $node$ for node name and $server$ for the application server name use the following command: wscp> XMLConfig import wasconfig.xml \ -substitute {{node itsohost} {server newas01}}

    18. WebSphere Control Program (WSCP) The following is an example shell script to stop an application: echo "stopping IIPAppServer on `hostname -s`" /usr/WebSphere/AppServer/bin/wscp.sh -p /usr/WebSphere/AppServer/bin/wscp.props -c "ApplicationServer stop /Node:hostname/ApplicationServer:intraAppServer/" sleep 60 cat /usr/W*/A*/logs/tracefile|grep -i stopped|tail -2|grep -i "intraAppServer" sleep 60 intraAppServer=`ps -eaf|grep java|grep -i intraAppServer |grep -v grep|wc -l` if [ $intraAppServer -eq 1 ] then echo "intraAppServer is still running pls stop the application `tail -10 /usr/W*/A*/logs/tra cefile|grep -i stopped|tail -2|grep -i "intraAppServer"` " else echo "intraAppServer is not running,allset" fi

    19. WebSphere Control Program (WSCP) The following is an example shell script to start an application: echo "stopping IIPAppServer on `hostname -s`" /usr/WebSphere/AppServer/bin/wscp.sh -p /usr/WebSphere/AppServer/bin/wscp.props -c "ApplicationServer start /Node:hostname/ApplicationServer:intraAppServer/" sleep 60 cat /usr/W*/A*/logs/tracefile|grep -i stopped|tail -2|grep -i "intraAppServer" sleep 60 intraAppServer=`ps -eaf|grep java|grep -i intraAppServer |grep -v grep|wc -l` sleep 120 if [ $intraAppServer -eq 1 ] then echo "intraAppServer is running `tail -10 /usr/W*/A*/logs/tra cefile|grep -i started|tail -2|grep -i "intraAppServer"` " else echo "intraAppServer is running,allset" fi

    20. Performance Tools Log Analyzer is a new tool in IBM WebSphere Application Server V4.0. It provides a graphical user interface for analyzing log files using a symptom database. /usr/W*/A*/bin/waslogbr - to invoke log analyzer Resource Analyzer is a tool you can use to monitor the performance of your runtime environment. It provides a GUI with chart and table views of performance data. /usr/W*/A*/bin/ra.sh - to invoke resource analyzer

    21. Log Analyzer

    22. Resource Analyzer

    23. WebSphere Portal Overview Introduction to WebSphere Portal V4.1 IBM WebSphere Portal for Multiplatforms provides a single point of interaction with dynamic information, applications, processes and people to help build successful business-to-employee (B2E), business-to-business (B2B) and business-to-consumer (B2C) portals. WebSphere Portal also supports a wide variety of pervasive devices enabling users to interact with their portal anytime, anywhere, using any device, wired or wireless. Portal prerequisites: The software applications to be installed are: DB2 Universal Database V7.2 Enterprise Edition WebSphere Application Server 4.02 WebSphere Portal V4.1 SecureWay Directory Server V3.2.2 WebSphere Personalization V4.0 portal overview

    24. WebSphere Portal Software Topology

    25. Comparison of Administration in Versions 4 and 5 IBM WebSphere Application Server (hereafter called Application Server) Version 5: provides enhancements to scalability, reliability, Web services, J2EETM 1.3 certification, and many other areas. provides a completely rewritten infrastructure for you to manage and administer your servers and applications. An open-standards-based management framework, JavaTM Management Extensions (JMX), is at the core of the Version 5 management capabilities. New administration tool sets built for Version 5 take advantage of this framework. You can also use the Version 5 administration tool capabilities for your own custom administration programs. Comparison of the Administration in Versions 4 and 5 There are significant differences between how you would handle administration in Application Server Versions 4 and 5. Some of the main differences are: The Version 4 Advanced Edition (AE) requires a database to hold configuration data, whereas no edition of Version 5 requires a database. Version 4 AE administration is based on J2EE Enterprise Java Beans (EJBs) and all of the Version 4 administrative programs are EJB client programs. Version 5 does not use EJBs to store configuration data; therefore, none of the Version 4 administration programs, such as the Swing console, wscp scripting (smapi for v4 on z/OS), and XMLConfig, are compatible with Version 5. Instead, Version 5 relies on Extensible Markup Language (XML) configuration files and industry-standard JMX components to handle management functions.

    26. Comparison of Administration in Versions 4 and 5 The Version 4 administration program is a single AdminServer program that serves several functions simultaneously. In Version 4: The AdminServer runs on every node, and every instance of the AdminServer is equivalent to any other. In Version 5, the same functions that were combined in the Version 4 AdminServer have been separated into different specialized administrative programs. The node agent program discussed earlier runs on every node and is specialized to perform node-specific administration functions, such as server monitoring, configuration synchronization, file transfer, and request routing. The single Deployment Manager program manages the entire cell, coordinating with the node agents for the various nodes in the cell. Unlike Version 4, all administrative functions and programs are applicable to all editions of the product in Version 5: The same scripting program, wsadmin, that works for the Version 5 WebSphere Express edition also works for the full Enterprise package, even on the enterprise-class zSeries server machines. The same Administrative Console program, a J2EE Web application based on Java Server Pages (JSPs) and the Jakarta struts framework, works for all editions of Application Server Version 5.

    27. Comparison of Administration in Versions 4 and 5

    28. Script to start a JVM process shell script :- #!/usr/bin/ksh COUNT=`ps -ef | egrep 'java_dev|aysncjvm' | grep -v egrep | wc -l` echo $COUNT if [ "$COUNT" -eq 0 ] then /usr/bin/start fi

More Related