Trouble Understanding Nextcloud Logic!

New to nextcloud here!

Set up a server on my unraid machine. And installed the client on my windows PC

I am a little unclear about how nextcloud works.

So I have set up a share on my server which is the “data” folder for nextcloud. And the default files seem to be under data/‘my username’/files

From my windows PC i set up a folder I want to sync with the server. After the sync started, the contents of the folder showed up fine in the files folder on server as above.

When I delete files from the server folder it does not delete the files from the client machine. But the opposite happens. So if I delete something on the windows side it disappears from the server. Seems like the only behaviour possible because I cant find any settings to change this behaviour. I think I would prefer the option of keeping files on the server even if I delete it from the pc, or receive some form of prompt to choose… is this possible?

Secondly, if I go into the ‘All Files’ section from the web interface section of the server I see a totally different combination of files altogether. It neither matches the folders in the data folder of the server, nor the contents of the synced folder on the laptop! It contains some but not all the folders of the combination of the 2 actual folders on the machine! What is the logic behind this?

Moving on to my actual goals, what I want to achieve is as follows:

  1. Sync my laptop and phones to my server so that the selected data on them gets backed up on a regular basis to the server. Post which I can delete some or all of the data from the clients since I have a backup on the server.

  2. Add a folder from my server to a ‘share’ or something so that my laptops and phones can browse the contents of that share and view/ download/ etc.

Is this all do able with nextcloud or am I making a mistake in understanding the capabilities? Thanks in advance.

Hello there
I’m a bit confused by the terminology that you’re using. In Nextcloud you create users and each user has access to their files from wherever they are logged in, be it their phone, tablet or laptop. You can choose to share files with other users, for instance you may have users Mary and Jack who would like access to your music folder.
On the server, the files are ‘glued’ in place by the database in use (mysql etc). It’s not a good idea to rm files from here as it will likely confuse the database. Deletions and edits should be done from the client file manager or through the user’s web interface instead.
I hope this helps, but if you need more guidance, the user manual may help!

1 Like

In short, it works like Dropbox or equivalent.

This is a system folder for Nextcloud. It’s very important that you leave it alone unless absolutely necessary. Access your data from the web interface, WebDAV, or one of the various clients.

The raw contents of the data folder will not exactly match what you upload because it also contains file versioning and metadata. If you mess with the data folder, it will lose consistency with the database and cause odd behavior (such as missing files in the web interface) until you do a manual rescan.

The data is meant to be an exact copy. If you delete a file on your device, the sync client will delete it on the server’s copy. It’s possible to have data on the server side that isn’t synced with the client if desired.

Sharing with yourself is not necessary. You can just log each device into your account.

1 Like