Start DSM Media Re-Indexing from PHP App

Currently reading
Start DSM Media Re-Indexing from PHP App


Deleted member 673

I use a home-brew PHP application to manage media files, including the movement of .mkv and .m4v video files within DSM's indexed 'video' folder. The PHP apps run on the same server as the media files, under Web Station / Apache.

Unfortunately, files moved using PHP 'rename' do not trigger automatic DSM media re-indexing. I have not tried PHP 'copy', but the files are generally much too large to copy (vs move) in a reasonable amount of time.

Is there a way to trigger DSM media re-indexing from a PHP app? I'd like to eliminate the need to remember doing this as a manual step via the DSM Web Console.

Thanks for any suggestions, Ron
The following PHP code appears to work as needed: exec('/usr/syno/bin/synoindex -R video');


Create an account or login to comment

You must be a member in order to leave a comment

Create account

Create an account on our community. It's easy!

Log in

Already have an account? Log in here.

Similar threads

Apache 2.4 in dsm 7.2 does not run after restarting DSM Leading to errors in WordPress, Joomla,... Out of...
Hi, hope someone can help here. I have a Synology ds2411+ and I can't get mergerfs to run properly and DSM...

Welcome to! is an unofficial Synology forum for NAS owners and enthusiasts.

Registration is free, easy and fast!

Trending threads