<iframe src="https://www.googletagmanager.com/ns.html?id=GTM-M74D8PB" height="0" width="0" style="display:none;visibility:hidden">
Loading
Skip to NavigationSkip to Main Content
System Status
Announcements
Announcements
Search
Search
Select Language

Troubleshooting Common Errors in the SAP NetWeaver ABAP Connector for Okta

Okta Classic Engine
Okta Identity Engine
Okta Integration Network

The SAP NetWeaver ABAP on-premises connector provisions users and role entitlements from Okta into an SAP system through the OPS Agent. Nearly every failure produces the same generic message in the Okta Admin Console — the agent log is the authoritative source for the actual cause. This article covers connection errors, SAP Java Connector (JCo) runtime errors, import behavior, create and update failures, role errors, known behavioral limitations, and a method for isolating SAP-side issues directly.

 


Reading the Agent Log Before Diagnosing Any Error

The agent log location depends on the installation type:

 

InstallAgent logStartup output
RPM/opt/OktaOnPremSCIMAgent/logs/application.log/opt/OktaOnPremSCIMAgent/logs/service.out, service.err
Docker/opt/OktaOnPremSCIMAgent/[OPS_AGENT_NAME]/logs/application.logdocker logs [container]

 

A useful first search for RPM installs:

sudo grep -iE 'SAP connection error|sapjco3|JCO_ERROR|Failed to ' \
  /opt/OktaOnPremSCIMAgent/logs/application.log | tail -50

 

Keep the following in mind when reading the log:

  • One attempt can log two failures. Okta retries a failed action once automatically, a few seconds later. Read the first failure, or the Caused by: lines of the second.
  • Saving the connection settings runs the connection check. Each save is a full attempt against SAP, the same as Test Connection. With a wrong password, every save is a failed SAP logon.
  • Stack-trace lines carry no timestamp. After a restart, read only from the agent's started successfully line onward, or older failures will appear current.

NOTE: Never paste the X-OKTA-ONPREM-DATA header value into a ticket, Slack message, or screenshot. It is base64 encoding, not encryption — it decodes to the SAP host, client, service-account username, and password. Mask passwords in any SU01 or SE37 screenshots, and never capture the hash columns of table USR02.

 


What Does the Admin Console Error Message Mean?

The following message appears for every connection and JCo failure — on Test Connection, on save, and when an import fails. It never identifies the specific cause; the SAP reason is in the agent log, not the console:

One or more provisioning agents cannot service this connector. Verify the SAP Java Connector (JCo) libraries and the RFC connectivity to the SAP application server on each agent. Failing agents: [agent name]

 

To identify the actual cause, note the agent name in the message, open that agent's log, find the first error after the attempt, and match it in the table below:

 

Agent log containsCause
Connect to SAP gateway failed, partner '...' not reachedSAP gateway not reachable or wrong system number
Client [nnn] is not available in this systemWrong client number
Name or password is incorrectWrong credentials
SAP JCo jar not found or invalidJCo jar not found
UnsatisfiedLinkError: no sapjco3Native library not found
cannot open shared object file, can't load ... .so on a ... platformNative library for the wrong platform
Native library sapjco3 is too oldJar and native library do not match
Could not initialize class com.sap.conn.jco.rt.JCoRuntimeFactoryJCo failed earlier in the same agent run

 


Connection Errors and How to Resolve Them

    Error: Connect to SAP gateway failed — partner '[host]:33[nn]' not reached

    JCo code (102) JCO_ERROR_COMMUNICATION.

    Reason: the agent cannot reach the SAP gateway. The address in the message tells you which setting is wrong:

    • Wrong host name — the message shows the wrong host, e.g. partner '10.255.255.1:3300' not reached.

     
    image-20261103-095250.png
    Ref Img: Agent log, wrong host
     
    • Wrong system number — the message shows the right host with the wrong port. JCo connects to port 33 + system number, so system number 42 gives partner '[host]:3342' not reached.

     
    image-20261103-095432.png
    Ref Img: agent log, wrong system number
     

     

    How long it takes is also a clue:

    • About 60 seconds per attempt (ERRNO 115 Operation now in progress) — the host or port is not reachable at all: wrong address, a firewall dropping traffic, or no route. With Okta's retry, the admin waits a minute or two before the banner appears.

    • Immediate (ERRNO 111 Connection refused) — the host is reachable but nothing listens on the port: the gateway is down or the system number is wrong.

    Resolution:

    • Correct the host or system number in the app's connection settings. The system number is the two digits in sapgw00, not the system ID.

    • Prove reachability from the agent host first:

     
     
    nc -vz [sap-host] 33[sysnr] # SAP gateway, e.g. 3300 for sysnr 00

     

    Logon groups (message server): when the app uses a logon group rather than a single application server, JCo looks up the message-server port as service sapms[SID]. If the agent host cannot resolve it, add sapms[SID] 36[nn]/tcp to the agent host's /etc/services.

     


    Error: Client [nnn] is not available in this system

    JCo code (103) JCO_ERROR_LOGON_FAILURE, returned immediately.

     
    image-20261103-100100.png
    Ref Img: agent log, wrong client

     

    Reason: the client number in the connection settings does not exist on that SAP system. SAP reports this as a logon failure, the same code as a wrong password, so read the text after the code before assuming the credentials are wrong.

    Resolution: confirm the three-digit client. A client that exists in one SAP system need not exist in another.

     


    Error: (103) JCO_ERROR_LOGON_FAILURE: Name or password is incorrect (repeat logon)

    Reason: the service-account username or password is wrong, or the account is locked.

    Resolution:

    • Stop retrying as soon as a logon fails. SAP locks the account after a set number of failed logons, and then the error changes to a lock message that hides the original cause. Each Save of the connection settings, each Test Connection and each Okta retry counts.

    • Check the account in SU01: unlock it if needed, correct the password, and try once.

    • A locked service account stops provisioning for every user on the app, not just one.


    Error: the service account authenticates, but every provisioning operation fails

    Reason: the account can log on but lacks the authorisations the connector needs. Test Connection can pass while operations fail.

    Resolution: grant the service account:

     
     
     

    Authorisation object

     

    Needed for

     

    S_RFC

    Calling any BAPI remotely — without it nothing works

    S_USER_GRP

    Reading and maintaining users (BAPI_USER_*)

    S_USER_AGR

    Reading and assigning roles (PRGN_ROLE_GETLIST, BAPI_USER_ACTGROUPS_ASSIGN)

     

     

    This is also the answer to the question of what access the agent requires. 

     


    Error: logon works in SAP GUI but fails from the agent

    Reason: the password was set by an administrator, so SAP treats it as an initial password that must be changed at first logon. SAP GUI prompts for the change; RFC logon simply fails.

    Resolution: create the service account with user type System (or Service), which is exempt from the initial-password rule. Changing the type on an existing account also clears it.

     


     

    JCo Runtime Errors and File Placement

     

    JCo is customer-supplied — the agent ships no SAP libraries.

    Where the files go: copy sapjco3.jar and libsapjco3.so directly into /opt/OktaOnPremSCIMAgent/userlib/, with no subfolder (for Docker, the userlib/ folder of that agent). Both files must come from the same SAP JCo download, for the agent host's platform.

    Always restart the agent after changing JCo files. JCo is loaded once per agent run; a running agent keeps using whatever it loaded first.

    Checking the JCo setup, step by step

    Run these on the agent host when any JCo error appears, or before the first Test Connection. Paths are for RPM installs; for Docker, use that agent's userlib/ folder.

    1. Check the host's processor type. This decides which SAP JCo download is needed.

       
       
      uname -m

      Expect x86_64 (Intel/AMD) or aarch64 (ARM).

    2. Check the files are in place.

       
       
      ls -l /opt/OktaOnPremSCIMAgent/userlib/

      Expect sapjco3.jar and libsapjco3.so directly in userlib/, readable by the agent. Other SAP jars, such as sapidoc3.jar, are not used by the connector and can stay.

    3. Check there are no other copies.

       
       
      find /opt/OktaOnPremSCIMAgent/userlib -name 'sapjco3.jar' -o -name 'libsapjco3*'

      Expect exactly two lines, both directly in userlib/. A copy in a subfolder: see a JCo error names a library in a subfolder.

    4. Check the library matches the processor.

       
       
      file /opt/OktaOnPremSCIMAgent/userlib/libsapjco3.so

      On an x86_64 host expect ELF 64-bit LSB shared object, x86-64; on an aarch64 host expect ELF 64-bit LSB shared object, ARM aarch64. Anything else, including Mach-O (a macOS build), is the wrong download: see wrong platform.

    5. Check the jar and library load together. If Java is on the host's path:

       
       
      cd /opt/OktaOnPremSCIMAgent/userlib && java -Djava.library.path=. -jar sapjco3.jar -stdout

      Expect the JCo and native library versions with no error. An error here is the same one the agent will hit.

    6. Restart the agent and run Test Connection once. Read the agent log from its latest started successfully line (§1).


    Error: SAP JCo jar not found or invalid at [path]

    Full text: SAP JCo jar not found or invalid at [path]. The customer-supplied sapjco3.jar must be placed at this path (configurable via -Dokta.sap.jco.jar.location), and must match the SAP release the agent connects to.

     
    image-20261103-100452.png
    Ref Img: agent log, jar missing

    Reason: no readable sapjco3.jar at the path in the message. After an upgrade, this is often a jar left in an old userlib/sap/ folder while the agent now reads userlib/.

    Resolution: place sapjco3.jar at the path the message names (normally userlib/), then restart the agent.


    Error: JCo initialization failed with java.lang.UnsatisfiedLinkError: no sapjco3 in java.library.path: [path]

    Reason: the native library libsapjco3.so is missing from the path in the message. If the message instead says cannot open shared object file, the file is there but built for the wrong processor — see wrong platform.

     
    image-20261103-100616.png
    Ref Img: agent log, native library missing

    Resolution: place libsapjco3.so beside sapjco3.jar in userlib/, then restart the agent. The library path is read once at startup, so a running agent never picks up a newly added file.


    Error: UnsatisfiedLinkError: [path]/libsapjco3.so: cannot open shared object file: No such file or directory (Possible cause: can't load [platform] .so on a [platform] platform)

    Example: UnsatisfiedLinkError: /opt/OktaOnPremSCIMAgent/userlib/libsapjco3.so: cannot open shared object file: No such file or directory (Possible cause: can't load AARCH64 .so on a AMD 64 platform)

    Reason: libsapjco3.so is present, but it was built for a different processor type than the agent host. JCo has two parts: sapjco3.jar is Java code and runs on any machine, but libsapjco3.so is a native library compiled for one processor type only. SAP publishes a separate JCo download for each platform — Linux x86_64 (Intel/AMD, also called AMD64), Linux aarch64 (ARM, for example AWS Graviton), Windows and macOS — and a library from one cannot be loaded on another.

     
    image-20261111-054419.png
    Ref Img: agent log, wrong platform

    The No such file or directory part is misleading: the file exists, Linux refuses to load it. The Possible cause part names the mismatch:

    • can't load AARCH64 .so on a AMD 64 platform — an ARM library on an Intel/AMD host. The most common case.

    • can't load AMD 64 .so on a AARCH64 platform — an Intel/AMD library on an ARM host.

    • invalid ELF header — not a Linux library at all, for example a macOS or Windows file renamed to libsapjco3.so, or an incomplete copy.

    Resolution:

    1. Check the agent host's processor with uname -m: x86_64 means Intel/AMD, aarch64 means ARM.

    2. Check what the library was built for with file /opt/OktaOnPremSCIMAgent/userlib/libsapjco3.so and compare (step 4 of the checklist at the top of this section).

    3. From SAP's Software Download Center, download the SAP JCo 3.1 package for Linux on the processor uname -m reported.

    4. Replace both sapjco3.jar and libsapjco3.so in userlib/ with the files from that one archive. Replacing only the library usually leads straight to Native library sapjco3 is too old.

    5. Restart the agent, then run Test Connection once.


    Error: Native library sapjco3 is too old. Found library [path]/libsapjco3.so has version "[x]", but required is at least version "[y]"

    Reason: the jar and the native library come from different JCo downloads. The jar requires at least version [y] of the native library.

     
    image-20261103-100709.png
    Ref Img: agent log, mismatched pair

    Resolution:

    • Re-download both files from the same archive on SAP's Software Download Center and replace them together, then restart the agent.

    • The platform must match too: a Linux x86-64 .so, a Linux arm64 .so and a macOS .dylib are different builds of the same version.

    • Check the path in the message. If it points into a subfolder of userlib/, see the next entry.


    Error: a JCo error names a library in a subfolder of userlib, even though the correct files are in userlib

    Reason: more than one sapjco3.jar exists under userlib/, for example a leftover userlib/sap/ folder. The agent picks up jars in subfolders too, and JCo always loads the libsapjco3.so next to the jar it was loaded from — so a stray jar brings its own native library, whatever the library-path setting says.

     
    image-20261103-100810.png
    Ref Img: userlib/ layout with the stray subfolder
     
    image-20261103-100853.png
    Ref Img: agent log, library loaded from the subfolder

    Resolution:

    • Keep exactly one sapjco3.jar and one libsapjco3.so anywhere under userlib/, both directly in userlib/.

    • Move older JCo folders out of userlib/ entirely, then restart the agent.


    Error: NoClassDefFoundError: Could not initialize class com.sap.conn.jco.rt.JCoRuntimeFactory

    Reason: JCo already failed to start earlier in this agent run, and every later attempt reports this instead. It is usually the second failure of a single attempt, after Okta's automatic retry.

    Resolution: look at the Caused by: lines under it, or at the first JCo error after the last restart — that is the real cause. Fix it, then restart the agent: until it restarts, every attempt keeps failing with this message.


    Error: the agent starts successfully, but the first SAP operation fails

    Reason: expected. JCo is loaded on first use, so a missing or unusable JCo does not stop the agent from starting. The startup output still lists the configured JCo paths.

     
    image-20261103-100956.png
    Ref Img: agent startup output

    Resolution: none needed. A clean startup does not prove SAP connectivity — always run Test Connection.

     


    Import Errors and Expected Import Behavior

    Error: the import fails with "cannot service this connector"

    The same banner as Test Connection (§2), with the same causes. Check the agent log against the table in §2. A Test Connection that passed earlier does not rule these out: the service account may have been locked, or its password changed, since.


    Locked SAP users are not imported

    Expected, and the same as the previous integration. List imports leave out users who are locked in SAP (LOCAL_LOCK). Looking a single user up by name still finds them.


    SAP system accounts appear in the import

    DDIC, SAP*, TMSADM and EARLYWATCH are imported like any other user; there is no built-in exclusion. Exclude them in the import-matching or import-rule configuration in Okta, and never provision to or modify these accounts — they are SAP's own administrative users.


    Large imports are slow, and incremental imports don't help

    The import reads each user individually from SAP — roughly 600 ms per user, about 10 minutes per 1,000 users. SAP cannot select users by last-modified time, so an incremental import is served as a full import (the agent logs serving a full import). Plan import schedules around full-import duration. If the duration is unacceptable for a user count, raise it as a scale question rather than a defect.

     


    Create and Update Errors

    Error: Failed to [operation] user=[username] reason=[SAP message]

    The shape of every write failure. The operation is one of create, update, patch, activate, deactivate or assign roles to.

    Reason: SAP rejected the write. The text after reason= is SAP's own message and is the part to act on. no RETURN message means SAP rejected the call without giving a reason.

    Resolution: resolve the SAP condition named in the message — usually a value SAP will not accept, a field mandatory for the user type, or a missing authorisation (§3).

    Related messages:

    • Failed to commit [operation] for user=[username] reason=... — SAP accepted the change but did not commit it; the change did not persist.

    • Failed to create user=[username] reason=... (cleanup failed, the user may still exist in SAP) — the create failed part-way and the half-created user could not be removed. Check SU01 before retrying.

    • An update also fails on a SAP warning, not just an error.


    Error: a long name is saved truncated, and the push still reports success

    SAP's name fields hold 40 characters, and SAP truncates rather than rejecting. Keep Okta-side values within SAP's field lengths. SAP rejects an over-length email address but truncates a name — that difference is SAP's behaviour, not the connector's.

     


    Role and Entitlement Errors

    Error: Failed to assign roles to user=[username] reason=Role [ROLE] does not exist

    Reason: a role sent from Okta does not exist in SAP — usually a stale entitlement after the role was renamed or deleted in SAP.

    Resolution: re-import entitlements so Okta's role list matches SAP, then retry.


    Deactivating a user removes their SAP roles

    Expected, and the same as the previous integration. Deactivating a user in Okta locks the SAP user and removes all of its roles; reactivating unlocks it and assigns the roles from Okta again.


    Known Behavioral Limitations

    These behaviors are inherited from the integration this connector replaces and are documented here for recognition.

    Users with a telephone or fax number cannot be updated

    Any update to such a user fails, even one that touches neither field, with Failed to update user=[username] reason=Specify a valid country indicator. The phone and fax rows are sent without a country, and SAP rejects the whole change. The only workaround is removing the telephone and fax numbers from the SAP user.

    Email addresses not held in Okta are removed on update

    A profile push sends the email addresses Okta holds and replaces the SAP list with them. An address kept only in SAP is lost, with no error. Landline, fax and parameter rows held only in SAP are kept. Flag this before go-live if email addresses are maintained in SAP outside Okta.

    Two Okta users can overwrite each other in SAP

    SAP usernames are 12 characters. Two Okta usernames that share their first 12 characters resolve to the same SAP user, and the write succeeds against whichever exists. Ensure usernames provisioned to SAP are unique within their first 12 characters.

     


    Diagnosing an Issue Not Listed in This Article

    Call the BAPI directly in SE37. This removes Okta, the agent and JCo from the picture and answers "is this SAP or the connector?" in one step. Do this first on any SAP oddity.

     
     

    Function module

     

    Used for

     

    BAPI_USER_GET_DETAIL

    Reading one user — what import sees

    BAPI_USER_GETLIST

    The user list the import starts from

    BAPI_USER_CREATE1

    User creation

    BAPI_USER_CHANGE

    Updates

    BAPI_USER_LOCK / BAPI_USER_UNLOCK

    Deactivate and reactivate

    PRGN_ROLE_GETLIST

    Entitlement and role import

    BAPI_USER_ACTGROUPS_ASSIGN

    Role assignment

     
     

    SAP reports a rejected write in a RETURN table rather than by failing the call, so "SAP returned no error" and "SAP applied the change" are different statements.

    Loading
    Troubleshooting Common Errors in the SAP NetWeaver ABAP Connector for Okta | Okta Support