Now return to interacting with the Application Server’s Domain Admin Server. You need a shell execution environment for this section.
Create a load balancer configuration called MyLbConfig targeted to the cluster FirstCluster:
asadmin create-http-lb-config --target FirstCluster MyLbConfig
Enable the FirstCluster cluster and the clusterjsp application deployed in it for HTTP load balancing:
asadmin enable-http-lb-server FirstCluster
asadmin enable-http-lb-application --name clusterjsp FirstCluster
Create a health checker for the load balancer, which signals when an instance that goes down recovers.
asadmin create-http-health-checker --interval 10 --config MyLbConfig FirstCluster
The interval is the number of seconds the health checker waits between checks of an unhealthy instance.
Export the configuration to a file loadbalancer.xml.
asadmin export-http-lb-config --config MyLbConfig loadbalancer.xml
Copy loadbalancer.xml to: