Re: Weird sshd-SshServer SSH2_DISCONNECT_PROTOCOL_ERROR - Detected AuthTimeout after messages

2021-05-06 Thread Jean-Baptiste Onofre
Hi Oleg,

Thanks for the update ;)

Regards
JB

> Le 6 mai 2021 à 18:01, Oleg Cohen  a écrit :
> 
> Hi JB,
> 
> Definitely my problem :-) Was able to figure it out. Wrong port for the POD 
> monitoring.
> 
> Thank you!
> Oleg
> 
>> On May 6, 2021, at 10:24 AM, Oleg Cohen  wrote:
>> 
>> Hi JB,
>> 
>> I didn’t install anything specific. No Decanter. Is there a way to trace and 
>> see where the SSH requests are coming from?
>> 
>> Thank you!
>> Oleg
>> 
>>> On May 6, 2021, at 10:10 AM, Jean-Baptiste Onofre  wrote:
>>> 
>>> Hi Oleg,
>>> 
>>> Maybe you have a monitoring solution (as Decanter) that pull the MBean, and 
>>> so perform ssh connection when listing the instances in the InstanceMBean.
>>> 
>>> It seems that something tries a ssh connect ;)
>>> 
>>> Regards
>>> JB
>>> 
 Le 6 mai 2021 à 15:53, Oleg Cohen  a écrit :
 
 Greetings,
 
 I started a new karat instance in a Kubernetes pod from a custom distro.
 
 I am seeing the following set of messages in the log every few seconds. 
 
 2021-05-06T13:49:30,946 | INFO  | 
 sshd-SshServer[7467ccad](port=8101)-timer-thread-1 | ServerSessionImpl 
| 309 - org.apache.sshd.osgi - 2.5.1 | 
 Disconnecting(ServerSessionImpl[null@/169.254.175.250:49648]): 
 SSH2_DISCONNECT_PROTOCOL_ERROR - Detected AuthTimeout after 120034/12 
 ms.
 2021-05-06T13:49:30,946 | WARN  | 
 sshd-SshServer[7467ccad](port=8101)-timer-thread-1 | ServerSessionImpl 
| 309 - org.apache.sshd.osgi - 2.5.1 | 
 disconnect(ServerSessionImpl[null@/169.254.175.250:49648]) operation 
 failed (IOException) for reason=SSH2_DISCONNECT_PROTOCOL_ERROR [Detected 
 AuthTimeout after 120034/12 ms.]: Broken pipe
 2021-05-06T13:49:30,946 | WARN  | 
 sshd-SshServer[7467ccad](port=8101)-nio2-thread-2 | ServerSessionImpl  
   | 309 - org.apache.sshd.osgi - 2.5.1 | 
 exceptionCaught(ServerSessionImpl[null@/169.254.175.250:49648])[state=Opened]
  IOException: Broken pipe
 
 The pod is completely isolated.
 
 Wonder if anybody has encountered this behavior before?
 
 Thank you!
 Oleg
>>> 
>> 
> 



Re: Karaf is not finding org.osgi.util.function and fails to start

2021-05-06 Thread Jean-Baptiste Onofre
Hi Alex,

Yes, the version is not correct. I would check your feature / pom.xml, maybe 
you don’t have version defined, so it takes the latest one.

Regards
JB

> Le 6 mai 2021 à 18:56, Alex Soto  a écrit :
> 
> 
> I see…  
> 
> Karaf is looking for wrap version 2.6.7, but the version the  framework 
> feature brings  is version is 2.6.2, so it does not find it.
> However, I don’t know who is pulling version 2.6.7.  Will search for that...
> 
> Best regards,
> Alex soto
> 
> 
> 
> 
>> On May 6, 2021, at 10:15 AM, Alex Soto > > wrote:
>> 
>> Thanks, JB, 
>> 
>> but I don’t understand.  When I inspect my 
>> /etc/org.apache.karaf.features.cfg  file:
>> 
>> #
>> # Comma separated list of features repositories to register by default
>> #
>> featuresRepositories = \
>> mvn:org.apache.karaf.features/standard/4.3.0/xml/features, \
>> mvn:org.apache.karaf.features/framework/4.3.0/xml/features, ...
>> 
>> #
>> # Comma separated list of features to install at startup
>> #
>> featuresBoot = \
>> (wrap), \
>> package/4.3.1, \
>> log/4.3.1, \
>> ssh/4.3.1, \
>> framework/4.3.0, \
>> system/4.3.1, \
>>  ...
>> 
>> 
>> 
>> The framework feature is there.
>> 
>> Also there is the jar:  
>> /system/org/osgi/org.osgi.util.function/1.0.0/org.osgi.util.function-1.0.0.jar
>>  
>> 
>> So, what do I need to do?
>> 
>> Best regards,
>> Alex soto
>> 
>> 
>> 
>> 
>>> On May 6, 2021, at 9:59 AM, Jean-Baptiste Onofre >> > wrote:
>>> 
>>> Hi,
>>> 
>>> osgi.function is part of the framework feature:
>>> 
>>> https://github.com/apache/karaf/blob/main/assemblies/features/framework/src/main/feature/feature.xml#L34
>>>  
>>> 
>>> 
>>> That’s for Karaf 4.3.1/4.3.2.
>>> 
>>> For 4.3.0, it’s there but in version 1.0.0:
>>> 
>>> https://repo1.maven.org/maven2/org/apache/karaf/features/framework/4.3.0/framework-4.3.0-features.xml
>>>  
>>> 
>>> 
>>> Regards
>>> JB
>>> 
 Le 6 mai 2021 à 17:36, Alex Soto >>> > a écrit :
 
 Hello,
 
 Using a custom distribution, based on  Karaf version 4.3.0, I am getting 
 the following error, and Karaf would not start:
 
 
 $ bin/karaf 
 org.apache.felix.resolver.reason.ReasonException: Unable to resolve root: 
 missing requirement [root] osgi.identity; osgi.identity=wrap; 
 type=karaf.feature; version="[2.6.7,2.6.7]"; 
 filter:="(&(osgi.identity=wrap)(type=karaf.feature)(version>=2.6.7)(version<=2.6.7))"
  [caused by: Unable to resolve wrap/2.6.7: missing requirement 
 [wrap/2.6.7] osgi.identity; osgi.identity=pax-url-wrap; 
 type=karaf.feature; version="[2.6.7,2.6.7]" [caused by: Unable to resolve 
 pax-url-wrap/2.6.7: missing requirement [pax-url-wrap/2.6.7] 
 osgi.identity; osgi.identity=org.ops4j.pax.url.wrap; type=osgi.bundle; 
 version="[2.6.7,2.6.7]"; resolution:=mandatory [caused by: Unable to 
 resolve org.ops4j.pax.url.wrap/2.6.7: missing requirement 
 [org.ops4j.pax.url.wrap/2.6.7] osgi.wiring.package; 
 filter:="(&(osgi.wiring.package=org.osgi.util.function)(version>=1.1.0)(!(version>=2.0.0)))"]]]
at 
 org.apache.felix.resolver.Candidates$MissingRequirementError.toException(Candidates.java:1341)
at 
 org.apache.felix.resolver.ResolverImpl.doResolve(ResolverImpl.java:434)
at org.apache.felix.resolver.ResolverImpl.resolve(ResolverImpl.java:421)
at org.apache.felix.resolver.ResolverImpl.resolve(ResolverImpl.java:375)
at 
 org.apache.karaf.features.internal.region.SubsystemResolver.resolve(SubsystemResolver.java:257)
at 
 org.apache.karaf.features.internal.service.Deployer.deploy(Deployer.java:392)
at 
 org.apache.karaf.features.internal.service.FeaturesServiceImpl.doProvision(FeaturesServiceImpl.java:1062)
at 
 org.apache.karaf.features.internal.service.FeaturesServiceImpl.lambda$doProvisionInThread$13(FeaturesServiceImpl.java:998)
at java.base/java.util.concurrent.FutureTask.run(FutureTask.java:264)
at 
 java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1128)
at 
 java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:628)
at java.base/java.lang.Thread.run(Thread.java:829)
 Caused by: org.apache.felix.resolver.reason.ReasonException: Unable to 
 resolve wrap/2.6.7: missing requirement [wrap/2.6.7] osgi.identity; 
 osgi.identity=pax-url-wrap; type=karaf.feature; version="[2.6.7,2.6.7]" 
 [caused by: Unable to resolve pax-url-wrap/2.6.7: missing requirement 
 [pax-url-wrap/2.6.7] osgi.identity; osgi.identity=org.ops4j.pax.url.wrap; 
 type=osgi.bundle; version="[2.6.7,2.6.7]"; 

Re: Karaf is not finding org.osgi.util.function and fails to start

2021-05-06 Thread Alex Soto

I see…  

Karaf is looking for wrap version 2.6.7, but the version the  framework feature 
brings  is version is 2.6.2, so it does not find it.
However, I don’t know who is pulling version 2.6.7.  Will search for that...

Best regards,
Alex soto




> On May 6, 2021, at 10:15 AM, Alex Soto  wrote:
> 
> Thanks, JB, 
> 
> but I don’t understand.  When I inspect my /etc/org.apache.karaf.features.cfg 
>  file:
> 
> #
> # Comma separated list of features repositories to register by default
> #
> featuresRepositories = \
> mvn:org.apache.karaf.features/standard/4.3.0/xml/features, \
> mvn:org.apache.karaf.features/framework/4.3.0/xml/features, ...
> 
> #
> # Comma separated list of features to install at startup
> #
> featuresBoot = \
> (wrap), \
> package/4.3.1, \
> log/4.3.1, \
> ssh/4.3.1, \
> framework/4.3.0, \
> system/4.3.1, \
>   ...
> 
> 
> 
> The framework feature is there.
> 
> Also there is the jar:  
> /system/org/osgi/org.osgi.util.function/1.0.0/org.osgi.util.function-1.0.0.jar
>  
> 
> So, what do I need to do?
> 
> Best regards,
> Alex soto
> 
> 
> 
> 
>> On May 6, 2021, at 9:59 AM, Jean-Baptiste Onofre > > wrote:
>> 
>> Hi,
>> 
>> osgi.function is part of the framework feature:
>> 
>> https://github.com/apache/karaf/blob/main/assemblies/features/framework/src/main/feature/feature.xml#L34
>>  
>> 
>> 
>> That’s for Karaf 4.3.1/4.3.2.
>> 
>> For 4.3.0, it’s there but in version 1.0.0:
>> 
>> https://repo1.maven.org/maven2/org/apache/karaf/features/framework/4.3.0/framework-4.3.0-features.xml
>>  
>> 
>> 
>> Regards
>> JB
>> 
>>> Le 6 mai 2021 à 17:36, Alex Soto >> > a écrit :
>>> 
>>> Hello,
>>> 
>>> Using a custom distribution, based on  Karaf version 4.3.0, I am getting 
>>> the following error, and Karaf would not start:
>>> 
>>> 
>>> $ bin/karaf 
>>> org.apache.felix.resolver.reason.ReasonException: Unable to resolve root: 
>>> missing requirement [root] osgi.identity; osgi.identity=wrap; 
>>> type=karaf.feature; version="[2.6.7,2.6.7]"; 
>>> filter:="(&(osgi.identity=wrap)(type=karaf.feature)(version>=2.6.7)(version<=2.6.7))"
>>>  [caused by: Unable to resolve wrap/2.6.7: missing requirement [wrap/2.6.7] 
>>> osgi.identity; osgi.identity=pax-url-wrap; type=karaf.feature; 
>>> version="[2.6.7,2.6.7]" [caused by: Unable to resolve pax-url-wrap/2.6.7: 
>>> missing requirement [pax-url-wrap/2.6.7] osgi.identity; 
>>> osgi.identity=org.ops4j.pax.url.wrap; type=osgi.bundle; 
>>> version="[2.6.7,2.6.7]"; resolution:=mandatory [caused by: Unable to 
>>> resolve org.ops4j.pax.url.wrap/2.6.7: missing requirement 
>>> [org.ops4j.pax.url.wrap/2.6.7] osgi.wiring.package; 
>>> filter:="(&(osgi.wiring.package=org.osgi.util.function)(version>=1.1.0)(!(version>=2.0.0)))"]]]
>>> at 
>>> org.apache.felix.resolver.Candidates$MissingRequirementError.toException(Candidates.java:1341)
>>> at 
>>> org.apache.felix.resolver.ResolverImpl.doResolve(ResolverImpl.java:434)
>>> at org.apache.felix.resolver.ResolverImpl.resolve(ResolverImpl.java:421)
>>> at org.apache.felix.resolver.ResolverImpl.resolve(ResolverImpl.java:375)
>>> at 
>>> org.apache.karaf.features.internal.region.SubsystemResolver.resolve(SubsystemResolver.java:257)
>>> at 
>>> org.apache.karaf.features.internal.service.Deployer.deploy(Deployer.java:392)
>>> at 
>>> org.apache.karaf.features.internal.service.FeaturesServiceImpl.doProvision(FeaturesServiceImpl.java:1062)
>>> at 
>>> org.apache.karaf.features.internal.service.FeaturesServiceImpl.lambda$doProvisionInThread$13(FeaturesServiceImpl.java:998)
>>> at java.base/java.util.concurrent.FutureTask.run(FutureTask.java:264)
>>> at 
>>> java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1128)
>>> at 
>>> java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:628)
>>> at java.base/java.lang.Thread.run(Thread.java:829)
>>> Caused by: org.apache.felix.resolver.reason.ReasonException: Unable to 
>>> resolve wrap/2.6.7: missing requirement [wrap/2.6.7] osgi.identity; 
>>> osgi.identity=pax-url-wrap; type=karaf.feature; version="[2.6.7,2.6.7]" 
>>> [caused by: Unable to resolve pax-url-wrap/2.6.7: missing requirement 
>>> [pax-url-wrap/2.6.7] osgi.identity; osgi.identity=org.ops4j.pax.url.wrap; 
>>> type=osgi.bundle; version="[2.6.7,2.6.7]"; resolution:=mandatory [caused 
>>> by: Unable to resolve org.ops4j.pax.url.wrap/2.6.7: missing requirement 
>>> [org.ops4j.pax.url.wrap/2.6.7] osgi.wiring.package; 
>>> filter:="(&(osgi.wiring.package=org.osgi.util.function)(version>=1.1.0)(!(version>=2.0.0)))"]]
>>> at 
>>> 

Re: Karaf is not finding org.osgi.util.function and fails to start

2021-05-06 Thread Alex Soto
Thanks, JB, 

but I don’t understand.  When I inspect my /etc/org.apache.karaf.features.cfg  
file:

#
# Comma separated list of features repositories to register by default
#
featuresRepositories = \
mvn:org.apache.karaf.features/standard/4.3.0/xml/features, \
mvn:org.apache.karaf.features/framework/4.3.0/xml/features, ...

#
# Comma separated list of features to install at startup
#
featuresBoot = \
(wrap), \
package/4.3.1, \
log/4.3.1, \
ssh/4.3.1, \
framework/4.3.0, \
system/4.3.1, \
...



The framework feature is there.

Also there is the jar:  
/system/org/osgi/org.osgi.util.function/1.0.0/org.osgi.util.function-1.0.0.jar 

So, what do I need to do?

Best regards,
Alex soto




> On May 6, 2021, at 9:59 AM, Jean-Baptiste Onofre  wrote:
> 
> Hi,
> 
> osgi.function is part of the framework feature:
> 
> https://github.com/apache/karaf/blob/main/assemblies/features/framework/src/main/feature/feature.xml#L34
>  
> 
> 
> That’s for Karaf 4.3.1/4.3.2.
> 
> For 4.3.0, it’s there but in version 1.0.0:
> 
> https://repo1.maven.org/maven2/org/apache/karaf/features/framework/4.3.0/framework-4.3.0-features.xml
>  
> 
> 
> Regards
> JB
> 
>> Le 6 mai 2021 à 17:36, Alex Soto > > a écrit :
>> 
>> Hello,
>> 
>> Using a custom distribution, based on  Karaf version 4.3.0, I am getting the 
>> following error, and Karaf would not start:
>> 
>> 
>> $ bin/karaf 
>> org.apache.felix.resolver.reason.ReasonException: Unable to resolve root: 
>> missing requirement [root] osgi.identity; osgi.identity=wrap; 
>> type=karaf.feature; version="[2.6.7,2.6.7]"; 
>> filter:="(&(osgi.identity=wrap)(type=karaf.feature)(version>=2.6.7)(version<=2.6.7))"
>>  [caused by: Unable to resolve wrap/2.6.7: missing requirement [wrap/2.6.7] 
>> osgi.identity; osgi.identity=pax-url-wrap; type=karaf.feature; 
>> version="[2.6.7,2.6.7]" [caused by: Unable to resolve pax-url-wrap/2.6.7: 
>> missing requirement [pax-url-wrap/2.6.7] osgi.identity; 
>> osgi.identity=org.ops4j.pax.url.wrap; type=osgi.bundle; 
>> version="[2.6.7,2.6.7]"; resolution:=mandatory [caused by: Unable to resolve 
>> org.ops4j.pax.url.wrap/2.6.7: missing requirement 
>> [org.ops4j.pax.url.wrap/2.6.7] osgi.wiring.package; 
>> filter:="(&(osgi.wiring.package=org.osgi.util.function)(version>=1.1.0)(!(version>=2.0.0)))"]]]
>>  at 
>> org.apache.felix.resolver.Candidates$MissingRequirementError.toException(Candidates.java:1341)
>>  at 
>> org.apache.felix.resolver.ResolverImpl.doResolve(ResolverImpl.java:434)
>>  at org.apache.felix.resolver.ResolverImpl.resolve(ResolverImpl.java:421)
>>  at org.apache.felix.resolver.ResolverImpl.resolve(ResolverImpl.java:375)
>>  at 
>> org.apache.karaf.features.internal.region.SubsystemResolver.resolve(SubsystemResolver.java:257)
>>  at 
>> org.apache.karaf.features.internal.service.Deployer.deploy(Deployer.java:392)
>>  at 
>> org.apache.karaf.features.internal.service.FeaturesServiceImpl.doProvision(FeaturesServiceImpl.java:1062)
>>  at 
>> org.apache.karaf.features.internal.service.FeaturesServiceImpl.lambda$doProvisionInThread$13(FeaturesServiceImpl.java:998)
>>  at java.base/java.util.concurrent.FutureTask.run(FutureTask.java:264)
>>  at 
>> java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1128)
>>  at 
>> java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:628)
>>  at java.base/java.lang.Thread.run(Thread.java:829)
>> Caused by: org.apache.felix.resolver.reason.ReasonException: Unable to 
>> resolve wrap/2.6.7: missing requirement [wrap/2.6.7] osgi.identity; 
>> osgi.identity=pax-url-wrap; type=karaf.feature; version="[2.6.7,2.6.7]" 
>> [caused by: Unable to resolve pax-url-wrap/2.6.7: missing requirement 
>> [pax-url-wrap/2.6.7] osgi.identity; osgi.identity=org.ops4j.pax.url.wrap; 
>> type=osgi.bundle; version="[2.6.7,2.6.7]"; resolution:=mandatory [caused by: 
>> Unable to resolve org.ops4j.pax.url.wrap/2.6.7: missing requirement 
>> [org.ops4j.pax.url.wrap/2.6.7] osgi.wiring.package; 
>> filter:="(&(osgi.wiring.package=org.osgi.util.function)(version>=1.1.0)(!(version>=2.0.0)))"]]
>>  at 
>> org.apache.felix.resolver.Candidates$MissingRequirementError.toException(Candidates.java:1341)
>>  ... 12 more
>> Caused by: org.apache.felix.resolver.reason.ReasonException: Unable to 
>> resolve pax-url-wrap/2.6.7: missing requirement [pax-url-wrap/2.6.7] 
>> osgi.identity; osgi.identity=org.ops4j.pax.url.wrap; type=osgi.bundle; 
>> version="[2.6.7,2.6.7]"; resolution:=mandatory [caused by: Unable to resolve 
>> org.ops4j.pax.url.wrap/2.6.7: missing requirement 
>> [org.ops4j.pax.url.wrap/2.6.7] osgi.wiring.package; 
>> 

Re: Weird sshd-SshServer SSH2_DISCONNECT_PROTOCOL_ERROR - Detected AuthTimeout after messages

2021-05-06 Thread Oleg Cohen
Hi JB,

Definitely my problem :-) Was able to figure it out. Wrong port for the POD 
monitoring.

Thank you!
Oleg

> On May 6, 2021, at 10:24 AM, Oleg Cohen  wrote:
> 
> Hi JB,
> 
> I didn’t install anything specific. No Decanter. Is there a way to trace and 
> see where the SSH requests are coming from?
> 
> Thank you!
> Oleg
> 
>> On May 6, 2021, at 10:10 AM, Jean-Baptiste Onofre  wrote:
>> 
>> Hi Oleg,
>> 
>> Maybe you have a monitoring solution (as Decanter) that pull the MBean, and 
>> so perform ssh connection when listing the instances in the InstanceMBean.
>> 
>> It seems that something tries a ssh connect ;)
>> 
>> Regards
>> JB
>> 
>>> Le 6 mai 2021 à 15:53, Oleg Cohen  a écrit :
>>> 
>>> Greetings,
>>> 
>>> I started a new karat instance in a Kubernetes pod from a custom distro.
>>> 
>>> I am seeing the following set of messages in the log every few seconds. 
>>> 
>>> 2021-05-06T13:49:30,946 | INFO  | 
>>> sshd-SshServer[7467ccad](port=8101)-timer-thread-1 | ServerSessionImpl  
>>>   | 309 - org.apache.sshd.osgi - 2.5.1 | 
>>> Disconnecting(ServerSessionImpl[null@/169.254.175.250:49648]): 
>>> SSH2_DISCONNECT_PROTOCOL_ERROR - Detected AuthTimeout after 120034/12 
>>> ms.
>>> 2021-05-06T13:49:30,946 | WARN  | 
>>> sshd-SshServer[7467ccad](port=8101)-timer-thread-1 | ServerSessionImpl  
>>>   | 309 - org.apache.sshd.osgi - 2.5.1 | 
>>> disconnect(ServerSessionImpl[null@/169.254.175.250:49648]) operation failed 
>>> (IOException) for reason=SSH2_DISCONNECT_PROTOCOL_ERROR [Detected 
>>> AuthTimeout after 120034/12 ms.]: Broken pipe
>>> 2021-05-06T13:49:30,946 | WARN  | 
>>> sshd-SshServer[7467ccad](port=8101)-nio2-thread-2 | ServerSessionImpl   
>>>  | 309 - org.apache.sshd.osgi - 2.5.1 | 
>>> exceptionCaught(ServerSessionImpl[null@/169.254.175.250:49648])[state=Opened]
>>>  IOException: Broken pipe
>>> 
>>> The pod is completely isolated.
>>> 
>>> Wonder if anybody has encountered this behavior before?
>>> 
>>> Thank you!
>>> Oleg
>> 
> 



Re: Karaf is not finding org.osgi.util.function and fails to start

2021-05-06 Thread Jean-Baptiste Onofre
Hi,

osgi.function is part of the framework feature:

https://github.com/apache/karaf/blob/main/assemblies/features/framework/src/main/feature/feature.xml#L34
 


That’s for Karaf 4.3.1/4.3.2.

For 4.3.0, it’s there but in version 1.0.0:

https://repo1.maven.org/maven2/org/apache/karaf/features/framework/4.3.0/framework-4.3.0-features.xml
 


Regards
JB

> Le 6 mai 2021 à 17:36, Alex Soto  a écrit :
> 
> Hello,
> 
> Using a custom distribution, based on  Karaf version 4.3.0, I am getting the 
> following error, and Karaf would not start:
> 
> 
> $ bin/karaf 
> org.apache.felix.resolver.reason.ReasonException: Unable to resolve root: 
> missing requirement [root] osgi.identity; osgi.identity=wrap; 
> type=karaf.feature; version="[2.6.7,2.6.7]"; 
> filter:="(&(osgi.identity=wrap)(type=karaf.feature)(version>=2.6.7)(version<=2.6.7))"
>  [caused by: Unable to resolve wrap/2.6.7: missing requirement [wrap/2.6.7] 
> osgi.identity; osgi.identity=pax-url-wrap; type=karaf.feature; 
> version="[2.6.7,2.6.7]" [caused by: Unable to resolve pax-url-wrap/2.6.7: 
> missing requirement [pax-url-wrap/2.6.7] osgi.identity; 
> osgi.identity=org.ops4j.pax.url.wrap; type=osgi.bundle; 
> version="[2.6.7,2.6.7]"; resolution:=mandatory [caused by: Unable to resolve 
> org.ops4j.pax.url.wrap/2.6.7: missing requirement 
> [org.ops4j.pax.url.wrap/2.6.7] osgi.wiring.package; 
> filter:="(&(osgi.wiring.package=org.osgi.util.function)(version>=1.1.0)(!(version>=2.0.0)))"]]]
>   at 
> org.apache.felix.resolver.Candidates$MissingRequirementError.toException(Candidates.java:1341)
>   at 
> org.apache.felix.resolver.ResolverImpl.doResolve(ResolverImpl.java:434)
>   at org.apache.felix.resolver.ResolverImpl.resolve(ResolverImpl.java:421)
>   at org.apache.felix.resolver.ResolverImpl.resolve(ResolverImpl.java:375)
>   at 
> org.apache.karaf.features.internal.region.SubsystemResolver.resolve(SubsystemResolver.java:257)
>   at 
> org.apache.karaf.features.internal.service.Deployer.deploy(Deployer.java:392)
>   at 
> org.apache.karaf.features.internal.service.FeaturesServiceImpl.doProvision(FeaturesServiceImpl.java:1062)
>   at 
> org.apache.karaf.features.internal.service.FeaturesServiceImpl.lambda$doProvisionInThread$13(FeaturesServiceImpl.java:998)
>   at java.base/java.util.concurrent.FutureTask.run(FutureTask.java:264)
>   at 
> java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1128)
>   at 
> java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:628)
>   at java.base/java.lang.Thread.run(Thread.java:829)
> Caused by: org.apache.felix.resolver.reason.ReasonException: Unable to 
> resolve wrap/2.6.7: missing requirement [wrap/2.6.7] osgi.identity; 
> osgi.identity=pax-url-wrap; type=karaf.feature; version="[2.6.7,2.6.7]" 
> [caused by: Unable to resolve pax-url-wrap/2.6.7: missing requirement 
> [pax-url-wrap/2.6.7] osgi.identity; osgi.identity=org.ops4j.pax.url.wrap; 
> type=osgi.bundle; version="[2.6.7,2.6.7]"; resolution:=mandatory [caused by: 
> Unable to resolve org.ops4j.pax.url.wrap/2.6.7: missing requirement 
> [org.ops4j.pax.url.wrap/2.6.7] osgi.wiring.package; 
> filter:="(&(osgi.wiring.package=org.osgi.util.function)(version>=1.1.0)(!(version>=2.0.0)))"]]
>   at 
> org.apache.felix.resolver.Candidates$MissingRequirementError.toException(Candidates.java:1341)
>   ... 12 more
> Caused by: org.apache.felix.resolver.reason.ReasonException: Unable to 
> resolve pax-url-wrap/2.6.7: missing requirement [pax-url-wrap/2.6.7] 
> osgi.identity; osgi.identity=org.ops4j.pax.url.wrap; type=osgi.bundle; 
> version="[2.6.7,2.6.7]"; resolution:=mandatory [caused by: Unable to resolve 
> org.ops4j.pax.url.wrap/2.6.7: missing requirement 
> [org.ops4j.pax.url.wrap/2.6.7] osgi.wiring.package; 
> filter:="(&(osgi.wiring.package=org.osgi.util.function)(version>=1.1.0)(!(version>=2.0.0)))"]
>   at 
> org.apache.felix.resolver.Candidates$MissingRequirementError.toException(Candidates.java:1341)
>   ... 13 more
> Caused by: org.apache.felix.resolver.reason.ReasonException: Unable to 
> resolve org.ops4j.pax.url.wrap/2.6.7: missing requirement 
> [org.ops4j.pax.url.wrap/2.6.7] osgi.wiring.package; 
> filter:="(&(osgi.wiring.package=org.osgi.util.function)(version>=1.1.0)(!(version>=2.0.0)))"
>   at 
> org.apache.felix.resolver.Candidates$MissingRequirementError.toException(Candidates.java:1341)
>   ... 14 more
> 
> 
> 
> Java version is:  openjdk version "11.0.11" 2021-04-20 LTS
> OS:  Linux version 3.10.0-1127.el7.x86_64 (mockbu...@kbuilder.bsys.centos.org 
> ) (gcc version 4.8.5 20150623 (Red 
> Hat 4.8.5-39) (GCC) ) #1 SMP Tue Mar 31 23:36:51 UTC 2020
> 
> 
> I have 

Karaf is not finding org.osgi.util.function and fails to start

2021-05-06 Thread Alex Soto
Hello,

Using a custom distribution, based on  Karaf version 4.3.0, I am getting the 
following error, and Karaf would not start:


$ bin/karaf 
org.apache.felix.resolver.reason.ReasonException: Unable to resolve root: 
missing requirement [root] osgi.identity; osgi.identity=wrap; 
type=karaf.feature; version="[2.6.7,2.6.7]"; 
filter:="(&(osgi.identity=wrap)(type=karaf.feature)(version>=2.6.7)(version<=2.6.7))"
 [caused by: Unable to resolve wrap/2.6.7: missing requirement [wrap/2.6.7] 
osgi.identity; osgi.identity=pax-url-wrap; type=karaf.feature; 
version="[2.6.7,2.6.7]" [caused by: Unable to resolve pax-url-wrap/2.6.7: 
missing requirement [pax-url-wrap/2.6.7] osgi.identity; 
osgi.identity=org.ops4j.pax.url.wrap; type=osgi.bundle; 
version="[2.6.7,2.6.7]"; resolution:=mandatory [caused by: Unable to resolve 
org.ops4j.pax.url.wrap/2.6.7: missing requirement 
[org.ops4j.pax.url.wrap/2.6.7] osgi.wiring.package; 
filter:="(&(osgi.wiring.package=org.osgi.util.function)(version>=1.1.0)(!(version>=2.0.0)))"]]]
at 
org.apache.felix.resolver.Candidates$MissingRequirementError.toException(Candidates.java:1341)
at 
org.apache.felix.resolver.ResolverImpl.doResolve(ResolverImpl.java:434)
at org.apache.felix.resolver.ResolverImpl.resolve(ResolverImpl.java:421)
at org.apache.felix.resolver.ResolverImpl.resolve(ResolverImpl.java:375)
at 
org.apache.karaf.features.internal.region.SubsystemResolver.resolve(SubsystemResolver.java:257)
at 
org.apache.karaf.features.internal.service.Deployer.deploy(Deployer.java:392)
at 
org.apache.karaf.features.internal.service.FeaturesServiceImpl.doProvision(FeaturesServiceImpl.java:1062)
at 
org.apache.karaf.features.internal.service.FeaturesServiceImpl.lambda$doProvisionInThread$13(FeaturesServiceImpl.java:998)
at java.base/java.util.concurrent.FutureTask.run(FutureTask.java:264)
at 
java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1128)
at 
java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:628)
at java.base/java.lang.Thread.run(Thread.java:829)
Caused by: org.apache.felix.resolver.reason.ReasonException: Unable to resolve 
wrap/2.6.7: missing requirement [wrap/2.6.7] osgi.identity; 
osgi.identity=pax-url-wrap; type=karaf.feature; version="[2.6.7,2.6.7]" [caused 
by: Unable to resolve pax-url-wrap/2.6.7: missing requirement 
[pax-url-wrap/2.6.7] osgi.identity; osgi.identity=org.ops4j.pax.url.wrap; 
type=osgi.bundle; version="[2.6.7,2.6.7]"; resolution:=mandatory [caused by: 
Unable to resolve org.ops4j.pax.url.wrap/2.6.7: missing requirement 
[org.ops4j.pax.url.wrap/2.6.7] osgi.wiring.package; 
filter:="(&(osgi.wiring.package=org.osgi.util.function)(version>=1.1.0)(!(version>=2.0.0)))"]]
at 
org.apache.felix.resolver.Candidates$MissingRequirementError.toException(Candidates.java:1341)
... 12 more
Caused by: org.apache.felix.resolver.reason.ReasonException: Unable to resolve 
pax-url-wrap/2.6.7: missing requirement [pax-url-wrap/2.6.7] osgi.identity; 
osgi.identity=org.ops4j.pax.url.wrap; type=osgi.bundle; 
version="[2.6.7,2.6.7]"; resolution:=mandatory [caused by: Unable to resolve 
org.ops4j.pax.url.wrap/2.6.7: missing requirement 
[org.ops4j.pax.url.wrap/2.6.7] osgi.wiring.package; 
filter:="(&(osgi.wiring.package=org.osgi.util.function)(version>=1.1.0)(!(version>=2.0.0)))"]
at 
org.apache.felix.resolver.Candidates$MissingRequirementError.toException(Candidates.java:1341)
... 13 more
Caused by: org.apache.felix.resolver.reason.ReasonException: Unable to resolve 
org.ops4j.pax.url.wrap/2.6.7: missing requirement 
[org.ops4j.pax.url.wrap/2.6.7] osgi.wiring.package; 
filter:="(&(osgi.wiring.package=org.osgi.util.function)(version>=1.1.0)(!(version>=2.0.0)))"
at 
org.apache.felix.resolver.Candidates$MissingRequirementError.toException(Candidates.java:1341)
... 14 more



Java version is:  openjdk version "11.0.11" 2021-04-20 LTS
OS:  Linux version 3.10.0-1127.el7.x86_64 (mockbu...@kbuilder.bsys.centos.org) 
(gcc version 4.8.5 20150623 (Red Hat 4.8.5-39) (GCC) ) #1 SMP Tue Mar 31 
23:36:51 UTC 2020


I have verified the required jar is present:

$ ls -l system/org/osgi/org.osgi.util.function/1.1.0/
total 16
-rw-r--r--. 1 vagrant vagrant 14053 May  6 14:49 
org.osgi.util.function-1.1.0.jar


Any help will be appreciated. 

Best regards,
Alex soto






RE: Configuring MDC logging karaf 4 camel 3.7.0

2021-05-06 Thread michael e
Hello All,

I still have bugs (by the way is terribly complex configuration with no clear 
documentation).
Here my configuration

log4j2.appender.sift.type = Routing
log4j2.appender.sift.name = Routing
log4j2.appender.sift.routes.type = Routes
log4j2.appender.sift.routes.pattern = \$\$\\\{ctx:camel.contextId\}
log4j2.appender.sift.routes.bundle.type = Route
log4j2.appender.sift.routes.bundle.appender.type = RollingRandomAccessFile
log4j2.appender.sift.routes.bundle.appender.name = 
Bundle-\$\\\{ctx:camel.contextId\}
log4j2.appender.sift.routes.bundle.appender.fileName = 
${karaf.log}/bundle-\$\\\{ctx:camel.contextId\}.log
log4j2.appender.sift.routes.bundle.appender.filePattern = 
${karaf.log}/bundle-\$\\\{ctx:camel.contextId\}.log.%i
log4j2.appender.sift.routes.bundle.appender.append = true
log4j2.appender.sift.routes.bundle.appender.layout.type = PatternLayout
log4j2.appender.sift.routes.bundle.appender.layout.pattern = ${log4j2.pattern}
log4j2.appender.sift.routes.bundle.appender.policies.type = Policies
log4j2.appender.sift.routes.bundle.appender.policies.size.type = 
SizeBasedTriggeringPolicy
log4j2.appender.sift.routes.bundle.appender.policies.size.size = 8MB

The problem is at startup and shutdown all bundle that doesn't have 
camelContext cause this errors
...
e-${ctx:camel.contextId:bundle.name}.log] with data 
[org.apache.logging.log4j.core.appender.rolling.RollingRandomAccessFileManager$FactoryData@74c3f4fd]
org.ops4j.pax.logging.pax-logging-api [log4j2] ERROR : Unable to invoke factory 
method in class 
org.apache.logging.log4j.core.appender.RollingRandomAccessFileAppender for 
element RollingRandomAccessFile: java.lang.IllegalStateException: No factory 
method found for class 
org.apache.logging.log4j.core.appender.RollingRandomAccessFileAppender
org.ops4j.pax.logging.pax-logging-api [log4j2] ERROR : Cannot access 
RandomAccessFile java.io.IOException: La syntaxe du nom de fichier, de 
répertoire ou de volume est incorrecte
org.ops4j.pax.logging.pax-logging-api [log4j2] ERROR : Could not create plugin 
of type class 
org.apache.logging.log4j.core.appender.RollingRandomAccessFileAppender for 
element RollingRandomAccessFile: java.lang.IllegalStateException: 
ManagerFactory 
[org.apache.logging.log4j.core.appender.rolling.RollingRandomAccessFileManager$RollingRandomAccessFileManagerFactory@69cf227a]
 unable to create manager for 
[D:\karaf\apache-karaf-4.3.1\data\log/bundle-${ctx:camel.contextId:bundle.name}.log]
 with data 
[org.apache.logging.log4j.core.appender.rolling.RollingRandomAccessFileManager$FactoryData@59ab51cc]
org.ops4j.pax.logging.pax-logging-api [log4j2] ERROR : Unable to invoke factory 
method in class 
org.apache.logging.log4j.core.appender.RollingRandomAccessFileAppender for 
element RollingRandomAccessFile: java.lang.IllegalStateException: No factory 
method found for class 
org.apache.logging.log4j.core.appender.RollingRandomAccessFileAppender


My question is how i can provide default key or something like to avoid this 
errors in my karaf ?
Michael.


De : michael e 
Envoyé : vendredi 22 janvier 2021 15:16
À : user 
Objet : RE: Configuring MDC logging karaf 4 camel 3.7.0

Hi JB,

I confirm, (for testing you can use my desktop).

Regards,
Michael.


De : Jean-Baptiste Onofre 
Envoyé : vendredi 22 janvier 2021 06:09
À : user 
Objet : Re: Configuring MDC logging karaf 4 camel 3.7.0

Hi Michael,

I’ve resumed my test about Camel MDC.

So, I created a simple route like this:


http://www.osgi.org/xmlns/blueprint/v1.0.0;>

  http://camel.apache.org/schema/blueprint; 
useMDCLogging="true">

  
  Hello World
  

  



Then, in etc/org.ops4j.pax.logging.cfg, I added:

log4j2.rootLogger.appenderRef.Sift.ref = Routing

…

log4j2.appender.routing.type = Routing
log4j2.appender.routing.name = Routing
log4j2.appender.routing.routes.type = Routes
log4j2.appender.routing.routes.pattern = \$\$\\\{ctx:bundle.name\}
log4j2.appender.routing.routes.bundle.type = Route
log4j2.appender.routing.routes.bundle.appender.type = RollingRandomAccessFile
log4j2.appender.routing.routes.bundle.appender.name = 
Bundle-\$\\\{ctx:bundle.name\}
log4j2.appender.routing.routes.bundle.appender.fileName = 
${karaf.log}/camel-context-\$\\\{ctx:camel.contextId\}.log
log4j2.appender.routing.routes.bundle.appender.filePattern = 
${karaf.log}/bundle-\$\\\{ctx:bundle.name\}.log.%i
log4j2.appender.routing.routes.bundle.appender.append = true
log4j2.appender.routing.routes.bundle.appender.layout.type = PatternLayout
log4j2.appender.routing.routes.bundle.appender.layout.pattern = 
${log4j2.pattern}
log4j2.appender.routing.routes.bundle.appender.policies.type = Policies
log4j2.appender.routing.routes.bundle.appender.policies.size.type = 
SizeBasedTriggeringPolicy
log4j2.appender.routing.routes.bundle.appender.policies.size.size = 8MB

You can see the fileName containing camel.contextId.

In data/log, I can see the log file created for my 

Re: Can't start karaf using the wrapper on AIX 7.2

2021-05-06 Thread Jean-Baptiste Onofre
Hi,

Definitely patch-module are required, my point is to use "regular" java command 
line instead of JDK_JAVA_OPTIONS.
As the wrapper won’t "parse" regular java command line, I guess it should work 
(I have to check the syntax though).

+1 to add some details in KARAF-6439.

Thanks !
Regards
JB

> Le 6 mai 2021 à 16:29, Frank 'S Jegers  a écrit :
> 
> Hi,
>  
> It may work without the --patch-module options, but I assume those options 
> were added for a reason ?
>  
> It works if in karaf-wrapper.conf the option set.JDK_JAVA_OPTIONS= is 
> removed. I added the arguments as JVM Parameters, like this :
> wrapper.java.additional.1=--add-reads=java.xml=java.logging
> wrapper.java.additional.2=--add-exports=java.base/org.apache.karaf.specs.locator=java.xml,ALL-UNNAMED
> wrapper.java.additional.3=--patch-module=java.base=lib/endorsed/org.apache.karaf.specs.locator-%KARAF_VERSION%.jar
> wrapper.java.additional.4=--patch-module=java.xml=lib/endorsed/org.apache.karaf.specs.java.xml-%KARAF_VERSION%.jar
> wrapper.java.additional.5=--add-opens=java.base/java.security=ALL-UNNAMED
> wrapper.java.additional.6=--add-opens=java.base/java.net 
> =ALL-UNNAMED
> wrapper.java.additional.7=--add-opens=java.base/java.lang=ALL-UNNAMED
> wrapper.java.additional.8=--add-opens=java.base/java.util=ALL-UNNAMED
> wrapper.java.additional.9=--add-opens=java.naming/javax.naming.spi=ALL-UNNAMED
> wrapper.java.additional.10=--add-opens=java.rmi/sun.rmi.transport.tcp=ALL-UNNAMED
> wrapper.java.additional.11=--add-exports=java.base/sun.net.www.protocol.file=ALL-UNNAMED
> wrapper.java.additional.12=--add-exports=java.base/sun.net.www.protocol.ftp=ALL-UNNAMED
> wrapper.java.additional.13=--add-exports=java.base/sun.net.www.protocol.http=ALL-UNNAMED
> wrapper.java.additional.14=--add-exports=java.base/sun.net.www.protocol.https=ALL-UNNAMED
> wrapper.java.additional.15=--add-exports=java.base/sun.net.www.protocol.jar=ALL-UNNAMED
> wrapper.java.additional.16=--add-exports=java.base/sun.net.www.content.text=ALL-UNNAMED
> wrapper.java.additional.17=--add-exports=jdk.xml.dom/org.w3c.dom.html=ALL-UNNAMED
> wrapper.java.additional.18=--add-exports=jdk.naming.rmi/com.sun.jndi.url.rmi=ALL-UNNAMED
>  
> wrapper.java.additional.19=-Dkaraf.instances=%KARAF_HOME%/instances
> wrapper.java.additional.20=-Dkaraf.home=%KARAF_HOME%
> wrapper.java.additional.21=-Dkaraf.base=%KARAF_BASE%
> wrapper.java.additional.22=-Dkaraf.data=%KARAF_DATA%
> wrapper.java.additional.23=-Dkaraf.etc=%KARAF_ETC%
> wrapper.java.additional.24=-Dkaraf.log=%KARAF_LOG%
> wrapper.java.additional.25=-Dkaraf.restart.jvm.supported=true
> wrapper.java.additional.26=-Djava.io.tmpdir=%KARAF_DATA%/tmp
> wrapper.java.additional.27=-Djava.util.logging.config.file=%KARAF_ETC%/java.util.logging.properties
> wrapper.java.additional.28=-Dcom.sun.management.jmxremote
> wrapper.java.additional.29=-Dkaraf.startLocalConsole=false
> wrapper.java.additional.30=-Dkaraf.startRemoteShell=true
>  
> Note that you can't set
> wrapper.java.additional.3=--patch-module 
> java.base=lib/endorsed/org.apache.karaf.specs.locator-%KARAF_VERSION%.jar
> So with a space between patch-module and java.base, because the wrapper will 
> treat the entire value as 1 argument.
> Nor can you set
> wrapper.java.additional.3=--patch-module
> wrapper.java.additional.4=java.base=lib/endorsed/org.apache.karaf.specs.locator-%KARAF_VERSION%.jar
> Because then the jvm will complain that the option "java.base" is invalid
>  
> You must replace the space with a "=" :
> wrapper.java.additional.3=--patch-module=java.base=lib/endorsed/org.apache.karaf.specs.locator-%KARAF_VERSION%.jar
>  
> I filed a bug report in the AdoptOpenJDK Github : 
> https://github.com/adoptium/adoptium-support/issues/303 
> 
> We'll see if anyone picks this up.
>  
> Do you want me to add this information to the KARAF-6439 issue ?
>  
> Regards,
> Frank ‘S Jegers
>  
> From: Jean-Baptiste Onofre [mailto:j...@nanthrax.net] 
> Sent: donderdag 6 mei 2021 6:16
> To: user
> Subject: Re: Can't start karaf using the wrapper on AIX 7.2
>  
> Hi,
>  
> I agree: it seems the patch-module option is not "AIX compliant" ;)
>  
> Does it work without patch module option ?
>  
> Regards
> JB
> 
> 
> Le 5 mai 2021 à 21:11, Frank 'S Jegers  > a écrit :
>  
> Hi,
>  
> I tried with a freshly downloaded Karaf 4.2.11, generated the wrapper files 
> by executing :
> export JAVA_HOME=/opt/ikan/java/jdk-11.0.11+9
> karaf/bin/shell wrapper:install
>  
> Also tried starting Karaf first, then, from the karaf console, did a
> feature install wrapper
> and
> wrapper:install
>  
> The JAVA_HOME is set in the karaf-wrapper.conf :
> set.default.JAVA_HOME=/opt/ikan/java/jdk-11.0.11+9
>  
> But it still wouldn't start. Turns out there was a wrapper.log after all 
> (wasn't looking in the right place).
>  
> This is the relevant content :
>  
> ERROR  | wrapper  | 2021/05/05 19:21:12 | JVM 

RE: Can't start karaf using the wrapper on AIX 7.2

2021-05-06 Thread Frank 'S Jegers
Hi,

It may work without the --patch-module options, but I assume those options were 
added for a reason ?

It works if in karaf-wrapper.conf the option set.JDK_JAVA_OPTIONS= is removed. 
I added the arguments as JVM Parameters, like this :
wrapper.java.additional.1=--add-reads=java.xml=java.logging
wrapper.java.additional.2=--add-exports=java.base/org.apache.karaf.specs.locator=java.xml,ALL-UNNAMED
wrapper.java.additional.3=--patch-module=java.base=lib/endorsed/org.apache.karaf.specs.locator-%KARAF_VERSION%.jar
wrapper.java.additional.4=--patch-module=java.xml=lib/endorsed/org.apache.karaf.specs.java.xml-%KARAF_VERSION%.jar
wrapper.java.additional.5=--add-opens=java.base/java.security=ALL-UNNAMED
wrapper.java.additional.6=--add-opens=java.base/java.net=ALL-UNNAMED
wrapper.java.additional.7=--add-opens=java.base/java.lang=ALL-UNNAMED
wrapper.java.additional.8=--add-opens=java.base/java.util=ALL-UNNAMED
wrapper.java.additional.9=--add-opens=java.naming/javax.naming.spi=ALL-UNNAMED
wrapper.java.additional.10=--add-opens=java.rmi/sun.rmi.transport.tcp=ALL-UNNAMED
wrapper.java.additional.11=--add-exports=java.base/sun.net.www.protocol.file=ALL-UNNAMED
wrapper.java.additional.12=--add-exports=java.base/sun.net.www.protocol.ftp=ALL-UNNAMED
wrapper.java.additional.13=--add-exports=java.base/sun.net.www.protocol.http=ALL-UNNAMED
wrapper.java.additional.14=--add-exports=java.base/sun.net.www.protocol.https=ALL-UNNAMED
wrapper.java.additional.15=--add-exports=java.base/sun.net.www.protocol.jar=ALL-UNNAMED
wrapper.java.additional.16=--add-exports=java.base/sun.net.www.content.text=ALL-UNNAMED
wrapper.java.additional.17=--add-exports=jdk.xml.dom/org.w3c.dom.html=ALL-UNNAMED
wrapper.java.additional.18=--add-exports=jdk.naming.rmi/com.sun.jndi.url.rmi=ALL-UNNAMED

wrapper.java.additional.19=-Dkaraf.instances=%KARAF_HOME%/instances
wrapper.java.additional.20=-Dkaraf.home=%KARAF_HOME%
wrapper.java.additional.21=-Dkaraf.base=%KARAF_BASE%
wrapper.java.additional.22=-Dkaraf.data=%KARAF_DATA%
wrapper.java.additional.23=-Dkaraf.etc=%KARAF_ETC%
wrapper.java.additional.24=-Dkaraf.log=%KARAF_LOG%
wrapper.java.additional.25=-Dkaraf.restart.jvm.supported=true
wrapper.java.additional.26=-Djava.io.tmpdir=%KARAF_DATA%/tmp
wrapper.java.additional.27=-Djava.util.logging.config.file=%KARAF_ETC%/java.util.logging.properties
wrapper.java.additional.28=-Dcom.sun.management.jmxremote
wrapper.java.additional.29=-Dkaraf.startLocalConsole=false
wrapper.java.additional.30=-Dkaraf.startRemoteShell=true

Note that you can't set
wrapper.java.additional.3=--patch-module 
java.base=lib/endorsed/org.apache.karaf.specs.locator-%KARAF_VERSION%.jar
So with a space between patch-module and java.base, because the wrapper will 
treat the entire value as 1 argument.
Nor can you set
wrapper.java.additional.3=--patch-module
wrapper.java.additional.4=java.base=lib/endorsed/org.apache.karaf.specs.locator-%KARAF_VERSION%.jar
Because then the jvm will complain that the option "java.base" is invalid

You must replace the space with a "=" :
wrapper.java.additional.3=--patch-module=java.base=lib/endorsed/org.apache.karaf.specs.locator-%KARAF_VERSION%.jar

I filed a bug report in the AdoptOpenJDK Github : 
https://github.com/adoptium/adoptium-support/issues/303
We'll see if anyone picks this up.

Do you want me to add this information to the KARAF-6439 issue ?

Regards,
Frank ‘S Jegers

From: Jean-Baptiste Onofre [mailto:j...@nanthrax.net]
Sent: donderdag 6 mei 2021 6:16
To: user
Subject: Re: Can't start karaf using the wrapper on AIX 7.2

Hi,

I agree: it seems the patch-module option is not "AIX compliant" ;)

Does it work without patch module option ?

Regards
JB


Le 5 mai 2021 à 21:11, Frank 'S Jegers 
mailto:frank.sjeg...@ikan.be>> a écrit :

Hi,

I tried with a freshly downloaded Karaf 4.2.11, generated the wrapper files by 
executing :
export JAVA_HOME=/opt/ikan/java/jdk-11.0.11+9
karaf/bin/shell wrapper:install

Also tried starting Karaf first, then, from the karaf console, did a
feature install wrapper
and
wrapper:install

The JAVA_HOME is set in the karaf-wrapper.conf :
set.default.JAVA_HOME=/opt/ikan/java/jdk-11.0.11+9

But it still wouldn't start. Turns out there was a wrapper.log after all 
(wasn't looking in the right place).

This is the relevant content :

ERROR  | wrapper  | 2021/05/05 19:21:12 | JVM exited while loading the 
application.
INFO   | jvm 5| 2021/05/05 19:21:12 | NOTE: Picked up JDK_JAVA_OPTIONS: 
--add-reads=java.xml=java.logging 
--add-exports=java.base/org.apache.karaf.specs.locator=java.xml,ALL-UNNAMED 
--patch-module java.base=lib/endorsed/org.apache.karaf.specs.locator-4.2.11.jar 
--patch-module java.xml=lib/endorsed/org.apache.karaf.specs.java.xml-4.2.11.jar 
--add-opens java.base/java.security=ALL-UNNAMED --add-opens 
java.base/java.net=ALL-UNNAMED --add-opens 
java.base/java.lang=ALL-UNNAMED --add-opens java.base/java.util=ALL-UNNAMED 
--add-opens java.naming/javax.naming.spi=ALL-UNNAMED --add-opens 

Re: Weird sshd-SshServer SSH2_DISCONNECT_PROTOCOL_ERROR - Detected AuthTimeout after messages

2021-05-06 Thread Oleg Cohen
Hi JB,

I didn’t install anything specific. No Decanter. Is there a way to trace and 
see where the SSH requests are coming from?

Thank you!
Oleg

> On May 6, 2021, at 10:10 AM, Jean-Baptiste Onofre  wrote:
> 
> Hi Oleg,
> 
> Maybe you have a monitoring solution (as Decanter) that pull the MBean, and 
> so perform ssh connection when listing the instances in the InstanceMBean.
> 
> It seems that something tries a ssh connect ;)
> 
> Regards
> JB
> 
>> Le 6 mai 2021 à 15:53, Oleg Cohen  a écrit :
>> 
>> Greetings,
>> 
>> I started a new karat instance in a Kubernetes pod from a custom distro.
>> 
>> I am seeing the following set of messages in the log every few seconds. 
>> 
>> 2021-05-06T13:49:30,946 | INFO  | 
>> sshd-SshServer[7467ccad](port=8101)-timer-thread-1 | ServerSessionImpl   
>>  | 309 - org.apache.sshd.osgi - 2.5.1 | 
>> Disconnecting(ServerSessionImpl[null@/169.254.175.250:49648]): 
>> SSH2_DISCONNECT_PROTOCOL_ERROR - Detected AuthTimeout after 120034/12 ms.
>> 2021-05-06T13:49:30,946 | WARN  | 
>> sshd-SshServer[7467ccad](port=8101)-timer-thread-1 | ServerSessionImpl   
>>  | 309 - org.apache.sshd.osgi - 2.5.1 | 
>> disconnect(ServerSessionImpl[null@/169.254.175.250:49648]) operation failed 
>> (IOException) for reason=SSH2_DISCONNECT_PROTOCOL_ERROR [Detected 
>> AuthTimeout after 120034/12 ms.]: Broken pipe
>> 2021-05-06T13:49:30,946 | WARN  | 
>> sshd-SshServer[7467ccad](port=8101)-nio2-thread-2 | ServerSessionImpl
>> | 309 - org.apache.sshd.osgi - 2.5.1 | 
>> exceptionCaught(ServerSessionImpl[null@/169.254.175.250:49648])[state=Opened]
>>  IOException: Broken pipe
>> 
>> The pod is completely isolated.
>> 
>> Wonder if anybody has encountered this behavior before?
>> 
>> Thank you!
>> Oleg
> 



Re: Weird sshd-SshServer SSH2_DISCONNECT_PROTOCOL_ERROR - Detected AuthTimeout after messages

2021-05-06 Thread Jean-Baptiste Onofre
Hi Oleg,

Maybe you have a monitoring solution (as Decanter) that pull the MBean, and so 
perform ssh connection when listing the instances in the InstanceMBean.

It seems that something tries a ssh connect ;)

Regards
JB

> Le 6 mai 2021 à 15:53, Oleg Cohen  a écrit :
> 
> Greetings,
> 
> I started a new karat instance in a Kubernetes pod from a custom distro.
> 
> I am seeing the following set of messages in the log every few seconds. 
> 
> 2021-05-06T13:49:30,946 | INFO  | 
> sshd-SshServer[7467ccad](port=8101)-timer-thread-1 | ServerSessionImpl
> | 309 - org.apache.sshd.osgi - 2.5.1 | 
> Disconnecting(ServerSessionImpl[null@/169.254.175.250:49648]): 
> SSH2_DISCONNECT_PROTOCOL_ERROR - Detected AuthTimeout after 120034/12 ms.
> 2021-05-06T13:49:30,946 | WARN  | 
> sshd-SshServer[7467ccad](port=8101)-timer-thread-1 | ServerSessionImpl
> | 309 - org.apache.sshd.osgi - 2.5.1 | 
> disconnect(ServerSessionImpl[null@/169.254.175.250:49648]) operation failed 
> (IOException) for reason=SSH2_DISCONNECT_PROTOCOL_ERROR [Detected AuthTimeout 
> after 120034/12 ms.]: Broken pipe
> 2021-05-06T13:49:30,946 | WARN  | 
> sshd-SshServer[7467ccad](port=8101)-nio2-thread-2 | ServerSessionImpl 
>| 309 - org.apache.sshd.osgi - 2.5.1 | 
> exceptionCaught(ServerSessionImpl[null@/169.254.175.250:49648])[state=Opened] 
> IOException: Broken pipe
> 
> The pod is completely isolated.
> 
> Wonder if anybody has encountered this behavior before?
> 
> Thank you!
> Oleg



Weird sshd-SshServer SSH2_DISCONNECT_PROTOCOL_ERROR - Detected AuthTimeout after messages

2021-05-06 Thread Oleg Cohen
Greetings,

I started a new karat instance in a Kubernetes pod from a custom distro.

I am seeing the following set of messages in the log every few seconds. 

2021-05-06T13:49:30,946 | INFO  | 
sshd-SshServer[7467ccad](port=8101)-timer-thread-1 | ServerSessionImpl  
  | 309 - org.apache.sshd.osgi - 2.5.1 | 
Disconnecting(ServerSessionImpl[null@/169.254.175.250:49648]): 
SSH2_DISCONNECT_PROTOCOL_ERROR - Detected AuthTimeout after 120034/12 ms.
2021-05-06T13:49:30,946 | WARN  | 
sshd-SshServer[7467ccad](port=8101)-timer-thread-1 | ServerSessionImpl  
  | 309 - org.apache.sshd.osgi - 2.5.1 | 
disconnect(ServerSessionImpl[null@/169.254.175.250:49648]) operation failed 
(IOException) for reason=SSH2_DISCONNECT_PROTOCOL_ERROR [Detected AuthTimeout 
after 120034/12 ms.]: Broken pipe
2021-05-06T13:49:30,946 | WARN  | 
sshd-SshServer[7467ccad](port=8101)-nio2-thread-2 | ServerSessionImpl   
 | 309 - org.apache.sshd.osgi - 2.5.1 | 
exceptionCaught(ServerSessionImpl[null@/169.254.175.250:49648])[state=Opened] 
IOException: Broken pipe

The pod is completely isolated.

Wonder if anybody has encountered this behavior before?

Thank you!
Oleg

Re: Issue with wrapping jar bundle

2021-05-06 Thread JB Onofré
It should work with escape char. 

> Le 6 mai 2021 à 11:26, Benjamin Graf  a écrit :
> 
> 
> Hi JB,
>  
> does this work in feature description xml? This more looks like 
> maven-bundle-plugin config.
>  
> Regards
> Benjamin
>  
> Gesendet: Donnerstag, 06. Mai 2021 um 11:11 Uhr
> Von: "Jean-Baptiste Onofre" 
> An: user@karaf.apache.org
> Betreff: Re: Issue with wrapping jar bundle
> Did you try Import-Package=!java.io,* ?
>  
> Regards
> JB
>  
> Le 6 mai 2021 à 10:45, Benjamin Graf  a écrit :
>  
> Hi JB,
>  
> yes still using 4.2.11. What's the correct syntax to exclude the generation 
> of java.io import in wrap:mvn:... feature statement?
>  
> Regards
> Benjamin
>  
>  
> Gesendet: Donnerstag, 06. Mai 2021 um 09:25 Uhr
> Von: "Jean-Baptiste Onofre" 
> An: "user" 
> Betreff: Re: Issue with wrapping jar bundle
> Hi Benjamin,
>  
> You can exclude the java.io import. Anyway, I guess you are not using Karaf 
> 4.3.1: I fixed the issue on this release with 
> https://issues.apache.org/jira/browse/KARAF-7012
>  
> Regards
> JB
>  
> Le 6 mai 2021 à 08:10, Benjamin Graf  a écrit :
>  
> Hi,
> 
> what can I do if wrapping a jar generates import for osgi package "java.io" 
> which can not be resolved. I recognized this issue with actual oracle ojdbc11 
> driver. The same works with sibling ojdbc8.
> 
> Thanks for help :)
> 
> Regards
> 
> Benjamin
> 
>  


Aw: Re: Issue with wrapping jar bundle

2021-05-06 Thread Benjamin Graf
Hi JB,

 

does this work in feature description xml? This more looks like maven-bundle-plugin config.

 

Regards

Benjamin


 

Gesendet: Donnerstag, 06. Mai 2021 um 11:11 Uhr
Von: "Jean-Baptiste Onofre" 
An: user@karaf.apache.org
Betreff: Re: Issue with wrapping jar bundle


Did you try Import-Package=!java.io,* ?

 

Regards

JB
 

Le 6 mai 2021 à 10:45, Benjamin Graf  a écrit :
 




Hi JB,

 

yes still using 4.2.11. What's the correct syntax to exclude the generation of java.io import in wrap:mvn:... feature statement?

 

Regards

Benjamin

 
 

Gesendet: Donnerstag, 06. Mai 2021 um 09:25 Uhr
Von: "Jean-Baptiste Onofre" 
An: "user" 
Betreff: Re: Issue with wrapping jar bundle


Hi Benjamin,
 

You can exclude the java.io import. Anyway, I guess you are not using Karaf 4.3.1: I fixed the issue on this release with https://issues.apache.org/jira/browse/KARAF-7012

 

Regards

JB

 

Le 6 mai 2021 à 08:10, Benjamin Graf  a écrit :
 


Hi,

what can I do if wrapping a jar generates import for osgi package "java.io" which can not be resolved. I recognized this issue with actual oracle ojdbc11 driver. The same works with sibling ojdbc8.

Thanks for help :)

Regards

Benjamin

 























Re: Issue with wrapping jar bundle

2021-05-06 Thread Jean-Baptiste Onofre
Did you try Import-Package=!java.io ,* ?

Regards
JB

> Le 6 mai 2021 à 10:45, Benjamin Graf  a écrit :
> 
> Hi JB,
>  
> yes still using 4.2.11. What's the correct syntax to exclude the generation 
> of java.io import in wrap:mvn:... feature statement?
>  
> Regards
> Benjamin
>  
>  
> Gesendet: Donnerstag, 06. Mai 2021 um 09:25 Uhr
> Von: "Jean-Baptiste Onofre" 
> An: "user" 
> Betreff: Re: Issue with wrapping jar bundle
> Hi Benjamin,
>  
> You can exclude the java.io  import. Anyway, I guess you are 
> not using Karaf 4.3.1: I fixed the issue on this release with 
> https://issues.apache.org/jira/browse/KARAF-7012 
> 
>  
> Regards
> JB
>  
> Le 6 mai 2021 à 08:10, Benjamin Graf  > a écrit :
>  
> Hi,
> 
> what can I do if wrapping a jar generates import for osgi package "java.io 
> " which can not be resolved. I recognized this issue with 
> actual oracle ojdbc11 driver. The same works with sibling ojdbc8.
> 
> Thanks for help :)
> 
> Regards
> 
> Benjamin
> 
>  



Aw: Re: Issue with wrapping jar bundle

2021-05-06 Thread Benjamin Graf
Hi JB,

 

yes still using 4.2.11. What's the correct syntax to exclude the generation of java.io import in wrap:mvn:... feature statement?

 

Regards

Benjamin

 
 

Gesendet: Donnerstag, 06. Mai 2021 um 09:25 Uhr
Von: "Jean-Baptiste Onofre" 
An: "user" 
Betreff: Re: Issue with wrapping jar bundle


Hi Benjamin,
 

You can exclude the java.io import. Anyway, I guess you are not using Karaf 4.3.1: I fixed the issue on this release with https://issues.apache.org/jira/browse/KARAF-7012

 

Regards

JB

 

Le 6 mai 2021 à 08:10, Benjamin Graf  a écrit :
 


Hi,

what can I do if wrapping a jar generates import for osgi package "java.io" which can not be resolved. I recognized this issue with actual oracle ojdbc11 driver. The same works with sibling ojdbc8.

Thanks for help :)

Regards

Benjamin

 












Re: Issue with wrapping jar bundle

2021-05-06 Thread Jean-Baptiste Onofre
Hi Benjamin,

You can exclude the java.io  import. Anyway, I guess you are 
not using Karaf 4.3.1: I fixed the issue on this release with 
https://issues.apache.org/jira/browse/KARAF-7012 


Regards
JB

> Le 6 mai 2021 à 08:10, Benjamin Graf  a écrit :
> 
> Hi,
> 
> what can I do if wrapping a jar generates import for osgi package "java.io" 
> which can not be resolved. I recognized this issue with actual oracle ojdbc11 
> driver. The same works with sibling ojdbc8.
> 
> Thanks for help :)
> 
> Regards
> 
> Benjamin
> 
> 



Issue with wrapping jar bundle

2021-05-06 Thread Benjamin Graf

Hi,

what can I do if wrapping a jar generates import for osgi package 
"java.io" which can not be resolved. I recognized this issue with actual 
oracle ojdbc11 driver. The same works with sibling ojdbc8.


Thanks for help :)

Regards

Benjamin




OpenPGP_signature
Description: OpenPGP digital signature