![]() ![]() ![]() ![]() ![]() ![]() |
In a WLOC environment, resource pools provide a virtual environment in which you can deploy WLOC services. Each resource pool provides access to physical computing resources (such as CPU cycles, memory, and disk space) and pre-installed software that a service needs to run.
To establish a WLOC resource environment, you need to configure a controller and one or more agents. You can do so using the WLOC Configuration Wizard. When you configure an Agent, you configure its resource pool. A Plain Agent manages the computing resources for the physical machine on which the Agent is installed.
When you configure the Controller, you bind it to the Agents so that it can get information about the resources and deploy services accordingly.
The Controller also hosts the WLOC Administration Console, which provides a graphical interface into the WLOC environment.
In this example, we will install and create a Plain Agent and a Controller on the same local Windows machine. For instructions about installing WLOC and starting the Configuration Wizard on UNIX or Linux platforms, see the following:
The main steps in this topic include:
In this example, we will install the Plain Agent and the Controller on the same local Windows machine. When you perform a Complete installation, all of the WLOC components are installed automatically. For details about installing WLOC, see the WLOC Installation Guide.
If the Plain Agent is managing resources on a different machine, be sure to install the Agent software on that machine.
In this example, we install WLOC into the C:\WLOC_UseCase
directory.
After you install the agent and the controller software, you create them using the WLOC Configuration Wizard.
To create the Plain Agent, complete the following steps:
By default, this directory is created in BEA_HOME
\user_projects\agent1
, but you can specify any name and directory location you choose.
Note that we used C:\WLOC_UseCase
as the BEA_HOME
directory when we installed the WLOC software, therefore that BEA_HOME
value is displayed as the default.
For this example, we accept the default C:\WLOC_UseCase\user_projects
location, and change the name of the directory to PlainAgent.
Note: | In this example, we do not need to select the Secure setting for the Security mode field because we do not need to use SSL between the Agent and the Controller. However, in a production environment, you need to use the secure settings, and set the passwords and passphrases accordingly. For details about secure communications, see “Configuring Security” in the Configuration Guide. |
After completing the Plain Agent installation and creation, the following directory structure is created in the C:\WLOC_UseCase\user_projects\PlainAgent
directory.
Table 2-2 describes the contents of these directories.
When you create an Agent using the WLOC Configuration Wizard, the configuration is persisted in an XML file named loc-agent-config.xml
. In this example, the file is created in the following directory:
C:\WLOC_UseCase\user_projects\PlainAgent\config
WLOC_UseCase
is the BEA Home directory containing the WLOC installation, and PlainAgent
is the name that we specified for the Agent Directory location in the Configuration Wizard.
After you have created the Agent using the Configuration Wizard, it can be modified using the Administration Console or by directly editing its configuration file.
The loc-agent-config.xml
file created in this example is shown in Listing 2-1
<?xml version="1.0" encoding="UTF-8"?><loc-agent xmlns="bea.com/loc/agent" xmlns:loc="http://bea.com/loc">
<name>PlainAgent</name>
<description>PlainAgent</description>
<network>
<loc:host>localhost</loc:host>
<loc:components>
<loc:component>
<loc:name>ListenPorts</loc:name>
<loc:description>ListenPorts</loc:description>
<loc:port>8001</loc:port>
<loc:secure-port>8002</loc:secure-port>
</loc:component>
</loc:components>
</network>
<use-secure-connections>false</use-secure-connections>
<logging>
<loc:file-severity>Info</loc:file-severity>
<loc:base-file-name>C:\WLOC_UseCase
/user_projects/PlainAgent/logs/Agent.log</loc:base-file-name>
<loc:rotation-type>BySize</loc:rotation-type>
<loc:rotation-size>5000</loc:rotation-size>
<loc:rotation-time>00:00</loc:rotation-time>
<loc:file-rotation-dir>./logs/logrotdir</loc:file-rotation-dir>
<loc:number-of-files-limited>true</loc:number-of-files-limited>
<loc:rotated-file-count>5</loc:rotated-file-count>
<loc:rotation-time-span>24</loc:rotation-time-span>
<loc:rotation-time-span-factor>3500000</loc:rotation-time-span-factor>
<loc:rotation-on-startup-enabled>true</loc:rotation-on-startup-enabled>
<loc:stdout-severity>Info</loc:stdout-severity>
</logging>
<audit>
<loc:base-file-name>./logs/audit.log</loc:base-file-name>
<loc:rotation-type>BySize</loc:rotation-type>
<loc:rotation-size>300</loc:rotation-size>
<loc:rotation-time>00:00</loc:rotation-time>
<loc:file-rotation-dir>./logs/logrotdir</loc:file-rotation-dir>
<loc:number-of-files-limited>true</loc:number-of-files-limited>
<loc:rotated-file-count>50</loc:rotated-file-count>
<loc:rotation-time-span>24</loc:rotation-time-span>
<loc:rotation-time-span-factor>50</loc:rotation-time-span-factor>
<loc:rotation-on-startup-enabled>true</loc:rotation-on-startup-enabled>
<loc:enabled>true</loc:enabled>
<loc:scope>
<loc:type>All</loc:type>
</loc:scope>
</audit>
<work-managers>
<loc:work-manager>
<loc:name>WM</loc:name>
<loc:description>WM</loc:description>
<loc:max-threads-constraint>64</loc:max-threads-constraint>
<loc:min-threads-constraint>3</loc:min-threads-constraint>
</loc:work-manager>
<loc:work-manager>
<loc:name>ResourceBrokerAgent-WM</loc:name>
<loc:description>ResourceBrokerAgent-WM</loc:description>
<loc:max-threads-constraint>15</loc:max-threads-constraint>
<loc:min-threads-constraint>3</loc:min-threads-constraint>
</loc:work-manager>
<loc:work-manager>
<loc:name>AgentRuntime-WM</loc:name>
<loc:description>AgentRuntime-WM</loc:description>
<loc:max-threads-constraint>15</loc:max-threads-constraint>
<loc:min-threads-constraint>3</loc:min-threads-constraint>
</loc:work-manager>
</work-managers>
<encryption>
<password>{Salted-3DES}8U+L9mNDmAFoUayTkWaFOQ==</password>
</encryption>
<resource-pools>
<plain-resource-pool>
<name>resource-resource-pool</name>
<description>plain resource pool</description>
<cpu-capacity>512</cpu-capacity>
<stdout-dir>C:\WLOC_UseCase
\user_projects\PlainAgent\stdout</stdout-dir>
<stderr-dir>C:\WLOC_UseCase
\user_projects\PlainAgent\stderr</stderr-dir>
</plain-resource-pool>
</resource-pools>
</loc-agent>
For information about the elements of the loc-agent-config.xml
Agent configuration file, see the
Agent Configuration Schema Reference.
Every WLOC environment includes a single Controller and one or more Agents. The Controller is the central component that gathers data about the operating environment from Agents. The Controller uses the data that it gathers to intelligently deploy new services and to evaluate and enforce policies for all services in the environment. The Controller also hosts the WLOC Administration Console.
Although you can install the Agent and the Controller on different physical machines, in this example, we installed the Controller as part of a complete installation on the local machine as described in Step 1: Install WLOC. After the controller is installed, you create it using the WLOC Configuration WIzard.
To create the Controller, complete the following steps:
Note: | To edit a field, you need to double-click the value in the field. |
Note that the passphrase specified here must match the passphrase that you defined when you created the Agent. Because we accepted the default when we created the Agent, we can accept the same default here.
Note: | The default username is WLOCBootUser and the default password is changeit: |
Note: | The default passwords are changeit. |
After completing the Controller installation and creation, the following directory structure is created in the C:\WLOC_UseCase\user_projects\controller
directory.
Table 2-2 describes the contents of these directories.
When you create a Controller using the WLOC Configuration Wizard, the configuration is persisted in an XML file named loc-controller-config.xml
. In this example, the file is created in the following directory:
C:\WLOC_UseCase\user_projects\controller\config
WLOC_UseCase
is the BEA Home directory containing the WLOC installation, and controller
is the name that we specified for the Controller Directory location in the Configuration Wizard.
After you have created the Controller using the Configuration Wizard, it can be modified using the Administration Console or by directly editing its configuration file.
The loc-controller-config.xml
file created in this example is shown in Listing 2-2.
<?xml version="1.0" encoding="UTF-8"?><loc-controller xmlns="bea.com/loc/controller" xmlns:loc="http://bea.com/loc">
<network>
<loc:host>localhost</loc:host>
<loc:components>
<loc:component>
<loc:name>Console</loc:name>
<loc:description>Console</loc:description>
<loc:port>9001</loc:port>
<loc:secure-port>9002</loc:secure-port>
</loc:component>
<loc:component>
<loc:name>InternalCommunication</loc:name>
<loc:description>InternalCommunication</loc:description>
<loc:port>9003</loc:port>
<loc:secure-port>9004</loc:secure-port>
</loc:component>
</loc:components>
</network>
<use-secure-connections>false</use-secure-connections>
<console-mode>BOTH</console-mode>
<logging>
<loc:file-severity>Info</loc:file-severity>
<loc:base-file-name>C:/WLOC_UseCase/user_projects/controller/logs/Controller.log</loc:base-file-name>
<loc:rotation-type>BySize</loc:rotation-type>
<loc:rotation-size>500</loc:rotation-size>
<loc:rotation-time>00:00</loc:rotation-time>
<loc:file-rotation-dir>./logs/logrotdir</loc:file-rotation-dir>
<loc:number-of-files-limited>true</loc:number-of-files-limited>
<loc:rotated-file-count>5</loc:rotated-file-count>
<loc:rotation-time-span>24</loc:rotation-time-span>
<loc:rotation-time-span-factor>3500000</loc:rotation-time-span-factor>
<loc:rotation-on-startup-enabled>true</loc:rotation-on-startup-enabled>
<loc:stdout-severity>Info</loc:stdout-severity>
</logging>
<audit>
<loc:base-file-name>./logs/audit.log</loc:base-file-name>
<loc:rotation-type>BySize</loc:rotation-type>
<loc:rotation-size>300</loc:rotation-size>
<loc:rotation-time>00:00</loc:rotation-time>
<loc:file-rotation-dir>./logs/logrotdir</loc:file-rotation-dir>
<loc:number-of-files-limited>true</loc:number-of-files-limited>
<loc:rotated-file-count>50</loc:rotated-file-count>
<loc:rotation-time-span>24</loc:rotation-time-span>
<loc:rotation-time-span-factor>50</loc:rotation-time-span-factor>
<loc:rotation-on-startup-enabled>true</loc:rotation-on-startup-enabled>
<loc:enabled>true</loc:enabled>
<loc:scope>
<loc:type>ControllerConfiguration</loc:type>
<loc:type>ServiceConfiguration</loc:type>
<loc:type>Rules</loc:type>
<loc:type>ControllerAction</loc:type>
<loc:type>Adjudication</loc:type>
<loc:type>AgentConfiguration</loc:type>
</loc:scope>
</audit>
<work-managers>
<loc:work-manager>
<loc:name>WM</loc:name>
<loc:description>WM</loc:description>
<loc:max-threads-constraint>64</loc:max-threads-constraint>
<loc:min-threads-constraint>3</loc:min-threads-constraint>
</loc:work-manager>
<loc:work-manager>
<loc:name>ResourceBroker-WM</loc:name>
<loc:description>ResourceBroker-WM</loc:description>
<loc:max-threads-constraint>15</loc:max-threads-constraint>
<loc:min-threads-constraint>3</loc:min-threads-constraint>
</loc:work-manager>
<loc:work-manager>
<loc:name>Action-Purge-WM</loc:name>
<loc:description>Action-Purge-WM</loc:description>
<loc:max-threads-constraint>15</loc:max-threads-constraint>
<loc:min-threads-constraint>3</loc:min-threads-constraint>
</loc:work-manager>
<loc:work-manager>
<loc:name>ExecuteEngine-WM</loc:name>
<loc:description>ExecuteEngine-WM</loc:description>
<loc:max-threads-constraint>15</loc:max-threads-constraint>
<loc:min-threads-constraint>3</loc:min-threads-constraint>
</loc:work-manager>
<loc:work-manager>
<loc:name>ProcessRuntime-WM</loc:name>
<loc:description>ProcessRuntime-WM</loc:description>
<loc:max-threads-constraint>15</loc:max-threads-constraint>
<loc:min-threads-constraint>3</loc:min-threads-constraint>
</loc:work-manager>
<loc:work-manager>
<loc:name>Actions-WM</loc:name>
<loc:description>Actions-WM</loc:description>
<loc:max-threads-constraint>15</loc:max-threads-constraint>
<loc:min-threads-constraint>3</loc:min-threads-constraint>
</loc:work-manager>
</work-managers>
<heartbeat-interval>20</heartbeat-interval>
<reconnect-attempts>3</reconnect-attempts>
<agents>
<agent>
<name>PlainAgent</name>
<host>localhost</host>
<port>8001</port>
<secure-port>8002</secure-port>
<state>Enabled</state>
<password>{Salted-3DES}P6sAuDdtOnRp7Q/eDWnhKg==</password>
</agent>
</agents>
<lvm-ssh-config>
<public-key-file/>
</lvm-ssh-config>
<notification>
<smtp>
<name>LOC EMail Notification Service</name>
<description>LOC EMail Notification Service</description>
<to-address>bogus</to-address>
<from-address>bogus</from-address>
<smtp-server>bogus</smtp-server>
<enabled>false</enabled>
</smtp>
<jms>
<name>LOC JMS Notification Service</name>
<description>LOC JMS Notification Service</description>
<destination-jndi-name>com.bea.adaptive.loc.notification.JMSNotifier</destination-jndi-name>
<connection-factory-jndi-name>QueueConnectionFactory</connection-factory-jndi-name>
<jndi-properties>
<initial-factory>org.mom4j.jndi.InitialCtxFactory</initial-factory>
<provider-url>bogus</provider-url>
<security-principal>bogus</security-principal>
<password>{Salted-3DES}ZlcPX6S/hpM=</password>
</jndi-properties>
<enabled>false</enabled>
</jms>
<jmx>
<name>JMX Notification Service</name>
<description>JMX Notification Service</description>
<enabled>false</enabled>
</jmx>
<snmp>
<name>LOC SNMP Notification Service</name>
<description>LOC SNMP Notification Service</description>
<agent>
<name>MySNMPAgent</name>
<description>MySNMPAgent</description>
<host>bogus</host>
<port>5555</port>
<trap-version>SNMPv2</trap-version>
<enable-inform>false</enable-inform>
</agent>
<trap-destinations>
<destination>
<name>testTrapDest</name>
<description>testTrapDest</description>
<host>bogus</host>
<port>5555</port>
<community>public</community>
<security-level>noAuthNoPriv</security-level>
</destination>
</trap-destinations>
<enabled>false</enabled>
</snmp>
</notification>
</loc-controller>
For information about the elements of the loc-controller-config.xml
Controller configuration file, see the
Controller Configuration Schema Reference.
After installing and creating the Plain Agent and Controller, go to Establish the WLOC Runtime Environment, which describes how to start the Agent, the Controller, and the WLOC Administration Console.
![]() ![]() ![]() |