# Unable to connect to database. Tried 1 times {:error\_message=\>"Java::JavaLang::NoClassDefFoundError: javax/xml/bind/DatatypeConverter"

**URL:** <https://discuss.elastic.co/t/unable-to-connect-to-database-tried-1-times-error-message-java-javax-xml-bind-datatypeconverter/200901>\
**Category:** Logstash\
**Created:** [September 24, 2019, 3:40pm UTC](https://discuss.elastic.co/t/unable-to-connect-to-database-tried-1-times-error-message-java-javax-xml-bind-datatypeconverter/200901 "2019-09-24T15:40:42Z")\
**Posts on this page:** 1\
**Showing post:** 3

<div class="post-metadata">

**Author:** ![Sigrud](https://avatars.discourse-cdn.com/v4/letter/s/76d3ee/32.png) [@Sigrud](https://discuss.elastic.co/u/Sigrud)\
**Post date:** [October 23, 2019, 1:21pm UTC](https://discuss.elastic.co/t/unable-to-connect-to-database-tried-1-times-error-message-java-javax-xml-bind-datatypeconverter/200901/3 "2019-10-23T13:21:47Z")

</div>

i was able to solve this issue by removing the installed java version, reinstall java 8 openjdk and setting the JAVA\_HOME path

I don't know if it's required but I also added java\_home/bin to the path variable

---

_[View the full topic](https://discuss.elastic.co/t/unable-to-connect-to-database-tried-1-times-error-message-java-javax-xml-bind-datatypeconverter/200901)._
