Steps to manually configure Entreprise Manager Control to manually created database.
This file extracted from the link given at the bottom if you need more details refer that link
Configuring Database Control with EMCA
When you use DBCA to configure Oracle Database 10g, DBCA provides a graphical user interface to help you select Database Control options and to configure other aspects of your database.
However, if you want to use the operating system command line to configure Database Control, you can use the Enterprise Manager Configuration Assistant (EMCA).
To configure Database Control with EMCA:
1. Set the following environment variables to identify the Oracle home and the system identifier (SID) for the database you want to manage:
o ORACLE_HOME
o ORACLE_SID
2. Change directory to the ORACLE_HOME/bin directory.
3. Start EMCA by entering the following command with any of the optional command-line arguments shown in Table 1-3:
4. $PROMPT> ./emca
5.
Depending upon the arguments you include on the EMCA command line, EMCA prompts you for the information required to configure Database Control.
For example, enter the following command to configure Database Control so it will perform automatic daily backups of your database:
$PROMPT> ./emca -config dbcontrol db -backup
EMCA commands are of the form:
emca [operation] [mode] [flags] [parameters]
Note: [once manually create database ue this commands to create repository for Entreprise Manager to that particular database and the configure with enterprie manager]
To configure Database Console for single instance database using ASM, no extra parameters need to be passed along with the EMCA command. Run the following command to configure the Database Console which will automatically detect the ASM instance:
emca -config dbcontrol db -repos create
Table 1-3 describes the valid execution operations and modes, and lists the optional parameters in brackets. Table 1-4 discusses the flags and their behavior, while Table 1-5 defines the optional parameters in detail. EMCA parameters are of the form [ -parameterName parameterValue ]. Multiple parameters can be used in combination at the command line.
Table 1-3 EMCA Command-Line Operations
Command Description
emca -h | --h | -help | --help Use this option to display the Help message for the EMCA utility. The options described in Table 1-3, Table 1-4, andTable 1-5, and the valid parameters you may include are listed.
emca –version Prints the version information associated with EMCA.
emca -config dbcontrol db [-repos (create | recreate)] [-cluster] [-silent] [-backup] [parameters] Configures Database Control for a database. Options include creating (or recreating) Database Control repository, configuring automatic backups, and performing these operations on a cluster database.
emca -config centralAgent (db | asm) [-cluster] [-silent] [parameters] Configures central agent management for a database or an Automatic Storage Management (ASM) instance. Options include performing this operation on a cluster environment.This operation will configure the database so that it can be centrally managed by the Oracle Enterprise Manager 10g Grid Control Console. To use this option, you must have previously installed the Oracle Management Service component of Enterprise Manager on a network host. In addition, the Oracle Management Agent must be installed on the host where you are running the database.
emca -config all db [-repos (create | recreate)] [-cluster] [-silent] [-backup] [parameters] Configures both Database Control and central agent management for a database. The possible configuration options are similar to those described above.
emca -deconfig dbcontrol db [-repos drop] [-cluster] [-silent] [parameters] Deconfigures Database Control for a database. Options include dropping the Database Control repository and performing these operations on a cluster database. For example, you might use this command to remove the Database Control configuration from a database you are planning to delete. In such a scenario, remove the Database Control configuration before physically deleting the database. This operation does not remove the actual database or its data files.
emca -deconfig centralAgent (db | asm) [-cluster] [ -silent] [parameters] Deconfigures central agent management for a database or an ASM instance. Options include performing this operation on a cluster environment. For example, you might use this command to remove the central agent management configuration from a database you are planning to delete. In such a scenario, remove the central agent management configuration before physically deleting the database. This operation does not remove the actual database or its data files.
emca -deconfig all db [-repos drop] [-cluster] [-silent] [parameters] Deconfigures both Database Control and central agent management for a database. The possible deconfiguration options are similar to those described above.
emca -addInst (db | asm) [-silent] [parameters] Configures Enterprise Manager for a new cluster instance of a database or ASM storage. For more information, refer to Section 1.2.6.5.
emca -deleteInst (db | asm) [-silent] [parameters] Deconfigures Enterprise Manager for a specific instance of a cluster database or ASM storage. This is discussed further below, in Section 1.2.6.5.
emca -reconfig ports [-cluster] [parameters] Explicitly reassigns Database Control ports. Options include performing this operation on a cluster environment. For more information, refer to Section 1.2.6.6.
emca -reconfig dbcontrol -cluster [-silent] [parameters] Reconfigures Database Control deployment for a cluster database. Note that this command must be used with the "-cluster" option. For more information, refer to Section 1.2.6.5.
emca -displayConfig dbcontrol -cluster [-silent] [parameters] Displays information about the current deployment configuration of Database Control in a cluster environment. Note that this command must be used with the "-cluster" option. For more information, refer to Section 1.2.6.5.
emca -upgrade (db | asm | db_asm) [-cluster] [-silent] [parameters] Upgrades the configuration of an earlier version of Enterprise Manager to the current version. This operation can be performed for database, ASM, or database and ASM instances together simultaneously. This does not upgrade the actual database or ASM instances, nor does it upgrade the Enterprise Manager software. Instead, it upgrades the configuration files for the specified instance so that they are compatible with the current version of the Enterprise Manager software. EMCA will attempt to upgrade all instances of the specified database and/or ASM target on the host, across all Oracle Homes (since it is likely that certain target properties, such as listener port or Oracle Home, have changed).
emca -restore (db | asm | db_asm) [-cluster] [-silent] [parameters] Restores the current version of Enterprise Manager configuration to an earlier version. This is the inverse of the "-upgrade" option (and will reverse any changes that result from an "-upgrade" operation), and as such, the options are similar.
Table 1-4 EMCA Command-Line Flags
Flag Description
Db Performs the operation for a database (including cluster databases). Use this option for databases that use Automatic Storage Management (ASM) to store the data files. If a database is using ASM, all the configuration operations and modes described above (except for "-upgrade" and "-restore") will detect this automatically and apply the changes to both the database and ASM instance(s).
Asm Performs the operation for an ASM-only instance (including cluster ASM instances).
db_asm This flag can only be used in "-upgrade" and "-restore" mode. Performs the upgrade/restore operation for a database and an ASM instance together. Database and ASM instances may be upgraded or restored separately (that is, upgrading an ASM instance does not require upgrading the database instances it services). Hence, the Enterprise Manager configuration can be upgraded or restored separately for a database and its respective ASM instance.
-repos create Creates a new Database Control management repository.
-repos drop Drops the current Database Control management repository.
-repos recreate Drops the current Database Control management repository and then recreates a new one.
-cluster Performs the operation for a cluster database or ASM instance.
-silent Performs the operation without prompting for additional information. If this mode is specified, all the required parameters must be entered at the command line or specified in an input file using the –respFile argument. You can view a list of the available parameters by entering emca -help at the command line.
-backup Configures automatic backup for a database. EMCA will prompt for daily automatic backup options. The default Enterprise Manager settings will be used to backup the database files.Note: If you use this option, EMCA will use the value of the db_recovery_file_dest initialization parameter to identify the flashback recovery area for the automated backups. If that parameter is not set, EMCA will generate an error. You can modify these settings later using the Maintenance page in Database Control. For more information, see the Database Control online Help.
Table 1-5 EMCA Command-Line Parameters
Parameter Description
-respFile Specifies the path of an input file listing parameters for EMCA to use while performing its configuration operation. For more information, refer to Section 1.2.6.4.
-SID Database system identifier
-PORT Port number for the listener servicing the database
-ORACLE_HOME Database Oracle Home, as an absolute path
-LISTENER_OH Oracle Home from where the listener is running. If the listener is running from an Oracle Home other than the one on which the database is running, the parameter LISTENER_OH must be specified.
-HOST_USER Host machine user name (for automatic backup)
-HOST_USER_PWD Host machine user password (for automatic backup)
-BACKUP_SCHEDULE Schedule in the form of "HH:MM" (for daily automatic backups)
-EMAIL_ADDRESS E-mail address for notifications
-MAIL_SERVER_NAME Outgoing Mail (SMTP) server for notifications
-ASM_OH Automatic Storage Management Oracle Home
-ASM_SID System identifier for ASM instance
-ASM_PORT Port number for the listener servicing the ASM instance
-ASM_USER_ROLE User role for connecting to the ASM instance
-ASM_USER_NAME User name for connecting to the ASM instance
-ASM_USER_PWD Password for connecting to the ASM instance
-DBSNMP_PWD Password for DBSNMP user
-SYSMAN_PWD Password for SYSMAN user
-SYS_PWD Password for SYS user
-SRC_OH Oracle Home of the database with Enterprise Manager configuration to be upgraded/restored
-DBCONTROL_HTTP_PORT Use this parameter to specify the port you use to display the Database Control Console in your Web browser. For more information, refer to Section 1.2.6.6.
-AGENT_PORT Use this parameter to specify the Management Agent port for Database Control. For more information, refer to Section 1.2.6.6.
-RMI_PORT Use this parameter to specify the RMI port for Database Control. For more information, refer to Section 1.2.6.6.
-JMS_PORT Use this parameter to specify the JMS port for Database Control. For more information, refer to Section 1.2.6.6.
-CLUSTER_NAME Cluster name (for cluster databases)
-DB_UNIQUE_NAME Database unique name (for cluster databases)
-SERVICE_NAME Database service name (for cluster databases)
-EM_NODE Node from which Database Control console is to be run (for cluster databases). For more information, refer to Section 1.2.6.5.
-EM_SID_LIST Comma-separated list of SIDs for agent-only configurations, uploading data to –EM_NODE. For more information, refer to Section 1.2.6.5.
1.2.6.4 Using an Input File for EMCA Parameters
Instead of answering a series of prompts when you run EMCA, you can use the -respFile argument to specify an input file. The input file you create must be in a format similar to the following example:
PORT=1521
SID=DB
DBSNMP_PWD=xpE234D
SYSMAN_PWD=KDOdk432
After you create an EMCA input file, you can use it on the command line as follows:
$PROMPT> ./emca -config dbcontrol db -respFile input_file_path
For example, to configure the Database Control to perform daily backups and create the Database Control Management Repository, create an input file similar to the one shown in and enter the following command at the operating system prompt:
$PROMPT> ./emca -config dbcontrol db -repos create -backup -respFile input_file_path
Example 1-1 EMCA Input File that Configures Database Control for Automatic Backup and Creates the Database Control Management Repository
PORT=1521
SID=DB
DBSNMP_PWD=dow3l224
SYSMAN_PWD=squN3243
HOST_USER=johnson
HOST_USER_PWD=diTf32of
SYS_PWD=qlKj4352
BACKUP_SCHEDULE=06:30
http://download.oracle.com/docs/cd/B19306_01/em.102/b40002/structure.htm#sthref73
1 comment:
I think that you may be also interested in another repair database access application, it quickly retrieves affected data from damaged files
Post a Comment