Files:scan --app not recognised

I am running OC with “su www-data -s occ”.

When I run files:scan it works and shows me the list of possible arguments,
but when I type files:scan --all, it gives me the error:

Command “files:scan --all” is not defined.

Did you mean one of these?
files:cleanup
files:recommendations:recommend
files:scan
files:scan-app-data
files:transfer-ownership

Running nextcloud on Debian

occ "files:scan --all" is not a defined command, but occ files:scan --all is. Do you spot the difference? :wink: I would try to run the command as follows:

su - www-data -s /bin/sh -c "<path-to-nextcloud-document-root>/occ files:scan --all"
1 Like

Thanks a lot it works now!