Log_rotate_size ignored

According to this document entry : ```
log_rotate_size

I set the log_rotate_size to 1024 * 1024. Yet the current log is 64 MB.



Some or all of the below information will be requested if it isn't supplied; for fastest response please provide as much as you can. :heart: 

## The Basics

* Nextcloud Server version:  
  - `Nextcloud 34.0.3`  
* Operating system and version:  
  - `#1 SMP PREEMPT Debian 1:6.18.39-1+rpt1 (2026-07-29)`  
* Web server and version:  
  - `Server version: Apache/2.4.68 (Debian)`  
* Reverse proxy and version:  
  - `nginx version: openresty/1.29.2.5`  
* PHP version:  
  - `PHP 8.5.10 (cli) (built: Aug 31 2026 19:31:34) (NTS)`
* Is this the first time you've seen this error? (Yes / No):
  - `yes`
* When did this problem seem to first start?
  - `recently`
* Installation method _(e.g. AlO, NCP, Bare Metal/Archive, etc.)_
  - `OMV Container`
* Are you using CloudfIare, mod_security, or similar? _(Yes / No)_
  - `No`

### Summary of the issues you are facing:

\[...\]

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

1. 
2. 
3. 

### Log entries

#### Nextcloud

{“reqId”:“grONn11HrvjXc5U9g6PC”,“level”:0,“time”:“2026-09-06T17:24:36+00:00”,“remoteAddr”:“”,“user”:“–”,“app”:“PHP”,“method”:“”,“url”:“–”,“scriptName”:“/var/www/html/occ”,“message”:“Non-canonical cast (integer) is deprecated, use the (int) cast instead at /var/www/html/custom_apps/eurooffice/lib/AppConfig.php#1294”,“userAgent”:“–”,“version”:“34.0.3.2”,“occ_command”:[“/var/www/html/occ”,“–version”],“data”:{“app”:“PHP”}}


#### Web Browser

#### Apps

> Enabled:
>   - activity: 7.0.0
>   - admin_audit: 1.24.0
>   - appstore: 1.0.0
>   - bookmarks: 16.2.6
>   - brewmemo: 0.8.0
>   - bruteforcesettings: 7.0.0
>   - calendar: 6.5.4
>   - camerarawpreviews: 1.1.3
>   - circles: 34.0.0
>   - cloud_federation_api: 1.18.0
>   - contacts: 8.8.0
>   - contactsinteraction: 1.15.0
>   - cookbook: 0.11.10
>   - dashboard: 7.14.0
>   - dav: 1.40.0
>   - encryption: 2.22.0
>   - end_to_end_encryption: 2.2.4
>   - eurooffice: 11.0.4
>   - federatedfilesharing: 1.24.0
>   - files: 2.6.0
>   - files_downloadlimit: 5.2.0
>   - files_external: 1.26.0
>   - files_lock: 34.0.1
>   - files_pdfviewer: 7.0.0-dev.0
>   - files_sharing: 1.26.0
>   - files_trashbin: 1.24.0
>   - files_versions: 1.27.0
>   - firstrunwizard: 7.0.0-dev.0
>   - groupfolders: 22.0.6
>   - logreader: 7.0.0
>   - lookup_server_connector: 1.22.0
>   - nextcloud_announcements: 6.0.0
>   - notes: 6.0.2
>   - notifications: 7.0.0-dev.1
>   - oauth2: 1.22.0
>   - officeonline: 3.2.1
>   - password_policy: 6.0.0-dev.0
>   - photos: 7.0.0
>   - privacy: 6.0.0-dev.1
>   - profile: 1.3.0
>   - provisioning_api: 1.24.0
>   - recommendations: 7.0.0
>   - serverinfo: 6.0.0
>   - settings: 1.17.0
>   - sharebymail: 1.24.0
>   - suspicious_login: 12.0.0-dev.0
>   - systemtags: 1.24.0
>   - theming: 2.9.0
>   - twofactor_backupcodes: 1.23.0
>   - twofactor_nextcloud_notification: 8.0.0
>   - twofactor_totp: 16.0.0
>   - updatenotification: 1.24.0
>   - uppush: 2.5.0
>   - user_status: 1.14.0
>   - viewer: 7.0.0-dev.0
>   - webhook_listeners: 1.6.0
>   - workflowengine: 2.16.0
> Disabled:
>   - app_api: 34.0.0 (installed 32.0.0)
>   - comments: 1.24.0 (installed 1.24.0)
>   - federation: 1.24.0 (installed 1.24.0)
>   - files_reminders: 1.7.0 (installed 1.7.0)
>   - fulltextsearch: 34.0.1 (installed 34.0.1)
>   - office: 1.0.0 (installed 1.0.0)
>   - previewgenerator: 5.14.0 (installed 5.14.0)
>   - related_resources: 5.0.0-dev.0 (installed 5.0.0-dev.0)
>   - sentry: 8.20.0 (installed 8.20.0)
>   - support: 6.0.0 (installed 6.0.0)
>   - survey_client: 6.0.0-dev.0 (installed 6.0.0-dev.0)
>   - tables: 2.3.0 (installed 2.3.0)
>   - text: 8.0.0 (installed 8.0.0)
>   - user_ldap: 1.25.0 (installed 1.22.0)
>   - weather_status: 1.14.0 (installed 1.14.0)

On your admin settings in the basics, what does it say when the cronjob was run for the last time? It should normally be a couple of minutes. => Cronjob normally should check for rotation, if it does not run, it does not rotate.

When you know that it runs and it is not possible, it might leave a few traces in the logs. You can also check if the webserver user has permissions to change the file and rename a file in the folder. Is the nextcloud.log in your normal data-folder? Or in a different location? If you change the default location, this is defined in the config/config.php file

is log rotation part of the standard cron? /cron.php is run every 3 min. Is there a log entry made I insert here?

how else should nextcloud control it? You can use system services like logrotate to do that for you. I’m not sure if it checks on each run, or just when the heavy tasks are enabled in the night. It might fail if the webserver user does not have permissions to move/copy files in the folder where the nextcloud.log is located (by default the data folder, there it should not be a problem but it might be one if you put the logs in /var/logs/…)

Also the error in the cron, make sure the other cronjobs run, check out which one creates the error with the more than 1000 expressions (in case the ones after do not run). There is also a db-table (oc_jobs, oc_cron … not sure) where there is a list of cronjobs executed, it keeps a timestamp when it was run the last time, executions times, …