Speed up synchronisation occ;scan files

Hi
I 'am not sure to understand all.
I have started with nextcloud for only few month, and I find it great.
But now I have huge data on my nextcloud (60GB).
I would like to move some folders on my nextcloud outside to another folders on my synology nas.
And I would also like to import data from other location on my NAS to nextcloud folders.

My idea is to put this data on USB key and bring it at my work place copy on my local nextcloud and restart nextcloud.
The aim is to speed up the synchronisation .

My undestanding is that it is possible by the following action.

  • put nextcloud in maitenance mode
  • copy file in nextcloud.
  • scan (could you precise me the command)
  • switch off maintenance mode .

it s that correct. Could you confirm and/or correct me
Thanks for your help

I tried this command

root@wawawynas:/volume1/web/nextcloud# sudo -u http php occ files:scan --all
The current PHP memory limit is below the recommended value of 512MB.
Nextcloud is in maintenance mode - no apps have been loaded

There are no commands defined in the “files” namespace.

you command seems right

sudo -u www-data php occ files:scan --all

there is a issue: File Scan not possible if nextcloud is in maintenance mode · Issue #20515 · nextcloud/server · GitHub . maybe it workts without maintenance mode

thanks kinimodmeyer.
sudo -u http php occ files:scan --all worked (without maintenance mode)
maintenance mode is only required for upgrading nextcloud ?
many thanks
kounga

Hi @kounga38 the maintenance mode disable the database so if you make an upgrade of nextcloud or a backup of the database, you must activate it