Results 1 to 12 of 12
  1. #1
    Join Date
    Feb 2002
    Location
    Hamilton
    Posts
    150

    Unanswered: The database name or the database alias could not be found

    We have Websphere running using a db2 database called was and we are trying to add another database under a separate instance to run in conjunction with websphere. It is on AIX 5.1, DB2 v7.2 Fixpack 6 but we keep getting the error that it cannot find the database in the local database directory. I catalogued the database at the node and and when I do a list database directory for the user I get the following output:

    $ db2 list database directory

    System Database Directory

    Number of entries in the directory = 3

    Database 1 entry:

    Database alias = WAS
    Database name = WAS
    Local database directory = /home/wasinst
    Database release level = 9.00
    Comment =
    Directory entry type = Indirect
    Catalog node number = 0

    Database 2 entry:

    Database alias = METRICS1
    Database name = METRICS
    Node name = ARCDEV03
    Database release level = 9.00
    Comment =
    Directory entry type = Remote
    Catalog node number = -1

    Database 3 entry:

    Database alias = WAS1
    Database name = WAS
    Node name = ARCDEV03
    Database release level = 9.00
    Comment =
    Directory entry type = Remote
    Catalog node number = -1

    The instance owner of the database was is one id and the instance owner of the metrics database is another but I have put both id's in the same groups to allow for use in both databases.

    This is the explanation of the error code from the message reference book, so I don't know what else I have to do to get this database recognized


    SQL1013N The database alias name or
    database name <name> could
    not be found.
    Explanation: The database name or alias
    specified in the command is not an existing
    database or the database could not be found in
    the (client or server) database directories.
    User Response: Ensure that the specified
    database name exists in the system database
    directory. If the database name does not exist in
    the system database directory, then the database
    either does not exist or the database name has
    not been cataloged.
    If the database name appears in the system
    database directory and the entry type is
    INDIRECT, ensure that the database exists in the
    specified local database directory. If the entry
    type is REMOTE, then ensure that the database
    exists and is cataloged on the database
    directories of the server node.
    For CREATE DATABASE with the AT NODE
    clause, ensure that the database name is in the
    system database directory with an entry type of
    INDIRECT and with a catalog node number that
    does not equal -1.
    Federated system users: in addition to the above,
    verify that the database names specified in
    SYSCAT.SERVERS are all valid. Correct any
    SYSCAT.SERVERS entry for which the database
    specified in that entry does not exist.


    Thanks in advance

  2. #2
    Join Date
    Sep 2002
    Posts
    456

    Re: The database name or the database alias could not be found

    Check the configuratin file on your AIX machine, you might be accessing the database through a different user.


    Paul Pabla

    Originally posted by mark_maz
    We have Websphere running using a db2 database called was and we are trying to add another database under a separate instance to run in conjunction with websphere. It is on AIX 5.1, DB2 v7.2 Fixpack 6 but we keep getting the error that it cannot find the database in the local database directory. I catalogued the database at the node and and when I do a list database directory for the user I get the following output:

    $ db2 list database directory

    System Database Directory

    Number of entries in the directory = 3

    Database 1 entry:

    Database alias = WAS
    Database name = WAS
    Local database directory = /home/wasinst
    Database release level = 9.00
    Comment =
    Directory entry type = Indirect
    Catalog node number = 0

    Database 2 entry:

    Database alias = METRICS1
    Database name = METRICS
    Node name = ARCDEV03
    Database release level = 9.00
    Comment =
    Directory entry type = Remote
    Catalog node number = -1

    Database 3 entry:

    Database alias = WAS1
    Database name = WAS
    Node name = ARCDEV03
    Database release level = 9.00
    Comment =
    Directory entry type = Remote
    Catalog node number = -1

    The instance owner of the database was is one id and the instance owner of the metrics database is another but I have put both id's in the same groups to allow for use in both databases.

    This is the explanation of the error code from the message reference book, so I don't know what else I have to do to get this database recognized


    SQL1013N The database alias name or
    database name <name> could
    not be found.
    Explanation: The database name or alias
    specified in the command is not an existing
    database or the database could not be found in
    the (client or server) database directories.
    User Response: Ensure that the specified
    database name exists in the system database
    directory. If the database name does not exist in
    the system database directory, then the database
    either does not exist or the database name has
    not been cataloged.
    If the database name appears in the system
    database directory and the entry type is
    INDIRECT, ensure that the database exists in the
    specified local database directory. If the entry
    type is REMOTE, then ensure that the database
    exists and is cataloged on the database
    directories of the server node.
    For CREATE DATABASE with the AT NODE
    clause, ensure that the database name is in the
    system database directory with an entry type of
    INDIRECT and with a catalog node number that
    does not equal -1.
    Federated system users: in addition to the above,
    verify that the database names specified in
    SYSCAT.SERVERS are all valid. Correct any
    SYSCAT.SERVERS entry for which the database
    specified in that entry does not exist.


    Thanks in advance

  3. #3
    Join Date
    Feb 2002
    Location
    Hamilton
    Posts
    150
    What configuration file are you referring to?

    And like I said we have websphere running id A and it uses id B for it's DB2 database. We have id C that now has a DB2 database with which we would like to access it through WebSphere as well.

    Thanks

    Mark

  4. #4
    Join Date
    Sep 2002
    Posts
    456
    Well, this is the file which contains all your configuration parameters, java info, classpath etc. and there might be a user name there which will connect to the database. Make sure that user can access the database in question. It's kind of complicated, but hope you know what I am talking about.

    Paul

    Originally posted by mark_maz
    What configuration file are you referring to?

    And like I said we have websphere running id A and it uses id B for it's DB2 database. We have id C that now has a DB2 database with which we would like to access it through WebSphere as well.

    Thanks

    Mark

  5. #5
    Join Date
    Aug 2001
    Location
    UK
    Posts
    4,650
    Mark, Please can you make it a bit more clear ? ie, post the names of the instances , their corresponding databases, which db you are trying to access, which user you are using etc.

    Cheers

    Sathyaram

    Originally posted by dollar489
    Well, this is the file which contains all your configuration parameters, java info, classpath etc. and there might be a user name there which will connect to the database. Make sure that user can access the database in question. It's kind of complicated, but hope you know what I am talking about.

    Paul

  6. #6
    Join Date
    Feb 2002
    Location
    Hamilton
    Posts
    150
    Sorry for the ambiguity.

    Websphere runs under user "symwas"

    It uses a DB2 database called "WAS" which runs under the user "wasinst"

    We have another user "symcsmf" and it has a corresponding database called "METRICS"

    As user "wasinst" I run the following commands

    $ db2 list database directory

    System Database Directory

    Number of entries in the directory = 3

    Database 1 entry:

    Database alias = WAS
    Database name = WAS
    Local database directory = /home/wasinst
    Database release level = 9.00
    Comment =
    Directory entry type = Indirect
    Catalog node number = 0

    Database 2 entry:

    Database alias = METRICS
    Database name = METRICS
    Node name = ARCDEV03
    Database release level = 9.00
    Comment =
    Directory entry type = Remote
    Catalog node number = -1

    Database 3 entry:

    Database alias = WAS1
    Database name = WAS
    Node name = ARCDEV03
    Database release level = 9.00
    Comment =
    Directory entry type = Remote
    Catalog node number = -1


    this is the new message I get

    $ db2 connect to metrics
    SQL1334N The database server cannot be used to route a remote request to a
    second database server in this configuration.

    As user "symcsmf" I get the following:

    $ db2 list database directory

    System Database Directory

    Number of entries in the directory = 2

    Database 1 entry:

    Database alias = METRICS
    Database name = METRICS
    Local database directory = /home/symcsmf
    Database release level = 9.00
    Comment =
    Directory entry type = Indirect
    Catalog node number = 0

    Database 2 entry:

    Database alias = METRICS1
    Database name = METRICS
    Node name = ARCDEV03
    Database release level = 9.00
    Comment =
    Directory entry type = Remote
    Catalog node number = -1


    $ db2 connect to metrics

    Database Connection Information

    Database server = DB2/6000 7.2.4
    SQL authorization ID = SYMCSMF
    Local database alias = METRICS


    Were getting a different error now than before but it may be some kind of JDBC error, I don't know, I am not a WebSphere expert but the version were running needs a db2 database

    Hope this is enough information, if not I can provide more

    Mark

  7. #7
    Join Date
    Aug 2001
    Location
    UK
    Posts
    4,650
    $ db2 connect to metrics
    SQL1334N The database server cannot be used to route a remote request to a
    second database server in this configuration.


    This I believe is because the node ARCDEV03 refers in turn to a Remote node on another machine/instance ..

    For eg:

    Node arcdev03

    remote instance rem1 and ipadd/hostname host1

    And on host1,

    rem1 is

    remote instance inst2 and ipadd/hostname host2


    So if you want a database in inst2, you will have to catalog a node referring to inst2 as the remote instance on host2.

    Hope it is clear ...

    Cheers

    Sathyaram

  8. #8
    Join Date
    Feb 2002
    Location
    Hamilton
    Posts
    150
    Thanks for your help but what if both instances and both databases reside on the same node, in this case arcdev03?


    thanks

    mark

  9. #9
    Join Date
    Aug 2001
    Location
    UK
    Posts
    4,650
    Maybe , you can post the node directory also to get a better picture ...


    I have mostly seen SQL1334N in the scenario I have explained ...

    Cheers

    Sathyaram


    Originally posted by mark_maz
    Thanks for your help but what if both instances and both databases reside on the same node, in this case arcdev03?


    thanks

    mark

  10. #10
    Join Date
    Feb 2002
    Location
    Hamilton
    Posts
    150
    I hope this is what you asked for:


    this command was issued by wasinst user

    $ db2 list node directory

    Node Directory

    Number of entries in the directory = 1

    Node 1 entry:

    Node name = ARCDEV03
    Comment =
    Protocol = TCPIP
    Hostname = arcdev03
    Service name = db2cdb2inst1



    this command was issued by symcsmf user

    $ db2 list node directory

    Node Directory

    Number of entries in the directory = 1

    Node 1 entry:

    Node name = ARCDEV03
    Comment =
    Protocol = TCPIP
    Hostname = arcdev03
    Service name = db2cdb2inst11

  11. #11
    Join Date
    Aug 2001
    Location
    UK
    Posts
    4,650
    Mark,

    I'm not very sure where things went wrong ...

    sorry about this ...

    Cheers

    Sathyaram

    Originally posted by mark_maz
    I hope this is what you asked for:


    this command was issued by wasinst user

    $ db2 list node directory

    Node Directory

    Number of entries in the directory = 1

    Node 1 entry:

    Node name = ARCDEV03
    Comment =
    Protocol = TCPIP
    Hostname = arcdev03
    Service name = db2cdb2inst1



    this command was issued by symcsmf user

    $ db2 list node directory

    Node Directory

    Number of entries in the directory = 1

    Node 1 entry:

    Node name = ARCDEV03
    Comment =
    Protocol = TCPIP
    Hostname = arcdev03
    Service name = db2cdb2inst11

  12. #12
    Join Date
    Feb 2002
    Location
    Hamilton
    Posts
    150
    Sathyaram

    I figured out the problem, since Websphere is using the was database on node ARCDEV03 it could not use the same node for the metrics database that runs under a different instance owner.

    I uncataloged the database on the node ARCDEV03 and cataloged a second node called TEST03 and configured it to listen to the Service name = db2cdb2inst11, that way it would be looking on a different port for the metrics database.

    All is good.

    thanks for all your help

    Mark

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •