AIO broken with an empty configuration.json

The Basics

  • Nextcloud Server version (e.g., 29.x.x):
    • 31.0.8.1
  • Operating system and version (e.g., Ubuntu 24.04):
    • OpenSuse Tumbleweed
  • Web server and version (e.g, Apache 2.4.25):
    • What ever AIO uses
  • Reverse proxy and version _(e.g. nginx 1.27.2)
    * nginx/1.29.5
  • PHP version (e.g, 8.3):
    • What ever AIO uses
  • Is this the first time you’ve seen this error? (Yes / No):
    • First I’ve noticed it
  • When did this problem seem to first start?
    • when 31 was current
  • Installation method (e.g. AlO, NCP, Bare Metal/Archive, etc.)
    • AIO
  • Are you using CloudfIare, mod_security, or similar? (Yes / No)
    • Nope

Summary of the issue you are facing:

Noticed my install was old, so I went to log into the AIO interface to see why I hadn’t been updated, and couldn’t.

Digging through logs and finding similar answer lead me to discover configuration.json is empty

Steps to replicate it (hint: details matter!):

  1. Attempt to load https://myserver:11088/login (AIO interface)

  2. get: Slim Application Error

    A website error has occurred. Sorry for the temporary inconvenience.

Log entries

Nextcloud

Logs from docker log nextcloud-aio-mastercontainer

[10-Apr-2026 02:53:35] NOTICE: exiting, bye-bye!
Initial startup of Nextcloud All-in-One complete!
You should be able to open the Nextcloud AIO Interface now on port 8080 of this server!
E.g. https://internal.ip.of.this.server:8080
⚠️ Important: do always use an ip-address if you access this port and not a domain as HSTS might block access to it later!

If your server has port 80 and 8443 open and you point a domain to your server, you can get a valid certificate automatically by opening the Nextcloud AIO Interface via:
https://your-domain-that-points-to-this-server.tld:8443
++ head -1 /mnt/docker-aio-config/data/daily_backup_time
+ BACKUP_TIME=16:00
+ export BACKUP_TIME
+ export DAILY_BACKUP=1
+ DAILY_BACKUP=1
++ sed -n 2p /mnt/docker-aio-config/data/daily_backup_time
+ '[' '' '!=' automaticUpdatesAreNotEnabled ']'
+ export AUTOMATIC_UPDATES=1
+ AUTOMATIC_UPDATES=1
++ sed -n 3p /mnt/docker-aio-config/data/daily_backup_time
+ '[' '' '!=' successNotificationsAreNotEnabled ']'
+ export SEND_SUCCESS_NOTIFICATIONS=1
+ SEND_SUCCESS_NOTIFICATIONS=1
+ set +x
[10-Apr-2026 02:53:50] NOTICE: fpm is running, pid 165
[10-Apr-2026 02:53:50] NOTICE: ready to handle connections
NOTICE: PHP message: Slim Application Error
Type: JsonException
Code: 4
Message: Syntax error
File: /var/www/docker-aio/php/src/Data/ConfigurationManager.php
Line: 297
Trace: #0 /var/www/docker-aio/php/src/Data/ConfigurationManager.php(297): json_decode('', true, 512, 4194304)
#1 /var/www/docker-aio/php/src/Data/ConfigurationManager.php(304): AIO\Data\ConfigurationManager->getConfig()
#2 /var/www/docker-aio/php/src/Data/ConfigurationManager.php(188): AIO\Data\ConfigurationManager->get('aio_community_c...', '')
#3 /var/www/docker-aio/php/src/ContainerDefinitionFetcher.php(45): AIO\Data\ConfigurationManager->$aioCommunityContainers::get()
#4 /var/www/docker-aio/php/src/ContainerDefinitionFetcher.php(364): AIO\ContainerDefinitionFetcher->GetDefinition()
#5 /var/www/docker-aio/php/src/ContainerDefinitionFetcher.php(26): AIO\ContainerDefinitionFetcher->FetchDefinition()
#6 /var/www/docker-aio/php/src/Docker/DockerActionManager.php(922): AIO\ContainerDefinitionFetcher->GetContainerById('nextcloud-aio-a...')
#7 /var/www/docker-aio/php/public/index.php(152): AIO\Docker\DockerActionManager->isLoginAllowed()
#8 /var/www/docker-aio/php/vendor/slim/slim/Slim/Handlers/Strategies/RequestResponse.php(39): Closure->{closure:/var/www/docker-aio/php/public/index.php:147}(Object(Slim\Psr7\Request), Object(Slim\Psr7\Response), Array)
#9 /var/www/docker-aio/php/vendor/slim/slim/Slim/Routing/Route.php(362): Slim\Handlers\Strategies\RequestResponse->__invoke(Object(Closure), Object(Slim\Psr7\Request), Object(Slim\Psr7\Response), Array)
#10 /var/www/docker-aio/php/vendor/slim/slim/Slim/MiddlewareDispatcher.php(73): Slim\Routing\Route->handle(Object(Slim\Psr7\Request))
#11 /var/www/docker-aio/php/vendor/slim/slim/Slim/MiddlewareDispatcher.php(73): Slim\MiddlewareDispatcher->handle(Object(Slim\Psr7\Request))
#12 /var/www/docker-aio/php/vendor/slim/slim/Slim/Routing/Route.php(321): Slim\MiddlewareDispatcher->handle(Object(Slim\Psr7\Request))
#13 /var/www/docker-aio/php/vendor/slim/slim/Slim/Routing/RouteRunner.php(74): Slim\Routing\Route->run(Object(Slim\Psr7\Request))
#14 /var/www/docker-aio/php/vendor/slim/csrf/src/Guard.php(482): Slim\Routing\RouteRunner->handle(Object(Slim\Psr7\Request))
#15 /var/www/docker-aio/php/vendor/slim/slim/Slim/MiddlewareDispatcher.php(178): Slim\Csrf\Guard->process(Object(Slim\Psr7\Request), Object(Slim\Routing\RouteRunner))
#16 /var/www/docker-aio/php/vendor/slim/twig-view/src/TwigMiddleware.php(117): Psr\Http\Server\RequestHandlerInterface@anonymous->handle(Object(Slim\Psr7\Request))
#17 /var/www/docker-aio/php/vendor/slim/slim/Slim/MiddlewareDispatcher.php(129): Slim\Views\TwigMiddleware->process(Object(Slim\Psr7\Request), Object(Psr\Http\Server\RequestHandlerInterface@anonymous))
#18 /var/www/docker-aio/php/src/Middleware/AuthMiddleware.php(54): Psr\Http\Server\RequestHandlerInterface@anonymous->handle(Object(Slim\Psr7\Request))
#19 /var/www/docker-aio/php/vendor/slim/slim/Slim/MiddlewareDispatcher.php(283): AIO\Middleware\AuthMiddleware->__invoke(Object(Slim\Psr7\Request), Object(Psr\Http\Server\RequestHandlerInterface@anonymous))
#20 /var/www/docker-aio/php/vendor/slim/slim/Slim/Middleware/ErrorMiddleware.php(77): Psr\Http\Server\RequestHandlerInterface@anonymous->handle(Object(Slim\Psr7\Request))
#21 /var/www/docker-aio/php/vendor/slim/slim/Slim/MiddlewareDispatcher.php(129): Slim\Middleware\ErrorMiddleware->process(Object(Slim\Psr7\Request), Object(Psr\Http\Server\RequestHandlerInterface@anonymous))
#22 /var/www/docker-aio/php/vendor/slim/slim/Slim/MiddlewareDispatcher.php(73): Psr\Http\Server\RequestHandlerInterface@anonymous->handle(Object(Slim\Psr7\Request))
#23 /var/www/docker-aio/php/vendor/slim/slim/Slim/App.php(209): Slim\MiddlewareDispatcher->handle(Object(Slim\Psr7\Request))
#24 /var/www/docker-aio/php/vendor/slim/slim/Slim/App.php(193): Slim\App->handle(Object(Slim\Psr7\Request))
#25 /var/www/docker-aio/php/public/index.php(220): Slim\App->run()
#26 {main}
Tips: To display error details in HTTP response set "displayErrorDetails" to true in the ErrorHandler constructor.Configuration

Others did not seam applicable to this.

My docker volume for the mastercontainer has not had it’s name changed.

I have had disks fill in the past year, ending up with an empty config file is not a great result if that was the cause :frowning:

NB: NextCloud it self appears to be running fine, which is why I haven’t noticed this for so long.

Yeah this is likely the reason…

I hope you created at least one backup before the configuration file was truncated?

This isn’t considered a serious bug?

I will start looking at restore from backup procedures.

Sure doesn’t mention anything about restoring configuration.yaml from a borg backup.

So I have to spin up a new AIO instance to restore? Is that going to want to create a new NextCloud instance and need to copy in all the data?

If you’ve created a borg backup earlier, you should be able to access it and restore the json via GitHub - nextcloud/all-in-one: 📦 The official Nextcloud installation method. Provides easy deployment and maintenance with most features included in this one Nextcloud instance. · GitHub

FYI: we will try to make the internal logic even more fail-proof in the future: Configurationmanager.php: atomic write for configuration.json to prevent truncation on low disk by Copilot · Pull Request #7888 · nextcloud/all-in-one · GitHub

gareth@cube-server:/torrents/backups/nextcloudAIO$ sudo borg list ./borg
Enter passphrase for key /torrents/backups/nextcloudAIO/borg: 
[10.798s] --> [0]
gareth@cube-server:/torrents/backups/nextcloudAIO$ sudo du -sh borg
168G    borg
[0.079s] --> [0]
gareth@cube-server:/torrents/backups/nextcloudAIO$ 

Hrm, that is a lot of data with nothing in it….

Is there any way for me to plausibly hand craft a useful configuration.json?

I mean there is this subfolder. Have you tried following the docs that I’ve sent above?

Sorry, I skipped the vital bit of:

I tried the linked instructions and the mounted dir was empty.

Then I tried some intuitive diagnostic options and got no errors, but nothing telling me that there is any data to see.

edit, log of mounting and having no data to see:

gareth@cube-server:/torrents/backups/nextcloudAIO$ sudo mkdir -p /tmp/borg && sudo borg mount "$BORG_REPO" /tmp/borg
[sudo] password for root: 
Enter passphrase for key /torrents/backups/nextcloudAIO/borg: 
fuse: warning: library too old, some operations may not work
[21.063s] --> [0]
gareth@cube-server:/torrents/backups/nextcloudAIO$ sudo ls /tmp/borg
[0.059s] --> [0]
gareth@cube-server:/torrents/backups/nextcloudAIO$ 

This might be the reason. Can you upgrade the borg and or fuse version?

Updating Suse TumbleWeed didn’t help.

I’ll try the container mentioned in that instruction next.

Is the contents of this config file full of secret keys or something? Why aren’t I just making a new config file?

Or I wont be….

After adding and starting the container, you need to visit https://ip.address.of.this.server:5801 in order to log in with the user nextcloud and the password that you can see next to the container in the AIO interface. (The web page uses a self-signed certificate, so you need to accept the warning).

Yes it is…

Weird, the only encryption is the borg backup that doesn’t appear to be worth anything….

New AIO install and move users/etc to it should work I guess.

Okay, I tried a thing, and I’m wondering if the step I reached is a good sign or not.

Wanting to see how much secret sauce was in the configuration.json, I tried to spin up an AIO install on my desktop. When greeted with the AIO setup screens I thought, hrm, maybe this will be happy with the borg backup and tried the remote borg restore.

Does that process getting to the step where it spawns the domaincheck container mean it successfully read from the borg backup, or does it do the domaincheck first? (domain check will 100% fail, no domain is forwarded to this box)

Yeah this is another way to restore thr instance. Did you suceed indoing so?

It got to the domaincheck step, but I expect it to fail there. Does that mean it has retrieved from borg?

image

No, if you scroll down in the first setup page when starting a new AIO instance you can either create a new aio instance or restore an old aio instance from borg backup. Basically start at step 11 here: GitHub - nextcloud/all-in-one: 📦 The official Nextcloud installation method. Provides easy deployment and maintenance with most features included in this one Nextcloud instance. · GitHub