pitfloner
30th July 2004, 12:42
Hello,

I set up a Oracle 8.1.7 database in a remote box but I can’t access it by
BaaN.

I run the command tnsping and the instance answers it. Besides, I try to
connect by sqlplus to the remote database by the baan box and it works.

After these tests, I try to connect to BaaN instance by BECS Client, but it
doesn’t work. BaaN shows me the 510 error.

The message logs in the log.oracle8 are:

2004-07-24[03:04:15]:E:root: ******* S T A R T of Error message *******
2004-07-24[03:04:15]:E:root: Log message called from
/view/port.6.1c.07.01/vobs/
tt/servers/ORACLE_2/ora_native.c: #1993 keyword: Oracle Error
2004-07-24[03:04:15]:E:root: Pid 1598 Uid 0 Euid 0 Gid 0 Egid 0
2004-07-24[03:04:15]:E:root: user_type S language 5 user_name root tty
locale ISO88591/NULL
2004-07-24[03:04:15]:E:root: Errno 239 (Connection refused) bdb_errno 0
2004-07-24[03:04:15]:E:root:
2004-07-24[03:04:15]:E:root: dbs_errno = 0Error 510 occurred:
2004-07-24[03:04:15]:E:root: Error ORA-12154 occurred during logon.
2004-07-24[03:04:15]:E:root: ORA-12154: TNS: could not resolve service name
2004-07-24[03:04:15]:E:root:
2004-07-24[03:04:15]:E:root: Error BDB-510 returned.
2004-07-24[03:04:15]:E:root: Check the Oracle settings:
2004-07-24[03:04:15]:E:root: NLS_LANG = 'Spanish_spain.WE8ISO8859P1'
2004-07-24[03:04:15]:E:root: ORACLE_HOME (client) =
'/baanIVc4.2/bse/lib/ora/oracle_home' (resource oracle_client_home)
2004-07-24[03:04:15]:E:root: ORACLE_HOME (server) = '' (resource
oracle_server_home)
2004-07-24[03:04:15]:E:root: Oracle Service Name = 'baan3' (resource
oracle_service_name --> TWO_TASK)
2004-07-24[03:04:15]:E:root: TWO_TASK = 'baan3'
2004-07-24[03:04:15]:E:root: ORACLE_SID = '' (ignored)
2004-07-24[03:04:15]:E:root: Logon failed; errno 510
2004-07-24[03:04:15]:E:root: Flushed at
/view/port.6.1c.07.01/vobs/tt/servers/ORACLE_2/ora_driver.c : #215.
2004-07-24[03:04:15]:E:root: ******* E N D of Error message *******

# cat db_resource
dbs_init:021
oracle_client_home:/baanIVc4.2/bse/lib/ora/oracle_home
nls_lang:Spanish_spain.WE8ISO8859P1
nls_sort:binary
ora_default_tablespace:datspace
ora_temporary_tablespace:tempspace
ora_column_format:8
two_task:baan3
tns_admin:/oracle/app/oracle/product/8.0.6/network/admin

# tail -2 tabledef6.1
trhec000:*:oracle8(TWO_TASK=baan3, TNS_ADMIN=/oracle/app/oracle/product/8.0.6/network/admin):Y
*:*:oracle8(TWO_TASK=baan3, TNS_ADMIN=/oracle/app/oracle/product/8.0.6/network/admin):N

Does anyone know the reason?

dave_23
30th July 2004, 14:45
hmm everything looks right there...

doublecheck to make sure that the tnsnames.ora in /oracle/app/oracle/product/8.0.6/network/admin
does have a "baan3" entry.

Also try using oracle_service_name:baan3 instead of TWO_TASK.
(I know the driver is translating it, but still give it a shot..)

Also, take:
(TWO_TASK=baan3, TNS_ADMIN=/oracle/app/oracle/product/8.0.6/network/admin) out of your
tabledef for this test..

Dave

dave_23
30th July 2004, 14:49
Oh, Is this the only DB that this baan instance is talking to?

Also - have you checked ora8_srv6.1 -v vs. $BSE/lib/ora/oracle_home/Version
to make sure they match?

Dave

pitfloner
7th September 2004, 15:27
After I change the file /baanIVc4.2/bse/lib/defaults/db_resource with the new values, it doesn't still work. I attached at the end the new values of db_resource as well the new logs for your consideration.

At this moment, I don't know what's the reason that it's doesn't work, since tnsping to the instance works perfectly


# cat db_resource
dbs_init:021
oracle_service_name:baan3
oracle_client_home:/baanIVc4.2/bse/lib/ora/oracle_home
oracle_server_home:/oracle/app/oracle/product/8.1.7
ora_default_tablespace:datspace
ora_temporary_tablespace:tempspace
ora_column_format:8
tns_admin:/oracle/app/oracle/product/8.0.6/network/admin

#cat log.oracle8
2004-09-07[03:10:20]:E:bsp: ******* S T A R T of Error message *******
2004-09-07[03:10:20]:E:bsp: Log message called from /view/port.6.1c.07.01/vobs/tt/servers/ORACLE_2/ora_native.c: #1993 keyword: Oracle Error
2004-09-07[03:10:20]:E:bsp: Pid 9103 Uid 125 Euid 125 Gid 125 Egid 125
2004-09-07[03:10:20]:E:bsp: user_type S language 5 user_name bsp tty ote locale ISO88591/NULL
2004-09-07[03:10:20]:E:bsp: Errno 239 (Connection refused) bdb_errno 0
2004-09-07[03:10:20]:E:bsp:
2004-09-07[03:10:20]:E:bsp: dbs_errno = 0Error 510 occurred:
2004-09-07[03:10:20]:E:bsp: Error ORA-12154 occurred during logon.
2004-09-07[03:10:20]:E:bsp: ORA-12154: TNS:could not resolve service name
2004-09-07[03:10:20]:E:bsp:
2004-09-07[03:10:20]:E:bsp: Error BDB-510 returned.
2004-09-07[03:10:20]:E:bsp: Check the Oracle settings:
2004-09-07[03:10:20]:E:bsp: NLS_LANG = '' (default US7ASCII)
2004-09-07[03:10:20]:E:bsp: ORACLE_HOME (client) = '/baanIVc4.2/bse/lib/ora/oracle_home' (resource oracle_client_home)
2004-09-07[03:10:20]:E:bsp: ORACLE_HOME (server) = '' (resource oracle_server_home)
2004-09-07[03:10:20]:E:bsp: Oracle Service Name = 'baan3' (resource oracle_service_name --> TWO_TASK)
2004-09-07[03:10:20]:E:bsp: TWO_TASK = 'baan3'
2004-09-07[03:10:20]:E:bsp: ORACLE_SID = '' (ignored)
2004-09-07[03:10:20]:E:bsp: Logon failed; errno 510
2004-09-07[03:10:20]:E:bsp: Flushed at /view/port.6.1c.07.01/vobs/tt/servers/ORACLE_2/ora_driver.c : #215.
2004-09-07[03:10:20]:E:bsp: ******* E N D of Error message *******

2004-09-07[03:10:20]:E:bsp: ******* S T A R T of Error message *******
2004-09-07[03:10:20]:E:bsp: Log message called from /view/port.6.1c.07.01/vobs/tt/servers/ORACLE_2/ora_native.c: #1993 keyword: Oracle Error
2004-09-07[03:10:20]:E:bsp: Pid 9104 Uid 125 Euid 125 Gid 125 Egid 125
2004-09-07[03:10:20]:E:bsp: user_type S language 5 user_name bsp tty ote locale ISO88591/NULL
2004-09-07[03:10:20]:E:bsp: Errno 239 (Connection refused) bdb_errno 0
2004-09-07[03:10:20]:E:bsp:
2004-09-07[03:10:20]:E:bsp: dbs_errno = 0Error 510 occurred:
2004-09-07[03:10:20]:E:bsp: Error ORA-12154 occurred during logon.
2004-09-07[03:10:20]:E:bsp: ORA-12154: TNS:could not resolve service name
2004-09-07[03:10:20]:E:bsp:
2004-09-07[03:10:20]:E:bsp: Error BDB-510 returned.
2004-09-07[03:10:20]:E:bsp: Check the Oracle settings:
2004-09-07[03:10:20]:E:bsp: NLS_LANG = '' (default US7ASCII)
2004-09-07[03:10:20]:E:bsp: ORACLE_HOME (client) = '/baanIVc4.2/bse/lib/ora/oracle_home' (resource oracle_client_home)
2004-09-07[03:10:20]:E:bsp: ORACLE_HOME (server) = '' (resource oracle_server_home)
2004-09-07[03:10:20]:E:bsp: Oracle Service Name = 'baan3' (resource oracle_service_name --> TWO_TASK)
2004-09-07[03:10:20]:E:bsp: TWO_TASK = 'baan3'
2004-09-07[03:10:20]:E:bsp: ORACLE_SID = '' (ignored)
2004-09-07[03:10:20]:E:bsp: Logon failed; errno 510
2004-09-07[03:10:20]:E:bsp: Flushed at /view/port.6.1c.07.01/vobs/tt/servers/ORACLE_2/ora_driver.c : #215.
2004-09-07[03:10:20]:E:bsp: ******* E N D of Error message *******

pitfloner
7th September 2004, 15:34
I have only one db instance for this baan instance.

The oracle version is 8.1.7.
The version saved in /baanIVc4.2/bse/lib/ora/oracle_home/Version is 8.0.6.3.0.

And the porting set is

-------------------------------------------------------
Portingset : 6.1c.06.02
Port no. : PA.1733
Date : Thu Jul 26 17:52:48 METDST 2001
Uname : HP-UX torka B.10.20 A 9000/861 2016171322 two-user license
Machine-id : HP9000_PA_8000
OS-release : HPUX10.20
CFLAGS : +DS2.0 +DA2.0 +Onolimit +O2 -Ae +Oconservative +ESlit +ESsfc +Ofastaccess -I/port.6.1c.06.02/vobs/tt/headers -I/port.6.1c.06.02/vobs/tt/lib/dbs -I/port.6.1c.06.02/vobs/tt/lib/qdb -I/port.6.1c.06.02/vobs/tt/servers/ORACLE_2 -I/port.6.1c.06.02/vobs/tt/lib/al_1 -I/port.6.1c.06.02/vobs/tt/lib/mb -I/port.6.1c.06.02/vobs/tt/lib/qp -I/port.6.1c.06.02/vobs/tt/lib/dbc -I/dbms/Oracle/8.0.6.0.0/HPUX10.20/rdbms/demo -I/dbms/Oracle/8.0.6.0.0/HPUX10.20/network/public -I/dbms/Oracle/8.0.6.0.0/HPUX10.20/plsql/public -DHP9000_PA_8000 -DHPUX10_20 -DREL6_1 -DTTYBUG -DHPUX -DHP9000_800 -DNOSETEUID -DINCLSTDLIB -D_HPUX_SOURCE -I/usr/include/X11R5 -DSYSV_PT -D_TSS -DORACLE8 -DNOSELECTH -DSOCKET -DLOCAL_SOCKET -DPIPE -DMQ -DSHM -DDWORDSIZ -DSELECTINTYPES -DCUSERIDBUG -DVOID_PTR -DSCANF_OK -DSYSMEMFUN -DIS_OPEN_BUG -DSLOTIO -DWRITEV -DHIGH_LOW -DGETCLOCK -DWAITPID -DNOWAIT3 -DSIGNAL_TYPE=void -DSEM_LOCK
LOADFLAGS : -z -L/usr/lib/X11R5 -Wl,+s
DBMS ver. : 8.0.6.0.0
-------------------------------------------------------

dave_23
7th September 2004, 15:50
That's strange,

DBMS ver. : 8.0.6.0.0
should match
/baanIVc4.2/bse/lib/ora/oracle_home/Version is 8.0.6.3.0

But I don't think that's your problem.

try this:
cp -R $TNS_ADMIN $BSE/lib/ora/oracle_home/

That should create a $BSE/lib/ora/oracle_home/network/admin
directory with your tnsnames.ora and sqlnet.ora in it.
Verify that the permissions are correct. Then try to connect.

You might also try not setting oracle_server_home/oracle_home at all.

Also, verify that nothing conflicting is in your tabledef6.1 file

Dave

pitfloner
7th September 2004, 16:03
In one of your replies, you have commented to take out the TWO_TASK and TNS_ADMIN variables and their values of my tabledef6.1 file, is it still ok?

dave_23
7th September 2004, 16:07
Right, in this case you're specifying them in the db_resource so that's fine.
just make sure you don't have anything like ORACLE_SID or ORACLE_HOME
set in your tabledef either.

Dave

pitfloner
8th September 2004, 09:41
Wich value I've to set up in the variable tns_admin in db_resource file?

pitfloner
8th September 2004, 18:15
Status summary

1. We can connect and query by sqlplus to the remote database from the baan box.
2. If we execute the tnsping command on the baan box, the db instance and the listener answers.
3. I take out all variables from the tabledef6.1file, e.g. : cpcom000:*:oracle8():Y
4. All variables are set up on the file $BSE/lib/defaults/db_resource

# cat db_resource
dbs_init:021
oracle_service_name:baan3
nls_lang:Spanish_spain.WE8ISO8859P1
nls_sort:binary
oracle_client_home:/baanIVc4.2/bse/lib/ora/oracle_home
ora_default_tablespace:datspace
ora_temporary_tablespace:tempspace
ora_column_format:8
tns_admin:/baanIVc4.2/bse/lib/ora/oracle_home/network/admin

IMPORTANT: We’ve tried with the two_task and with oracle_service_name

5. We’ve copied the $BSE/lib/ora/ora_users and $BSE/lib/ora/ora_groups files from Baan production instance to the test instance.

Attention: The oracle version of production instance is 8.0.6.0.0, whereas the oracle version of test instance is 8.1.7.

6. We’ve copied all files inside the $ORACLE_HOME/network/admin directory on $BSE/lib/ora/oracle_home/network/admin.

7. We’ve create the baan user in the oracle db with the following roles: connect, resource, r_baan. The password is the same as the production instance.

8. We’ve create the bsp user in the oracle db with the following roles: connect, r_baan. The password is the same as the production instance.

Dikkie Dik
9th September 2004, 13:43
I advise to test with TNS_ADMIN and TWO TASK in the tabledef. But don't use a space between the parameters. So use:

*:*:oracle8(TWO_TASK=baan3,TNS_ADMIN=/oracle/app/oracle/product/8.0.6/network/admin):N

Hope this helps,
Dick