Files/ folders wrong or pending size

Decided to post this here instead of as GitHub issue. Which is preferred method for future issues?

Transferred to new server (32-bit operating system like prior one) few weeks ago. Hardware is old HP Pavilion that only supports 32-bit operating system. As a result uploads set to 2 GB in php.ini, ect. Run daily below.
occ files:scan --all daily

Folders across users show wrong total sizes and some files show pending sizes. This occurs in both internal storage and external storage. Copied files and folders in external storage to internal storage to see if this resolved. It did not. File sizes still show as pending days later in their new/ fresh location if independently uploaded .

Here is the interesting point. The issue appears to be with files exclusively over over some amount/ size (not sure what amount exactly as see a 1.2 GB file size correctly) but anything bigger than this seems to always stay as pending in size.

A few other points. Nextcloud data folder on a luks partition. Samba drives on a luks partiton sometimes show odd sizes when you view disk usage on Windows. Old server data folder was on luks partition too though.

It seems like it is some kind of php or issue relating to files over 2 GB on the Apache server or something. I don’t know at this point. Can anyone assist or offer solutions? Even with 32-bit 2 GB upload limit was able to previously view file sizes above 2 GB and folder sizes were always correct after running
occ files:scan --all daily.

Nextcloud version (eg, 10.0.2): 12.0
Operating system and version (eg, Ubuntu 16.04): Ubuntu 16.04
Apache or nginx version (eg, Apache 2.4.25): Apache
PHP version (eg, 5.6): 7

Related issue on github:

The same issue occurred at my end. And this was solved by setting up the Cron option from the Basic Settings section. The following are the steps:

  1. First you need to enable the Cron option from the Basic Settings section. Let’s open NextCloud as Admin user, go to SettingsBasic settings and select Cron.

  2. You must set up the following cron job to call the cron.php script. For Nextcloud to run smoothly, you will want to set up a cronjob. This is a task that is executed automatically in the background. Modify your Apache/Nginx cronjob:

sudo crontab -u www-data -e

If asked, press “1” to use the nano editor (which is super easy to use) and add the following line to your crontab file:

*/5  *  *  *  * php -f /var/www/nextcloud/cron.php

You have to replace the path /var/www/nextcloud/cron.php with the path to your current Nextcloud installation.

You can verify if the cron job has been added and scheduled by executing:

crontab -u www-data -l

Which returns:

*/5  *  *  *  * php -f /var/www/nextcloud/cron.php

This Cron method enables the execution of scheduled jobs without the inherent limitations the Web server might have.