# JCo initialization failed: Native Library already loaded in another classloader in MuleSoft: cause and fix

Source page: https://ipaaserrors.com/mulesoft/sap-native-library-already-loaded-in-another-classloader
Platform: MuleSoft · SAP Connector
Checked against vendor docs: 2026-11-30

This SAP Connector error means the JCo native library is loaded twice, usually because a copy sits in the same directory as the JCo JARs. Remove the duplicate native library from the JAR directory, or put it on LD_LIBRARY_PATH and share it across apps.

## Error text

```
java.lang.ExceptionInInitializerError: JCo initialization failed with java.lang.UnsatisfiedLinkError: Native Library ... already loaded in another classloader
```

## Likely causes

- Loading the native library from the global configuration copies it into the app, but leaves the source. If the source is in the same directory as the JCo JARs, the library is loaded twice.

## How to fix it

1. Remove the duplicate native library from the JAR directory (the simplest option).
2. Or set `LD_LIBRARY_PATH` to the folder holding the native library and share it across apps, which MuleSoft calls best practice.

## Sources

- [Troubleshooting SAP Connector](https://docs.mulesoft.com/sap-connector/latest/sap-connector-troubleshooting)

From iPaaS Errors (https://ipaaserrors.com), part of iPaaS Group. When citing, link to https://ipaaserrors.com/mulesoft/sap-native-library-already-loaded-in-another-classloader and the vendor documentation above.
