This discussion is archived
1 2 Previous Next 18 Replies Latest reply: Nov 1, 2012 8:13 PM by 936666 RSS

Error in creating Cache Group

936666 Newbie
Currently Being Moderated
Hi,

When i tried to create cache group i am getting below error

CREATE READONLY CACHE GROUP customer_orders
FROM myuser.customer
(cust_num NUMBER(6) NOT NULL,
region VARCHAR2(10),
name VARCHAR2(50),
address VARCHAR2(100),
PRIMARY KEY(cust_num)),
myuser.orders
(ord_num NUMBER(10) NOT NULL,
cust_num NUMBER(6) NOT NULL,
when_placed DATE NOT NULL,
when_shipped DATE NOT NULL,
PRIMARY KEY(ord_num),
FOREIGN KEY(cust_num) REFERENCES myuser.customer(cust_num)) ;

5220: Permanent Oracle connection failure error in OCIServerAttach(): ORA-12154: TNS:could not resolve the connect identifier specified rc = -1
5131: Cannot connect to backend database: OracleNetServiceName = "orcl_db", uid = "XXXXXXX", pwd is hidden, TNS_ADMIN = "C:\TimesTen11.2.2", ORACLE_HOME= ""

But my Oracle database Name is MYdatabase

Oracle LSNRCTL

LSNRCTL> status
Connecting to (DESCRIPTION=(ADDRESS=(PROTOCOL=IPC)(KEY=EXTPROC1522)))
STATUS of the LISTENER
------------------------
Alias LISTENER
Version TNSLSNR for 32-bit Windows: Version 11.2.0.2.0 - Production
Start Date 07-AUG-2012 10:31:38
Uptime 4 days 3 hr. 1 min. 55 sec
Trace Level off
Security ON: Local OS Authentication
SNMP OFF
Listener Parameter File C:\TimesTen11.2.2\listener.ora
Listener Log File E:\app\XXXXXXX\diag\tnslsnr\localhost\listener\alert\log.xml
Listening Endpoints Summary...
(DESCRIPTION=(ADDRESS=(PROTOCOL=ipc)(PIPENAME=\\.\pipe\EXTPROC1522ipc)))
(DESCRIPTION=(ADDRESS=(PROTOCOL=tcp)(HOST=localhost)(PORT=1522)))
Services Summary...
Service "MYdatabaseXDB" has 1 instance(s).
Instance "MYdatabase", status READY, has 1 handler(s) for this service...
Service "MYdatabase" has 1 instance(s).
Instance "MYdatabase", status READY, has 1 handler(s) for this service...
Service "orcl" has 1 instance(s).
Instance "orcl", status UNKNOWN, has 1 handler(s) for this service...
The command completed successfully

how to change OracleNetServiceName = "orcl_db" to OracleNetServiceName = "MYdatabase"


Thanks!
  • 1. Re: Error in creating Cache Group
    936666 Newbie
    Currently Being Moderated
    addition to this i am getting this error

    5186: The OCI client library in use does not contain required routines to support caching LOBS from Oracle.
    5183: Function kollgsnp2 was not in the library. The function will not be called.
    5183: Function kollglid2 was not in the library. The function will not be called.
    5219: Temporary Oracle connection failure error in OCIServerAttach(): ORA-12541: TNS:no listener rc = -1
    5131: Cannot connect to backend database: OracleNetServiceName = "MYdatabase", uid = "XXXXXXXX", pwd is hidden, TNS_ADMIN
    = "C:\TimesTen11.2.2", ORACLE_HOME= ""
    The command failed.


    Thanks!
  • 2. Re: Error in creating Cache Group
    rajeshp Explorer
    Currently Being Moderated
    I am assuming the first error on "TNS:could not resolve the connect identifier specified" is resolved now .

    For this error

    5186: The OCI client library in use does not contain required routines to support caching LOBS from Oracle.
    5183: Function kollgsnp2 was not in the library. The function will not be called.

    Are you trying to use the instance client shipped with Timesten ? We only support instanceclient provided with Timesten software . It can be found here

    $TT_DAEMON_HOME/ttoracle_home/instantclient_11_2

    Regards
    Rajesh
  • 3. Re: Error in creating Cache Group
    936666 Newbie
    Currently Being Moderated
    rajeshp wrote:
    5186: The OCI client library in use does not contain required routines to support caching LOBS from Oracle.
    5183: Function kollgsnp2 was not in the library. The function will not be called.

    Are you trying to use the instance client shipped with Timesten ? We only support instanceclient provided with Timesten software . It can be found here

    $TT_DAEMON_HOME/ttoracle_home/instantclient_11_2
    Hi,
    I have downloaded Timesten from
    http://www.oracle.com/technetwork/products/timesten/downloads/index.html
         TimesTen 11.2.2.3.0 for Windows (32-bit) (188,795,087 bytes)

    Still i am getting the error.

    Warning 5183: Function kollglid2 was not in the library. The function will not be called.
    Warning 5183: Function kollgsnp2 was not in the library. The function will not be called.
    Warning 5186: The OCI client library in use does not contain required routines to support caching LOBS from Oracle.

    Thanks.
  • 4. Re: Error in creating Cache Group
    rajeshp Explorer
    Currently Being Moderated
    can you check where your ORACLE_HOME point to ?

    echo %ORACLE_HOME%
  • 5. Re: Error in creating Cache Group
    Gennady Sigalaev Journeyer
    Currently Being Moderated
    Hi 933663,

    I found some information here (http://www.xifenfei.com/2584.html). It looks like the following messages appear in the first function execution.
    Warning 5183: Function kollglid2 was not in the library. The function will not be called.
    Warning 5183: Function kollgsnp2 was not in the library. The function will not be called.
    Warning 5186: The OCI client library in use does not contain required routines to support caching LOBS from Oracle.
    After that it should works fine. Additionally there are not errors, these messages are warnings, so you can ignore them.

    regards,
    Gennady
  • 6. Re: Error in creating Cache Group
    936666 Newbie
    Currently Being Moderated
    I followed the steps in link

    Now i am getting this error

    COMMAND>
    CREATE READONLY CACHE GROUP readcache
    AUTOREFRESH INTERVAL 5 SECONDS
    FROM ORATT.readtab
    (keyval NUMBER NOT NULL PRIMARY KEY, str VARCHAR2(32));

    5140: Could not find ORATT.READTAB in Oracle. May not have privileges. At TT end i am getting error

    in oracle

    SQL> Select Count(*) from ORATT.READTAB;

    COUNT(*)
    ----------
    2

    Thanks!
  • 7. Re: Error in creating Cache Group
    Gennady Sigalaev Journeyer
    Currently Being Moderated
    You should create the cache groups by using cachadmin user, not use object owner user.

    In Oracle DB:
    SQL> @grantCacheAdminPrivileges "cacheadmin"
    
    Please enter the administrator user id
    The value chosen for administrator user id is cacheadmin
    
    ***************** Initialization for cache admin begins ******************
    0. Granting the CREATE SESSION privilege to CACHEADMIN
    1. Granting the TT_CACHE_ADMIN_ROLE to CACHEADMIN
    2. Granting the DBMS_LOCK package privilege to CACHEADMIN
    3. Granting the RESOURCE  privilege to CACHEADMIN
    4. Granting the CREATE PROCEDURE  privilege to CACHEADMIN
    5. Granting the CREATE ANY TRIGGER  privilege to CACHEADMIN
    6. Granting the DBMS_LOB package privilege to CACHEADMIN
    7. Granting the SELECT on SYS.ALL_OBJECTS privilege to CACHEADMIN
    8. Granting the SELECT on SYS.ALL_SYNONYMS privilege to CACHEADMIN
    9. Checking if the cache administrator user has permissions on the default
    tablespace
         Permission exists
    11. Granting the CREATE ANY TYPE privilege to CACHEADMIN
    ********* Initialization for cache admin user done successfully *********
    SQL>
    In TimesTen:
    Command> CREATE USER cacheadmin IDENTIFIED BY oracle;
    User created.
    Command> GRANT CREATE SESSION, CACHE_MANAGER, CREATE ANY TABLE, DROP ANY TABLE TO cacheadmin;
    Command>
    Command> CREATE USER oratt IDENTIFIED BY oracle;
    User created.
    Command> grant create session to oratt;
    Command>
    ...
    
    [oracle@tt1 ~]$ ttIsql "DSN=db_cache;UID=cacheadmin;PWD=oracle;OraclePWD=oracle"
    
    Copyright (c) 1996-2010, Oracle.  All rights reserved.
    Type ? or "help" for help, type "exit" to quit ttIsql.
    
    
    connect "DSN=db_cache;UID=cacheadmin;PWD=oracle;OraclePWD=oracle";
    Connection successful: DSN=db_cache;UID=cacheadmin;DataStore=/u01/app/oracle/datastore/db_cache;DatabaseCharacterSet=AL32UTF8;ConnectionCharacterSet=US7ASCII;DRIVER=/u01/app/oracle/product/11.2.1/TimesTen/tt1/lib/libtten.so;PermSize=100;TempSize=32;TypeMode=0;CacheGridEnable=0;OracleNetServiceName=ORCL;
    (Default setting AutoCommit=1)
    Command> call ttCacheUidPwdSet('cacheadmin','oracle');
    Command>
    ...
    Command> CREATE READONLY CACHE GROUP readcache
           >   AUTOREFRESH INTERVAL
           >   5 SECONDS
           > FROM oratt.readtab (
           >        a NUMBER NOT NULL PRIMARY KEY,
           >        b VARCHAR2(100) );
    Command> 
    Additionally dont forget to issue the grants for cacheadmin user in Oracle DB
    SQL> GRANT SELECT ON readtab TO cacheadmin;
    
    Grant succeeded.
    Regards,
    Gennady
  • 8. Re: Error in creating Cache Group
    936666 Newbie
    Currently Being Moderated
    Thanks for the information
    now i am getting the error as

    Command> Drop table oratt.readtab;
    8228: Cannot drop cache group table READTAB; please use DROP CACHE GROUP instead
    The command failed.
    Command> Drop cache group oratt.readtab ;
    8227: Cache group ORATT.READTAB not found
    The command failed.
  • 9. Re: Error in creating Cache Group
    Gennady Sigalaev Journeyer
    Currently Being Moderated
    Command> Drop table oratt.readtab;
    8228: Cannot drop cache group table READTAB; please use DROP CACHE GROUP instead
    The command failed.
    Executing the above command, you are trying to delete the table linked with cache groups. Dont do that.
    Command> Drop cache group oratt.readtab ;
    8227: Cache group ORATT.READTAB not found
    The command failed. 
    What user do you use for this command. Try this by using the cacheadmin user:
    Command> cachegroups;
    
    Cache Group CACHEADMIN.AWTCACHE:
    …
      Cache Group Type: Asynchronous Writethrough
      Autorefresh: No
      Aging: No aging defined
    
      Root Table: ORATT.AWTTAB
      Table Type: Propagate
    …
    Command>
    and after that
    Command> drop cache group awtcache; 
    regards,
    Gennady
  • 10. Re: Error in creating Cache Group
    936666 Newbie
    Currently Being Moderated
    Command> cachegroups;

    Cache Group CACHEADMIN.READCACHE:

    Cache Group Type: Asynchronous Writethrough
    Autorefresh: No
    Aging: No aging defined

    Root Table: ORATT.AWTTAB
    Table Type: Propagate


    Command> Drop Cache Group READCACHE;
    8227: Cache group READCACHE not found

    and i am getting this error also.
    call ttCacheUidPwdSet('cacheadmin','oracle');

    5247: The operation cannot be executed while the cache agent for this datastore is running.
    this error occurs when i tried to connect for the second time in a new connection

    Thanks
  • 11. Re: Error in creating Cache Group
    Gennady Sigalaev Journeyer
    Currently Being Moderated
    1. Please run this:
    select user from dual;
    2. Dont run this command ttCacheUidPwdSet('cacheadmin','oracle'); one more time. You 've already set the pwd and user for cache agent.

    3. Try this:
    Drop Cache Group CACHEADMIN.READCACHE
    regards,
    Gennady
  • 12. Re: Error in creating Cache Group
    936666 Newbie
    Currently Being Moderated
    hi,
    I am getting this error when i execute the below command.

    Drop Cache Group CACHEADMIN.READCACHE

    5213: Bad Oracle login error in OCISessionBegin(): ORA-01017: invalid username/password; logon denied rc = -1
    5131: Cannot connect to backend database: OracleNetServiceName = "XXXXXXXXXXXX", uid = "YYYYYYYY", pwd is hidden, TNS_ADMIN = "", ORACLE_HOME= ""
    5109: Cache Connect general error: BDB connection not open.


    Thanks!
  • 13. Re: Error in creating Cache Group
    936666 Newbie
    Currently Being Moderated
    Hi,
    I am getting the same Error for Alter Command also ,

    Command> ALTER CACHE GROUP CACHEADMIN.READCACHE SET AUTOREFRESH INTERVAL 3 SECONDS;
    5213: Bad Oracle login error in OCISessionBegin(): ORA-01017: invalid username/password; logon denied rc = -1
    5131: Cannot connect to backend database: OracleNetServiceName = "XXXXXXXXXXXX", uid = "YYYYYYYY", pwd is hidden, TNS_ADMIN = "", ORACLE_HOME= ""
    5109: Cache Connect general error: BDB connections not open.
    The command failed.


    Thanks !
  • 14. Re: Error in creating Cache Group
    Gennady Sigalaev Journeyer
    Currently Being Moderated
    Hi 933663,

    I think in your case the right decision is recreate the TimesTen database
    1 - Stop all agents
    call ttCachestop;
    call ttRepstop;
    2 - Delete TimesTen DB using ttDestroy utility - ttDestroy your_DSN
    3 - Dont forget drop all TimesTen objects into Oracle DB
    4 - Create a TimesTen DB and set up Cache Connect by using documentation (http://download.oracle.com/otn_hosted_doc/timesten/1122/quickstart/html/admin/imdb_cache.html) or my article (http://ggsig.blogspot.co.uk/2011/04/tech-in-memory-database-cache-11g.html, for Translation from Russian to English using Google Translate).

    Regards,
    Gennady
1 2 Previous Next

Legend

  • Correct Answers - 10 points
  • Helpful Answers - 5 points