Manually moved data into user folders - not displaying on server interface

So I reinstalled nextcloudPi on Debian 10. I kept my home partition from last install.

I migrated the datadir to a new folder on the home partition, setup the two users, then migrated the contents of the “files” folders of both users from the data of the last install.

The NC server interface doesn’t display these files.

SOLUTION:
ended up having to use sudo -u www-data php /var/www/nextcloud/occ files:scan --all

the nc-scan tool didn’t work.

I thought maybe I should run the nc-permissions tool but I get the following error:

Unauthorized request. Try reloading the page

My question is, how do I restore these files to the data directory?

I’d try from terminal thru ncp-config.

I’ll give this a shot. Or I may try nc-scan from the web interface.

well using nc-scan via the webpanel or via terminal, did not pull in any data. it shows “1 user” and 0 files and 0 folders added.

I pointed it to /home/pcusername/nextcloud/data-dir/nextcloudusername/files/' my data directory top level is located /home/pcusername/nextcloud/data-dir/`

Prior to running this I checked the existing files directory to see what the permissions were set as, then moved the contents of my backed up data from ~/ncusername/files/ to my new install `/home/pcusername/nextcloud/data-dir/nextcloudusername/files/’ . Then I ran the nc-fix-permissions tool, then ran the nc-scan tool.

I guess I can try the suggestion linked in the solution here: Can I move files direct to Nextcloud?