Problem connecting to Oracle using Oracle 12 client

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
11 messages Options
Reply | Threaded
Open this post in threaded view
|

Problem connecting to Oracle using Oracle 12 client

Hermann Ottens
Hi group,

i'm having a problem with connecting from VAST to Oracle using the Oracle 12 Client.
I can reproduce the error with the following code:

| conSpec logonSpec conn querySpec resultCollection |
conSpec := AbtDatabaseConnectionSpec
forDbmClass: #AbtOracle10DatabaseManager
databaseName: '...'.
["================================"
self halt.
conn := conSpec connect.
querySpec := AbtQuerySpec new statement: 'SELECT sysdate FROM dual'.
resultCollection := (conn resultTableFromQuerySpec: querySpec) asStrings.
"================================"]
ensure: [conn disconnect].
resultCollection inspect.

This code works fine with any Oracle 11 client.
I tried it with several Oracle 12 clients (12.1.0.1.0 instant client, 12.1.0.2.0 instant client and normal client, 12.2.0.1.0 instant client)
and each time i get the following results:

- in VAST 8.5.2: crash without any trace, process abt.exe just disappears.

- in VAST 9.0 (32 bit): error 'Primitive failed in: PlatformFunction>>#callWithArguments: due to Unknown floating point exception'

- in VAST 9.0 (64 bit): works

The code fails always at "connect", to be more exact, it fails when calling the external function OCILogon.
I wrote a little c program based on a simple source code snippet from Oracle. It ran fine using the Oracle 12 client.
Then i transferred the code to a dll and called that from VAST and again the image crashed when calling "connect".
Right now i'm a bit at a loss.

Any ideas?

Hermann

--
You received this message because you are subscribed to the Google Groups "VA Smalltalk" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
To post to this group, send email to [hidden email].
Visit this group at https://groups.google.com/group/va-smalltalk.
For more options, visit https://groups.google.com/d/optout.
Reply | Threaded
Open this post in threaded view
|

Re: Problem connecting to Oracle using Oracle 12 client

Wayne Johnston
Is this on Windows, and the Oracle server a 64-bit DLL?

--
You received this message because you are subscribed to the Google Groups "VA Smalltalk" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
To post to this group, send email to [hidden email].
Visit this group at https://groups.google.com/group/va-smalltalk.
For more options, visit https://groups.google.com/d/optout.
Reply | Threaded
Open this post in threaded view
|

Re: Problem connecting to Oracle using Oracle 12 client

Hermann Ottens
Hups, i was blinded by routine.
I was talking about using VAST on Windows.
The servers are Oracle 11 (Windows) and Oracle 12 servers (Windows and Linux) (all of them 64 bit).
I forgot to mention, that on Linux a connection from VAST to Oracle is possible without any problems using the Oracle 11 or the Oracle 12 client.

Hermann

--
You received this message because you are subscribed to the Google Groups "VA Smalltalk" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
To post to this group, send email to [hidden email].
Visit this group at https://groups.google.com/group/va-smalltalk.
For more options, visit https://groups.google.com/d/optout.
Reply | Threaded
Open this post in threaded view
|

Re: Problem connecting to Oracle using Oracle 12 client

Bob Brodd
In reply to this post by Hermann Ottens
Hi Hermann,

For VAST 8.5.2 and 9.0(x86) , you will have to install 32bit versions of the Oracle client.  Any chance you are trying to talk to a 64bit oracle client in these cases?

Bob


On Thursday, March 8, 2018 at 4:48:47 AM UTC-5, Hermann Ottens wrote:
Hi group,

i'm having a problem with connecting from VAST to Oracle using the Oracle 12 Client.
I can reproduce the error with the following code:

| conSpec logonSpec conn querySpec resultCollection |
conSpec := AbtDatabaseConnectionSpec
forDbmClass: #AbtOracle10DatabaseManager
databaseName: '...'.
["================================"
self halt.
conn := conSpec connect.
querySpec := AbtQuerySpec new statement: 'SELECT sysdate FROM dual'.
resultCollection := (conn resultTableFromQuerySpec: querySpec) asStrings.
"================================"]
ensure: [conn disconnect].
resultCollection inspect.

This code works fine with any Oracle 11 client.
I tried it with several Oracle 12 clients (12.1.0.1.0 instant client, 12.1.0.2.0 instant client and normal client, 12.2.0.1.0 instant client)
and each time i get the following results:

- in VAST 8.5.2: crash without any trace, process abt.exe just disappears.

- in VAST 9.0 (32 bit): error 'Primitive failed in: PlatformFunction>>#callWithArguments: due to Unknown floating point exception'

- in VAST 9.0 (64 bit): works

The code fails always at "connect", to be more exact, it fails when calling the external function OCILogon.
I wrote a little c program based on a simple source code snippet from Oracle. It ran fine using the Oracle 12 client.
Then i transferred the code to a dll and called that from VAST and again the image crashed when calling "connect".
Right now i'm a bit at a loss.

Any ideas?

Hermann

--
You received this message because you are subscribed to the Google Groups "VA Smalltalk" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
To post to this group, send email to [hidden email].
Visit this group at https://groups.google.com/group/va-smalltalk.
For more options, visit https://groups.google.com/d/optout.
Reply | Threaded
Open this post in threaded view
|

Re: Problem connecting to Oracle using Oracle 12 client

Hermann Ottens
Hello Bob,

reasonable question, but i used the correct client.
(Just for the records:
Trying to connect 32-bit VAST to a 64-bit-Oracle Client results in 'Primitive failed in: PlatformFunction>>#callWithArguments: due to OS error193'.
According to winerror.h
#define ERROR_BAD_EXE_FORMAT 193L)

When i made the tests i used the Sysinternals ProcessExplorer to make sure that the right DLLs from the right path were loaded.
I also checked with DependencyWalker that the 32-bit DLLs were in fact 32-bit DLLs.

Cheers,
Hermann

Am Donnerstag, 8. März 2018 16:58:49 UTC+1 schrieb Bob Brodd:
Hi Hermann,

For VAST 8.5.2 and 9.0(x86) , you will have to install 32bit versions of the Oracle client.  Any chance you are trying to talk to a 64bit oracle client in these cases?

Bob

--
You received this message because you are subscribed to the Google Groups "VA Smalltalk" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
To post to this group, send email to [hidden email].
Visit this group at https://groups.google.com/group/va-smalltalk.
For more options, visit https://groups.google.com/d/optout.
Reply | Threaded
Open this post in threaded view
|

Re: Problem connecting to Oracle using Oracle 12 client

Bob Brodd

Hermann,
I will try to set up a 12c environment and test it.  I usually test things with the Express Edition, but that is not available for 12c in any version yet, so ill install a 64bit db server and a 32bit client and see what my results are.
Bob

On Friday, March 9, 2018 at 5:27:59 AM UTC-5, Hermann Ottens wrote:
Hello Bob,

reasonable question, but i used the correct client.
(Just for the records:
Trying to connect 32-bit VAST to a 64-bit-Oracle Client results in 'Primitive failed in: PlatformFunction>>#callWithArguments: due to OS error193'.
According to winerror.h
#define ERROR_BAD_EXE_FORMAT 193L)

When i made the tests i used the Sysinternals ProcessExplorer to make sure that the right DLLs from the right path were loaded.
I also checked with DependencyWalker that the 32-bit DLLs were in fact 32-bit DLLs.

Cheers,
Hermann

Am Donnerstag, 8. März 2018 16:58:49 UTC+1 schrieb Bob Brodd:
Hi Hermann,

For VAST 8.5.2 and 9.0(x86) , you will have to install 32bit versions of the Oracle client.  Any chance you are trying to talk to a 64bit oracle client in these cases?

Bob

--
You received this message because you are subscribed to the Google Groups "VA Smalltalk" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
To post to this group, send email to [hidden email].
Visit this group at https://groups.google.com/group/va-smalltalk.
For more options, visit https://groups.google.com/d/optout.
Reply | Threaded
Open this post in threaded view
|

Re: Problem connecting to Oracle using Oracle 12 client

Bob Brodd
Hermann,

I have finally managed to set up a Windows 10 32-bit  machine with the 32-bit Oracle 12c client and a 64-bit Windows 10 machine running an Oracle 12c 64-bit server.  I have been able to successfully run a large number of DB tests from a VA Smalltalk 9.0 32-bit image running on the client machine.   Is this a similar setup to what you are using?

I also tried out your test snippet of code ( with a slight change to avoid prompt for userid/pw) that also works ok.  The 'XE' is the service name I defined in the tnsnames.ora file that points to my server:

| conSpec logonSpec conn querySpec resultCollection |
conSpec := AbtDatabaseConnectionSpec
forDbmClass: #AbtOracle10DatabaseManager
databaseName: ''.
logonSpec := AbtDatabaseLogonSpec
id: 'system'
password: '<enter pw here>'' 
server: 'XE'.
["================================"
self halt.
conn := conSpec connectUsingAlias: 'test' logonSpec: logonSpec .
querySpec := AbtQuerySpec new statement: 'SELECT sysdate FROM dual'.
resultCollection := (conn resultTableFromQuerySpec: querySpec) asStrings.
"================================"]
ensure: [conn disconnect].
resultCollection inspect.

Bob

On Monday, March 12, 2018 at 11:23:41 AM UTC-4, Bob Brodd wrote:

Hermann,
I will try to set up a 12c environment and test it.  I usually test things with the Express Edition, but that is not available for 12c in any version yet, so ill install a 64bit db server and a 32bit client and see what my results are.
Bob

On Friday, March 9, 2018 at 5:27:59 AM UTC-5, Hermann Ottens wrote:
Hello Bob,

reasonable question, but i used the correct client.
(Just for the records:
Trying to connect 32-bit VAST to a 64-bit-Oracle Client results in 'Primitive failed in: PlatformFunction>>#callWithArguments: due to OS error193'.
According to winerror.h
#define ERROR_BAD_EXE_FORMAT 193L)

When i made the tests i used the Sysinternals ProcessExplorer to make sure that the right DLLs from the right path were loaded.
I also checked with DependencyWalker that the 32-bit DLLs were in fact 32-bit DLLs.

Cheers,
Hermann

Am Donnerstag, 8. März 2018 16:58:49 UTC+1 schrieb Bob Brodd:
Hi Hermann,

For VAST 8.5.2 and 9.0(x86) , you will have to install 32bit versions of the Oracle client.  Any chance you are trying to talk to a 64bit oracle client in these cases?

Bob

--
You received this message because you are subscribed to the Google Groups "VA Smalltalk" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
To post to this group, send email to [hidden email].
Visit this group at https://groups.google.com/group/va-smalltalk.
For more options, visit https://groups.google.com/d/optout.
Reply | Threaded
Open this post in threaded view
|

Re: Problem connecting to Oracle using Oracle 12 client

Hermann Ottens
Hi Bob,

(i have been absent for a while so that i couldn't answer earlier)
thank you for your reply.
I already had a suspicion that this might be a special problem because nobody else seems to complain about this.
What i could find out additionally is, that this error only occurs on machines that have some kind of virtualization in use.
As far as i can see, this behaviour appears here on Citrix machines on VMWare machines and on physical machines with Symantec Workspace Virtualization.

Cheers,
Hermann

--
You received this message because you are subscribed to the Google Groups "VA Smalltalk" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
To post to this group, send email to [hidden email].
Visit this group at https://groups.google.com/group/va-smalltalk.
For more options, visit https://groups.google.com/d/optout.
Reply | Threaded
Open this post in threaded view
|

Re: Problem connecting to Oracle using Oracle 12 client

Bob Brodd
Hermann,
All of my DB testing takes place in VMWare virtual machines.  For this test, I had a Windows 10 x64 vm set up with an Oracle 12c server and a Windows 10 x86 vm set up with the Oracle 12c client.  Both VMs running on the same physical machine.  
Bob

On Mar 28, 2018, at 11:06 AM, Hermann Ottens <[hidden email]> wrote:

Hi Bob,

(i have been absent for a while so that i couldn't answer earlier)
thank you for your reply.
I already had a suspicion that this might be a special problem because nobody else seems to complain about this.
What i could find out additionally is, that this error only occurs on machines that have some kind of virtualization in use.
As far as i can see, this behaviour appears here on Citrix machines on VMWare machines and on physical machines with Symantec Workspace Virtualization.

Cheers,
Hermann

--
You received this message because you are subscribed to a topic in the Google Groups "VA Smalltalk" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/va-smalltalk/-soxo7KknKI/unsubscribe.
To unsubscribe from this group and all its topics, send an email to [hidden email].
To post to this group, send email to [hidden email].
Visit this group at https://groups.google.com/group/va-smalltalk.
For more options, visit https://groups.google.com/d/optout.

--
You received this message because you are subscribed to the Google Groups "VA Smalltalk" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
To post to this group, send email to [hidden email].
Visit this group at https://groups.google.com/group/va-smalltalk.
For more options, visit https://groups.google.com/d/optout.
Reply | Threaded
Open this post in threaded view
|

Re: Problem connecting to Oracle using Oracle 12 client

Hermann Ottens
Hello Bob,

thank you for your effort.
I will inform you as soon as i find out more about this strange behaviour-

Cheers,
Hermann

--
You received this message because you are subscribed to the Google Groups "VA Smalltalk" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
To post to this group, send email to [hidden email].
Visit this group at https://groups.google.com/group/va-smalltalk.
For more options, visit https://groups.google.com/d/optout.
Reply | Threaded
Open this post in threaded view
|

Re: Problem connecting to Oracle using Oracle 12 client

Noschvie
In reply to this post by Hermann Ottens
Hermann,

for VAST 8.5.2 you should check the Oracle platform functions at:
AbtOracle10DatabaseManager class>>#buildAbtOraclePlatformFunctionsDictionary:language:library:return:integer:

bugs are fixed in VAST 9.0 and the changes are needed in VAST 8 too

Norbert

--
You received this message because you are subscribed to the Google Groups "VA Smalltalk" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
To post to this group, send email to [hidden email].
Visit this group at https://groups.google.com/group/va-smalltalk.
For more options, visit https://groups.google.com/d/optout.