# How to trigger Nextcloud to index files, generate thumbnails for newly created files by Syncthing (External storage)

**URL:** <https://help.nextcloud.com/t/how-to-trigger-nextcloud-to-index-files-generate-thumbnails-for-newly-created-files-by-syncthing-external-storage/175050>\
**Category:** ℹ️ Support\
**Created:** [November 24, 2023, 2:59pm UTC](https://help.nextcloud.com/t/how-to-trigger-nextcloud-to-index-files-generate-thumbnails-for-newly-created-files-by-syncthing-external-storage/175050 "2023-11-24T14:59:43Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![zilexa](https://help.nextcloud.com/user_avatar/help.nextcloud.com/zilexa/32/56247_2.png) [@zilexa](https://help.nextcloud.com/u/zilexa)\
**Post date:** [November 24, 2023, 2:59pm UTC](https://help.nextcloud.com/t/how-to-trigger-nextcloud-to-index-files-generate-thumbnails-for-newly-created-files-by-syncthing-external-storage/175050/1 "2023-11-24T14:59:44Z")

</div>

> **Support intro**
>
> Sorry to hear you’re facing problems 🙁
> 
> _**[help.nextcloud.com](http://help.nextcloud.com) is for home/non-enterprise users. If you’re running a business, paid support can be accessed via [portal.nextcloud.com](http://portal.nextcloud.com) where we can ensure your business keeps running smoothly.**_
> 
> In order to help you as quickly as possible, before clicking **Create Topic** please provide as much of the below as you can. Feel free to use a pastebin service for logs, otherwise either indent short log examples with four spaces:
> 
> ```
> example
> 
> ```
> 
> Or for longer, use three backticks above and below the code snippet:
> 
> ```auto
> longer
> example
> here
> 
> ```
> 
> 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 ❤

Nextcloud version _(eg, 20.0.5)_: 27  
Operating system and version _(eg, Ubuntu 20.04)_: Fedora, Nextcloud via Docker  
Apache or nginx version _(eg, Apache 2.4.25)_: Nextcloud via Docker  
PHP version _(eg, 7.4)_: Nextcloud via Docker

The issue you are facing:  
If I setup Nextcloud, with only “external storage”, which will be local storage really, but the same folder that Syncthing is syncing to/from, how do I ensure filenames/paths will be indexed, metadata read and all images (if possible videos too) thumbnails are being generated after the files have been locally created?  
To ensure smooth web browsing experience, I want to generate-in-advance as much as possible.

I already understand Syncthing and Nextcloud need to use the same user etc. That is no problem for me.  
This is really about triggering Nextcloud, for example, by built in mechanism monitoring folders (inotify) or more efficiently, by leveraging the Syncthing API:

[Syncthing Folder Event Daemon](https://github.com/desbma/stfed)

---

<div class="post-metadata">

**Author:** ![anon75456558](https://help.nextcloud.com/letter_avatar/anon75456558/32/6_22734026db12803ebb3e059622ac3534.png) [@anon75456558](https://help.nextcloud.com/u/anon75456558)\
**Post date:** [November 24, 2023, 5:09pm UTC](https://help.nextcloud.com/t/how-to-trigger-nextcloud-to-index-files-generate-thumbnails-for-newly-created-files-by-syncthing-external-storage/175050/2 "2023-11-24T17:09:09Z")

</div>

You will need to script occ to scan for changes. See examples in other threads like [Automatically do a files:scan on that specific file when a new file is added - #13 by ChineseAegis](https://help.nextcloud.com/t/automatically-do-a-files-scan-on-that-specific-file-when-a-new-file-is-added/95448/13)

---

<div class="post-metadata">

**Author:** ![wwe](https://help.nextcloud.com/user_avatar/help.nextcloud.com/wwe/32/72963_2.png) [@wwe](https://help.nextcloud.com/u/wwe)\
**Post date:** [December 14, 2024, 1:20pm UTC](https://help.nextcloud.com/t/how-to-trigger-nextcloud-to-index-files-generate-thumbnails-for-newly-created-files-by-syncthing-external-storage/175050/3 "2024-12-14T13:20:00Z")

</div>


