Open csware opened 1 month ago
Can confirm.
Steps to reproduce:
To monitor the preview folder for create events:
inotifywait -m -r -e create /path/to/preview/folder
Output:
preview/1/0/ CREATE,ISDIR a
preview/1/0/a/b/2/6/9/39539/ CREATE 2560-1440-max.jpg
preview/1/0/a/b/2/6/9/39539/ CREATE 256-144.jpg
preview/b/5/7/ CREATE,ISDIR 7
preview/b/5/7/7/2/e/7/39548/ CREATE 1920-1080-max.jpg
preview/b/5/7/7/2/e/7/39548/ CREATE 256-144.jpg
preview/e/4/ CREATE,ISDIR 9
preview/e/4/9/f/1/7/b/39556/ CREATE 2559-1599-max.jpg
preview/e/4/9/f/1/7/b/39556/ CREATE 256-160.jpg
preview/c/a/b/ CREATE,ISDIR 8
preview/c/a/b/8/c/3/7/39565/ CREATE 1920-1080-max.jpg
preview/c/a/b/8/c/3/7/39565/ CREATE 256-144.jpg
preview/7/1/ CREATE,ISDIR c
preview/7/1/c/7/2/2/e/39573/ CREATE 1920-1200-max.png
preview/7/1/c/7/2/2/e/39573/ CREATE 256-160.png
That could be https://github.com/nextcloud/server/blob/4e2ada015528ca37736f142f2456c8375ab0d125/lib/private/Blurhash/Listener/GenerateBlurhashMetadata.php#L73, however adding a return before getPreview had no effect on my end.
cc @ArtificialOwl @artonge
What is worse is that even with enable_previews => false in config.php the preview folder is growing too I dropped 4 images on my desktop app and
root@maqueta-nextcloud-backend2:~# inotifywait -m -r -e create /disco_datos_nextcloud/nextcloud_data/appdata_XXX/preview/
Setting up watches. Beware: since -r was given, this may take a while!
Watches established.
/disco_datos_nextcloud/nextcloud_data/appdata_XXX/preview/5/6/1/ CREATE,ISDIR f
/disco_datos_nextcloud/nextcloud_data/appdata_XXX/preview/0/3/9/ CREATE,ISDIR 7
/disco_datos_nextcloud/nextcloud_data/appdata_XXX/preview/4/7/a/f/ CREATE,ISDIR d
/disco_datos_nextcloud/nextcloud_data/appdata_XXX/preview/7/f/8/2/ CREATE,ISDIR f
I'm on nc 29.0.2
What is worse is that even with enable_previews => false in config.php the preview folder is growing too
We indeed need to generate the blurhash after the preview generation:
@artonge I may have miss understood your last comment. There is a difference between "we need to generate the blurhash after preview generation" and "we need to always generate a blurhash (after causing a preview generation)"
I may have miss understood your last comment. There is a difference between "we need to generate the blurhash after preview generation" and "we need to always generate a blurhash (after causing a preview generation)"
To be clearer, blurhash generation should not trigger preview generation ;)
⚠️ This issue respects the following points: ⚠️
Bug description
After upgrading to 29 I noticed that my previews folder grew over 250 GiB. I tried to investigate and found that Nextcloud automatically generates previews after an upload (using Nextcloud client) and not just on-demand (using the browser interface) as the old versions did. (I also have the impression that Nextcloud generated previews for all files with missing previews after the upgrade to 29.)
Maybe this is related to the new FilesMetadata API?
Steps to reproduce
Expected behavior
No previews are generated automatically. I've many users who do not use the browser interface and, thus, generating lots pf previews is a waste of CPU time and space.
Generating previews only happens on-demand or can be configured to be on-demand only.
Installation method
Community Manual installation with Archive
Nextcloud Server version
29
Operating system
Debian/Ubuntu
PHP engine version
PHP 8.2
Web server
Apache (supported)
Database engine version
MariaDB
Is this bug present after an update or on a fresh install?
Upgraded to a MAJOR version (ex. 22 to 23)
Are you using the Nextcloud Server Encryption module?
None
What user-backends are you using?
Configuration report
List of activated Apps
Nextcloud Signing status
Nextcloud Logs
No response
Additional info
No response