Unable to start - unexpected end of JSON input

Hello,

Very rarely do I get stuck with caddy, and this is one of those very rarelys :\

× caddy.service - Caddy web server
     Loaded: loaded (/usr/lib/systemd/system/caddy.service; enabled; preset: disabled)
    Drop-In: /etc/systemd/system/caddy.service.d
             └─override.conf
     Active: failed (Result: exit-code) since Wed 2024-08-21 00:14:04 CDT; 9min ago
 Invocation: 1fcf7694c331455a9c88b27dc4a8e967
       Docs: https://caddyserver.com/docs/
    Process: 2350 ExecStartPre=/usr/local/bin/caddy validate --config /etc/caddy/Caddyfile (code=exited, status=0/SUCCESS)
    Process: 4020 ExecStart=/usr/local/bin/caddy run --environ --config /etc/caddy/Caddyfile (code=exited, status=1/FAILURE)
    Process: 4238 ExecStopPost=/usr/bin/rm -f /run/caddy/admin.socket (code=exited, status=0/SUCCESS)
   Main PID: 4020 (code=exited, status=1/FAILURE)
     Status: "loading new config: http app module: start: finalizing automatic HTTPS: managing certificates for [1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17]: automate: manage [1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17]: 1: caching certificate: decoding certificate metadata: unexpected end of JSON input"
   Mem peak: 57M
        CPU: 304ms

Aug 21 00:14:04 cirrus caddy[4020]: XDG_DATA_HOME=/var/lib
Aug 21 00:14:04 cirrus caddy[4020]: XDG_CONFIG_HOME=/etc
Aug 21 00:14:04 cirrus caddy[4020]: VARIABLE=VALUE
Aug 21 00:14:04 cirrus caddy[4020]: {"level":"info","ts":1724217244.3087733,"msg":"using config from file","file":"/etc/caddy/Caddyfile"}
Aug 21 00:14:04 cirrus caddy[4020]: {"level":"info","ts":1724217244.3153036,"msg":"adapted config to JSON","adapter":"caddyfile"}
Aug 21 00:14:04 cirrus caddy[4020]: {"level":"info","ts":1724217244.3219929,"msg":"redirected default logger","from":"stderr","to":"/var/log/caddy/access.log"}
Aug 21 00:14:04 cirrus caddy[4020]: Error: loading initial config: loading new config: http app module: start: finalizing automatic HTTPS: managing certificates for [1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17]: automate: manage [1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17]: 1: caching certificate: decoding certificate metadata: unexpected end of JSON input
Aug 21 00:14:04 cirrus systemd[1]: caddy.service: Main process exited, code=exited, status=1/FAILURE
Aug 21 00:14:04 cirrus systemd[1]: caddy.service: Failed with result 'exit-code'.
Aug 21 00:14:04 cirrus systemd[1]: Failed to start Caddy web server.
  • domains and env var have been changed for obvious reasons
  • ive used xcaddy to build with a specific dns plugin since the dawn of time
  • i use arch btw

ive checked perms, rebuilt, updated, rebooted, cracked forehead, cracked monitor, cracked keyboard, im stumped

edit: /var/log/caddy/access.log shows
2024/08/21 05:14:04.356 ERROR tls could not clean default/global storage {"error": "unable to acquire storage_clean lock: context canceled"}
I moved storage_clean.lock and attempted to start again, same fail, same logs

Blowing out /var/lib/caddy and reinstalling upstream package seems to have got passed whatever block this was. Weird.

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.