-
Notifications
You must be signed in to change notification settings - Fork 216
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Using Docker images on Apple M1 #416
Comments
Preference would be to have a Multi-Architecture support or ability to configure the JDK |
@theyinyanguy It should be fixed in OpenJDK v17 but I have another error in version 18. Still investigating. Edit: v17 same error log openjdk v18
|
Thanks for your help @prokopsimek. Just to clarify openjdk v18 is the host JDK or the JDK in the docker image? Also did you update the docker file? |
@theyinyanguy the host openjdk v18 and I haven't updated Dockerfile and it could be probably next step. |
https://hub.docker.com/r/lahirulls/wso2apim-for-m1 This seems to work. |
With the #428 you should be able to use Ubuntu and CentOS images to build APIM 4.0.0 on arm64 devices as well. |
We have updated our Dockerfiles to support arm64 compatible JDKs. This will solve the issue of building the image on M1 based Macbooks. Furthermore, will be releasing an image which will support both amd64 and arm64 architecture. Please note that this image is for testing only, not for production use. |
Description:
I'm consuming these docker images on Apple macbook air which is based on Apple Silicon (ARM instruction set). When I use these images the apim container fails. I guess this is due to linux-amd64 JDK. Below is the error log.
Using the ARM based JDK should resolve this issue.
Start WSO2 Carbon server
JAVA_HOME environment variable is set to /opt/java/openjdk
CARBON_HOME environment variable is set to /home/wso2carbon/wso2am-4.0.0
Using Java memory options: -Xms256m -Xmx1024m
[2021-06-24 02:25:23,856] INFO {org.wso2.config.mapper.ConfigParser} - Initializing configurations with deployment configurations
andes [org.wso2.andes.wso2.internal.QpidBundleActivator] INFO : Setting BundleContext in PluginManager
callhome [org.wso2.carbon.callhome.internal.CallHomeActivator] DEBUG : Activating CallHome agent
org.ops4j.pax.logging.pax-logging-api [log4j2] ERROR : Unable to locate plugin type for PaxOsgi Ignored FQCN: org.apache.logging.log4j.spi.AbstractLogger
org.ops4j.pax.logging.pax-logging-api [log4j2] ERROR : Unable to locate plugin for PaxOsgi Ignored FQCN: org.apache.logging.log4j.spi.AbstractLogger
org.ops4j.pax.logging.pax-logging-api [log4j2] ERROR : Unable to invoke factory method in class org.apache.logging.log4j.core.config.AppendersPlugin for element Appenders: java.lang.NullPointerException Ignored FQCN: org.apache.logging.log4j.spi.AbstractLogger
java.lang.NullPointerException
at org.apache.logging.log4j.core.config.plugins.visitors.PluginElementVisitor.visit(PluginElementVisitor.java:52)
at org.apache.logging.log4j.core.config.plugins.util.PluginBuilder.generateParameters(PluginBuilder.java:258)
at org.apache.logging.log4j.core.config.plugins.util.PluginBuilder.build(PluginBuilder.java:135)
at org.apache.logging.log4j.core.config.AbstractConfiguration.createPluginObject(AbstractConfiguration.java:1002)
at org.apache.logging.log4j.core.config.AbstractConfiguration.createConfiguration(AbstractConfiguration.java:942)
at org.apache.logging.log4j.core.config.AbstractConfiguration.doConfigure(AbstractConfiguration.java:552)
at org.apache.logging.log4j.core.config.AbstractConfiguration.initialize(AbstractConfiguration.java:241)
at org.apache.logging.log4j.core.config.AbstractConfiguration.start(AbstractConfiguration.java:288)
at org.apache.logging.log4j.core.LoggerContext.setConfiguration(LoggerContext.java:579)
at org.apache.logging.log4j.core.LoggerContext.start(LoggerContext.java:285)
at org.ops4j.pax.logging.log4j2.internal.PaxLoggingServiceImpl.configureLog4J2(PaxLoggingServiceImpl.java:439)
at org.ops4j.pax.logging.log4j2.internal.PaxLoggingServiceImpl.updated(PaxLoggingServiceImpl.java:272)
at org.ops4j.pax.logging.log4j2.internal.Activator.start(Activator.java:120)
at org.eclipse.osgi.internal.framework.BundleContextImpl$3.run(BundleContextImpl.java:842)
at org.eclipse.osgi.internal.framework.BundleContextImpl$3.run(BundleContextImpl.java:1)
at java.base/java.security.AccessController.doPrivileged(Native Method)
at org.eclipse.osgi.internal.framework.BundleContextImpl.startActivator(BundleContextImpl.java:834)
at org.eclipse.osgi.internal.framework.BundleContextImpl.start(BundleContextImpl.java:791)
at org.eclipse.osgi.internal.framework.EquinoxBundle.startWorker0(EquinoxBundle.java:1013)
at org.eclipse.osgi.internal.framework.EquinoxBundle$EquinoxModule.startWorker(EquinoxBundle.java:365)
at org.eclipse.osgi.container.Module.doStart(Module.java:598)
at org.eclipse.osgi.container.Module.start(Module.java:462)
at org.eclipse.osgi.container.ModuleContainer$ContainerStartLevel$1.run(ModuleContainer.java:1820)
at org.eclipse.osgi.internal.framework.EquinoxContainerAdaptor$2$1.execute(EquinoxContainerAdaptor.java:150)
at org.eclipse.osgi.container.ModuleContainer$ContainerStartLevel.incStartLevel(ModuleContainer.java:1813)
at org.eclipse.osgi.container.ModuleContainer$ContainerStartLevel.incStartLevel(ModuleContainer.java:1770)
at org.eclipse.osgi.container.ModuleContainer$ContainerStartLevel.doContainerStartLevel(ModuleContainer.java:1735)
at org.eclipse.osgi.container.ModuleContainer$ContainerStartLevel.dispatchEvent(ModuleContainer.java:1661)
at org.eclipse.osgi.container.ModuleContainer$ContainerStartLevel.dispatchEvent(ModuleContainer.java:1)
at org.eclipse.osgi.framework.eventmgr.EventManager.dispatchEvent(EventManager.java:234)
at org.eclipse.osgi.framework.eventmgr.EventManager$EventThread.run(EventManager.java:345)
org.ops4j.pax.logging.pax-logging-api [log4j2] ERROR : Unable to locate appender "PaxOsgi" for logger config "root" Ignored FQCN: org.apache.logging.log4j.spi.AbstractLogger
org.ops4j.pax.logging.pax-logging-api [log4j2] ERROR : Unable to locate appender "CARBON_CONSOLE" for logger config "root" Ignored FQCN: org.apache.logging.log4j.spi.AbstractLogger
org.ops4j.pax.logging.pax-logging-api [log4j2] ERROR : Unable to locate appender "ERROR_LOGFILE" for logger config "root" Ignored FQCN: org.apache.logging.log4j.spi.AbstractLogger
org.ops4j.pax.logging.pax-logging-api [log4j2] ERROR : Unable to locate appender "CARBON_LOGFILE" for logger config "root" Ignored FQCN: org.apache.logging.log4j.spi.AbstractLogger
org.ops4j.pax.logging.pax-logging-api [log4j2] ERROR : Unable to locate appender "CARBON_TRACE_LOGFILE" for logger config "trace.messages" Ignored FQCN: org.apache.logging.log4j.spi.AbstractLogger
org.ops4j.pax.logging.pax-logging-api [log4j2] ERROR : Unable to locate appender "ATOMIKOS_LOGFILE" for logger config "com.atomikos" Ignored FQCN: org.apache.logging.log4j.spi.AbstractLogger
org.ops4j.pax.logging.pax-logging-api [log4j2] ERROR : Unable to locate appender "AUDIT_LOGFILE" for logger config "AUDIT_LOG" Ignored FQCN: org.apache.logging.log4j.spi.AbstractLogger
org.ops4j.pax.logging.pax-logging-api [log4j2] ERROR : Unable to locate appender "TRACE_APPENDER" for logger config "TRACE_LOGGER" Ignored FQCN: org.apache.logging.log4j.spi.AbstractLogger
org.ops4j.pax.logging.pax-logging-api [log4j2] ERROR : Unable to locate appender "CARBON_LOGFILE" for logger config "org.apache.axis2.wsdl.codegen.writer.PrettyPrinter" Ignored FQCN: org.apache.logging.log4j.spi.AbstractLogger
org.ops4j.pax.logging.pax-logging-api [log4j2] ERROR : Unable to locate appender "CORRELATION" for logger config "correlation" Ignored FQCN: org.apache.logging.log4j.spi.AbstractLogger
org.ops4j.pax.logging.pax-logging-api [log4j2] ERROR : Unable to locate appender "CARBON_LOGFILE" for logger config "org.apache.directory.shared.ldap.ldif.LdifReader" Ignored FQCN: org.apache.logging.log4j.spi.AbstractLogger
org.ops4j.pax.logging.pax-logging-api [log4j2] ERROR : Unable to locate appender "CARBON_LOGFILE" for logger config "org.apache.directory.shared.ldap" Ignored FQCN: org.apache.logging.log4j.spi.AbstractLogger
org.ops4j.pax.logging.pax-logging-api [log4j2] ERROR : Unable to locate appender "CARBON_LOGFILE" for logger config "org.apache.directory.server.ldap.LdapProtocolHandler" Ignored FQCN: org.apache.logging.log4j.spi.AbstractLogger
org.ops4j.pax.logging.pax-logging-api [log4j2] ERROR : Unable to locate appender "OPEN_TRACING" for logger config "trace" Ignored FQCN: org.apache.logging.log4j.spi.AbstractLogger
org.ops4j.pax.logging.pax-logging-api [log4j2] ERROR : Unable to locate appender "CARBON_LOGFILE" for logger config "org.apache.directory.shared.ldap.entry.DefaultServerAttribute" Ignored FQCN: org.apache.logging.log4j.spi.AbstractLogger
org.ops4j.pax.logging.pax-logging-api [log4j2] ERROR : Unable to locate appender "CARBON_LOGFILE" for logger config "org.apache.directory.server.ldap.handlers" Ignored FQCN: org.apache.logging.log4j.spi.AbstractLogger
org.ops4j.pax.logging.pax-logging-api [log4j2] ERROR : Unable to locate appender "SERVICE_APPENDER" for logger config "SERVICE_LOGGER" Ignored FQCN: org.apache.logging.log4j.spi.AbstractLogger
org.ops4j.pax.logging.pax-logging-api [log4j2] ERROR : Unable to locate appender "CARBON_LOGFILE" for logger config "org.apache.directory.server.ldap.LdapSession" Ignored FQCN: org.apache.logging.log4j.spi.AbstractLogger
org.ops4j.pax.logging.pax-logging-api [log4j2] ERROR : Unable to locate appender "CARBON_LOGFILE" for logger config "org.apache.directory.server.core" Ignored FQCN: org.apache.logging.log4j.spi.AbstractLogger
org.ops4j.pax.logging.pax-logging-api [log4j2] ERROR : Unable to locate appender "CARBON_LOGFILE" for logger config "org.apache.directory.server.core.DefaultDirectoryService" Ignored FQCN: org.apache.logging.log4j.spi.AbstractLogger
org.ops4j.pax.logging.pax-logging-api [log4j2] ERROR : Unable to locate appender "BOTDATA_APPENDER" for logger config "org.wso2.carbon.apimgt.gateway.mediators.BotDetectionMediator" Ignored FQCN: org.apache.logging.log4j.spi.AbstractLogger
org.ops4j.pax.logging.pax-logging-api [log4j2] ERROR : Unable to locate appender "CARBON_LOGFILE" for logger config "org.apache.axis2.enterprise" Ignored FQCN: org.apache.logging.log4j.spi.AbstractLogger
org.ops4j.pax.logging.pax-logging-api [log4j2] ERROR : Unable to locate plugin type for PaxOsgi Ignored FQCN: org.apache.logging.log4j.spi.AbstractLogger
org.ops4j.pax.logging.pax-logging-api [log4j2] ERROR : Unable to locate plugin for PaxOsgi Ignored FQCN: org.apache.logging.log4j.spi.AbstractLogger
org.ops4j.pax.logging.pax-logging-api [log4j2] ERROR : Unable to invoke factory method in class org.apache.logging.log4j.core.config.AppendersPlugin for element Appenders: java.lang.NullPointerException Ignored FQCN: org.apache.logging.log4j.spi.AbstractLogger
java.lang.NullPointerException
at org.apache.logging.log4j.core.config.plugins.visitors.PluginElementVisitor.visit(PluginElementVisitor.java:52)
at org.apache.logging.log4j.core.config.plugins.util.PluginBuilder.generateParameters(PluginBuilder.java:258)
at org.apache.logging.log4j.core.config.plugins.util.PluginBuilder.build(PluginBuilder.java:135)
at org.apache.logging.log4j.core.config.AbstractConfiguration.createPluginObject(AbstractConfiguration.java:1002)
at org.apache.logging.log4j.core.config.AbstractConfiguration.createConfiguration(AbstractConfiguration.java:942)
at org.apache.logging.log4j.core.config.AbstractConfiguration.doConfigure(AbstractConfiguration.java:552)
at org.apache.logging.log4j.core.config.AbstractConfiguration.initialize(AbstractConfiguration.java:241)
at org.apache.logging.log4j.core.config.AbstractConfiguration.start(AbstractConfiguration.java:288)
at org.apache.logging.log4j.core.LoggerContext.setConfiguration(LoggerContext.java:579)
at org.apache.logging.log4j.core.LoggerContext.start(LoggerContext.java:285)
at org.ops4j.pax.logging.log4j2.internal.PaxLoggingServiceImpl.configureLog4J2(PaxLoggingServiceImpl.java:439)
at org.ops4j.pax.logging.log4j2.internal.PaxLoggingServiceImpl.updated(PaxLoggingServiceImpl.java:272)
at org.ops4j.pax.logging.log4j2.internal.PaxLoggingServiceImpl$1ManagedPaxLoggingService.updated(PaxLoggingServiceImpl.java:581)
at org.eclipse.equinox.internal.cm.ManagedServiceTracker$1.run(ManagedServiceTracker.java:279)
at org.eclipse.equinox.internal.cm.SerializedTaskQueue$1.run(SerializedTaskQueue.java:40)
org.ops4j.pax.logging.pax-logging-api [log4j2] ERROR : Unable to locate appender "PaxOsgi" for logger config "root" Ignored FQCN: org.apache.logging.log4j.spi.AbstractLogger
org.ops4j.pax.logging.pax-logging-api [log4j2] ERROR : Unable to locate appender "CARBON_CONSOLE" for logger config "root" Ignored FQCN: org.apache.logging.log4j.spi.AbstractLogger
org.ops4j.pax.logging.pax-logging-api [log4j2] ERROR : Unable to locate appender "ERROR_LOGFILE" for logger config "root" Ignored FQCN: org.apache.logging.log4j.spi.AbstractLogger
org.ops4j.pax.logging.pax-logging-api [log4j2] ERROR : Unable to locate appender "CARBON_LOGFILE" for logger config "root" Ignored FQCN: org.apache.logging.log4j.spi.AbstractLogger
org.ops4j.pax.logging.pax-logging-api [log4j2] ERROR : Unable to locate appender "CARBON_TRACE_LOGFILE" for logger config "trace.messages" Ignored FQCN: org.apache.logging.log4j.spi.AbstractLogger
org.ops4j.pax.logging.pax-logging-api [log4j2] ERROR : Unable to locate appender "ATOMIKOS_LOGFILE" for logger config "com.atomikos" Ignored FQCN: org.apache.logging.log4j.spi.AbstractLogger
org.ops4j.pax.logging.pax-logging-api [log4j2] ERROR : Unable to locate appender "AUDIT_LOGFILE" for logger config "AUDIT_LOG" Ignored FQCN: org.apache.logging.log4j.spi.AbstractLogger
org.ops4j.pax.logging.pax-logging-api [log4j2] ERROR : Unable to locate appender "TRACE_APPENDER" for logger config "TRACE_LOGGER" Ignored FQCN: org.apache.logging.log4j.spi.AbstractLogger
org.ops4j.pax.logging.pax-logging-api [log4j2] ERROR : Unable to locate appender "CARBON_LOGFILE" for logger config "org.apache.axis2.wsdl.codegen.writer.PrettyPrinter" Ignored FQCN: org.apache.logging.log4j.spi.AbstractLogger
org.ops4j.pax.logging.pax-logging-api [log4j2] ERROR : Unable to locate appender "CORRELATION" for logger config "correlation" Ignored FQCN: org.apache.logging.log4j.spi.AbstractLogger
org.ops4j.pax.logging.pax-logging-api [log4j2] ERROR : Unable to locate appender "CARBON_LOGFILE" for logger config "org.apache.directory.shared.ldap.ldif.LdifReader" Ignored FQCN: org.apache.logging.log4j.spi.AbstractLogger
org.ops4j.pax.logging.pax-logging-api [log4j2] ERROR : Unable to locate appender "CARBON_LOGFILE" for logger config "org.apache.directory.shared.ldap" Ignored FQCN: org.apache.logging.log4j.spi.AbstractLogger
org.ops4j.pax.logging.pax-logging-api [log4j2] ERROR : Unable to locate appender "CARBON_LOGFILE" for logger config "org.apache.directory.server.ldap.LdapProtocolHandler" Ignored FQCN: org.apache.logging.log4j.spi.AbstractLogger
org.ops4j.pax.logging.pax-logging-api [log4j2] ERROR : Unable to locate appender "OPEN_TRACING" for logger config "trace" Ignored FQCN: org.apache.logging.log4j.spi.AbstractLogger
org.ops4j.pax.logging.pax-logging-api [log4j2] ERROR : Unable to locate appender "CARBON_LOGFILE" for logger config "org.apache.directory.shared.ldap.entry.DefaultServerAttribute" Ignored FQCN: org.apache.logging.log4j.spi.AbstractLogger
org.ops4j.pax.logging.pax-logging-api [log4j2] ERROR : Unable to locate appender "CARBON_LOGFILE" for logger config "org.apache.directory.server.ldap.handlers" Ignored FQCN: org.apache.logging.log4j.spi.AbstractLogger
org.ops4j.pax.logging.pax-logging-api [log4j2] ERROR : Unable to locate appender "SERVICE_APPENDER" for logger config "SERVICE_LOGGER" Ignored FQCN: org.apache.logging.log4j.spi.AbstractLogger
org.ops4j.pax.logging.pax-logging-api [log4j2] ERROR : Unable to locate appender "CARBON_LOGFILE" for logger config "org.apache.directory.server.ldap.LdapSession" Ignored FQCN: org.apache.logging.log4j.spi.AbstractLogger
org.ops4j.pax.logging.pax-logging-api [log4j2] ERROR : Unable to locate appender "CARBON_LOGFILE" for logger config "org.apache.directory.server.core" Ignored FQCN: org.apache.logging.log4j.spi.AbstractLogger
org.ops4j.pax.logging.pax-logging-api [log4j2] ERROR : Unable to locate appender "CARBON_LOGFILE" for logger config "org.apache.directory.server.core.DefaultDirectoryService" Ignored FQCN: org.apache.logging.log4j.spi.AbstractLogger
org.ops4j.pax.logging.pax-logging-api [log4j2] ERROR : Unable to locate appender "BOTDATA_APPENDER" for logger config "org.wso2.carbon.apimgt.gateway.mediators.BotDetectionMediator" Ignored FQCN: org.apache.logging.log4j.spi.AbstractLogger
org.ops4j.pax.logging.pax-logging-api [log4j2] ERROR : Unable to locate appender "CARBON_LOGFILE" for logger config "org.apache.axis2.enterprise" Ignored FQCN: org.apache.logging.log4j.spi.AbstractLogger
A fatal error has been detected by the Java Runtime Environment:
SIGSEGV (0xb) at pc=0x000000401d4b5801, pid=88, tid=129
JRE version: OpenJDK Runtime Environment AdoptOpenJDK-11.0.11+9 (11.0.11+9) (build 11.0.11+9)
Java VM: OpenJDK 64-Bit Server VM AdoptOpenJDK-11.0.11+9 (11.0.11+9, mixed mode, tiered, compressed oops, g1 gc, linux-amd64)
Problematic frame:
J 690 c1 java.util.Arrays$ArrayItr.next()Ljava/lang/Object; java.base@11.0.11 (36 bytes) @ 0x000000401d4b5801 [0x000000401d4b57e0+0x0000000000000021]
No core dump will be written. Core dumps have been disabled. To enable core dumping, try "ulimit -c unlimited" before starting Java again
An error report file with more information is saved as:
/home/wso2carbon/wso2am-4.0.0/hs_err_pid88.log
Compiled method (c1) 73474 690 3 java.util.Arrays$ArrayItr::next (36 bytes)
total in heap [0x000000401d4b5610,0x000000401d4b5a90] = 1152
relocation [0x000000401d4b5788,0x000000401d4b57c8] = 64
main code [0x000000401d4b57e0,0x000000401d4b5980] = 416
stub code [0x000000401d4b5980,0x000000401d4b59c0] = 64
metadata [0x000000401d4b59c0,0x000000401d4b59c8] = 8
scopes data [0x000000401d4b59c8,0x000000401d4b59f8] = 48
scopes pcs [0x000000401d4b59f8,0x000000401d4b5a78] = 128
dependencies [0x000000401d4b5a78,0x000000401d4b5a80] = 8
nul chk table [0x000000401d4b5a80,0x000000401d4b5a90] = 16
Could not load hsdis-amd64.so; library not loadable; PrintAssembly is disabled
If you would like to submit a bug report, please visit:
https://github.com/AdoptOpenJDK/openjdk-support/issues
qemu: uncaught target signal 6 (Aborted) - core dumped
Aborted
Suggested Labels:
Apple M1, ARM JDK
Suggested Assignees:
Affected Product Version:
docker-apim-4.0.0
OS, DB, other environment details and versions:
macOS Big Sur 11.4. Apple M1
Steps to reproduce:
docker-compose up --build
Related Issues:
The text was updated successfully, but these errors were encountered: