Emca drop and recreate for RAC DB.

metalink notes Note:315299.1 discuss the same problem
Now question is
1-What are the steps to Recreate the Database Control configuration files:
& what -x and -r flags are doing ? can i run simple emca and do the job? I am in RAC environment.
./bin/emca -x <sid>
./bin/emca -r

You can add the -cluster parameter.
Read more about it in the documentation

Similar Messages

  • EMDATABASEControl emca drop and recreate in RAC

    Any body know how to drop and recreate EMDATABASEControl (emca) drop and recreate for RAC DB?

    use emca -help you can get the parameters used to de-configure and re-configure the emca for RAC
    $emca -help
    -deleteInst (db | asm) [-silent] [parameters]: de-configure EM for a specified RAC instance
    -reconfig dbcontrol -cluster [-silent] [parameters]: reconfigures RAC Database Control deployment

  • What is the best way to drop and recreate a Primary Key in the Replication Table?

    I have a requirement to drop and recreate a primary key in a table which is part of Transaction replication. What is the best way to fo it other than remove it from replication and add again?
    Thanks
    Swapna

    Hi Swapna,
    Unfortunately you cannot drop columns used in a primary key from articles in transactional replication.  This is covered in
    Make Schema Changes on Publication Databases:
    You cannot drop columns used in a primary key from articles in transactional publications, because they are used by replication.
    You will need to drop the article from the publication, drop and recreate the primary key, and add the article back into the publication.
    To avoid having to send a snapshot down to the subscriber(s), you could specify the option 'replication support only' for the subscription.  This would require the primary key be modified at the subscriber as well prior to adding the article back in
    and should be done during a maintenance window when no activity is occurring on the published tables.
    I suggest testing this out in your test environment first, prior to deploying to production.
    Brandon Williams (blog |
    linkedin)

  • Synonyms cant be recompiled when the tables are dropped and recreated?

    hi
    i have a synonym pointing to a table .
    1)when i drop and recreate a table.............
    isnt it enough to recompile the synonym? do i need to drop the synonym as well and recreate again?
    2) when i add new columns to a table will the synonym also show up the new column?
    thanks in advance
    raj

    Recompiled is probably not quite the correct word. Re-validated is more like it.
    Notice that the synonym goes invalid when the table is dropped, but does NOT become valid when the table is recreated.
    That happens the first time it's used (similar to invalid stored procedures).
    SQL> drop table t;
    Table dropped.
    SQL> select object_name, status
      2  from user_objects
      3  where object_name = 'T_SYN';
    OBJECT_NAME                    STATUS
    T_SYN                          INVALID
    SQL> create table t(c number);
    Table created.
    SQL> select object_name, status
      2  from user_objects
      3  where object_name = 'T_SYN';
    OBJECT_NAME                    STATUS
    T_SYN                          INVALID
    SQL> select * from t_syn;
    no rows selected
    SQL> select object_name, status
      2  from user_objects
      3  where object_name = 'T_SYN';
    OBJECT_NAME                    STATUS
    T_SYN                          VALID

  • RE: Drop and recreate user

    Hi,
    If we drop and recreate the oracle user in production database, what advantages we will get?
    Any one help me...
    DB Version:10.2.04
    OS: HP-UX
    Thanks,
    Srini ...

    935930 wrote:
    Hi,
    If we drop and recreate the oracle user in production database, what advantages we will get?
    Any one help me...
    DB Version:10.2.04
    OS: HP-UX
    Thanks,
    Srini ...The "advantage" (or "disadvantage") would depend on what you are trying to accomplish, correct?

  • Drop and recreate table in stored procedure

    Hi all
    When creating tables using Transact-SQL scripts, I have always preferred to drop the table if it exists and then create it explicitly using CREATE TABLE.  For two reasons:
    1) It does not matter if it is the first time the SP is run ie. if I create the table manually in the first instance and just use TRUNCATE TABLE it could fail if the table is deleted
    2) I have control over the data types of the table fields
    Just recently though I discovered the error that can occur when dropping and creating a table in the same batch (see link below)
    Microsoft Website
    This causes me a problem when dropping and creating tables in stored procedures, as I understand that a stored procedure is in itself a single batch?
    Can I avoid this error in a stored procedure whilst continuing to drop and create tables?  Or should I be taking a different approach?
    Coding best practice advice would be greatly appreciated.
    Thank you

    Thanks Ronen
    Please see my second post immediately before your reply.
    Given that I need to store the data output in a physical table for use in QlikView, would you suggest truncating the table each time the SP runs?  And then having a script that handles both dropping and creating the physical table, and also creating
    the SP?
    >> QlikView
    QlikView is an Israeli company, right?
    In any case I am not familiar with QlikView's application, therefore I can only give you general information, based on assumptions regarding the application, and facts regarding the SQL Server.
    >> for use in QlikView
    I assume that external application use specific database structure (table
    structure) and it is change only in rare situations (for example CMS interface might change the tables if and when a module s update/install). In this case there is no need to drop the table and recreate it and TRUNCATE is the solution.
    >> would you suggest truncating the table each time the SP runs
    I am sorry but i cant recommend on TRUNCATE a table each time you execute SP, without know the exact reason for this logic. It sound to me, at this point of time (with the information that we have), that this
    is very bad logic (application architecture). As I wrote above, basing your application on TRUNCATING the table each time mean that you have problems with multi users. Thins about 2 people that try to execute the same SP at almost the same time. Think about
    locking in the SQL Server and bad data (one truncate while the other already inserted the new data and get no rows, if there is no locking).
    But TRUNCATE is much better in this case probably then DROP and DELETE, since it is faster, and locking will be shorter (hopefully the application use the correct locking). There are other reasons why TRUNCATE is better, and other people already mentioned
    most of them, but time in this scenario might be critical.
    >> having a script that handles both dropping and creating the physical table, and also creating the SP?
    I do not undestand what is this second step. we said that you truncate the table, so why do you need to
    dropping and creating the physical table and who
    creating the SP?
    Are you meaning that the application create the tables and SP?
    There are lot of application that during installation create the database structure. is this what you mean?
      Ronen Ariely
     [Personal Site]    [Blog]    [Facebook]

  • What happens if column from idex is dropped and recreated

    I have question. I need to drop one column from a table. That column is part of unique index.
    If i drop a column and recreate it would it drop index also. Do i need to re-create the index also.
    Thanks

    Is it not possible for you run a quick test on a small table to find out?

  • Help! wifi constantly dropping and (looking for network)

    I attempted to updated my Macbook air via MacBookAirUpdate.pkg. I was prompted (this is not supported on your system). I am having a major problem with my wifi constantly dropping and searching (looking for network) I was told this update have the fix. I’m very frustrated! help! what do I do?

    Hello ronnieluv1960,
    The following article provides a host of tips that can help stabilize your WiFi.
    Wi-Fi: How to troubleshoot Wi-Fi connectivity
    http://support.apple.com/kb/HT4628
    Cheers,
    Allen

  • DROP and RECREATE TEMP TABLESPACE

    Hey,
    is it ok just to drop the TEMP tablespace and recreate it?
    Will data get lost? Will developers kill me if I do? ;o)
    Can i reuse the datafile?
    Is it possible to change name on the tablespace?
    Thanks
    Kjersti

    Hey there is absolutely no problem. Only ensure that only system is logged on and no other user is using the database. Best thing is to shut down the database and restart in restricted session and then create the temp tablespace. give tempfile instead of datafile.

  • How to drop and recreate dbconsole in RAC?

    Hi Guys,
    I might not be in the right Forum area, so apologize for that. Here is my dilemma, I restored a database (10.2.0.3 on RHEL4AS) from standalone to 2-Node RAC Cluster (10.2.0.3 on RHEL4AS) and now need to recreate dbconsole. I see quite few articles on create dbconsole on a single standalone but having hard time finding how to recreate dbconsole in RAC. Any help will be a great help to me.
    Thanks,
    --MM                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                               

    You can check this part of Oracle Doc, use EMCA to reconfigure.
    Using EMCA with Real Application Clusters
    http://download.oracle.com/docs/cd/B19306_01/em.102/b40002/structure.htm#sthref80

  • Can I dropped triggers and recreate them? Dropped is easy but I dont know how to recreate them. I need separate proc to drop and recreate triggers to avoid deadlock issues in package.

    drop  triggers---
    CREATE PROC [dbo].[SP_DropTriggers] 
    AS
    BEGIN
    DECLARE @Table_Triggers SYSNAME, @trName sysname
    DECLARE Cursor_Disabletriggers CURSOR FOR  
    SELECT  object_name(parent_id) , name
    FROM   sys.triggers  
    OPEN Cursor_Disabletriggers
    FETCH NEXT FROM   Cursor_Disabletriggers   
    INTO @Table_Triggers  ,@trname
    DECLARE @SQL nvarchar(max)
    WHILE @@FETCH_STATUS = 0   
    BEGIN  
    SET @SQL  = 'drop trigger ' + 'dbo.'+@trname + ' on dbo.'+@Table_Triggers
    select @sql
    EXECUTE (@SQL)
    FETCH NEXT FROM   Cursor_Disabletriggers INTO @Table_Triggers  ,@trname
    END  
    CLOSE Cursor_Disabletriggers
    DEALLOCATE Cursor_Disabletriggers
    END
    I would like to recreate them in separate proc, How can I achieve this?

    You need a permanent table to store the trigger code in:
    create table
    dbo.TriggerDefinitions
    (TableName nvarchar(128) not null,
    TriggerName nvarchar(128) not null,
    TriggerDefinition nvarchar(max) not null,
    constraint PK_TriggerDefinitions primary key (TableName, TriggerName))
    go
    In your procedure which drops the triggers you need to add code that stores the latest trigger definitions in the table above:
    create procedure dbo.DropTriggers
    as
    begin
    declare @TableName nvarchar(128),
    @TriggerName nvarchar(128),
    @TriggerDefinition nvarchar(max),
    @DynamicSQL nvarchar(max)
    declare TriggerCursor
    cursor fast_forward for
    select quotename(object_schema_name(po.object_id)) + '.' + quotename(po.name),
    quotename(object_schema_name(co.object_id)) + '.' + quotename(co.name),
    m.definition
    from sys.sql_modules as m
    join sys.objects as co
    join sys.objects as po
    on po.object_id = co.parent_object_id
    on co.object_id = m.object_id
    where co.type = 'tr'
    open TriggerCursor
    fetch next
    from TriggerCursor
    into @TableName,
    @TriggerName,
    @TriggerDefinition
    while @@fetch_status = 0
    begin
    if exists(select top 1 1 from TriggerDefinitions where TableName = @TableName and TriggerDefinition = @TriggerDefinition)
    update TriggerDefinitions
    set TriggerDefinition = @TriggerDefinition
    where TableName = @TableName
    and TriggerName = @TriggerName
    else
    insert TriggerDefinitions
    values (@TableName, @TriggerName, @TriggerDefinition)
    if @@rowcount = 1
    begin
    set @DynamicSQL = 'drop trigger ' + @TriggerName + ' on ' + @TableName
    print @DynamicSQL
    --execute sp_executesql
    -- @DynamicSQL
    end
    fetch next
    from TriggerCursor
    into @TableName,
    @TriggerName,
    @TriggerDefinition
    end
    close TriggerCursor
    deallocate TriggerCursor
    end
    go
    Finally the procedure which will re-create the triggers will simply query the table created and populated above and execute the code contained therein.
    create procedure dbo.CreateTriggers
    as
    begin
    declare @TableName nvarchar(128),
    @TriggerName nvarchar(128),
    @TriggerDefinition nvarchar(max),
    @DynamicSQL nvarchar(max)
    declare TriggerCursor
    cursor fast_forward for
    select *
    from dbo.TriggerDefinitions
    open TriggerCursor
    fetch next
    from TriggerCursor
    into @TableName,
    @TriggerName,
    @TriggerDefinition
    while @@fetch_status = 0
    begin
    set @DynamicSQL = @TriggerDefinition
    print @DynamicSQL
    --execute sp_executesql
    -- @DynamicSQL
    fetch next
    from TriggerCursor
    into @TableName,
    @TriggerName,
    @TriggerDefinition
    end
    close TriggerCursor
    deallocate TriggerCursor
    end
    go
    I've commented out the code which actually runs the dynamically created SQL.  You'll have to uncomment those lines for the code I've posted will work.

  • SSIS Package drops and recreates constraint

    My SSIS package is apparently dropping a constraint and later recreating it.  So I deleted the constraint.  When I reran the package the constraint was back.  Somewhere in the package in a location I can't see/don't know about is the information
    on the constraint.  The primary purpose of the package is a number of Data Flow Tasks.

    I just did a search and the drop is there.  And so is the code to add the constraint.  
    Both are in elements of <DTS:LoggingOptions>
    Is there anyway to get rid of it without an XML edit?
    Strange. That node describes merely some logging options for  the SSIS package (like which log provider is used).
    Is logging enabled in the package and what is configured over there?
    MCSE SQL Server 2012 - Please mark posts as answered where appropriate.

  • Wifi dropping and asking for password all the time

    Hi,
    My (27 Mid 2010) iMac keeps dropping its internet connection every time I switch it on or wake it from sleep. It also recently started asking for password each time i try to connect and I havent found a way to stop it asking.
    Thanks in advance

    Hi,
    My (27 Mid 2010) iMac keeps dropping its internet connection every time I switch it on or wake it from sleep. It also recently started asking for password each time i try to connect and I havent found a way to stop it asking.
    Thanks in advance

  • Emca configuration/ How i can drop existing emca and recreate it?

    emca configuration/ How i can drop existing emca and recreate it?

    Hmmmm?
    emca is the program used to create/drop/update the em configuration. Not sure why you want to drop emca.
    If you want to drop and recreate the em configuration, have you tried "emca ?" or "emca help=y"

  • Drop and create tablespace for users

    I am using Oracle 8i. I have created some users and, assigned the default & temporary tablespace to them.
    I would like to drop and re-create the temporary tablespace, should I assign the tablespace to users again?
    my script for creation of users:
    CREATE USER USER01 IDENTIFIED BY ABC
    DEFAULT TABLESPACE WEB_DATA
    TEMPORARY TABLESPACE TEMPORARY_DATA
    PROFILE DEFAULT;

    Hi,
    I would like to drop and re-create the temporary tablespace, should I assign the
    tablespace to users again?If temp tbs is not in usage, you can drop and recreate it without reassign. Users keep this one.
    Nicolas.

Maybe you are looking for