ORA-01804: failure to initialize timezone information

Hello,
I am having an issue to connect my C++ application to my Oracle DB. When my code calls oracle::occi::Environment::createEnvironment(), I get an error "ORA-01804: failure to initialize timezone information".
The application works on other people's Windows machine with their Oracle DB. But it doesn't work from my machine connecting to their Oracle instance. So I guess the issue does not come from my instance but rather from my Oracle dlls maybe?
I would appreciate any suggestion to solve that issue.
Thanks,
Tom
Oracle Database 10g Enterprise Edition Release 10.2.0.3.0

You getting me wrong, I am using SQLplus.
I mean when I run the query as you can see above it runs, but when the same statement is in my procedure and then when I run it I get timezone error. Here is the entire sample code:
set serveroutput on;
whenever sqlerror exit;
execute dbms_output.put_line('Creating/replacing procedure MyTest...');
create or replace procedure MyTest
as
inter interval day(6) to second (0) := to_dsinterval('2 2:05:13.34');
myDate date;
utc_time timestamp;
begin
     select current_timestamp at time zone 'UTC' into utc_time from dual;
dbms_output.put_line('utc_time ' || utc_time);
     dbms_output.put_line('ER - inter ' || inter);
     --myDate := utc_time + inter;
myDate := to_date(to_char((utc_time+inter),'YYYYMMDD'),'YYYYMMDD');
dbms_output.put_line('myDate ' || myDate );
end;
execute MyTest;
execute dbms_output.put_line('Execution completed...');
show errors;
Edited by: Neuron on May 26, 2009 6:03 PM
Edited by: Neuron on May 26, 2009 6:09 PM

Similar Messages

  • ORA-13282: failure on initialization of coordinate transformation

    Hi all,
    I try to create an index with type spatial_index and get this errormessage:
    ORA-29855: error occurred in the execution of ODCIINDEXCREATE routine
    ORA-13282: failure on initialization of coordinate transformation
    ORA-06512: at "MDSYS.SDO_INDEX_METHOD_10I", line 10
    ORA-06512: at line 1
    The WKTEXT ist this one (if it has something to do with it):
    PROJCS["Thueringen 4",GEOGCS["GCS_Deutsche_Hauptdreiecksnetz", DATUM["D_DHDN",SPHEROID["Bessel_1841",6377397.155,299.1528128]], PRIMEM["Greenwich",0],UNIT["Degree",0.0174532925199433]], PROJECTION["Transverse_Mercator"],PARAMETER["False_Easting",4500000], PARAMETER["False_Northing",0],PARAMETER["Central_Meridian",12], PARAMETER["Scale_Factor",1],PARAMETER["Latitude_Of_Origin",0],
    UNIT["Meter",1]]
    Does anybody have any idea, what the problem could be?
    Thanks in advance
    Alex

    Hi Udo,
    This worked for me in 10g R1:
    insert into cs_srs values (
    'DHDN Soldner Berlin (EPSG 3068)',
    81989002,
    81989002,
    NULL,
    'PROJCS ["DHDN / Soldner Berlin",
    GEOGCS ["",
    DATUM ["",
    SPHEROID ["Bessel 1841", 6377397.155000, 299.152813],
    582.000000, 105.000000, 414.000000, -1.040000, -0.350000, 3.080000, 8.300000],
    PRIMEM [ "Greenwich", 0.000000 ],
    UNIT ["Decimal Degree", 0.01745329251994330]],
    PROJECTION ["Transverse Mercator"],
    PARAMETER ["Central_Meridian", 13.6272037],
    PARAMETER ["Latitude_Of_Origin", 52.41864828],
    PARAMETER ["False_Easting", 40000.00],
    PARAMETER ["False_Northing", 10000.00],
    UNIT ["Meter",1.000000000000]
    null);
    select sdo_cs.validate_wkt(81989002) from dual;
    select sdo_cs.transform(sdo_geometry(2001,8192,sdo_point_type(13.6,52.4,null),null,null),81989002)
    from dual;
    select sdo_cs.transform(SDO_GEOMETRY(2001,81989002,SDO_POINT_TYPE(38098.5904,8073.54076,NULL),NULL,NULL),8192)
    from dual;
    In 10gR2, you'll have to follow the new requirements for coordinate systems.

  • ORA-01804 when calling function from java client

    Hi All,
    we changed a PL/SQL-function that is called from a java client from using sysdate to localtimestamp. The function works fine in TOAD, but when called from the java client ist throws an ora-01804: failure to initialize timezone information.
    Any suggestions?
    Alexander

    The change was only made to a local variable in a function that was called from the original function that got the parameters from the java client.
    I changed it from localtimestamp to systimestamp and it works fine.
    Do i have to make any settings about the time zone in the jdbc thin client ?

  • Spatial query index creation fails with ORA-13282: failure on initializatio

    Hi,
    I have an Oracle 10g 10.2.0.5.0 database newly installed. Spatial index creation fails:
    ORA-29855: error occurred in the execution of ODCIINDEXCREATE routine
    ORA-13282: failure on initialization of coordinate transformation
    ORA-06512: at "MDSYS.SDO_INDEX_METHOD_10I", line 10
    The script I am trying to run is:
    Insert into USER_SDO_GEOM_METADATA
    (TABLE_NAME, COLUMN_NAME, DIMINFO, SRID)
    Values
    ('SOME_TABLE', 'geo',
    "SDO_DIM_ARRAY"(
    "SDO_DIM_ELEMENT"('X',600000,900000,0.001),
    "SDO_DIM_ELEMENT"('Y',150000,400000,0.001)), 23700);
    CREATE INDEX IX_GEO_SOME_TABLE ON SOME_TABLE (GEO) INDEXTYPE IS MDSYS.SPATIAL_INDEX ;
    Earlier I had some issues with NLS settings in relation to Spatial, but in this particular case setting the NLS_LANG for AMERICAN_AMERICA does not help. I found this comment http://www.orafaq.com/forum/t/127312/2/ but would not like to hack around with MDSYS table content. Any help is highly appreciated.
    Regards, Tamas

    Tamas,
    1 . . .Are you indexing a table that already has geometries or an empty table?
    . . . .If the former, do all the geometries in that table have the same (not NULL) SRID (23700)?
    2 . .The link you posted suggests a parsing problem since in Hungarian (23700), the decimal seperator is a comma (not a period). Accordingly, I believe the edit to mdsys.sdo_cs_srs.WKTEXT would be:
    PROJCS["HD72 / EOV", GEOGCS [ "HD72", DATUM ["Hungarian Datum 1972 (EPSG ID 6237)", SPHEROID ["GRS 1967 (EPSG ID 7036)", 6378160, 298,247167427]], PRIMEM [ "Greenwich", 0,000000 ], UNIT ["Decimal Degree", 0,01745329251994328]], PROJECTION ["Egyseges Orszagos Vetuleti (EPSG OP 19931)"], UNIT ["Meter", 1]]
                                                                                                                                         ^                                    ^                                   ^                                                                                                  Regards,
    Noel

  • Failure on initialization of coordinate transformation

    I am trying to define a "custom" projection for our local coordinate system. The local coordinate system is a shifted and rotated state plane. To begin, I inserted a row in the mdsys.cs_srs that uses the WKTEXT field from the record for State Plance SC-south, 3902 (SRID=41133). I then "added", after the SPHEROID parameter, the shift, rotate, and scale values. Since our local coordinate system origin (0,0) is 1795630.77, 434471.63 svy_ft in SRID 41133, I converted the value to meters (547308.2586,132426.9528) and placed them in the position's of xShift, xShift, with negative signs. (ie SPHEROID["Clarke 1866",6378206.4,294.978698],-547308.2586,-132426.9528,0.0,0.0,0.0,0.0,1.0] )with the expectation that if I "transformed" a point (e.g. 1795630.77, 434471.63) into my custom projection, I should get back 0,0 as the answer. When I run my test case, I receive:
    ORA-13282 failure on initialization of coordinate transformation
    ORA-06512 at "MDSYS.SDO_CS", line 23
    ORA-06512 at "MDSYS.SDO_CS", line 43
    Any recommendations/thoughts on what is wrong??
    Thanks in Advance!!

    I think (but i am not sure) that you should not be changing the datum to shift the ellipsoid in X and Y.
    Without knowing exactly what you are trying to do, it is difficult to be sure, but I think you just want to shift the results so the point (1795630.77, 434471.63) in 41133 becomes 0,0 in the shifted coordinate system, but you don't want to change the standard parallels or the latitude of origin.
    To do this I think you want to take the original definition of 41133, and apply/reapply a false easting and a false northing.
    I did this with the following:
    delete from cs_srs where srid=1041133;
    insert into cs_srs values (
    'SRS Local Grid',1041133,1041133,
    'dan',
    'PROJCS["SRS Local Grid",
    GEOGCS [ "NAD 27 (Continental US)",
    DATUM ["NAD 27 (Continental US)",
    SPHEROID ["Clarke 1866", 6378206.4, 294.9786982]],
    PRIMEM [ "Greenwich", 0.000000 ],
    UNIT ["Decimal Degree", 0.01745329251994330]],
    PROJECTION ["Lambert Conformal Conic"],
    PARAMETER ["Standard_Parallel_1", 32.333333],
    PARAMETER ["Standard_Parallel_2", 33.666667],
    PARAMETER ["Central_Meridian", -81.000000],
    PARAMETER ["Latitude_Of_Origin", 31.833333],
    PARAMETER ["False_Easting", 204369.23],
    PARAMETER ["False_Northing", -434471.63],
    UNIT ["U.S. Foot", 0.3048006096012]]',
    null);
    select sdo_cs.transform(mdsys.sdo_geometry
    (2001,41133,sdo_point_type(1795630.77, 434471.63,null),null,null), 1041133)from dual;
    SDO_CS.TRANSFORM(MDSYS.SDO_GEO(SDO_GTYPE, SDO_SRID, SDO_POINT(X, Y, Z), SDO_ELEM
    SDO_GEOMETRY(2001, 1041133, SDO_POINT_TYPE(4.4806E08, .000006755, NULL), NULL,NULL)

  • Trouble with dateTime if data has Timezone information

    I have a problem with inserting a document in a XMLType column. I get the following error message:
    ORA-01830: date format picture ends before converting entire input stringI did some searching and the problem is the element which is a dateTime with Timezone information. If the entry oraxdb:SQLType="TIMESTAMP WITH TIME ZONE" is added everything is correct.
    The problem is that we dont want to edit the XSD because it was standardized. Is there another way to get around this error ( e.g. parameter or column definition, ... ) ?
    Greeting
    Alex
    Oracle Database 11g Enterprise Edition Release 11.2.0.1.0 - 64bit Production
    PL/SQL Release 11.2.0.1.0 - Production
    CORE 11.2.0.1.0 Production
    TNS for IBM/AIX RISC System/6000: Version 11.2.0.1.0 - Production
    NLSRTL Version 11.2.0.1.0 - Production

    XSL is probably a bit overkill, you could do stuff like the following as well
    SQL> declare
      V_FILENAME  VARCHAR2(700) := 'CMFXML.SWIFT.MT544.xsd';
      V_XMLSCHEMA XMLTYPE := xmltype(bfilename('XMLDIR',V_FILENAME),nls_charset_id('AL32UTF8'));
      2    3    4  begin
      5          -- dbms_xmlschema_annotate.addXDBNamespace(V_XMLSCHEMA);
      6          dbms_xmlschema_annotate.setDefaultTable(V_XMLSCHEMA,'CMFXML','CMFXML_MT544_TABLE');
      7          dbms_xmlschema_annotate.DISABLEDEFAULTTABLECREATION(V_XMLSCHEMA);
      8
      9          select insertChildXML
    10           (
    11                   V_XMLSCHEMA,
    12                   '//xsd:element[@type="TIndicator-22F-01"]',
    13                   '@xdb:SQLInline',
    14                   'false',
    15                   'xmlns:xdb="http://xmlns.oracle.com/xdb" xmlns:xsd="http://www.w3.org/2001/XMLSchema"'
    16                 )
    17            into V_XMLSCHEMA
    18            from dual;
    19
    20          select insertChildXML
    21           (
    22                   V_XMLSCHEMA,
    23                   '//xsd:element[@type="TAmount-19A-01"]',
    24                   '@xdb:SQLInline',
    25                   'false',
    26                   'xmlns:xdb="http://xmlns.oracle.com/xdb" xmlns:xsd="http://www.w3.org/2001/XMLSchema"'
    27                 )
    28            into V_XMLSCHEMA
    29            from dual;
    30
    31          select insertChildXML
    32           (
    33                   V_XMLSCHEMA,
    34                   '//xsd:element[@type="TDate-98A-01"]',
    35                   '@xdb:SQLInline',
    36                   'false',
    37                   'xmlns:xdb="http://xmlns.oracle.com/xdb" xmlns:xsd="http://www.w3.org/2001/XMLSchema"'
    38                 )
    39            into V_XMLSCHEMA
    40            from dual;
    41
    42          select insertChildXML
    43           (
    44                   V_XMLSCHEMA,
    45                   '//xsd:element[@type="TRate-92A-01"]',
    46                   '@xdb:SQLInline',
    47                   'false',
    48                   'xmlns:xdb="http://xmlns.oracle.com/xdb" xmlns:xsd="http://www.w3.org/2001/XMLSchema"'
    49                 )
    50            into V_XMLSCHEMA
    51            from dual;
    52
    53          select insertChildXML
    54           (
    55                   V_XMLSCHEMA,
    56                   '//xsd:element[@type="TFlag-17B-01"]',
    57                   '@xdb:SQLInline',
    58                   'false',
    59                   'xmlns:xdb="http://xmlns.oracle.com/xdb" xmlns:xsd="http://www.w3.org/2001/XMLSchema"'
    60                 )
    61            into V_XMLSCHEMA
    62            from dual;
    63
    64          select insertChildXML
    65           (
    66                   V_XMLSCHEMA,
    67                   '//xsd:element[@type="TQuantityOfFinancialInstrument-36B-01"]',
    68                   '@xdb:SQLInline',
    69                   'false',
    70                   'xmlns:xdb="http://xmlns.oracle.com/xdb" xmlns:xsd="http://www.w3.org/2001/XMLSchema"'
    71                 )
    72            into V_XMLSCHEMA
    73            from dual;
    74
    75          select insertChildXML
    76           (
    77                   V_XMLSCHEMA,
    78                   '//xsd:element[@type="TReference-20C-01"]',
    79                   '@xdb:SQLInline',
    80                   'false',
    81                   'xmlns:xdb="http://xmlns.oracle.com/xdb" xmlns:xsd="http://www.w3.org/2001/XMLSchema"'
    82                 )
    83            into V_XMLSCHEMA
    84            from dual;
    85
    86  select insertChildXML
    87           (
    88                   V_XMLSCHEMA,
    89                   '//xsd:element[@type="TParty-95PQR-01"]',
    90                   '@xdb:SQLInline',
    91                   'false',
    92                   'xmlns:xdb="http://xmlns.oracle.com/xdb" xmlns:xsd="http://www.w3.org/2001/XMLSchema"'
    93                 )
    94            into V_XMLSCHEMA
    95            from dual;
    96
    97
    98          dbms_xmlschema_annotate.setOutOfLine(V_XMLSCHEMA,'element','ReceiveFreeConfirmationType','TwoLegTransactionDetails','MT544_TWO_LEG_TRANS_TABLE');
    99          dbms_xmlschema_annotate.setOutOfLine(V_XMLSCHEMA,'element','ReceiveFreeConfirmationType','TradeDetails','MT544_TRADE_DETAILS_TABLE');
    100          dbms_xmlschema_annotate.setOutOfLine(V_XMLSCHEMA,'element','TTradeDetails','FinancialInstrumentAttributes','MT544_FIN_INST_ATTRS_TABLE');
    101
    102    dbms_xmlschema.registerSchema
    103    (
    104      schemaurl       => V_FILENAME,
    105      schemadoc       => V_XMLSCHEMA.getClobVal(),
    106      local           => TRUE,
    107      genTypes        => TRUE,
    108      genBean         => FALSE,
    109      genTables       => TRUE
    110    );
    111  end;
    112  /

  • Backup Error ORA-12640: Authentication adapter initialization failed

    Dear All,
    I have scheduled full backup from DB13 and it ends up in error. The error log is attached below.
    BR0204I Percentage done: 100.00%, estimated end time: 20:12
    BR0001I **************************************************
    BR0280I BRBACKUP time stamp: 2009-06-03 20.12.52
    BR0317I 'Alter tablespace SYSTEM end backup' successful
    BR0280I BRBACKUP time stamp: 2009-06-03 20.12.56
    BR0530I Cataloging backups of all database files...
    BR0278E Command output of 'E:\oracle\SID\102\BIN\rman nocatalog':
    Recovery Manager: Release 10.2.0.2.0 - Production on Wed Jun 3 20:12:57 200
    Copyright (c) 1982, 2005, Oracle.  All rights reserved.
    RMAN>
    RMAN> connect target *
    RMAN-00571: ===========================================================
    RMAN-00569: =============== ERROR MESSAGE STACK FOLLOWS ===============
    RMAN-00571: ===========================================================
    ORA-12640: Authentication adapter initialization failed
    RMAN> *end-of-file*
    RMAN>
    host command complete
    RMAN> 2> 3> 4> 5> 6> 7> 8> 9> 10> 11> 12> 13> 14> 15> 16> 17> 18> 19> 20> 2
    RMAN-00571: ===========================================================
    RMAN-00569: =============== ERROR MESSAGE STACK FOLLOWS ===============
    RMAN-00571: ===========================================================
    RMAN-03002: failure of catalog command at 06/03/2009 20:12:58
    RMAN-06171: not connected to target database
    RMAN>
    Recovery Manager complete.
    BR0280I BRBACKUP time stamp: 2009-06-03 20.12.58
    BR0279E Return code from 'E:\oracle\SID\102\BIN\rman nocatalog': 1
    BR0536E RMAN call for database instance DEV failed
    BR0280I BRBACKUP time stamp: 2009-06-03 20.12.58
    BR0532E Cataloging backups of all database files failed
    BR0056I End of database backup: beasixaz.fnd 2009-06-03 20.12.58
    BR0280I BRBACKUP time stamp: 2009-06-03 20.12.58
    BR0054I BRBACKUP terminated with errors
    BR0280I BRBACKUP time stamp: 2009-06-03 20.12.58
    I have tried upgrading Brtools as per suggestion from SAP but in vain. All the services run under administrator account but still no luck. The backup device type is disk
    Kindly help on the same
    Regards,
    Anand

    Hello Vedival.
    I am getting exact same error.
    We are using Tivoli with BRTOOLS and no RMAN at all..not sure why at the end of Backup its executing "'SHELL=/bin/sh /oracle/QAS/102_64/bin/rman nocatalog'" command.
    I will appreciate your help.
    Thanks
    Laxmichand.
    BR0530I Cataloging backups of all database files...                                                              
    BR0278E Command output of 'SHELL=/bin/sh /oracle/QAS/102_64/bin/rman nocatalog':                                 
    Recovery Manager: Release 10.2.0.2.0 - Production on Fri Oct 8 01:23:12 2010                                     
    Copyright (c) 1982, 2005, Oracle.  All rights reserved.                                                          
    RMAN>                                                                               
    RMAN> connect target *                                                                               
    RMAN-00571: ===========================================================                                          
    RMAN-00569: =============== ERROR MESSAGE STACK FOLLOWS ===============                                          
    RMAN-00571: ===========================================================                                          
    RMAN-04002: ocipi failed, ORA  1                                                                               
    RMAN> *end-of-file*                                                                               
    RMAN>                                                                               
    host command complete                                                                               
    RMAN> 2> 3> 4> 5> 6> 7> 8> 9> 10> 11> 12> 13> 14> 15> 16> 17> 18> 19> 20> 21> 22> 23> 24> 25> 26> 27> 28> 29> 30>
    RMAN-00571: ===========================================================                                          
    RMAN-00569: =============== ERROR MESSAGE STACK FOLLOWS ===============                                          
    RMAN-00571: ===========================================================                                          
    RMAN-03002: failure of catalog command at 10/08/2010 01:23:15                                                    
    RMAN-06171: not connected to target database                                                                     
    RMAN>                                                                               
    Recovery Manager complete.                                                                               
    BR0280I BRBACKUP time stamp: 2010-10-08 01.23.15                                                                 
    BR0279E Return code from 'SHELL=/bin/sh /oracle/QAS/102_64/bin/rman nocatalog': 1                                
    BR0536E RMAN call for database instance QAS failed                                                               
    BR0280I BRBACKUP time stamp: 2010-10-08 01.23.15                                                                 
    BR0532E Cataloging backups of all database files failed                                                          
    BR0280I BRBACKUP time stamp: 2010-10-08 01.23.40                                                                 
    BR0317I 'Alter database end backup' successful                                                                   
    BR0056I End of database backup: beehfpbh.fnf 2010-10-08 01.23.15                                                 
    BR0280I BRBACKUP time stamp: 2010-10-08 01.23.41

  • Oracle::occi::SQLException ORA-01804

    I'm trying to connect to my oracle server using OCCI, my code runs when I run it from any client. but when I try to run it under the server itself, I get this error:
    terminate called after throwing an instance of 'oracle::occi::SQLException'
    what(): Error while trying to retrieve text for error ORA-01804
    It seems to be somehow a timezone problem, but my server time zone is equal to the database time zone and both are +0330.
    Using JDBC connection I can connect to the oracle server from the server itself. I confirmed it using sqldeveloper.
    How can I solve the problem?

    This is from babelfish
    I am migrating a data base 8i to 10g I am in the change of pro*c to occi, when I compile leaves the following thing to me: : undefined reference to ` oracle::occi::SQLException::SQLException(oracle::occi::SQLException const&) ' and other things the problem is that not if is a problem of path with librerias since it lowers librerias occi and it places in several sides but nothing, ademas I see that the file occiObjects.h has a problem in 146 line sera that what is the problem if alguin has solved to this please me envie the answer thanks. Daniel
    Best regards
    Maxim

  • Debugger on Windows Vista - ORA-30683: Failure establishing connection to d

    We can't get the debugger to work on our Vista machines... On our XP machines we don't have this problem, so I suspect it's a "Vista" issue.
    The vista machine is a desktop running sql developer, connection to another machines (server's) database. XP machines connect and debug on that same database fine.
    We get this error when debugging:
    Executing PL/SQL: CALL DBMS_DEBUG_JDWP.CONNECT_TCP('0.0.0.0', '4000')
    ORA-30683: Failure establishing connection to debugger
    ORA-12541: TNS: no listener
    ORA-06512: at "SYS"."DBMS_DEBUG_JDWP", line 68
    we've tried:
    1) controlling the port on the SQL Developer preferences to be 4000, then making an exception on the firewall (on the vista machien) for that port
    2) making an exception for sql developerj.exe files
    3) Running it as an administrator
    no luck.
    I do notice that on teh first line, it puts: CONNECT_TCP('0.0.0.0', '4000')
    The zero's... on an xp machine, the IP: 127.0.0.0 would be there instead. Not sure if that's related to the problem.
    Please help, we can't debug on our Vista machines until this is resolved.

    Definitely. The database needs to be able to contact your PC, so '0.0.0.0' won't work.
    Check Preferences - Debugger - Prompt for Debugger Host, initiate another debug session, and when prompted, give your IP instead. Once you had a successful debug session, I'm pretty sure you can uncheck the preference again.
    Have fun,
    K.

  • ORA-00349: failure obtaining block size for '+Z'  in Oracle XE

    Hello,
    I am attempting to move the online redo log files to a new flash recovery area location created on network drive "Z" ( Oracle Database 10g Express Edition Release 10.2.0.1.0).
    When I run @?/sqlplus/admin/movelogs; in SQL*Plus as a local sysdba, I get the following errors:
    ERROR at line 1:
    ORA-00349: failure obtaining block size for '+Z'
    ORA-06512: at line 14
    Please let me know how to go about resolving this issue.
    Thank you.
    See below for detail:
    Connected.
    SQL> @?/sqlplus/admin/movelogs;
    SQL> Rem
    SQL> Rem $Header: movelogs.sql 19-jan-2006.00:23:11 banand Exp $
    SQL> Rem
    SQL> Rem movelogs.sql
    SQL> Rem
    SQL> Rem Copyright (c) 2006, Oracle. All rights reserved.
    SQL> Rem
    SQL> Rem NAME
    SQL> Rem movelogs.sql - move online logs to new Flash Recovery Area
    SQL> Rem
    SQL> Rem DESCRIPTION
    SQL> Rem This script can be used to move online logs from old online
    log
    SQL> Rem location to Flash Recovery Area. It assumes that the database
    SQL> Rem instance is started with new Flash Recovery Area location.
    SQL> Rem
    SQL> Rem NOTES
    SQL> Rem For use to rename online logs after moving Flash Recovery
    Area.
    SQL> Rem The script can be executed using following command
    SQL> Rem sqlplus '/ as sysdba' @movelogs.sql
    SQL> Rem
    SQL> Rem MODIFIED (MM/DD/YY)
    SQL> Rem banand 01/19/06 - Created
    SQL> Rem
    SQL>
    SQL> SET ECHO ON
    SQL> SET FEEDBACK 1
    SQL> SET NUMWIDTH 10
    SQL> SET LINESIZE 80
    SQL> SET TRIMSPOOL ON
    SQL> SET TAB OFF
    SQL> SET PAGESIZE 100
    SQL> declare
    2 cursor rlc is
    3 select group# grp, thread# thr, bytes/1024 bytes_k
    4 from v$log
    5 order by 1;
    6 stmt varchar2(2048);
    7 swtstmt varchar2(1024) := 'alter system switch logfile';
    8 ckpstmt varchar2(1024) := 'alter system checkpoint global';
    9 begin
    10 for rlcRec in rlc loop
    11 stmt := 'alter database add logfile thread ' ||
    12 rlcRec.thr || ' size ' ||
    13 rlcRec.bytes_k || 'K';
    14 execute immediate stmt;
    15 begin
    16 stmt := 'alter database drop logfile group ' || rlcRec.grp;
    17 execute immediate stmt;
    18 exception
    19 when others then
    20 execute immediate swtstmt;
    21 execute immediate ckpstmt;
    22 execute immediate stmt;
    23 end;
    24 execute immediate swtstmt;
    25 end loop;
    26 end;
    27 /
    declare
    ERROR at line 1:
    ORA-00349: failure obtaining block size for '+Z'
    ORA-06512: at line 14
    Can someone point me in the right direction as to what I may be doing wrong here - Thank you!

    888442 wrote:
    I am trying to drop and recreate ONLINE redo logs on my STANDB DATABASE (11.1.0.7)., but i am getting the below error.
    On primary, we have done the changes., ie we added new logfile with bigger size and 3 members. When trying to do the same on Standby we are getting this error.
    Our database is in Active DG Read only mode and the oracle version is 11.1.0.7.
    I have deffered the log apply and cancelled the managed recovery, and dg is in manual mode.
    SQL> alter database Add LOGFILE GROUP 4 ('+DT_DG1','+DT_DG2','+DT_DG3') SIZE 1024M;
    alter database Add LOGFILE GROUP 4 ('+DT_DG1','+DT_DG2','+DT_DG3') SIZE 1024M
    ERROR at line 1:
    ORA-00349: failure obtaining block size for '+DT_DG1'First why you are dropping & recreating online redo log files on standby.
    On standby only standby redo log files will be used. Not sure what you are trying to do.
    here is example how to create online redo log files, Check that diskgroup is mounted and have sufficient space to create.
    sys@ORCL> select member from v$logfile;
    MEMBER
    C:\ORACLE\ORADATA\ORCL\REDO03.LOG
    C:\ORACLE\ORADATA\ORCL\REDO02.LOG
    C:\ORACLE\ORADATA\ORCL\REDO01.LOG
    sys@ORCL> alter database add logfile group 4 (
      2     'C:\ORACLE\ORADATA\ORCL\redo_g01a.log',
      3     'C:\ORACLE\ORADATA\ORCL\redo_g01b.log',
      4     'C:\ORACLE\ORADATA\ORCL\redo_g01c.log') size 10m;
    Database altered.
    sys@ORCL> select member from v$logfile;
    MEMBER
    C:\ORACLE\ORADATA\ORCL\REDO03.LOG
    C:\ORACLE\ORADATA\ORCL\REDO02.LOG
    C:\ORACLE\ORADATA\ORCL\REDO01.LOG
    C:\ORACLE\ORADATA\ORCL\REDO_G01A.LOG
    C:\ORACLE\ORADATA\ORCL\REDO_G01B.LOG
    C:\ORACLE\ORADATA\ORCL\REDO_G01C.LOG
    6 rows selected.
    sys@ORCL>
    Your profile:-
    888442      
         Newbie
    Handle:      888442
    Status Level:      Newbie
    Registered:      Sep 29, 2011
    Total Posts:      12
    Total Questions:      8 (7 unresolved)
    Close the threads if answered, Keep the forum clean.

  • Oracle Streams ORA-23616: Failure in executing block 167 for script

    oracle : Oracle Database 10g Enterprise Edition Release 10.2.0.4.0 - Production
    os : linux i686 i686 i386 GNU/Linux
    application : testing streams for schema ROOT
    1. Both the databases INDCTRAK, INDDTRAK are in archive.
    2. DB link created
    CREATE DATABASE LINK dbl_INDDTRAK CONNECT TO strmadmin IDENTIFIED BY strmadmin USING 'INDDTRAK';
    3. tbs created
    CREATE TABLESPACE streams_tbs datafile '/u02/oradata/INDDTRAK/streams01.dbf' size 100m;
    4 user created
    CREATE USER strmadmin IDENTIFIED BY strmadmin DEFAULT TABLESPACE streams_tbs TEMPORARY TABLESPACE temp
    QUOTA UNLIMITED ON streams_tbs;
    5. All req. grants
    GRANT CONNECT, RESOURCE, DBA ,Select_CATALOG_ROLE,
    SELECT ANY DICTIONARY TO strmadmin;
    6. grants
    BEGIN
    DBMS_STREAMS_AUTH.GRANT_ADMIN_PRIVILEGE (Grantee => 'strmadmin',Grant_privileges => true);
    END;
    PL/SQL procedure successfully completed.
    7. Created directory
    CREATE OR REPLACE DIRECTORY ADMIN AS '/u02/oradata/INDDTRAK/streams';
    step 2-7 executed without errors
    8.run with perform_actions as false
    SQL> BEGIN
    2 DBMS_STREAMS_ADM.MAINTAIN_SCHEMAS(
    3 schema_names =>'ROOT',
    4 source_directory_object =>'ADMIN',
    5 destination_directory_object =>'ADMIN',
    6 source_database => 'INDCTRAK',
    7 destination_database => 'INDDTRAK',
    8 perform_actions => false,
    9 script_name => 'schema_replication.sql',
    10 script_directory_object => 'admin',
    11 dump_file_name => 'ROOT.DMP',
    12 capture_name => 'capture_ROOT',
    13 capture_queue_table => 'rep_capture_queue_table',
    14 capture_queue_name => 'rep_capture_queue',
    15 capture_queue_user => null,
    16 propagation_name => 'prop_ROOT',
    17 apply_name => 'apply_ROOT',
    18 apply_queue_table => 'rep_dest_queue_table',
    19 apply_queue_name => 'rep_dest_queue',
    20 apply_queue_user => null,
    21 log_file => 'exp.log',
    22 bi_directional => false,
    23 include_ddl => true,
    24 instantiation => dbms_streams_adm.instantiation_schema_network);
    25 END;
    26 /
    9. when running perform_actions true getting error
    SQL> BEGIN
    2 DBMS_STREAMS_ADM.MAINTAIN_SCHEMAS(
    3 schema_names =>'ROOT',
    4 source_directory_object =>'ADMIN',
    5 destination_directory_object =>'ADMIN',
    6 source_database => 'INDCTRAK',
    7 destination_database => 'INDDTRAK',
    8 perform_actions => TRUE,
    9 script_name => 'schema_replication.sql',
    10 script_directory_object => 'admin',
    11 dump_file_name => 'ROOT.DMP',
    12 capture_name => 'capture_ROOT',
    13 capture_queue_table => 'rep_capture_queue_table',
    14 capture_queue_name => 'rep_capture_queue',
    15 capture_queue_user => null,
    16 propagation_name => 'prop_ROOT',
    17 apply_name => 'apply_ROOT',
    18 apply_queue_table => 'rep_dest_queue_table',
    19 apply_queue_name => 'rep_dest_queue',
    20 apply_queue_user => null,
    21 log_file => 'exp.log',
    22 bi_directional => false,
    23 include_ddl => true,
    24 instantiation => dbms_streams_adm.instantiation_schema_network);
    25 END;
    26 /
    BEGIN
    ERROR at line 1:
    ORA-23616: Failure in executing block 167 for script
    4D2E52386C84C1CAE040A8C0FC015222
    ORA-06512: at "SYS.DBMS_RECOVERABLE_SCRIPT", line 560
    ORA-06512: at "SYS.DBMS_RECOVERABLE_SCRIPT", line 583
    ORA-06512: at "SYS.DBMS_STREAMS_MT", line 7673
    ORA-06512: at "SYS.DBMS_STREAMS_ADM", line 2606
    ORA-06512: at "SYS.DBMS_STREAMS_ADM", line 2667
    ORA-06512: at line 2
    10 errors
    SQL> select * from dba_recoverable_script_errors;
    SCRIPT_ID BLOCK_NUM ERROR_NUMBER
    ERROR_MESSAGE
    ERROR_CRE
    4D2E52386C84C1CAE040A8C0FC015222 167 -39001
    ORA-39001: invalid argument value
    ORA-06512: at "SYS.DBMS_RECO_SCRIPT_INVOK", line 130
    ORA-06512: at "SYS.DBMS_STREAMS_RPC", line 447
    14-MAY-08
    I could not find much explanation on net.
    pl. help in case it is already solved.

    Hi,
    we are implementing datavault on an existing 11g DB.The database is up and running fine , but DBCA shows this error when I am trying to configure datavault using DBCA.
    I have created a spfile from the same pfile, and Db does not show any error while coming up or shutting down. The issue comes only while using DBCA. I shall try minimizing the parameters and try again.
    Thanks
    Pankaj

  • ORA-00349: failure obtaining block size

    I am trying to drop and recreate ONLINE redo logs on my STANDB DATABASE (11.1.0.7)., but i am getting the below error.
    On primary, we have done the changes., ie we added new logfile with bigger size and 3 members. When trying to do the same on Standby we are getting this error.
    Our database is in Active DG Read only mode and the oracle version is 11.1.0.7.
    I have deffered the log apply and cancelled the managed recovery, and dg is in manual mode.
    SQL> alter database Add LOGFILE GROUP 1 ('+DT_DG1','+DT_DG2','+DT_DG3') SIZE 1024M;
    alter database Add LOGFILE GROUP 1 ('+DT_DG1','+DT_DG2','+DT_DG3') SIZE 1024M
    ERROR at line 1:
    ORA-00349: failure obtaining block size for '+DT_DG1'

    888442 wrote:
    I am trying to drop and recreate ONLINE redo logs on my STANDB DATABASE (11.1.0.7)., but i am getting the below error.
    On primary, we have done the changes., ie we added new logfile with bigger size and 3 members. When trying to do the same on Standby we are getting this error.
    Our database is in Active DG Read only mode and the oracle version is 11.1.0.7.
    I have deffered the log apply and cancelled the managed recovery, and dg is in manual mode.
    SQL> alter database Add LOGFILE GROUP 4 ('+DT_DG1','+DT_DG2','+DT_DG3') SIZE 1024M;
    alter database Add LOGFILE GROUP 4 ('+DT_DG1','+DT_DG2','+DT_DG3') SIZE 1024M
    ERROR at line 1:
    ORA-00349: failure obtaining block size for '+DT_DG1'First why you are dropping & recreating online redo log files on standby.
    On standby only standby redo log files will be used. Not sure what you are trying to do.
    here is example how to create online redo log files, Check that diskgroup is mounted and have sufficient space to create.
    sys@ORCL> select member from v$logfile;
    MEMBER
    C:\ORACLE\ORADATA\ORCL\REDO03.LOG
    C:\ORACLE\ORADATA\ORCL\REDO02.LOG
    C:\ORACLE\ORADATA\ORCL\REDO01.LOG
    sys@ORCL> alter database add logfile group 4 (
      2     'C:\ORACLE\ORADATA\ORCL\redo_g01a.log',
      3     'C:\ORACLE\ORADATA\ORCL\redo_g01b.log',
      4     'C:\ORACLE\ORADATA\ORCL\redo_g01c.log') size 10m;
    Database altered.
    sys@ORCL> select member from v$logfile;
    MEMBER
    C:\ORACLE\ORADATA\ORCL\REDO03.LOG
    C:\ORACLE\ORADATA\ORCL\REDO02.LOG
    C:\ORACLE\ORADATA\ORCL\REDO01.LOG
    C:\ORACLE\ORADATA\ORCL\REDO_G01A.LOG
    C:\ORACLE\ORADATA\ORCL\REDO_G01B.LOG
    C:\ORACLE\ORADATA\ORCL\REDO_G01C.LOG
    6 rows selected.
    sys@ORCL>
    Your profile:-
    888442      
         Newbie
    Handle:      888442
    Status Level:      Newbie
    Registered:      Sep 29, 2011
    Total Posts:      12
    Total Questions:      8 (7 unresolved)
    Close the threads if answered, Keep the forum clean.

  • ORA-01078: failure in processing system parameters LRM-00109: could not open parameter file '/u01/app/oracle/product/11.2.0/dbhome_1/dbs/initORA11G.ora'

    I have installed an Oracle 11gR2 on Oracle Linux Server 6.6 (Virtualbox). I have the users grid and oracle11g. Add groups and install grid infrastructure first as a grid user and install database as oracle user as in documentation successfully.
    I have following users and groups as
    [grid@orcl11g ~]$ id grid
       uid=501(grid) gid=502(oinstall) groups=502(oinstall),492(vboxsf),501(grid),503(dba),505(asmdba),506(asmadmin),507(asmoper)
    [grid@orcl11g ~]$ id oracle11g
       uid=500(oracle11g) gid=502(oinstall) groups=502(oinstall),500(oracle11g),492(vboxsf),503(dba),504(oper),505(asmdba)
    .bash_profile edited  for oracle11g user as
    "export TMP=/tmp
    export ORACLE_HOSTNAME=orcl11g
    export ORACLE_UNQNAME=ora11g
    export ORACLE_BASE=/u01/app/oracle
    export ORACLE_HOME=$ORACLE_BASE/product/11.2.0/dbhome_1
    export ORACLE_SID=ora11g
    export PATH=$PATH:$ORACLE_HOME/bin
    export LD_LIBRARY_PATH=$ORACLE_HOME/lib:/lib:/usr/lib;
    export CLASSPATH=$ORACLE_HOME/jlib:$ORACLE_HOME/rdbms/jlib;
    .bash_profile edited  for grid user as
    "export TMP=/tmp
    export ORACLE_HOSTNAME=orcl11g
    export ORACLE_UNQNAME=+ASM
    export ORACLE_BASE=/u01/app/grid
    export ORACLE_HOME=$ORACLE_BASE/product/11.2.0/grid
    export GRID_HOME=$ORACLE_BASE/product/11.2.0/grid
    export ORACLE_SID=+ASM
    export PATH=$PATH:$ORACLE_HOME/bin
    export LD_LIBRARY_PATH=$ORACLE_HOME/lib:/lib:/usr/lib;
    export CLASSPATH=$ORACLE_HOME/jlib:$ORACLE_HOME/rdbms/jlib;
    When I log on as grid user. I check the followings:
    [grid@orcl11g ~]$ crsctl check has
    CRS-4638: Oracle High Availability Services is online
    [grid@orcl11g ~]$ srvctl status database -d ora11g
    Database is running.
    [grid@orcl11g ~]$ sqlplus sys as sysdba
    SQL*Plus: Release 11.2.0.1.0 Production on Thu Dec 25 19:17:37 2014
    Copyright (c) 1982, 2009, Oracle.  All rights reserved.
    Enter password:
    Connected to:
    Oracle Database 11g Enterprise Edition Release 11.2.0.1.0 - 64bit Production
    With the Automatic Storage Management option
    SQL> select status from v$instance;
    STATUS
    STARTED
    Till here everything seems to be OK!!!!
    When I log as  oracle user. I check the followings:
    [oracle11g@orcl11g ~]$ sqlplus sys as sysdba
    SQL*Plus: Release 11.2.0.1.0 Production on Thu Dec 25 19:21:46 2014
    Copyright (c) 1982, 2009, Oracle.  All rights reserved.
    Enter password:
    Connected to an idle instance.
    SQL> select status from v$instance;
    select status from v$instance
    ERROR at line 1:
    ORA-01034: ORACLE not available
    Process ID: 0
    Session ID: 0 Serial number: 0
    SQL> startup
    ORA-01078: failure in processing system parameters
    LRM-00109: could not open parameter file '/u01/app/oracle/product/11.2.0/dbhome_1/dbs/initORA11G.ora'
    Also when I log on as a grid user again and use following commands to shutdown and start database again the STATUS of instance is again STARTED not OPEN.
    [grid@orcl11g ~]$ srvctl stop database -d ora11g -o normal
    [grid@orcl11g ~]$ srvctl start database -d ora11g
    And also when I edit /etc/oratab file. I change N to Y for +ASM. But when restart system it seems not changed value is N again.
        +ASM:/u01/app/grid/product/11.2.0/grid:N   # line added by Agent
         ora11g:/u01/app/oracle/product/11.2.0/dbhome_1:Y
    NOW QUESTIONS!!!!!
    1. Why I can't change the status of database to OPEN as grid user?
    2. The status is always STARTED when querying v$instance. İs it status of +ASM or database?
    3. When checking database as grid user it seems to be Database runnning...  If running why it is not in OPEN state? What is running means here?
    4. When I log on as oracle user and query v$instance, then error shown above occured. And also when startup  the database then another error occured as in above. WHY?
    5. When I edit /etc/oratab file manually why second row saved but the first one is changed after restart the system?
    6. Normally, which user have to start, stop or manage database? I think that oracle user is necessary for managing database and the grid user is only for managing ASM and Oracle Restart.
    PLEASE HELP ME TO SOLVE THIS CHAOTİC SİTUATİON!!!
    Thanks,
    DBA_84

    I have installed an Oracle 11gR2 on Oracle Linux Server 6.6 (Virtualbox)
    Pl identify exact version of 11gR2 to 4 decimal places. As noted in your other thread - Failed to start oracle-ohasd, error: Inappropriate ioctl for device ohasd failed to start at roothas.pl - you will need a minimum version of 11.2.0.3 for Linux 6.x - using a lower version may result in unexpected issues or problems.

  • Cannot connect to Database: ORA-01078: failure in processing system paramet

    Hi,
    i just installed Oracle Database XE 10g. But i cannot connect to the database. I'm trying to connect to the database with sqlplus.
    After searching for some log files i found the log-file oradim.log where i get the following error messages:
    Tue Jul 18 14:36:25 2006
    <INSTALLDIR>\app\oracle\product\10.2.0\server\bin\oradim.exe -startup -sid xe -usrpwd * -log oradim.log -nocheck 0
    Tue Jul 18 14:36:25 2006
    ORA-01078: failure in processing system parameters
    ORA-01565: error in identifying file '<INSTALLDIR>\app\oracle\product\10.2.0\server\dbs/spfileXE.ora'
    ORA-27041: unable to open file
    OSD-04002: Datei kann nicht geöffnet werden
    O/S-Error: (OS 2) Das System kann die angegebene Datei nicht finden.
    Any help is highly appreciated.
    Thank you in advance.
    Yuecel

    Installation finished successfully. No error messages at all.
    Was my first install and it did never work. I tried to reinstall a few time (with and without firewall etc.), but still not working.
    I did not change anything after install. Just opened sqlplus console and tried to connect to the database.

  • Oracle Windows Sevice does not start (ORA-12640: Authentication adapter initialization failed)

    I converted a physical windows 2003 machine to a virtual hyperv machine.
    The following error occurs in oradim.log when I try to start the Oracle Windows Service on the virtual server:
    ORA-12640: Authentication adapter initialization failed
    I recreated the service and the password file but with no luck.
    I also tried to change sqlnet.ora with the following: (Replaced NTS to NONE)
    SQLNET.AUTHENTICATION_SERVICES= (NONE)
    In this case the service was started but when I tried to connect as sysdba using sqlplus "/ as sysdba" the "ORA-01031: insufficient privileges" error occurs. If you connect using the password then it connects fine. But I would like to be able to connect without a password because I have some scripts that I do not want to hardcode the sysdba password.
    I also removed and readded the administrator password from ORA_DBA group but again with no luck.

    Have you seen this:
    Oracle Database Service on Windows 2000 in AutoStart Mode with Logon as SYSTEM
    (Bug 1397927) If you have installed an Oracle database service on Windows 2000, when logging in as SYSTEM user (Local System), with startup mode set to Automatic, it is possible that the Oracle database service starts but the database does not start automatically. The following error message is written to the ORADIM.LOG file in the ORACLE_BASE\ORACLE_HOME\DATABASE directory.
    ORA-12640: Authentication adapter initialization failed
    It has also been observed that the services like Oracle Enterprise Management Agent, Oracle Enterprise Manager Management Server and Oracle Internet Directory may also fail for the same reason because they cannot connect to the database.
    The workarounds for this problem are:
    Remove the line sqlnet.authentication_services=(NTS) from SQLNET.ORA or set sqlnet.authentication_services=(NONE) in SQLNET.ORA.
    Start the database manually after the Oracle database service has started using SQL*Plus connecting as user name INTERNAL. Note that the INTERNAL user name will not be available after release 8.1.7.
    Start the service as a specific user:
    Choose Start > Settings > Control Panel > Services. The Services dialog box appears.
    Select the service you want to start.
    Click the Startup button. The Service dialog box appears.
    Click This account and specify the user name and corresponding password.

Maybe you are looking for