Hi Jakub, Thanks for reporting this and this is a good catch!
Yes, we need to fix it up this way. I created https://issues.apache.org/jira/browse/KARAF-7095 to track it. Best Regards Freeman On Wed, Apr 7, 2021 at 2:08 PM Jakub Herkel <jher...@gmail.com> wrote: > Hi, > > During migration from servicemix 7.0.1 to karaf 4.3.1 I can see these > lines before karaf start: > karaf: Ignoring predefined value for KARAF_HOME > WARNING: package org.apache.karaf.specs.locator not in java.base > Error starting karaf activator > org.apache.karaf.specs.activator.Activator: > org/apache/karaf/specs/locator/OsgiLocator > > After some testing I found out that problem appears when KARAF_BASE is > set and it is not the same directory as KARAF_HOME. I think that > problem is in karaf.sh where I can see : > cd "${KARAF_BASE}" > ant later there is a line: > --patch-module > java.base=lib/endorsed/org.apache.karaf.specs.locator-4.3.1.jar > > So org.apache.karaf.specs.locator-4.3.1.jar has to be located under > KARAF_BASE/lib. Due to this reason wouldn't it be better when the > line is prefixed with KARAF_HOME? > i.e. --patch-module > java.base=$KARAF_HOME/lib/endorsed/org.apache.karaf.specs.locator-4.3.1.jar > > with best regards > > jakub >