Skip to content

[Bug]: Integrity checks wrongly flags log files #65923

Closed as not planned
Closed as not planned

Description

@lollo03

⚠️ This issue respects the following points: ⚠️

  • This is not a troubleshooting question, general support matter, or webserver/proxy problem, but likely a bug (if unsure, ask the Community Help Forum).
  • This issue is not already reported on Github OR solved at the Community Help Forum (I've searched!).
  • I'm using a maintained major version of Nextcloud Server and tested against the latest patch level. (Supported major versions and current patch levels).
  • I agree to follow Nextcloud's Code of Conduct.
  • I've tried my best to provide clear reproduction steps that someone unfamiliar with this bug could use to reproduce it.

Bug description

I am using nextcloud helm chart 9.4.1 . Upgraded to latest version from 9.2.*
Integrity check keep failing, in particular a nextcloud.log file keep spawning in /var/www/html and /var/www/html/ocs

I try deleting this files, but they keep spawining and the integrity check keeps failing.

Steps to reproduce

  1. Upgrade helm from 9.2.* to 9.4.1
  2. Run an integrity check php occ integrity:check-core
  3. Remove the 2 .log files
  4. Wait a little bit
  5. Run the integrity check

Expected behavior

I expect the integrity check to not fail for 2 log files or the log files to be created in the correct directory

Nextcloud Server version

35

Operating system

Other

PHP engine version

PHP 8.5

Web server

Apache (supported)

Database engine version

PostgreSQL

Is this bug present after an update or on a fresh install?

Upgraded to a MAJOR version (ex. 31 to 32)

Are you using the Nextcloud Server Encryption module?

Encryption is Disabled

What user-backends are you using?

  • Default user-backend (database)
  • LDAP/ Active Directory
  • SSO - SAML
  • Other

Configuration report

{
    "system": {
        "htaccess.RewriteBase": "\/",
        "memcache.local": "\\OC\\Memcache\\APCu",
        "apps_paths": [
            {
                "path": "\/var\/www\/html\/apps",
                "url": "\/apps",
                "writable": false
            },
            {
                "path": "\/var\/www\/html\/custom_apps",
                "url": "\/custom_apps",
                "writable": true
            }
        ],
        "upgrade.disable-web": true,
        "passwordsalt": "***REMOVED SENSITIVE VALUE***",
        "secret": "***REMOVED SENSITIVE VALUE***",
        "trusted_domains": [
            "nextcloud.lolloandr.com",
            "nextcloud.nextcloud.svc.cluster.local"
        ],
        "datadirectory": "***REMOVED SENSITIVE VALUE***",
        "dbtype": "pgsql",
        "version": "35.0.2.2",
        "overwrite.cli.url": "https:\/\/nextcloud.lolloandr.com",
        "dbname": "***REMOVED SENSITIVE VALUE***",
        "instanceid": "***REMOVED SENSITIVE VALUE***",
        "dbhost": "***REMOVED SENSITIVE VALUE***",
        "dbtableprefix": "oc_",
        "dbuser": "***REMOVED SENSITIVE VALUE***",
        "dbpassword": "***REMOVED SENSITIVE VALUE***",
        "installed": true,
        "config_preset": 1,
        "log_type": "file",
        "logfile": "nextcloud.log",
        "loglevel": 0,
        "logdateformat": "F d, Y H:i:s",
        "memcache.distributed": "\\OC\\Memcache\\Redis",
        "memcache.locking": "\\OC\\Memcache\\Redis",
        "redis": {
            "host": "***REMOVED SENSITIVE VALUE***",
            "password": "***REMOVED SENSITIVE VALUE***",
            "port": 6379
        },
        "overwriteprotocol": "https",
        "trusted_proxies": "***REMOVED SENSITIVE VALUE***",
        "maintenance": false,
        "mail_smtpmode": "smtp",
        "mail_sendmailmode": "smtp",
        "mail_from_address": "***REMOVED SENSITIVE VALUE***",
        "mail_domain": "***REMOVED SENSITIVE VALUE***",
        "mail_smtphost": "***REMOVED SENSITIVE VALUE***",
        "mail_smtpauth": true,
        "mail_smtpname": "***REMOVED SENSITIVE VALUE***",
        "mail_smtppassword": "***REMOVED SENSITIVE VALUE***",
        "mail_smtpport": "465",
        "mail_smtpsecure": "ssl",
        "forbidden_filename_characters": [
            "\\",
            "\/"
        ],
        "forbidden_filename_extensions": [
            ".filepart",
            ".part"
        ],
        "openmetrics_allowed_clients": [
            "127.0.0.1",
            "10.42.0.0\/16",
            "10.43.0.0\/16"
        ]
    }
}

List of activated Apps

Enabled:
  - activity: 8.0.0
  - app_api: 35.0.0
  - appstore: 2.0.0
  - bruteforcesettings: 8.0.0
  - circles: 35.0.0
  - cloud_federation_api: 2.0.0
  - comments: 2.0.0
  - contactsinteraction: 2.0.0
  - dashboard: 8.0.0
  - dav: 2.0.0
  - federatedfilesharing: 2.0.0
  - federation: 2.0.0
  - files: 3.0.0
  - files_downloadlimit: 5.3.0
  - files_lock: 35.0.1
  - files_pdfviewer: 8.0.0
  - files_reminders: 2.0.0
  - files_sharing: 2.0.0
  - files_trashbin: 2.0.0
  - files_versions: 2.0.0
  - firstrunwizard: 8.0.0
  - logreader: 8.0.0
  - lookup_server_connector: 2.0.0
  - mail: 5.10.5
  - nextcloud_announcements: 7.0.0
  - notifications: 8.0.1
  - oauth2: 2.0.0
  - office: 1.1.0
  - password_policy: 7.0.0
  - privacy: 7.0.0
  - profile: 2.0.0
  - provisioning_api: 2.0.0
  - recommendations: 8.0.0
  - related_resources: 6.0.0
  - serverinfo: 7.0.0
  - settings: 2.0.0
  - sharebymail: 2.0.0
  - sharing: 1.0.4
  - support: 7.0.0
  - survey_client: 7.0.0
  - systemtags: 2.0.0
  - text: 9.0.1
  - theming: 3.0.0
  - twofactor_backupcodes: 2.0.0
  - twofactor_totp: 17.1.0
  - updatenotification: 2.0.0
  - user_status: 2.0.0
  - viewer: 8.0.0
  - weather_status: 2.0.0
  - webhook_listeners: 2.0.0
  - workflowengine: 3.0.0
Disabled:
  - admin_audit: 2.0.0
  - calendar: 6.5.0 (installed 6.5.0)
  - encryption: 3.0.1
  - files_external: 2.0.0
  - photos: 8.0.0 (installed 5.0.0-dev.1)
  - suspicious_login: 13.0.0
  - twofactor_nextcloud_notification: 9.0.0
  - user_ldap: 2.0.0

Nextcloud Signing status

Technical information
=====================
The following list covers which files have failed the integrity check. Please read
the previous linked documentation to learn more about the errors and how to fix
them.

Results
=======
- core
	- EXTRA_FILE
		- nextcloud.log

Raw output
==========
Array
(
    [core] => Array
        (
            [EXTRA_FILE] => Array
                (
                    [nextcloud.log] => Array
                        (
                            [expected] => 
                            [current] => 3c0223cde3afa9cf8df6a920ded7d849d849f0a54de5b35b8bcb9bab84cd333ec2dfbb061cfc32bb7f836ef6afe69dafeb80488e881fc6bd8c4f2c5da4c11cef
                        )

                )

        )

)

Nextcloud Logs

Additional info

No response

Activity

  1. added
    0. Needs triage
    on Oct 26, 2026
  2. added theissue type on Oct 26, 2026
  3. changed the title [-][Bug]:[/-] [+][Bug]: Integrity checks wrongly flags log files[/+] on Oct 26, 2026
  4. stefangweichinger commented on Oct 29, 2026

    @stefangweichinger

    I see similar issues with files like: nextcloud/app/tmp/sfi_file_sequence_oc65lc0lmz8d/*

    I remove, rescan .. warning is gone, files are recreated, integrity check fails again

  5. joshtrichards commented on Nov 1, 2026

    @joshtrichards
    Member
        "logfile": "nextcloud.log",
    

    See https://docs.nextcloud.com/server/latest/admin_manual/configuration_server/config_sample_php_parameters.html#logfile

    Generally not needed if you want logging to your data directory. Otherwise use an absolute path.

  6. joshtrichards commented on Nov 1, 2026

    @joshtrichards
    Member

    @stefangweichinger Yours also sounds like a config matter, albeit a different one, related to your Nextcloud or PHP temp directory config. Use the help forum or Admin Manual for assistance: https://help.nextcloud.com and https://docs.nextcloud.co!

  7. lollo03 commented on Nov 5, 2026

    @lollo03
    Author

    @joshtrichards I am using the helm chart. I didn't made any modification regarding logging in the values.yaml file.
    I don't think this is a configuration issue.
    If i describe my deployment you can see that the config is imported from the nextcloud-config configMap:

        Mounts:
          /var/www/ from nextcloud-main (rw,path="root")
          /var/www/html from nextcloud-main (rw,path="html")
          /var/www/html/config from nextcloud-main (rw,path="config")
          /var/www/html/config/.htaccess from nextcloud-config (rw,path=".htaccess")
          /var/www/html/config/apache-pretty-urls.config.php from nextcloud-config (rw,path="apache-pretty-urls.config.php")
          /var/www/html/config/apcu.config.php from nextcloud-config (rw,path="apcu.config.php")
          /var/www/html/config/apps.config.php from nextcloud-config (rw,path="apps.config.php")
          /var/www/html/config/autoconfig.php from nextcloud-config (rw,path="autoconfig.php")
          /var/www/html/config/helm-metrics.config.php from nextcloud-config (rw,path="helm-metrics.config.php")
          /var/www/html/config/helm-metrics.php from nextcloud-config (rw,path="helm-metrics.php")
          /var/www/html/config/redis.config.php from nextcloud-config (rw,path="redis.config.php")
          /var/www/html/config/reverse-proxy.config.php from nextcloud-config (rw,path="reverse-proxy.config.php")
          /var/www/html/config/s3.config.php from nextcloud-config (rw,path="s3.config.php")
          /var/www/html/config/smtp.config.php from nextcloud-config (rw,path="smtp.config.php")
          /var/www/html/config/swift.config.php from nextcloud-config (rw,path="swift.config.php")
          /var/www/html/config/trusted-domains.config.php from nextcloud-config (rw,path="trusted-domains.config.php")
          /var/www/html/config/upgrade-disable-web.config.php from nextcloud-config (rw,path="upgrade-disable-web.config.php")
          /var/www/html/custom_apps from nextcloud-main (rw,path="custom_apps")
          /var/www/html/data from nextcloud-data (rw,path="data")
          /var/www/html/themes from nextcloud-main (rw,path="themes")
          /var/www/tmp from nextcloud-main (rw,path="tmp")
    

    If I run

    kubectl describe configmaps -n nextcloud nextcloud-config | grep log
    kubectl describe configmaps -n nextcloud nextcloud-config | grep LOG
    

    to see if the generated configMap has any entry regarding logs i get nothing.

  8. stefangweichinger commented on Nov 5, 2026

    @stefangweichinger

    9. @stefangweichinger Yours also sounds like a config matter, albeit a different one, related to your Nextcloud or PHP temp directory config. Use the help forum or Admin Manual for assistance: https://help.nextcloud.com and https://docs.nextcloud.co!

    Well, that's a very general pointer ... do you think I didn't follow all kinds of howtos and admin manuals to get to this point?
    I will post how the tmp-dir is configured there. Currently I don't have access to that site.
    Things worked for years with this config ... without these warnings.
    But maybe I have to adjust something to recent NC-images, sure. thanks ...

  9. susnux commented on Nov 7, 2026

    @susnux
    Contributor

    Both points of the integrity errors are valid.
    Except from config or data no additional files should exist.

    The log file should be within the data directory or somewhere external, if this comes from the helm chart then please report it there:
    https://github.com/nextcloud/helm

    For general trouble shooting i recommend using the forums: https://help.nextcloud.com/c/support/7

  10. stefangweichinger commented on Nov 9, 2026

    @stefangweichinger

    I looked at the problematic installation now: I only set tempdirectory in config.php, and would expect that files there won't be scanned for integrity.

    I might post that somewhere else, I see ...

    EDIT: did so at https://help.nextcloud.com/t/tempfiles-and-integrity-scan/251772

  11. github-actions commented on Nov 24, 2026

    @github-actions
    Contributor

    This issue has been automatically locked because it has been closed for more than 14 days. As we do not monitor closed issues, we are locking this issue to prevent further comments from getting lost in the noise.
    Please open a new issue if you have a similar problem instead. For general discussions, please use our forum: https://help.nextcloud.com

  12. locked as resolved and limited conversation to collaborators on Nov 24, 2026
  13. joshtrichards commented on Nov 24, 2026

    @joshtrichards
    Member

    I suspect some of this can be traced to a documentation matter in the Helm chart README where the logfile isn't specified as an absolute path, which will make make the actually used folder inconsistent:

    https://github.com/nextcloud/helm/blob/main/charts/nextcloud/README.md#changing-the-logging-behavior

    https://docs.nextcloud.com/server/latest/admin_manual/configuration_server/logging_configuration.html#file

    EDIT: Done - nextcloud/helm#908

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    0. Needs triage35-feedbackbugfeature: loggingneeds info

    Type

    Projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions