shutterstock_105420140

Cloud Storage for Your Linux Platform


Most of us are storing some of our files (pictures, music, documents, etc) in the cloud in one way or another. What we are going to talk about today is some of the cloud storage providers that support Linux integration Рsome directly with an install-able client, some by implementing access through standard technologies. Finally, we will point out those who (at least at this point) do not seem to want the Linux crowd to soil their premises with our footprints.

Drop It and Forget It
If you do not have a Dropbox account already, go get one. It is free and comes with a (measly) 2gb of storage. You can qualify for various upgrades all the way to 16gb max on their free account.

The great thing about Dropbox is not the 2gb of free space however. Dropbox maintains a version history of every file you store there. This makes it perfect for documents that you frequently edit, pictures, or source code. I have my code repository checked out there and then I can add/delete/update files to subversion on whatever systems I have Dropbox bound to.

Finally, the best news is that they have a native client for Windows, Mac OSX and Linux (as well as iOS and Android) that works to synchronize the local and remote filesystems automatically. Note that with Dropbox, you have a local folder (or folders) that have a copy of the remotely stored files that gets synchronized. The good news is that local access to your files is fast, the bad news is that synchronizing the files can take a while the first time. Out of the solutions I am reviewing here, Dropbox is by far the fastest upload and download speeds over high speed internet connections.

The One to Rule Them All
Ubuntu One has a pretty strong offering and now that they support Windows, OSX and Linux, they join Dropbox as the only other fully supported native client for all operating systems (including iOS and Android).

Ubuntu is kind enough to give us a fairly generous 5gb of free space, see below:

One Client to Rule Them All

So in this case, whereas Dropbox is attempting just recently to move into other online ‘services’ like photo sychronization, Ubuntu launched with native client support for that as well as the ability to purchase and stream your music. It even comes with a browser based music player (convenient for your phone or tablet):

Tunes Anyone?

The reason I point out the music service is because Ubuntu routinely offers bonus storage for 90/180 days if you buy as little as one song from their service. In my case, I spent $.99 for one song and received 20gb more storage for six months of free use. If/when I choose to keep that in July, it will only cost a $2.99 a month premium, significantly less than the storage upgrade (for more) than Dropbox.

Truck My Files to the Dump
A relatively new cloud storage provider called DumpTruck offers a fair solution for storage online as well.

Their native client is written in Python (which strangely does not support Linux at this time) and they offer 5gb of free storage as well. Although their client only supports Windows and Mac OSX, we can get access to it either through the web browser or, even more conveniently, through WEBDAV.

If you have never mounted a remote filesystem this way, it effectively allows you to mount a remote filesystem over HTTPS using the ‘davfs2’ filesystem. On Ubuntu, you can install the appropriate packages as follows:
sudo apt-get install davfs2

Once installed, create a directory to mount the filesystem:
sudo /mnt/dumptruck

Copy the default ‘/etc/davfs2/secrets’ file to a local directory for your use:
sudo mkdir ~/.davfs2 && sudo cp /etc/davfs2/secrets ~/.davfs2 && sudo chown $USER:$USER ~/.davfs2/secrets
and then
sudo cp /etc/davfs2/davfs2.conf ~/.davfs2/davfs2.conf && sudo chown $USER:$USER ~/.davfs2/davfs2.conf
finally
chmod 600 ~/.davfs2/secrets && chmod 611 ~/.davfs2/davfs2.conf

In the case of Dumptruck, you will insert the following line (with appropriate username and password) in your home directory ‘secrets’ file:

# dumptruck login credentials
https://dav.dumptruck.goldenfrog.com/dav USERNAME PASSWD

Assuming you want to now mount the remote filesystem, you can execute the following command:
sudo mount -t davfs2 https://dav.dumptruck.goldenfrog.com/dav /mnt/dumptruck

This will read your ‘secrets’ file and mount the filesystem appropriately in that directory. Making this ‘permanent’ can be accomplished by adding the following to your ‘/etc/fstab’ file:

# dumptruck webdav mount
https://dav.dumptruck.goldenfrog.com/dav/ /mnt/dumptruck davfs rw,user,noauto 0 0

You can then test by executing:
sudo mount -a

To mount the drive immediately, or reboot which will do it automatically. You can then check the drive mount using ‘df -h’ to see it is there. The great thing about this particular setup (using ‘webdav’) is that although you have access to all your folders and files, there is no local copy taking up space on your local system. So if you choose to purchase a large block of storage, you won’t have to have that much free space locally to maintain synchronization.

Bad Boys, Bad Boys
There are a large number of other cloud providers that either do not support Linux at all (Microsoft I am looking square at you and your Skydrive with your sneaky ‘webdav’ redirect) or frequently change their security implementation so one day your access will work, the next you will lose the mount and have to hunt down why (Google drive, Spider, Oak, shame on you guys).

Final Thoughts
There are enough options that we can get working in Linux that, for free, you can get up to 36gb of storage space. With specials or partner offers, you can (like me) get up to 63gb of space, which cost me $.99 once.

Dropbox is the fastest up/down and has handy file versioning built in. Ubuntu One has value added services and runs specials to get large chunks of storage for little or no incremental cost. Dumptruck allows command line, secure access without filling up your local file system. In combination, you have a very flexible online backup and storage solution right from your Linux desktop.

Drop a comment below and share your experiences and any other tools or vendors I may have missed!

Terrence T. Cox

A veteran of twenty years in Information Technology in a variety of roles. He has worked in development, security and infrastructure well before they merged into what we now call DevOps. He provides training in Linux, VMWare, DevOps (Ansible, Jenkins, etc) as well as containers and AWS topics.

Leave a Reply

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