neo4j / docker-neo4j

Docker Images for the Neo4j Graph Database
Apache License 2.0
327 stars 171 forks source link

Docker-entrypoint stores unreadable bytes in neo4j.conf -> Startup broken #102

Open ThomasKoppensteiner opened 7 years ago

ThomasKoppensteiner commented 7 years ago

I'm running community edition of neo4j in docker (version 3.2.2). To persist the configuration I'm mounting a host folder to /var/lib/neo4j/conf. The first start is fine and prints out:

Active database: graph.db
Directories in use:
  home:         /var/lib/neo4j
  config:       /var/lib/neo4j/conf
  logs:         /logs
  plugins:      /var/lib/neo4j/plugins
  import:       /var/lib/neo4j/import
  data:         /var/lib/neo4j/data
  certificates: /var/lib/neo4j/certificates
  run:          /var/lib/neo4j/run
Starting Neo4j.
...

The docker-entrypoint creates or appends to the neo4j.conf file settings, but some lines contain unreadable data.

The startup of the neo4j breaks on the next time, when the container is restarted.

/docker-entrypoint.sh: line 104: echo: write error: Invalid argument

Version 3.2.1 has the same issue, but I think older versions worked (can't say which one).

janwo commented 7 years ago

Have the same issue https://github.com/neo4j/neo4j/issues/9663

mneedham commented 7 years ago

Can you try mounting your host folder to /conf rather than /var/lib/neo4j/conf and see if that makes any difference?

ThomasKoppensteiner commented 7 years ago

@mneedham yes, when I mount the host config folder to /conf I can restart the container several times. What makes me wonder is the output during the startup (see above) - is the config from within this folder even read? How can I/we prove this?

FYI: Using environment variables instead of mounting the conf folder also works.

agalazis commented 6 years ago

Same here on v3.3