Forum Stats

  • 3,760,200 Users
  • 2,251,663 Discussions
  • 7,871,021 Comments

Discussions

Getting ORA-28579: network error during callback from external procedure agent

3293976
3293976 Member Posts: 3
edited Jul 12, 2017 1:29AM in R Technologies

After an overnight Linux update automatically upgraded Oracle R packages from 3.3.1 to 3.4.0, R started failing as below:

R> ore.doEval(function() { 123 })

Error in .oci.GetQuery(conn, statement, data = data, prefetch = prefetch,  :

  ORA-20000: RQuery error

Error in do.call(Cairo, png.args) : object 'Cairo' not found

ORA-06512: at "RQSYS.RQEVALIMPL", line 104

ORA-06512: at "RQSYS.RQEVALIMPL", line 101

In addition: Warning message:

the Oracle Enterprise server is running R 3.3.1, which differs from the current session of R 3.4.0

> traceback()

8: .oci.GetQuery(conn, statement, data = data, prefetch = prefetch,

       bulk_read = bulk_read)

7: .local(conn, statement, ...)

6: ROracle::dbGetQuery(.ore.con(), qry, ...)

5: ROracle::dbGetQuery(.ore.con(), qry, ...)

4: .ore.QueryEnv$dbGetQuery(qry, noframe = noframe, ...)

3: OREbase:::.ore.dbGetQuery(sprintf("create table %s as %s", tabName,

       lstQry))

2: .ore.eval("rqEval", NULL, FUN, FUN.NAME, FUN.VALUE, .ore.matchFUN(FUN,

       FUN.NAME, ..., has.implicit = FALSE))

1: ore.doEval(function() {

       123

   })

We then upgraded R from 1.4.1 to 1.5, and performed the server upgrade from 3.3.1 to 3.4.0

However now we get the following error:

> ore.doEval(function() { 123 })

Error in .oci.GetQuery(conn, statement, data = data, prefetch = prefetch,  :

  ORA-28579: network error during callback from external procedure agent

ORA-06512: at "RQSYS.RQEVALIMPL", line 104

ORA-06512: at "RQSYS.RQEVALIMPL", line 101

And a core dump gets created in $ORACLE_HOME/rdbms/log e.g. /oracle/product/12.1.0.2/dbhome_1/rdbms/log/hs_core_55457. The only error in the trace is:

========== FRAME [4] (CairoGD_Circle()+11 cairotalk.c:365 -> __sighandler()) ==========

defined by frame pointers 0x7fffe2fc2660  and 0x7fffe2fc2610

CALL TYPE: signal   ERROR SIGNALED: yes   CALLER: CairoGD_Circle

If we run "ore.doEval(function() {123}, ore.graphics = FALSE)" it succeeds as below:

> ore.doEval(function() {123}, ore.graphics = FALSE)

[1] 123

See the following for more debugging:

> ore.doEval(function() {capabilities()}, ore.graphics = FALSE)

       jpeg         png        tiff       tcltk         X11        aqua

       TRUE        TRUE        TRUE        TRUE        TRUE       FALSE

   http/ftp     sockets      libxml        fifo      cledit       iconv

       TRUE        TRUE        TRUE        TRUE        TRUE        TRUE

        NLS     profmem       cairo         ICU long.double     libcurl

       TRUE       FALSE        TRUE        TRUE        TRUE        TRUE

> ore.doEval(function() {.libPaths()}, ore.graphics = FALSE)

[1] "/oracle/product/12.1.0.2/dbhome_1/R/library"

[2] "/usr/lib64/R/library"

[3] "/usr/share/R/library"

> ore.doEval(function() {library(Cairo)}, ore.graphics = FALSE)

[1] "Cairo"     "OREcommon" "stats"     "graphics"  "grDevices" "utils"

[7] "datasets"  "methods"   "base"

X11 forwarding is setup correctly: when I run "xclock" on the server the clock appears on my Windows desktop.

This is on RHEL 7.3, Oracle RDBMS 12.1.0.2.0. Using default extproc settings (i.e. allow all).

I've had a look at other, similar posts, but nothing seems to work.

Any help would be much appreciated as we are going around in circles!

Best Answer

  • Sherry Lamonica-Oracle
    Sherry Lamonica-Oracle Posts: 437 Employee
    edited Jul 10, 2017 11:11PM Accepted Answer

    Can you load directly in R, on the database server?

    R> library(Cairo)

    If so, the error you are seeing:

    R> ore.doEval(function() { 123 })

    Error in .oci.GetQuery(conn, statement, data = data, prefetch = prefetch,  :

      ORA-20000: RQuery error

    Error in do.call(Cairo, png.args) : object 'Cairo' not found

    most likely indicates that the embedded R process isn't finding the libraries Cairo requires prior to loading.

    However before going too far down this path, note that none of the released Oracle R Enterprise versions will work with anything above R-3.2.0.  Refer to Talbe 1-2 in the Oracle R Enterprise Installation Guide  (Oracle server support matrix) for details:

    Overview of Oracle R Enterprise Installation

    Your next steps should be:

    1. On the server:

    uninstall Oracle R Enterprise

    uninstall R-3.4.0

    install the correct Oracle R Distribution version (this would be version 3.2.0 for the latest ORE, version 1.5.0, but verify with your ORE version and table 1-2 above)
    install Oracle R Enterprise (most likely you want the latest version, 1.5.0) server and supporting packages

    2. On the client
    uninstall the ORE client and supporting packages
    uninstall R
    install Oracle R Distribution (same version as on server)
    install Oracl R Enterprise client and supporting packages

    The Oracle R Enterprise Installation & Administration Guide contains all the steps.  Appendix A includes and end to end server installation on Linux and client installation on Windows.

    After resolving the installation issues, please try embedded R again.  I will wait for your response.

    -Sherry

Answers

  • Sherry Lamonica-Oracle
    Sherry Lamonica-Oracle Posts: 437 Employee
    edited Jul 10, 2017 11:11PM Accepted Answer

    Can you load directly in R, on the database server?

    R> library(Cairo)

    If so, the error you are seeing:

    R> ore.doEval(function() { 123 })

    Error in .oci.GetQuery(conn, statement, data = data, prefetch = prefetch,  :

      ORA-20000: RQuery error

    Error in do.call(Cairo, png.args) : object 'Cairo' not found

    most likely indicates that the embedded R process isn't finding the libraries Cairo requires prior to loading.

    However before going too far down this path, note that none of the released Oracle R Enterprise versions will work with anything above R-3.2.0.  Refer to Talbe 1-2 in the Oracle R Enterprise Installation Guide  (Oracle server support matrix) for details:

    Overview of Oracle R Enterprise Installation

    Your next steps should be:

    1. On the server:

    uninstall Oracle R Enterprise

    uninstall R-3.4.0

    install the correct Oracle R Distribution version (this would be version 3.2.0 for the latest ORE, version 1.5.0, but verify with your ORE version and table 1-2 above)
    install Oracle R Enterprise (most likely you want the latest version, 1.5.0) server and supporting packages

    2. On the client
    uninstall the ORE client and supporting packages
    uninstall R
    install Oracle R Distribution (same version as on server)
    install Oracl R Enterprise client and supporting packages

    The Oracle R Enterprise Installation & Administration Guide contains all the steps.  Appendix A includes and end to end server installation on Linux and client installation on Windows.

    After resolving the installation issues, please try embedded R again.  I will wait for your response.

    -Sherry

  • 3293976
    3293976 Member Posts: 3
    edited Jul 11, 2017 12:53AM

    Thanks for your quick response Sherry, it is much appreciated.

    Strangely, the installation has been working with 1.4.1 and 3.3.1 for quite some months, it is only since the upgrade to 3.4.0 that embedded R broke.

    Executing "library(Cairo)" does indeed work, so I'll follow the steps to downgrade to 3.2.0 and 1.5 and let you know how it goes.

    Thanks again

  • 3293976
    3293976 Member Posts: 3
    edited Jul 12, 2017 1:29AM

    Many thanks for your help in this Sherry, after reverting to 3.2.0 and 1.5 as you suggested, all is working again.

This discussion has been closed.