Error on next cloud

Support intro

Sorry to hear you’re facing problems. :slightly_frowning_face:

The community help forum (help.nextcloud.com) is for home and non-enterprise users. Support is provided by other community members on a best effort / “as available” basis. All of those responding are volunteering their time to help you.

If you’re using Nextcloud in a business/critical setting, paid and SLA-based support services can be accessed via portal.nextcloud.com where Nextcloud engineers can help ensure your business keeps running smoothly.

Getting help

In order to help you as efficiently (and quickly!) as possible, please fill in as much of the below requested information as you can.

Before clicking submit: Please check if your query is already addressed via the following resources:

(Utilizing these existing resources is typically faster. It also helps reduce the load on our generous volunteers while elevating the signal to noise ratio of the forums otherwise arising from the same queries being posted repeatedly).

Some or all of the below information will be if it isn’t supplied; for fastest

I’m new to nextcloud and today when I copied over files and ran a occ command it picked up all the files but when I try to upload from android I get permission error and I changed the permissions using

sudo chown -R www-data:www-data /mnt/cloud/nextcloud

I get Error

Configuration was not read or initialized correctly, not overwriting /app/www/public/config/config.php

My config file is

GNU nano 8.4 docker-compose.yml

-–

services:

nextcloud:

image: lscr.io/linuxserver/nextcloud:latest

container_name: nextcloud

environment:

  - PUID=1000

  - PGID=1000

  - TZ=Etc/UTC

volumes:

  - /mnt/cloud/nextcloud/config:/config

  - /mnt/cloud/nextcloud/data:/data

ports:

  - 447:443
 -8080:80
restart: unless-stopped

Portainer log

ctions

usermod: no changes

───────────────────────────────────────

  ██╗     ███████╗██╗ ██████╗

  ██║     ██╔════╝██║██╔═══██╗

  ██║     ███████╗██║██║   ██║

  ██║     ╚════██║██║██║   ██║

  ███████╗███████║██║╚██████╔╝

  ╚══════╝╚══════╝╚═╝ ╚═════╝

Brought to you by linuxserver.io

───────────────────────────────────────

To support LSIO projects visit:

───────────────────────────────────────

GID/UID

───────────────────────────────────────

User UID: 1000

User GID: 1000

───────────────────────────────────────

Linuxserver.io version: 34.0.3-ls447

Build-date: 2026-08-25T12:06:59+00:00

───────────────────────────────────────

using keys found in /config/keys

[custom-init] No custom files found, skipping…

[ls.io-init] done.

Cannot write into “config” directory!

This can usually be fixed by giving the web server write access to the config directory.

But, if you prefer to keep config.php file read only, set the option “config_is_read_only” to true in it.

See Documentation Redirect

2026-09-01T09:50:00+00:00 3 fopen(/app/www/public/config/config.php): Failed to open stream: Permission denied at /app/www/public/lib/private/Config.php#221 | reqId=3v6Qls8vhPLib7xYFUd0 remoteAddr= user=-- app=PHP method= url=-- scriptName=/app/www/public/cron.php userAgent=-- version= occ_command=[“/app/www/public/cron.php”] data={“app”:“PHP”}

[migrations] started

[migrations] 01-nginx-site-confs-default: skipped

[migrations] 02-default-location: skipped

[migrations] done

usermod: no changes

───────────────────────────────────────

  ██╗     ███████╗██╗ ██████╗

  ██║     ██╔════╝██║██╔═══██╗

  ██║     ███████╗██║██║   ██║

  ██║     ╚════██║██║██║   ██║

  ███████╗███████║██║╚██████╔╝

  ╚══════╝╚══════╝╚═╝ ╚═════╝

Brought to you by linuxserver.io

───────────────────────────────────────

To support LSIO projects visit:

───────────────────────────────────────

GID/UID

───────────────────────────────────────

User UID: 1000

User GID: 1000

───────────────────────────────────────

Linuxserver.io version: 34.0.3-ls447

Build-date: 2026-08-25T12:06:59+00:00

───────────────────────────────────────

using keys found in /config/keys

[custom-init] No custom files found, skipping…

[ls.io-init] done.

Cannot write into “config” directory!

This can usually be fixed by giving the web server write access to the config directory.

But, if you prefer to keep config.php file read only, set the option “config_is_read_only” to true in it.

See Documentation Redirect

2026-09-01T09:55:00+00:00 3 fopen(/app/www/public/config/config.php): Failed to open stream: Permission denied at /app/www/public/lib/private/Config.php#221 | reqId=rM7bVXTZyrOWgBvtcthI remoteAddr= user=-- app=PHP method= url=-- scriptName=/app/www/public/cron.php userAgent=-- version= occ_command=[“/app/www/public/cron.php”] data={“app”:“PHP”}

Cannot write into “config” directory!

This can usually be fixed by giving the web server write access to the config directory.

But, if you prefer to keep config.php file read only, set the option “config_is_read_only” to true in it.

See Documentation Redirect

2026-09-01T10:00:00+00:00 3 fopen(/app/www/public/config/config.php): Failed to open stream: Permission denied at /app/www/public/lib/private/Config.php#221 | reqId=2I8pbXnmlG2MBbPtbza7 remoteAddr= user=-- app=PHP method= url=-- scriptName=/app/www/public/cron.php userAgent=-- version= occ_command=[“/app/www/public/cron.php”] data={“app”:“PHP”}

Cannot write into “config” directory!

This can usually be fixed by giving the web server write access to the config directory.

But, if you prefer to keep config.php file read only, set the option “config_is_read_only” to true in it.

See Documentation Redirect

2026-09-01T10:05:00+00:00 3 fopen(/app/www/public/config/config.php): Failed to open stream: Permission denied at /app/www/public/lib/private/Config.php#221 | reqId=YpVrLd7xZVi95gZ0BaKL remoteAddr= user=-- app=PHP method= url=-- scriptName=/app/www/public/cron.php userAgent=-- version= occ_command=[“/app/www/public/cron.php”] data={“app”:“PHP”}

Cannot write into “config” directory!

This can usually be fixed by giving the web server write access to the config directory.

But, if you prefer to keep config.php file read only, set the option “config_is_read_only” to true in it.

See Documentation Redirect

2026-09-01T10:10:00+00:00 3 fopen(/app/www/public/config/config.php): Failed to open stream: Permission denied at /app/www/public/lib/private/Config.php#221 | reqId=BDYTigOt3OE7cy1wUdll remoteAddr= user=-- app=PHP method= url=-- scriptName=/app/www/public/cron.php userAgent=-- version= occ_command=[“/app/www/public/cron.php”] data={“app”:“PHP”}

Cannot write into “config” directory!

This can usually be fixed by giving the web server write access to the config directory.

But, if you prefer to keep config.php file read only, set the option “config_is_read_only” to true in it.

See Documentation Redirect

2026-09-01T10:15:00+00:00 3 fopen(/app/www/public/config/config.php): Failed to open stream: Permission denied at /app/www/public/lib/private/Config.php#221 | reqId=R5jZyByDzALuq66xG2q4 remoteAddr= user=-- app=PHP method= url=-- scriptName=/app/www/public/cron.php userAgent=-- version= occ_command=[“/app/www/public/cron.php”] data={“app”:“PHP”}