Database Reference
In-Depth Information
EMCTL or EMCLI
Enterprise Manager control utility, or EMCTL, is installed with each OEM agent and is used to manually start and stop
OEM agents and to manage local functionality at the remote host.
EMCTL can be used to start and stop (but not delete) OEM blackouts just like EM CLI, but with one key
advantage: EMCTL is already installed and configured. If you choose EM CLI as your blackout-management tool for a
remote host using shell scripts, you must manually install and configure the EM CLI client on each host. EM CLI client
is a static installation of a Java program. The client software installations are reported but not managed through OEM
itself. The number of remote hosts in your environment might make EMCTL the better solution if you are limiting the
functionality to blackout maintenance and other tasks that it can manage. The installation process covered in Chapter 2
provides a scripted means of performing that installation.
Managing blackouts with EMCTL is very similar to the techniques used for EM CLI and lends itself to the same
scripting applications.
The syntax is straightforward:
emctl start blackout <blackout name><target names>
emctl start blackout <blackout name> -nodelevel
emctl stop blackout <blackout name>
emctl status blackout <blackout name>
The nodelevel flag blacks out all targets on the node and works well for patching activities.
Durations are specified by a -d flag and may be set for a combination of days and hours like this:
emctl start blackout WeekendBlackout -nodelevel -d 2 12:00
In this example, a blackout for all targets on a development node could be scheduled to start at 6:00 PM on a
Friday and would run up to 6:00 AM on Monday (two days and twelve hours).
Managing OEM Administrators with EM CLI
The console provides a clear, convenient method for managing OEM administrator accounts, but its flexibility makes
it tremendously inconvenient for creating multiple accounts as you click through all the screens. By the author's
count, creating a new administrator in the console requires at least 17 mouse clicks! EM CLI combines the flexibility
inherent in the OEM code base with the simplicity of the command-line interface.
All of the options defined in the console can be granted as options in EM CLI using the flags shown below. To
create an administrator you only need to give the account a name and password:
emcli create_user -name="SuzyQueue"-password="oracle"
You wouldn't be reading a book from Apress if you ignored user security, so you'll want to expire the user's new
password with the -expired="true" flag, like this:
emcli create_user \
-name="SuzyQueue"\
-password="oracle"\
-expired="true"
The other optional parameters allow you to perform the user grants available in the OEM console but without the
click-stream.
 
Search WWH ::




Custom Search