Skip to content
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

Running with Docker ldap broken connection #1468

Closed
jimOnAir opened this issue Jun 22, 2018 · 1 comment
Closed

Running with Docker ldap broken connection #1468

jimOnAir opened this issue Jun 22, 2018 · 1 comment
Assignees
Labels
bug Something isn't working
Milestone

Comments

@jimOnAir
Copy link

Hi. I'm trying to run dcm4chee with Docker and have a problem with ldap connection. After some time (about 15-20 minutes) of innactivity first api or web-ui query return 500 error

"javax.naming.ServiceUnavailableException: ldap:389; socket closed; remaining name 'cn=Devices,cn="Dicom Configuration",dc=mdw,dc=io'

I see this error in server.log:
2018-06-22 08:40:28,931 INFO [org.dcm4che3.conf.ldap.ReconnectDirContext] (default task-1) Connection to ldap://ldap:389 broken - reconnect
Next query seems to pass normal.

My docker-compose file:

version: '3.6'
services:
  ldap:
    image: dcm4che/slapd-dcm4chee:2.4.44-13.1
    ports:
      - "389:389"
    env_file: docker-compose.env
    volumes:
      - /etc/localtime:/etc/localtime:ro
      - /etc/timezone:/etc/timezone:ro
      - type: volume
        source: ldap
        target: /var/lib/ldap
      - type: volume
        source: slapd.d
        target: /etc/ldap/slapd.d
    networks:
      - mdw
    deploy:
      placement:
        constraints:
          - node.labels.dcm4chee == true
  dcm4che-postgres:
    image: dcm4che/postgres-dcm4chee:10.0-13
    ports:
      - "5432:5432"
    env_file: docker-compose.env
    volumes:      
    - /etc/localtime:/etc/localtime:ro
    - /etc/timezone:/etc/timezone:ro
    - type: volume
      source: db
      target: /var/lib/postgresql/data
    networks:
      - mdw
    deploy:
      placement:
        constraints:
          - node.labels.dcm4chee == true
  arc:
    image: dcm4che/dcm4chee-arc-psql:5.13.1
    ports:
      - "11112:11112"
      - "2575:2575"
    env_file: docker-compose.env
    environment:
      WILDFLY_CHOWN: /opt/wildfly/standalone /storage
      WILDFLY_WAIT_FOR: ldap:389 dcm4che-postgres:5432
      POSTGRES_HOST: dcm4che-postgres
      LDAP_HOST: ldap
      JAVA_OPTS: -Xms64m -Xmx512m -XX:MetaspaceSize=96M -XX:MaxMetaspaceSize=256m -Djava.net.preferIPv4Stack=true -Djboss.modules.system.pkgs="org.jboss.byteman" -Djava.awt.headless=true -Dcom.sun.jndi.ldap.connect.pool=true -Dcom.sun.jndi.ldap.connect.pool.maxsize=30 -Dcom.sun.jndi.ldap.connect.pool.prefsize=10 -Dcom.sun.jndi.ldap.connect.pool.timeout=60000
    depends_on:
      - ldap
      - dcm4che-postgres
    volumes:
      - /etc/localtime:/etc/localtime:ro
      - /etc/timezone:/etc/timezone:ro
      - type: volume
        source: wildfly
        target: /opt/wildfly/standalone
      - type: volume
        source: storage
        target: /storage
    networks:
      - mdw
      - reverse-proxy
    deploy:
      placement:
        constraints:
          - node.labels.dcm4chee == true

networks:
  mdw:
    external: true
  reverse-proxy:
    external: true
volumes:
  ldap:
    external: true
    name: '{{index .Service.Labels "com.docker.stack.namespace"}}-ldap-{{.Task.Slot}}'
  slapd.d:
    external: true
    name: '{{index .Service.Labels "com.docker.stack.namespace"}}-slapd.d-{{.Task.Slot}}'
  db:
    external: true
    name: '{{index .Service.Labels "com.docker.stack.namespace"}}-db-{{.Task.Slot}}'
  keycloak:
    external: true
    name: '{{index .Service.Labels "com.docker.stack.namespace"}}-keycloak-{{.Task.Slot}}'
  wildfly:
    external: true
    name: '{{index .Service.Labels "com.docker.stack.namespace"}}-wildfly-{{.Task.Slot}}'
  storage:
    external: true
    name: '{{index .Service.Labels "com.docker.stack.namespace"}}-storage-{{.Task.Slot}}'

I'm running Docker 18.05.0-ce, build f150324 in swarm mode on ubunut 16.04 in Amazon AWS cloud

@gunterze gunterze added this to the 5.22.5 milestone Aug 20, 2020
@gunterze gunterze modified the milestones: 5.22.5, 5.23.0 Sep 11, 2020
@gunterze gunterze modified the milestones: 5.22.6, 5.23.0 Oct 16, 2020
@gunterze gunterze modified the milestones: 5.23.0, 5.23.1 Dec 14, 2020
@gunterze gunterze modified the milestones: 5.23.1, 5.24.0 Feb 10, 2021
@gunterze gunterze modified the milestones: 5.23.2, 5.24.0 Mar 24, 2021
@gunterze gunterze modified the milestones: 5.23.3, 5.24.0 May 18, 2021
@gunterze gunterze modified the milestones: 5.24.0, 5.24.1 Aug 6, 2021
@gunterze gunterze modified the milestones: 5.24.1, 5.24.2 Sep 15, 2021
@gunterze gunterze modified the milestones: 5.24.2, 5.25.0 Oct 1, 2021
@gunterze gunterze modified the milestones: 5.25.0, 5.26.0 Dec 15, 2021
@gunterze gunterze modified the milestones: 5.25.1, 5.26.0 Dec 28, 2021
@gunterze gunterze modified the milestones: 5.25.2, 5.26.0 Feb 14, 2022
@gunterze gunterze modified the milestones: 5.26.0, 5.26.1 Mar 23, 2022
@gunterze gunterze modified the milestones: 5.26.1, 5.26.2 Jun 9, 2022
@graeme-interlinx
Copy link

I am seeing the same issue, after a period of time the connection closes and the first search fails.
2022-06-13 16:47:25,704 WARN [org.dcm4chee.arc.dimse.rs.QueryRS] (default task-12) Response Not Found caused by {"errorMessage":"javax.naming.NamingException: LDAP connection has been closed; remaining name 'cn=Devices,cn=DICOM Configuration,dc=dcm4che,dc=org'"}
2022-06-13 16:47:25,710 INFO [org.dcm4che3.conf.ldap.ReconnectDirContext] (default task-12) Connection to ldap://ldap:389 broken - reconnect

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

3 participants