Nextcloud as storage

Is there a way to use a nextcloud server as a way to store files remotely but not keep them synchronized with the client, yet still have them readily available? I have put up a nextcloud server and everything is working great, but the storage I have on the server far exceeds what I have at my desktop, and I’d like to be able to utilize that ability for mass storage.

Webdav?
https://docs.nextcloud.com/server/latest/user_manual/en/files/access_webdav.html

Due to the fact that WebDAV is the default protocol you can use all kind of compatible apps which support that protocol. You can e.g. use the FolderSync app on Android :wink:

Maybe, apart from the WebDAV option already mentioned above by @anon71540698 and @j-ed, you could also have a look at the Samba/CIFS integration.
The relevant doc can be found here (NC21):
https://docs.nextcloud.com/server/21/admin_manual/configuration_files/external_storage/smb.html?highlight=samba
This way you can use Samba/CIFS shares both inside of Nextcloud, as well as using it as a “normal” network share. The Samba/CIFS share can (usually) be made available to any network client you want to.

–Updated to add:–
This means that you would have to install and configure Samba on the server as well. I only added this for clarification purposes.
A tutorial, by and for Ubuntu, can be accessed here:

If your Nextcloud server is running on hardware, you could otherwise mount your files to Nextcloud using the local external storage and create a smbserver from linux which shares those same folders via smb.

This is a good idea! I did try to get this working but I could not. The client, right now, is Windows 10, and the server is Arch/Nextcloud snap. When I try to use, in Windows 10, ‘net use n: https://192.168.1.10/remote.php/dav/files/paul /user:paul “thepass”’ I get “The operation being requested was not performed because the user has not been authenticated.”

I get a similar message (relating to failure to authenticate) when trying to use the Explorer shell to do the same thing. “thepass” is in quotes because the real password has weird chars that the command line delimits upon.

The Nextcloud app for Android already behaves the way I want – that is, it doesn’t sync, just makes available as remote storage. I’m trying to get similar functionality in Windows 10.

By combining this with the next best workaround which I’m already doing (specifying an ‘ignore’ folder and using the web client to upload files to it), I suppose this could be a working solution. I could put up a share of the ignored folder and mount it to a mirrored location inside the sync folder in the client side, that way it would appear just the same as the rest of the folders but would actually work more like a simple network mount.

I’m not understanding the document for SMB integration in Nextcloud, though. This seems like it would be a separate action set up by me that has nothing to do with Nextcloud per se. Does Nextcloud facilitate this in some way?

Yes, it’s on a real machine. This is what I’m thinking of doing. I have a folder in my Nextcloud account that is set to be ignored, and I’m thinking of just mounting that, via SMB, to a mirror folder in my local Nextcloud sync folder. It should appear identical, but instead not keep the remote file stored locally but only as a remote resource. Is this what you’re suggesting?

Hm… I don’t really understand what you are proposing.

To paraphase my proposal:
It is possible to use only the so called external storage to store all your files. (No files will be stored in the datadir of Nextcloud in this case but instead at a location that you can define in the external storage app (you should use the mount type local then). If you share the same location then via smb from your linux server, you can access those files via smb with all devices on your LAN.

I’m wanting to be able to move files from the client computer to the Nextcloud server via the file browser (Windows Explorer, or the command line, etc.), and not have them on the filesystem of the client computer.

1 Like

Yes, that should be possible via SMB in your LAN with the solution that I’ve proposed to you.

@Transigence,

As far as the SMB-solution is concerned, you are right. NC in itself does not provide SMB shares. It can “only” make use of them as an external_storage. In order to use SMB-shares in NC you have to install Samba as a separate package. Having said that, it’s actually rather straight forward.
What needs to be done on your server is that:

  1. Install and configure the appropriate Samba package. Seeing as you are using Arch, I think this tutorial should help you: https://wiki.archlinux.org/index.php/samba;
  2. In order to be able to use a SMB-share in NC, you first have to make sure that the requirements from SMB/CIFS — Nextcloud latest Administration Manual latest documentation have been met;
  3. In order to configure the SMB-share in NC, you have to adjust the settings for the " External storage support"-app in NC according the instructions from Configuring External Storage (GUI) — Nextcloud latest Administration Manual latest documentation
  4. In Windows 10, please make sure that you have the Windows Feature “SMB Direct” enabled.

After having done this, you should be able to access your SMB-share through both your Windows Explorer, as well as from within NC.

I hope this helps.

BTW, concerning your WebDAV-authentication problem:
If I understand correctly, you tried to access your NC using WebDAV on a Win 10 machine, but did receive an authentication error. This might have something to do with the so called “Basic Authentication” on Windows. Have a look here, see the section “Windows Troubleshooting”, for a possible remedy:

I would advice caution editing the registry though :wink:

HI @Transigence ,

@LordMort seems to offer you the solution that best fits the use case you described.

Using Webdav you’ll create a mount point and work directly with the files on your next cloud server, wherever that happens to be located.

Alternatively you could (depending on what types of files / apps you need to use or access) simply use a web-browser to access and use files. With a Collabra or Libreoffice integration there would be no obstruction to creating or editing office files via a simple browser. Although there may be more effort in this than simply resolving your windows Webdav issue.

Please do let us all know how you get on and what you did / do to resolve your issue so others may benefit who are facing a similar problem and looking for a similar solution.

Yes, you can, but it is not the same solution as Microsoft OneDrive has with On demand files.

On desktop client you can choose which folders and files you want to synchronize. You can anytime check/uncheck files and folders you need or don’t need this way preserving space on PC.

You can also use Webdav like others already mentioned, but technically it is not synchronizing, because Webdav is just a protocol for accessing files, its not synchronizing anything so not answering your question.

Reading this thread prompted me to explore how accessible my own NC instance is with webdav. While it was fully accessible (and fast locally), I discovered a caveat.

For any file touched (not even opened), it gets cached to C:\Windows\ServiceProfiles\LocalService\AppData\Local\Temp\TfsStore\Tfs_DAV. This can result is LOTS of wear and tear if your C drive happens to be a ssd and there’s lots of file’s accessed. My assumption is this is to improve performance.

SMB might have more overhead but less wear and tear on the client. Pick your poison…

In my case, the entire NC data directory is on a NFS export on a file server. It’s easy enough to configure a SMB share on the file server this location and mount that in windows instead. I think the suggestion above to use SMB mounts directly as user’s root folders is probably best.

Given there’s overlap in function of NC vs fileserver, I suppose the OP needs determine what and how they want to use NC for. To me, NC is more for the purpose of sharing content outside the local realm than functioning as a psuedo file server.

I still have not been able to get WebDAV to work, either with Windows clients or Linux clients. Even if I could get it to work, at least with Windows, the solution would be suboptimal. Though it’s a trivial inconvenience, I don’t really want a mapped drive – I want a mounted folder.

Although the reason I’m going through all of this trouble is so that I don’t have to use a browser (I don’t really want to use a browser for file management), that is currently what I’m stuck with. I have set a mask in the “ignore” files “ns.*” with the Windows client software and I have a couple of directories, “ns.Storage” and “ns.Video” which I keep large amounts of data in by uploading to it through the web browser. Everything else is used as normal with syncing.

My WebDAV issue is proving to be intractable. I’m beginning to suspect that it has something to do with using self-signed certificates for SSL, as I’ve found that when it comes to security-related failures, error messages (if you should get them at all) are designed to be as unhelpful as possible.

I think what I’m going to settle on is using SMB to mount ignored folders into matching locations on the client-side sync folder. I might look into some kind of sftp solution, too, but all of the files on the NC system are owned by root.

The Windows NC client is incredibly unintuitive and difficult to use, and I’d like to use it as little as possible. For instance, if it’s ever not in focus, it closes. That is absolutely infuriating. It also doesn’t maintain the connection and requires me to intervene manually almost every time I need to use it, and the file browser integration gives me no indication I need to do so.

But the behavior for what happens when I have a synced folder, with stuff in it, and I turn off syncing is unclear. I’ve just never tried it. I also don’t know where that list is being built from. Server side or client side? All of these particulars are nebulous and, as far as I can tell, undocumented.

That’s a good heads-up about the caching of files used by WebDAV on Windows. I will probably not be pursuing that as a solution, especially given that it doesn’t look like I can get Windows to mount a WebDAV location to a directory anyway, which is already not what I want.

However, I’ve been quite clear and explicit from the beginning on exactly what I want out of my NC server. I think you’re mistaking the difference in how we want to use our NC servers as confusion on my part. I’m not confused at all about how I want to use NC, it’s just slightly different than how you use yours.

I’ll be as explicit and clear and comprehensive as I can for you here:
I want:

  1. To be able to use all of NC’s features (except email), including folder sync, sharing, collaboration, contacts management, the calendar, and Thunderbird integration for the calendar, as well as certain 3rd-party add-on apps, AND;
  2. To be able to mount certain directories in my NC home directory as remote storage that do not get synchronized by the Windows (or any other) client, and have them mapped to matching directories in the file browser integration folder on the client side, SUCH THAT;
  3. The file hierarchy looks identical on both the client and server and moving and copying files to and fro work seamlessly, however, certain folders on the server side are not kept locally.

My NC server has a lot of block storage and in the future it’s going to be the vast majority of the block storage in the house. I want to take advantage of syncing for certain coding projects, documents, and the meme stash, but I do not want or need 4 terabytes of raw video game captures, my movie collection, my music collection, my 350gb “homework” folder, et. all to be mirrored on my desktop. Yet I still want all that stuff available to me over the internet.

Does this help?

Seems to work here. Run as administrator

S:\ is a ramdisk. Windows_vm is a folder on S: that’s mapped to a smb share on the file server. Depending how you have your data folder set up in NC, you’ll have to make some part of it shareable via smb.

S:\>net use \\10.10.10.136\pool1\windows_vm
The password or user name is invalid for \\10.10.10.136\pool1\windows_vm.

Enter the user name for '10.10.10.136': username
Enter the password for 10.10.10.136:password
The command completed successfully.

C:\Windows\system32>mklink /d s:\windows_vm \\10.10.10.136\pool1\windows_vm
symbolic link created for s:\windows_vm <<===>> \\10.10.10.136\pool1\windows_vm

Initial view

after pasting some files in

The only caveats is to figure out how to get the system to remember the passwords so mounting is automatic.