Using occ on snap nextcloud installation

I am running nextcloud on a Ubuntu VM. It is installed via snap. I’ve copied files from my Notes folder on my old instance, to the Notes folder on the new instance, with same file permissions. I did a reload of the Notes app on my new Nextcloud instance site, and it isn’t loading, so I tried the following:
sudo -u www-data php occ files:scan -vvv
But this is the error that I run into:
sudo: php: command not found
I look at where php is being called from on my old instance, and mimic it on my new instance:
sudo -u www-data /snap/nextcloud/26119/bin/php occ files:scan -vvv
But this is what I get:
/snap/nextcloud/26119/bin/php: error while loading shared libraries: libargon2.so.0: cannot open shared object file: No such file or directory
How can I get the app to recognize these new Notes files?

3 Likes

Hi @droidus,

on snap installations the correct command should be:
sudo nextcloud.occ files:scan --all -vvv

3 Likes