Thursday, May 8, 2014

Get notified when your WebLogic server is in trouble

Once you have enabled the Oracle Middleware plugin in Enterprise Manager and discovered your WebLogic servers, how do you get notified if something misbehaves?

First you need to configure Monitoring Templates. Monitoring Templates are used to set limits and thresholds for Metric Data. Metric Data are collected from your targets at given intervals. Actually the biggest task for any new Enterprise Manager installation is to configure the different Monitoring Templates for target types, environments and even custom metrics that you need to monitor.



It is possible to create new templates or used pre-created ones as a starting point. Even if you create a new one, it is not going to be empty. It has default metrics and limits already configured for the specific target type.



Not going into more details about Monitoring templates, have a look at the EM documentation here for more specific details.

Once the Monitoring Template has been created, it needs to be applied to a target. This can either be done via Administration Groups or directly by selecting the template and clicking [Apply] in the Monitoring Template list screen.



Apply the Monitoring template directly to a specific Target, Group, Farm or Domain


Once done, lets explore the Incident management settings

Incident Management

First, we need to configure an e-mail server connection if not done already:


Configure the correct e-mail server properties, username etc. and test the configuration by clicking the [Test Mail Servers] button.

Make sure that your user has been configured with a valid e-mail address by going into the Password & Email page:


Next, it is time to configure some Incident Rules:


Before beginning adding new rules, have a look at the little "play" button beneath the menu line.
TIP: These icons are links to YouTube videos that explain and demo functionality in EM.  


Press the link button and follow the links or play them directly from YouTube located here and here. The videos will take you through the process of creating rules and rule sets. 

Now go ahead and create your own rules and rule sets that you would like to use on your middleware, hosts, databases and other targets.

Subscribe to the work of others

Going back to the rule set menu, notice that it is possible to subscribe to other rule sets then the ones you create or target to yourself. 

 

Blackouts vs. disabling notifications

Some times I have seen examples of organizations disabling rule sets instead of creating Blackouts when performing maintenance. There are several reasons for doing this, but mainly the explanation has been that they want to still be able to see the up/down status of targets and not only black. Just remember to enable the rule sets afterwards, and clear any related incidents before they get escalated.  

Wednesday, May 7, 2014

Easy backup of your WebLogic domains

How to create a Provisioning Profile

One of the questions I often get is on how to create a backup of a middleware domain. It is as simple as to create a file backup of your directories and maybe take a database backup if you use any other Fusion Middleware product on top. The only catch is that you need to have a machine for restore with the exact same layout, name etc.
What if there is another way to backup your domain and your Fusion Middleware binary files? Can the same backup be used to create additional development, test and production environments? The solution is Enterprise Manager provisioning profiles. It still won't do a database backup, but when later deploying a profile, you can change passwords, ports in use, install directories etc.

To create a backup of your domain, go to the top menu and select [Provisioning], and then [Create WebLogic Domain Provisioning Profile].


You are then taken into the Software Library of Enterprise Manager. It is recommended that you create a separate directory structure for your provisioning profiles. To create additional directories, just right-click and create a new directory from the parent directory.


When happy with the layout, right-click again and choose [Component]. A new pop-up will appear.


Choose [WebLogic Domain Provisioning Profile].

The difference between Oracle Middleware Home Gold Image and Provisioning Profile is the following:

  1. Oracle Middleware Home Gold Image is used to create a deployable profile of your binary installation. This will ease your next installation of Fusion Middleware. Do it once, and the just provision the Gold Image the next time a new installation is required.
  2. WebLogic Domain Provisioning Profile is used to backup and provision your domain as well. When creating a WebLogic Domain Provisioning Profile, you have the option to create a Oracle Middleware Home Gold Image as well.

Just follow the Wizard, entering the required information. Note that it is possible to add Attachments and Notes. Such as documentation, network charts and Word or Excel documents. 


Press [Next]. It is possible to add a Middleware Home to be used with the domain. It does not need to be the same as hosting your domain.

The next screen is just a summary


Press [Save and Upload]

A job is created that can be monitored


Once the job has finished the new profile should be visible in the Enterprise Manager Software Library.

Provision your newly created Profile

To provision the newly created profile to the same or a different machine, then go into [Enterprise->Provisioning and Patching->Middleware Provisioning]



Then select [Provision Middleware]


A Wizard will then help you to provision both domains, and Middleware Homes.