Skip to main content

Featured post

Deployment of Wine

The project is to build a Linux Mint machine to have the identical functionality and ergonomics as the existing Windows 10 machine.
Having established that there is no way to migrate fully from Windows to Linux, the project now needs to consider running Windows apps in Linux.This is a big change to the strategy of the project.This is a big change to the deployment of a Linux workstation, a crushing admission of failure, and the opening of a whole new world of risks to an otherwise secure operating system. Environment & required functionalityFor this blog post, Wine was tested on: The Linux Mint Xfce 19 virtual machine "Bilbo", on host Windows 10 laptop "Saruman"The Linux Mint Xfce 18.3 virtual machine "Gimli", on host Windows 10 host "Legolas".
Alternatives There are alternatives to Wine/PlayOnLinux, notably the paid software Crossover. Software selection Wine and PlayOnLinux are present in Linux Mint by default.  If uninstalled following advice fr…

Googe Drive Backup & Sync (more like Google File Steam): ocaml-fuse

The project is to build a Linux Mint machine to have the identical functionality and ergonomics as the existing Windows 10 machine.

This stage relates to Google Drive.

Environment & required functionality

Google Drive needs to be used on the following machines:
  • The Linux Mint Xfce 18.3 laptop "Gandalf";
  • The Windows 10 laptop "Legolas";
  • The Linux Mint Xfce 19 virtual machine "Bilbo", on host Windows 10 laptop "Saruman" (that's the employer's laptop, by the way; the clue's in the name).
  • The Linux Mint Xfce 18.3 virtual machine "Gimli", on host "Legolas".
  • Another Windows 10 machine, name withheld to protect the guilty.
The synchronisation agent is Google Drive in Windows 10.  In a prior test, the sync agent has been grive2.

But grive2's functionality was too limited: files held in more than one folder in Google Drive cloud are symbolic links to the synchronisation agents installed on the laptops.  grive2 cannot handle symbolic links, so it pretended that the file didn't exist.  This was to such an extent that if a file once successfully synced to the laptop was added to a second folder in Google Drive Cloud, grive2 would delete the local copy of the file.  grive2 couldn't see it, so presumed it deleted, so replicated a deletion command on the local copy!

Alternatives

The next software on the original list in the prior test was Google-drive-ocamlfuse.

Installation experience

The installation documentation is spot-on.  Use the CLI to add the PPA to the Linux machine, then install the software.  It was a copy-and-paste job, worked first time, just perfect.

User experience

In the user's eyes, the behaviour of Google-drive-ocamlfuse is closer to Google Drive File Stream, which is generally available only to paid-up corporations using G-Suite.

This means the Linux machine can see the entire directory tree of Google Drive, but does not pull any data down until the user calls for it.  By contrast, grive2 (and Google Backup & Sync) copy the whole repository of data onto the local machine.  A large Google Drive can thus take 20 minutes to synchronise for the first time.  But ocamlfuse - like File Stream - is instantly available, because it syncs data only on demand.

Where directories deep down the directory tree contain a lot of files, the user occasionally needs to wait more than 20 seconds for a directory listing.

Unlike grive2, but like Google Backup & Sync, ocamlfuse polls the server regularly to look for downstream synchronisation instructions pending, or to deliver upstream synchronisation instructions pending.

Unlike grive2, ocamlfuse sees symbolic links and Google docs.  However, unlike Google File Stream and Google Backup & Sync, ocamlfuse does not automatically launch a browser to open Google docs.  Instead, it converts the Google doc to an OpenOffice format for use in the locally installed LibreOffice/OpenOffice/Microsoft Office, and then makes the file read-only.  Common therefore to both grive2 and ocamlfuse, the user needs to launch an internet browser manually, log into Google and edit the Google doc over the internet (or, if the browser supports it, work offline).

Implications for backups

ocamlfuse has its advantages, but there is a limitation in the scope of a local data backup regime.  If ocamlfuse is the primary sync tool between Google Drive Cloud and the local desktop environment, there are two choices to backup:

  • a hosted backup service like Spanning, which backs up the whole Google Drive Cloud repository to Spanning's own servers.  To backup other data on the local machine outside the scope of Google Drive sync agents (whether grive2 or ocamlfuse), a different desktop-based backup agent would be required.
  • a local backup tool, like Duplicati, combined with a background sync agent, like BackupGoo, that converts Google docs to an OpenOffice format for Duplicati to have some data to back up.

grive2 doesn't solve the backup issue either.  Whilst it would download data for Duplicati to see and backup, grive2 doesn't sync Google docs (or any other symbolic links), so Duplicati cannot see them.

It seems rational for Duplicati to combine the functionality of both Spanning and BackupGoo to have OAUTH access to the user's Google Drive, and back up the content to the user's preferred backup repository without conversion.

Conclusion

Google-drive-ocamlfuse works fine.


Completed Jul2018.


Comments