This section explains about clustering Portal Server 7.1 on BEA WebLogic 8.1 Service Pack 4 and Service Pack 5.
In this section, you do the following:
Install Directory Server and Web Server on Node 1. (psconsole of Sun Java System Portal Server does not support WebSphere and WebLogic.)
Install BEA WebLogic 8.1 Service Pack 4 or WebLogic 8.1 Service Pack 5 using Sun Java Development Kit.
Create a node agent on Node 1 on the port 5555.
Create three managed servers on the following ports of the node agent: port 7011, port 7022, and port 55555. The first two managed servers are used for creating the Portal Server instances. The third managed server is used as proxy server for load balancing.
Create a BEA WebLogic managed server on Node 2.
Create a node agent and managed server on Node 2 using the Administrator Server on Node 1.
Install Access Manager on Administrator Server on Node 1.
Install Portal Server on port 7011 of Node 1. Creates an instance of Portal Server on the managed servers created on Node 1 and Node 2.
Configure a cluster and a load balancer.
Install a Gateway on Node 3.
Ensure that the node on which you perform the task has a BEA license for clustering to work.
Ensure that all clustered nodes are in the same subnet.
Run the BEA WebLogic 8.1 installer to install BEA WebLogic 8.1.
Run the script quickStart.sh after a successful installation.
Bea-base/weblogic81/common/bin/quickStart.sh
Click Create a New Domain Configuration or Extend an Existing One.
The installation panel appears.
Enter admin and the admin password.
Leave the other defaults as they are.
Click Finish to complete the installation.
To start WebLogic, run the startWeblogic.sh script.
Bea-base/user_projects/domains/mydomain/startWeblogic.sh
Access the Administrator server.
http://node1.domain-name:7001/console
By default, the administrator server of WebLogic is created on port 7001.
This procedure creates a node agent on the port 5555, which is the default port for node agents. A node agent is required to create managed servers.
Log in to the administrator server.
http://node1.domain-name:7001/console
Click Machines and click Configure a New Machine.
Enter a name for the node agent, and click Create. For example, node_1.
By default, the node agent runs on the port 5555. If you need any other port, enter the port number in the Node Manager tab.
On Node 1, start the node agent.
Bea-base/weblogic81/server/bin/startNodeManager.sh node1-ip-address 5555
This procedure creates managed servers on port 7011, port 7022, and port 55555. The first two managed servers are used for creating Portal Server instances. The last one is used as a proxy server to set up the load balancer.
Log in to the administrator server.
http://node1.domain-name:7001/console
Click Servers, and click Configure a New Machine.
Enter a name for the managed server. For example, node1_7011.
Select node_1 from the Machine list box.
Enter the Listen Port as 7011, and click Create.
To start the managed server, click the Control tab and click Start the Server.
(Optional) You can also start the managed server using the command-line interface.
bea_base/user_projects/domains/mydomain/startManagedWeblogic.sh node1_7011
Use steps 2 through 5 to create a managed server named node1_7022 with a listen port of 7022.
Start the second managed server.
Use steps 2 through 5 to create a managed server named proxy with a listen port of 55555.
This managed server is used for the proxy settings.
Start the third managed server.
This procedure creates a node agent on port 5555 on Node 2 using the administrator console installed in Node 1.
Install BEA WebLogic on Node 2.
Log in to the administrator server of Node 1.
http://node1.domain-name:7001/console
Click Machines and click Configure a New Machine.
Enter node_2 for the node agent name, and click Create.
In the Listen Address field, enter the IP address of Node 2.
On Node 2, start the node agent.
Bea-base/weblogic81/server/bin/startNodeManager.sh node2-ip-address 5555
In the nodemanager.Hosts file of Node 2, add the IP address of Node 1.
Bea-base/weblogic81/common/nodemanager.Hosts
You need to do this to ensure that Node 2's node agent can accept commands from the administrator server on Node 1.
This procedure creates a managed server on Node 2 on the port 7033 using the administrator console installed on Node 1.
Log in to the administration server.
http://node1.domain-name:7001/console
Click on Servers, and click Configure a New Machine.
Enter a name for the managed server. For example, node2_7033.
Select node_2 from the Machine list box.
Enter the Listen Address as the IP address of Node 2.
Enter the Listen Port as 7022, and click Create.
Click the Control tab and click Start the Server.
(Optional) You can also start the managed server using the command-line interface on Node 2.
bea_base/user_projects/domains/mydomain/startManagedWeblogic.sh node2_7033
This procedure installs Access Manager on the Administrator server (BEA WebLogic 8.1 Administrator Server) on Node 1. By default, the Administrator Server port is 7001.
Install Directory Server and Web Server using the Java ES installer.
Install Access Manger in the Configure Later mode.
Run amsamplesilent.
AccessManager_base/SUNWam/amconfig -s amsamplesilent
Change the values in amsamplesilent accordingly.
Access amconsole and verify whether Access Manager is running.
http://node1.domain-name:7001/amconsole
This procedure installs Portal Server 7.1 on port 7011 of the managed server on Node 1.
Install Portal Server 7.1 using the Java ES installer.
In the installer, select Managed Server while installing.
Access the portal.
http://node1.domain-name:7011/portal/dt
The Portal Welcome page appears.
This procedure creates an instance of Portal Server on port 7022 of the managed server on Node 1.
Modify the Webcontainer.properties file in BEA WebLogic to change the values corresponding to the managed servernode1_7022.
Create an instance of Portal Server.
PortalServer_base/SUNWportal/bin/psadmin create-instance -u amadmin -f password -p portal1 -w webcontainer.properties.BEAWL8
Restart the managed server named node1_7022.
Access the portal.
http://node1.domain-name:7022/portal/dt
The Portal Welcome page appears.
This procedure creates an instance of Portal Server on port 7033 of the managed server on Node 2.
Install Portal Server 7.1 and Access Manager SDK in the Configure Later mode using the installer.
Modify the amsamplesilent script with appropriate values. Ensure that DEPLOY_LEVEL is set as 4.
The amsamplesilent script is located in the AccessManager_base/SUNWam/bin directory.
Run the amsamplesilent script.
AccessManager_base/SUNWam/bin/amconfig -s amsamplesilent.
Copy the example15.xml file to a temporary directory and modify it with appropriate values.
The example15.xml file is located in the PortalServer_base/SUNWportal/samples/psconfig directory.
Configure Portal Server using the example15.xml as the configuration XML file.
PortalServer_base/SUNWportal/bin/psconfig --config example15.xml
Modify the webcontainer.properties file in BEA WebLogic to change the values corresponding to the managed server node1_7033.
Create a Portal Server instance.
PortalServer_base/SUNWportal/bin/psadmin create-instance -u amadmin -f password -p portal1 -w webcontainer.properties.BEAWL8
Restart the managed server node1_7033.
Access the portal.
http://node1.domain-name:7033/portal/dt
The Portal Welcome page appears.
This procedure configures a cluster for the three managed server that were created: node1_7011, node1_7022, and node2_7033.
Log in to the administrator server.
http://node1.domain-name:7001/console
Click Cluster and click Configure a New Cluster.
Enter a cluster name and cluster address.
Enter the cluster name as new_cluster and enter the cluster address as node1.domain-name.
Select Default Load Algorithm as round robin, and click Create.
Click the Server tab, and select node1_7011, node1_7022 and node1_7033 and drag them into the list box.
Stop and restart all of the servers.
Each time you change the cluster configuration you must stop and restart all of the servers in the cluster.
Select the Monitoring tab.
After a successful configuration of cluster, the following is displayed.
Number of servers configured for this cluster: 2 Number of servers currently participating in this cluster: 2 |
This procedure creates a proxy server .war file for load balancing.
Telnet to Node 1.
Create files web.xml and weblogic.xml in the new proxy/WEB-INF directory.
mkdir -p proxy/WEB-INF cd proxy/WEB-INF |
Add the following contents to the web.xml file.
<!DOCTYPE web-app PUBLIC "-//Sun Microsystems, Inc.//DTD Web Application 2.3 //EN? "http://java.sun.com/dtd/web-app_2_3.dtd"><web-app> <servlet> <servlet-name>HttpClusterServlet</servlet-name> <servlet-class>weblogic.servlet.proxy.HttpClusterServlet</servlet-class> <init-param> <param-name>WebLogicCluster</param-name> <param-value>HOST.DOMAIN:7011|HOST.DOMAIN:7022</param-value> </init-param> </servlet> <servlet-mapping> <servlet-name>HttpClusterServlet</servlet-name> <url-pattern>/</url-pattern> </servlet-mapping> <servlet-mapping> <servlet-name>HttpClusterServlet</servlet-name> <url-pattern>*.jsp</url-pattern> </servlet-mapping> <servlet-mapping> <servlet-name>HttpClusterServlet</servlet-name> <url-pattern>*.htm</url-pattern> </servlet-mapping> <servlet-mapping> <servlet-name>HttpClusterServlet</servlet-name> <url-pattern>*.html</url-pattern> </servlet-mapping> </web-app> |
Add the following contents to the weblogic.xml file.
<!DOCTYPE weblogic-web-app PUBLIC "-//BEA Systems, Inc.//DTD Web Application 8.1// EN" "http://www.bea.com/servers/wls810/dtd/weblogic810-web-jar.dtd"> <weblogic-web-app> <context-root>/</context-root> </weblogic-web-app> |
Change directories to the proxy directory.
Run the following command:
/usr/jdk/jdk1.5.0_01/bin/jar cvf proxy.war WEB-INF
Access the administrator console.
http://node1.domain-name:7001/console
Click Server > Configure a New Server.
Enter the new server name as proxy and the listen port as 55555, and click Apply.
Click Deployment in the left pane, click Web Applications Module, and click Deploy New.
Select proxy.war from the node1.domain and deploy it on the independent server named proxy.
This procedure deploys all .war files on the cluster. Redeployment of all the .war files needs to be done on the cluster.
Log in to administrator server.
Click Web Application Modules.
For each Portal Web Application module, click the Target tab, select All Servers in the Cluster option, and click Apply.
Click Services > JDBC > Connection Pools.
For each connection pool related to Portal Server, click the Target tab, select All Servers in the Cluster option, and click Apply.
Click Services > JDBC > Data Source.
For each data source related to Portal Server, click the Target tab, select All Servers in the Cluster option, and click Apply.
Restart all servers.
Install Gateway on Node 3.
Enter the load balancer URL, http://node1/domain-name:55555/portal, as the portal URL while installing gateway.
Log in to gateway and access developer/developer.
If the proxy is working, the URL changes to the following: https://GWhost:443/http://node1.domain-name:55555/portal/dt