Bug#986866: apacheds: ApacheDS fails to start after clean install

2021-05-02 Thread tony mancill
On Sun, May 02, 2021 at 07:29:56AM -0700, tony mancill wrote:
> 1)  The exception is being thrown in the mina library (source package
> mina2: https://tracker.debian.org/pkg/mina2), so we will likely end up
> reassigning the bug to that package.

I have reassigned the bug to mina2.

> 2) Because mina2 and apacheds2 haven't changed in over 6 months and this
> issue began shortly after the introduction of OpenJDK 11.0.11 to
> unstable, I suspect that Apache Mina2 has been setting a socket option
> that has been deprecated for a while and is now no longer supported.

I didn't find a difference in OpenJDK that would account for the change
in behavior, although it could be that I didn't go far enough back (I
was comparing sources back to 11.0.9.1), or that I missed the salient
bit.

> Assuming my hunch is correct, I propose patching mina2 to no longer
> attempt to set SO_SNDBUF [2].  mina2 is only used by ApacheDS within
> Debian, so it should be fairly quick to test the change.

I have built mina2 with SO_SNDBUF line disabled [1], and then thought
better of it (maybe it still works on certain platforms - it seems to
have worked in the past) and updated the patch to attempt to set the
option and then ignore the UnsupportedOperationException [2] if thrown.

I installed this package locally and tested with the current apacheds,
confirming that it now starts as expected.  I also verified via ratt
that all build r-deps of mina2 are still healthy (although since this is
a runtime bug, that's just due diligence).

I propose uploading and requesting an unblock for mina2 but since we're
in the freeze and this is an RC bug, I want to give other members of the
Java Team who might be more familiar with the code a chance to comment.

If there are no objections, I will upload on 2021-05-03 (afternoon UTC).

Cheers,
tony

[1] 
https://salsa.debian.org/java-team/mina2/-/blob/eab3e3cfeff66c694fc9bf7c7047f13f258946ae/debian/patches/SO_SNDBUF.patch
[2] 
https://salsa.debian.org/java-team/mina2/-/blob/bc58296df862065ec641ce47095f2fb46d54aeb9/debian/patches/SO_SNDBUF.patch


signature.asc
Description: PGP signature


Bug#986866: apacheds: ApacheDS fails to start after clean install

2021-05-02 Thread tony mancill
Hello Carlos,

Thank you for reporting this bug and to others for confirming it.
Several comments below:

On Mon, Apr 12, 2021 at 10:09:58PM -0600, Carlos Ramos wrote:
> Package: apacheds
> Version: 2.0.0~M24-4
> Severity: important
> 
> [2021-52-12T21:52:39.039-0600] WARN 
> [org.apache.directory.server.core.DefaultDirectoryService] - You didn't 
> change the admin password of directory service instance 'default'.  Please 
> update the admin password as soon as possible to prevent a possible security 
> breach.
> [2021-52-12T21:52:39.039-0600] DEBUG 
> [org.apache.directory.server.ldap.handlers.extended.StartTlsHandler] - 
> Setting LDAP Service
> [2021-52-12T21:52:39.039-0600] DEBUG 
> [org.apache.directory.server.ldap.handlers.extended.StartTlsHandler] - 
> provider = SUN version 11
> [2021-52-12T21:52:39.039-0600] ERROR 
> [org.apache.directory.server.UberjarMain] - Failed to start the service.
> java.lang.UnsupportedOperationException: 'SO_SNDBUF' not supported
>   at 
> java.base/sun.nio.ch.ServerSocketChannelImpl.setOption(ServerSocketChannelImpl.java:151)
>   at 
> org.apache.mina.transport.socket.nio.NioSocketAcceptor.open(NioSocketAcceptor.java:255)
>   at 
> org.apache.mina.transport.socket.nio.NioSocketAcceptor.open(NioSocketAcceptor.java:52)
>   at 
> org.apache.mina.core.polling.AbstractPollingIoAcceptor$Acceptor.registerHandles(AbstractPollingIoAcceptor.java:591)
>   at 
> org.apache.mina.core.polling.AbstractPollingIoAcceptor$Acceptor.run(AbstractPollingIoAcceptor.java:460)
>   at 
> org.apache.mina.util.NamePreservingRunnable.run(NamePreservingRunnable.java:64)
>   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)

1)  The exception is being thrown in the mina library (source package
mina2: https://tracker.debian.org/pkg/mina2), so we will likely end up
reassigning the bug to that package.

2) Because mina2 and apacheds2 haven't changed in over 6 months and this
issue began shortly after the introduction of OpenJDK 11.0.11 to
unstable, I suspect that Apache Mina2 has been setting a socket option
that has been deprecated for a while and is now no longer supported.

That is speculation so far - I haven't yet tracked this down to a
change in OpenJDK (but will try by reverting locally). However,
11.0.11+$x appears in your bug report and others confirming the bug.

Also, when I look at the Java 11 javadoc for ServerSocketChannel [1], I
don't see SO_SNDBUF as a supported option anyway.

Assuming my hunch is correct, I propose patching mina2 to no longer
attempt to set SO_SNDBUF [2].  mina2 is only used by ApacheDS within
Debian, so it should be fairly quick to test the change.

Thanks,
tony

[1] 
https://docs.oracle.com/en/java/javase/11/docs/api/java.base/java/nio/channels/ServerSocketChannel.html
[2] 
https://salsa.debian.org/java-team/mina2/-/blob/master/src/mina-core/src/main/java/org/apache/mina/transport/socket/nio/NioSocketAcceptor.java#L253-256


signature.asc
Description: PGP signature


Bug#986866: apacheds: ApacheDS fails to start after clean install

2021-04-30 Thread Chris Hofstaedtler
Control: severity -1 serious
Control: tags -1 + confirmed

I can also trivially reproduce this problem.

Chris



Bug#986866: apacheds: ApacheDS fails to start after clean install

2021-04-30 Thread Elias Batek - IT Kaufmann GmbH

Can confirm.
Unfortunately, same here.

Regards,
Elias



Bug#986866: apacheds: ApacheDS fails to start after clean install

2021-04-12 Thread Carlos Ramos
Package: apacheds
Version: 2.0.0~M24-4
Severity: important

Dear Maintainer,

After a clean install of apachedsi, `apt install apacheds`, the services does
not start and the following error is observed in
'/var/log/apacheds/apacheds-rolling.log':

[2021-52-12T21:52:39.039-0600] WARN 
[org.apache.directory.server.core.DefaultDirectoryService] - You didn't change 
the admin password of directory service instance 'default'.  Please update the 
admin password as soon as possible to prevent a possible security breach.
[2021-52-12T21:52:39.039-0600] DEBUG 
[org.apache.directory.server.ldap.handlers.extended.StartTlsHandler] - Setting 
LDAP Service
[2021-52-12T21:52:39.039-0600] DEBUG 
[org.apache.directory.server.ldap.handlers.extended.StartTlsHandler] - provider 
= SUN version 11
[2021-52-12T21:52:39.039-0600] ERROR [org.apache.directory.server.UberjarMain] 
- Failed to start the service.
java.lang.UnsupportedOperationException: 'SO_SNDBUF' not supported
at 
java.base/sun.nio.ch.ServerSocketChannelImpl.setOption(ServerSocketChannelImpl.java:151)
at 
org.apache.mina.transport.socket.nio.NioSocketAcceptor.open(NioSocketAcceptor.java:255)
at 
org.apache.mina.transport.socket.nio.NioSocketAcceptor.open(NioSocketAcceptor.java:52)
at 
org.apache.mina.core.polling.AbstractPollingIoAcceptor$Acceptor.registerHandles(AbstractPollingIoAcceptor.java:591)
at 
org.apache.mina.core.polling.AbstractPollingIoAcceptor$Acceptor.run(AbstractPollingIoAcceptor.java:460)
at 
org.apache.mina.util.NamePreservingRunnable.run(NamePreservingRunnable.java:64)
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)

-- System Information:
Debian Release: bullseye/sid
  APT prefers testing
  APT policy: (500, 'testing')
Architecture: amd64 (x86_64)

Kernel: Linux 5.10.0-5-amd64 (SMP w/8 CPU threads)
Locale: LANG=en_US.UTF-8, LC_CTYPE=en_US.UTF-8 (charmap=UTF-8), 
LANGUAGE=en_US:en
Shell: /bin/sh linked to /usr/bin/dash
Init: systemd (via /run/systemd/system)
LSM: AppArmor: enabled

Versions of packages apacheds depends on:
ii  adduser   3.118
ii  default-jre-headless [java7-runtime-headless] 2:1.11-72
ii  init-system-helpers   1.60
ii  libapacheds-java  2.0.0~M24-4
ii  openjdk-11-jre-headless [java7-runtime-headless]  11.0.11+4-1

apacheds recommends no packages.

apacheds suggests no packages.

-- Configuration Files:
/etc/apacheds/config.ldif [Errno 2] No such file or directory: 
'/etc/apacheds/config.ldif'

-- no debconf information