[GH-ISSUE #98] Problem start acme-dns in installation #40

Closed
opened 2026-03-13 15:29:08 +03:00 by kerem · 21 comments
Owner

Originally created by @LinuxCuba on GitHub (Aug 9, 2018).
Original GitHub issue: https://github.com/acme-dns/acme-dns/issues/98

After install and config. exec acme-dns
this error not start the service.
INFO[0000] Using config file file=/etc/acme-dns/config.cfg
ERRO[0000] Could not open database [sql: unknown driver "" (forgotten import?)]

Originally created by @LinuxCuba on GitHub (Aug 9, 2018). Original GitHub issue: https://github.com/acme-dns/acme-dns/issues/98 After install and config. exec acme-dns this error not start the service. INFO[0000] Using config file file=/etc/acme-dns/config.cfg ERRO[0000] Could not open database [sql: unknown driver "" (forgotten import?)]
kerem 2026-03-13 15:29:08 +03:00
  • closed this issue
  • added the
    question
    label
Author
Owner

@joohoi commented on GitHub (Aug 9, 2018):

I’m sorry that tou are experiencing issues with acme-dns. We just had a
similar issue, I wonder if this is the case with your configuration as
well:
https://github.com/joohoi/acme-dns/issues/93#issuecomment-402906927

On Thu, 9 Aug 2018 at 19.27, LinuxCuba notifications@github.com wrote:

After install and config. exec acme-dns
this error not start the service.
INFO[0000] Using config file file=/etc/acme-dns/config.cfg
ERRO[0000] Could not open database [sql: unknown driver "" (forgotten
import?)]


You are receiving this because you are subscribed to this thread.
Reply to this email directly, view it on GitHub
https://github.com/joohoi/acme-dns/issues/98, or mute the thread
https://github.com/notifications/unsubscribe-auth/AE_hpVJcgGeuQc8Wx1yqm7AK_TyILP-mks5uPGMMgaJpZM4V2BT-
.

<!-- gh-comment-id:411818577 --> @joohoi commented on GitHub (Aug 9, 2018): I’m sorry that tou are experiencing issues with acme-dns. We just had a similar issue, I wonder if this is the case with your configuration as well: https://github.com/joohoi/acme-dns/issues/93#issuecomment-402906927 On Thu, 9 Aug 2018 at 19.27, LinuxCuba <notifications@github.com> wrote: > After install and config. exec acme-dns > this error not start the service. > INFO[0000] Using config file file=/etc/acme-dns/config.cfg > ERRO[0000] Could not open database [sql: unknown driver "" (forgotten > import?)] > > — > You are receiving this because you are subscribed to this thread. > Reply to this email directly, view it on GitHub > <https://github.com/joohoi/acme-dns/issues/98>, or mute the thread > <https://github.com/notifications/unsubscribe-auth/AE_hpVJcgGeuQc8Wx1yqm7AK_TyILP-mks5uPGMMgaJpZM4V2BT-> > . >
Author
Owner

@LinuxCuba commented on GitHub (Aug 9, 2018):

Yes, but driver is sqlite3 in debian system.

<!-- gh-comment-id:411819770 --> @LinuxCuba commented on GitHub (Aug 9, 2018): Yes, but driver is sqlite3 in debian system.
Author
Owner

@joohoi commented on GitHub (Aug 9, 2018):

Yeah, in the referenced issue, the actual problem was missing quotes around
the configuration value. I believe this is rather config parser than db
driver issue.

On Thu, 9 Aug 2018 at 19.35, LinuxCuba notifications@github.com wrote:

Yes, but driver is sqlite3 in debian system.


You are receiving this because you commented.

Reply to this email directly, view it on GitHub
https://github.com/joohoi/acme-dns/issues/98#issuecomment-411819770, or mute
the thread
https://github.com/notifications/unsubscribe-auth/AE_hpX0cuDM18UOOfVX8w13GM6ADWHe3ks5uPGTMgaJpZM4V2BT-
.

<!-- gh-comment-id:411820670 --> @joohoi commented on GitHub (Aug 9, 2018): Yeah, in the referenced issue, the actual problem was missing quotes around the configuration value. I believe this is rather config parser than db driver issue. On Thu, 9 Aug 2018 at 19.35, LinuxCuba <notifications@github.com> wrote: > Yes, but driver is sqlite3 in debian system. > > — > You are receiving this because you commented. > > > Reply to this email directly, view it on GitHub > <https://github.com/joohoi/acme-dns/issues/98#issuecomment-411819770>, or mute > the thread > <https://github.com/notifications/unsubscribe-auth/AE_hpX0cuDM18UOOfVX8w13GM6ADWHe3ks5uPGTMgaJpZM4V2BT-> > . >
Author
Owner

@LinuxCuba commented on GitHub (Aug 9, 2018):

How to solve and fix this problem please, i need start the server.

<!-- gh-comment-id:411820971 --> @LinuxCuba commented on GitHub (Aug 9, 2018): How to solve and fix this problem please, i need start the server.
Author
Owner

@joohoi commented on GitHub (Aug 9, 2018):

Please see
https://github.com/joohoi/acme-dns/issues/93#issuecomment-402092630

And
https://github.com/joohoi/acme-dns/issues/93#issuecomment-402487006

On Thu, 9 Aug 2018 at 19.39, LinuxCuba notifications@github.com wrote:

How to solve and fix this problem please, i need start the server.


You are receiving this because you commented.

Reply to this email directly, view it on GitHub
https://github.com/joohoi/acme-dns/issues/98#issuecomment-411820971, or mute
the thread
https://github.com/notifications/unsubscribe-auth/AE_hpcXpspBzpGgCXKZUkWtEFmKIIZ4Wks5uPGXAgaJpZM4V2BT-
.

<!-- gh-comment-id:411822295 --> @joohoi commented on GitHub (Aug 9, 2018): Please see https://github.com/joohoi/acme-dns/issues/93#issuecomment-402092630 And https://github.com/joohoi/acme-dns/issues/93#issuecomment-402487006 On Thu, 9 Aug 2018 at 19.39, LinuxCuba <notifications@github.com> wrote: > How to solve and fix this problem please, i need start the server. > > — > You are receiving this because you commented. > > > Reply to this email directly, view it on GitHub > <https://github.com/joohoi/acme-dns/issues/98#issuecomment-411820971>, or mute > the thread > <https://github.com/notifications/unsubscribe-auth/AE_hpcXpspBzpGgCXKZUkWtEFmKIIZ4Wks5uPGXAgaJpZM4V2BT-> > . >
Author
Owner

@joohoi commented on GitHub (Aug 10, 2018):

Are you sure that the file /etc/acme-dns/config.cfg can be read by the user that acme-dns is started with? There is an outstanding PR that makes the error messages more elaborate, but the error you are seeing can also indicate the acme-dns wasn't able to read the configuration file.

<!-- gh-comment-id:412027095 --> @joohoi commented on GitHub (Aug 10, 2018): Are you sure that the file `/etc/acme-dns/config.cfg` can be read by the user that acme-dns is started with? There is an outstanding PR that makes the error messages more elaborate, but the error you are seeing can also indicate the acme-dns wasn't able to read the configuration file.
Author
Owner

@joohoi commented on GitHub (Aug 10, 2018):

If you are building acme-dns from sources, you could try using branch err-handling-suppl which has changes that give some more information about issues in reading the configuration file.

<!-- gh-comment-id:412042606 --> @joohoi commented on GitHub (Aug 10, 2018): ~~If you are building acme-dns from sources, you could try using branch `err-handling-suppl` which has changes that give some more information about issues in reading the configuration file.~~
Author
Owner

@joohoi commented on GitHub (Aug 12, 2018):

The current master as well as the new release v0.5 have vastly improved error messages. You could retry with either of those to figure out what's the underlying issue.

<!-- gh-comment-id:412377396 --> @joohoi commented on GitHub (Aug 12, 2018): The current `master` as well as the new release v0.5 have vastly improved error messages. You could retry with either of those to figure out what's the underlying issue.
Author
Owner

@LinuxCuba commented on GitHub (Aug 13, 2018):

Yes i sure the file config is read by user acme-dns;
root@certbot:/# ls -l /etc/acme-dns total 6 -rw-r--r-- 1 acme-dns acme-dns 2167 Aug 9 17:37 config.cfg
root@certbot:/# ls -ld /etc/acme-dns drwxr-xr-x 2 acme-dns acme-dns 3 Aug 13 11:47 /etc/acme-dns

<!-- gh-comment-id:412492459 --> @LinuxCuba commented on GitHub (Aug 13, 2018): Yes i sure the file config is read by user acme-dns; `root@certbot:/# ls -l /etc/acme-dns total 6 -rw-r--r-- 1 acme-dns acme-dns 2167 Aug 9 17:37 config.cfg ` `root@certbot:/# ls -ld /etc/acme-dns drwxr-xr-x 2 acme-dns acme-dns 3 Aug 13 11:47 /etc/acme-dns`
Author
Owner

@joohoi commented on GitHub (Aug 13, 2018):

If you are not able to figure out the underlying issue by trying to run the latest version (the Docker Hub container image is also updated), could you please pastebin the contents of your config.cfg. GitHub formatting often breaks because of the config syntax.

<!-- gh-comment-id:412493257 --> @joohoi commented on GitHub (Aug 13, 2018): If you are not able to figure out the underlying issue by trying to run the latest version (the Docker Hub container image is also updated), could you please pastebin the contents of your `config.cfg`. GitHub formatting often breaks because of the config syntax.
Author
Owner

@LinuxCuba commented on GitHub (Aug 13, 2018):

How to update, replaced all fille??

<!-- gh-comment-id:412493794 --> @LinuxCuba commented on GitHub (Aug 13, 2018): How to update, replaced all fille??
Author
Owner

@joohoi commented on GitHub (Aug 13, 2018):

I would delete the files you have installed now, and start the installation from the beginning.

<!-- gh-comment-id:412493990 --> @joohoi commented on GitHub (Aug 13, 2018): I would delete the files you have installed now, and start the installation from the beginning.
Author
Owner

@LinuxCuba commented on GitHub (Aug 13, 2018):

ohh bad.

<!-- gh-comment-id:412494266 --> @LinuxCuba commented on GitHub (Aug 13, 2018): ohh bad.
Author
Owner

@LinuxCuba commented on GitHub (Aug 13, 2018):

Update acme-dns this the new error in release v0.5
root@certbot:/# acme-dns INFO[0000] Using config file file=/etc/acme-dns/config.cfg ERRO[0000] Encountered an error while trying to read configuration file: Near line 45 (last key parsed 'api'): expected a top-level item to end with a newline, comment, or EOF, but got 't' instead

<!-- gh-comment-id:412502556 --> @LinuxCuba commented on GitHub (Aug 13, 2018): Update acme-dns this the new error in release v0.5 `root@certbot:/# acme-dns INFO[0000] Using config file file=/etc/acme-dns/config.cfg ERRO[0000] Encountered an error while trying to read configuration file: Near line 45 (last key parsed 'api'): expected a top-level item to end with a newline, comment, or EOF, but got 't' instead`
Author
Owner

@joohoi commented on GitHub (Aug 13, 2018):

Yeah, there seems to be a syntax error in your configuration file. Please double verify.

<!-- gh-comment-id:412502901 --> @joohoi commented on GitHub (Aug 13, 2018): Yeah, there seems to be a syntax error in your configuration file. Please double verify.
Author
Owner

@LinuxCuba commented on GitHub (Aug 13, 2018):

corrected in api the value of the tls change let`s encrypt by cert, but now I get a new unknown error.

INFO[0000] Using config file file=/etc/acme-dns/config.cfg ERRO[0000] Encountered an error while trying to read configuration file: toml: cannot load TOML value of type string into a Go boolean

<!-- gh-comment-id:412505087 --> @LinuxCuba commented on GitHub (Aug 13, 2018): corrected in api the value of the tls change let`s encrypt by cert, but now I get a new unknown error. `INFO[0000] Using config file file=/etc/acme-dns/config.cfg ERRO[0000] Encountered an error while trying to read configuration file: toml: cannot load TOML value of type string into a Go boolean`
Author
Owner

@joohoi commented on GitHub (Aug 13, 2018):

Check the default config.cfg against your edited configuration, and look for quote marks ( " ). Boolean values should not be quoted.

<!-- gh-comment-id:412505508 --> @joohoi commented on GitHub (Aug 13, 2018): Check the default `config.cfg` against your edited configuration, and look for quote marks ( `"` ). Boolean values should not be quoted.
Author
Owner

@LinuxCuba commented on GitHub (Aug 13, 2018):

Yes already worked, it had a double quote in a Boolean value.
but this error when trying read the datebase.
ERRO[0000] Could not open database [file is not a database]
How to create the database and what is your structure?

<!-- gh-comment-id:412511044 --> @LinuxCuba commented on GitHub (Aug 13, 2018): Yes already worked, it had a double quote in a Boolean value. but this error when trying read the datebase. `ERRO[0000] Could not open database [file is not a database]` How to create the database and what is your structure?
Author
Owner

@LinuxCuba commented on GitHub (Aug 13, 2018):

Remove the file /var/lib/acme-dns/acme-dns.db, and start again, and work perfect. Thank.

<!-- gh-comment-id:412511524 --> @LinuxCuba commented on GitHub (Aug 13, 2018): Remove the file /var/lib/acme-dns/acme-dns.db, and start again, and work perfect. Thank.
Author
Owner

@LinuxCuba commented on GitHub (Aug 13, 2018):

Another problem, it works in the terminal with the acme-dns command executing directly, but it does not start the service with systemd.

<!-- gh-comment-id:412515371 --> @LinuxCuba commented on GitHub (Aug 13, 2018): Another problem, it works in the terminal with the acme-dns command executing directly, but it does not start the service with systemd.
Author
Owner

@joohoi commented on GitHub (Aug 14, 2018):

it works in the terminal with the acme-dns command executing directly, but it does not start the service with systemd

I don't have a direct answer to that one, as I don't know what the problem might be. Some things you could check:

  • If the systemd service specifies a unprivileged user for running acme-dns, check that the configuration path is readable by that user, and the database is writable by the said user.
  • acme-dns exists on a correct path
  • If acme-dns is configured to serve on default (privileged) ports, make sure it has the privileges to do so.
<!-- gh-comment-id:412789928 --> @joohoi commented on GitHub (Aug 14, 2018): > it works in the terminal with the acme-dns command executing directly, but it does not start the service with systemd I don't have a direct answer to that one, as I don't know what the problem might be. Some things you could check: - If the systemd service specifies a unprivileged user for running acme-dns, check that the configuration path is readable by that user, and the database is writable by the said user. - acme-dns exists on a correct path - If acme-dns is configured to serve on default (privileged) ports, make sure it has the privileges to do so.
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
starred/acme-dns#40
No description provided.