Next Cloud Gotchas

Published on April 4, 2023 at 9:55 am by LEW

Introduction

Lets face facts, There are some significant differences with how Next Cloud syncs files, as compared to other cloud storage solutions. Some of theses can cause pretty significant gotcha moments.

You may ask what I mean by a gotcha moment. For this post I am defining a Gotcha moment as discovering an unexpected disruptive challenge. Believe me, you want to avoid Gotcha moments.

The best way to avoid these Gotcha moments is to have a clear understanding of how Next cloud handles your data. And to be fair, this information is all in the documentation, someplace. It can be a little hard to find if you are not sure of what you are looking for, and you don’t want to read the whole thing; Administrator Manual, User manual, and Client manual.

In this post, I will be putting down what I think are the important takeaways, and behaviors that can help reduce the Next Cloud Gotcha moments.

Using Next Cloud

Basically Next Cloud is Network Storage plus. You can store data on a network server that can be accessed by multiple devices (the basic cloud storage metaphor). Next Cloud also has a selection of applications (apps) that can perform various functions with data stored on the server; like a calendar, contact list, task list, media player, etc.

Next Cloud also has several modes of access/operation; your Browser, the Next Cloud Sync Client, and the Webdav Interface. Each has its own use cases and issues.

Basics of Next Cloud Operation

Next Cloud is an application designed to run on web servers with a database. At a basic level when you copy a file to the Next Cloud application, it not only stores the file, it also creates a tracking entry in its database. And every time you do something with that file, the database entry is updated.

Note that using a database is what makes it possible to increase Next Cloud functionality through additional application.

Introducing a database, while increasing functionality, adds additional risk. What is stored needs to match what is entered in the database. In many situations this can prove to be a uniquely challenging condition.

Next Cloud Browser Interface

Probably the simplest and most reliable way to use Next Cloud for file storage is through the web interface. This is pretty much a drag and drop experience.

Next Cloud Browser Interface
Using the browser interface is straight forward. Find the file on your computer, and drag it over the browser window while in file view. It will be copied to the server, and the database will be updated.

Within the browser interface the basic functions of creating new folders and files, as well as deleting files and folders is available. Additional functionality is available, but in many cases will depend on what application have been installed in your Next Cloud instance.

With the browser you are the one in control, and Next Cloud does pretty much what you tell it too. And this basically means you are in control of your own data integrity. And as long as you exclusivity use the browser interface it works pretty well. The problem occurs when files are added through other means, like FTP, SCP, or SMB, and the database does not get properly updated.

There are ways around this type of problem, but they are generally beyond what the average user wants to deal with.

Next Cloud Desktop Client

Next Cloud has desktop clients for most major Operating Systems; Windows, Linux, Mac, Android, and IOS. The desktop clients, beyond file storage, also perform synchronization of your data across multiple platforms.

It is important to understand that Next cloud is a Server, that is it provides a service. And when you access it, via the browser or sync client, you are a client. And like any server Next Cloud can have multiple clients, even within the same account.

For example, you have a Next Cloud Server. You also have a laptop computer and a phone. Both are clients when connecting to Next Cloud. Beyond that both are clients of your account.

Whenever you start a client application, the first thing it does after connecting is synchronize. That is to say it compares the client database against the server database, and determines if there were changes. If changes are found, the client will attempt to download/upload the latest files.

Continuing with our example, lets say we modify a text file on our laptop. When we save it, it gets a new time modified stamp. When the next Cloud Client scans its files it notes this is different from what is in its database. If the time modified is newer, the client will upload the file to the Next Cloud Server, replacing then older version there.

On the server the file has a unique random identification number associated with it in the server database. A new number will be generated when the file is updated. It does not matter what the number is, only that it is different.

Note that last modified date and time is not a good reference if the server and client times are not synchronized. This can create some ambiguity about which file is the latest. Therefore the server uses a unique number that changes when the file is updated instead of a time. This does involve a few assumptions on Next Clouds part as to how these files are handled.

When you try to access the file on your phone, the client application queries the server, and determines the file has been changed on the server (random id number changed), and downloads the file from the server, assuming that it is the newest file. This works pretty well for the most part, but has the potential to lead to some syncing problems.

The other difference is that the Next Cloud sync model does not assume the server is the master. If a change is made (add, delete, edit) in any database (client or server) it will be reflected in the other databases after sync.

There are mechanisms in place for dealing with conflicts when they arise. This mainly involves saving both files but appending conflict and date time stamp to one of the file names.

WebDAV

Technically all connections are made via WebDAV (Web Distributed Authoring and versioning). Most modern file managers have the ability to establish a remote WebDSAV connection. In this case you are also updating the database when you add or remove files.

The other use of the WebDAV interface is for tracking and exchanging information between application (like Contacts and Calendars) and remote clients.

For example, the calendar app that came pre-installed on your phone probably has the capability of displaying a remote calendar via WebDav. Therefore you could have a central calendar on your Next Cloud Server, and all your remote devices could access, display and use it.

Next Cloud Virtual File System

Next Cloud clients have a virtual file system. You may not want to sync every file on your server to a device. For example you might have several terabytes of storage on your server and only gigabytes on your phone Instead of downloading everything, most files will have metadata synced. Then if needed you can set files and directories to be available locally.

Conclusion

After discussing the Next Cloud interface there are a few takeaways to avoid the Gotchas.

A final note, Next Cloud comes with some tools, but using them requires shell access. If running next cloud on a local server this is generally not a problem. If running non a remote host, you will want to check what sort of administrative access you have.

Add New Comment

Your email address will not be published. Required fields are marked *