Vote Charlie!

Backup chronicles: Google Drive client constantly crashing

Posted at age 29.

Since Amazon canceled the unlimited storage I planned to use to replace BackBlaze, I have been weighing my options. I decided to pay $100 to upgrade my Google Drive to 1TB for one year and try syncing my documents (~900GB) there, but after three days I have not managed to upload much due to the Mac client crashing frequently. Not promising!

My 17TB of data

I keep my data on a 20TB volume comprised of two 10TB Seagate hard drives “Seagate Enterprise Capacity 3.5 HDD 10TB (Helium) 7200RPM SATA 6Gb/s 256 MB Cache Internal Bare Drive (ST10000NM0016)”. The volume is vulnerable to either disk failing, but I justified this risk by my use of Backblaze to nearly constantly back everything up to the cloud. I also periodically sync to my Drobo 5D that has five 6TB hard drives providing a volume of about 18TB that can supposedly survive two simultaneous hard drive failures. The only problem there is the enclosure has been getting very hot and making more noise than I would like in my bedroom, so I keep it off except when I remember to do a backup. Not ideal.

My current data spread is as follows:

➜  Striped sudo du -sh ./*
869G    ./Backups
285G    ./Bundle
825G    ./Documents
172G    ./Music
611G    ./Pictures
236G    ./Reading
58G     ./Software
13T     ./Videos

I had been trying to get everything backed up except for most of the videos folder, but the furthest I ever got with Backblaze was about 4TB before I needed to start over due to a system change on my end. So for now, I am just trying to get the documents and pictures folders backed up at the very least.

Google Drive versus Amazon Drive

It looks like Google Drive costs $100 for 1TB for one year, but I would need at least 2TB. The 20% discount for paying yearly apparently is only for 1TB, so I would need to pay $20 per month.

Amazon Prime comes with unlimited photo storage, so theoretically I could back up most of that 600GB of photos there for no extra cost. (I would of course not be surprised if this unlimited option disappeared once I was well on the way to uploading all my photos!) It is unclear whether the unlimited option includes any videos, but at the very least it does not include videos larger than 2GB. Note this email I received:

Welcome to Prime Photos

Unlimited online photo storage, plus 5 GB for videos and files. …

Since a few years ago, I switched from storing my videos in a separate folder structure to storing them alongside my photos, as often they are directly related. (I wish Facebook allowed organizing videos alongside photos in albums!) It seems Amazon will count RAW photos as photos at least. So, probably, if I used the unlimited photos option, I would end up paying for 1TB Amazon Drive space as well, which would cost $60 per year.

I would be tempted to store everything on Amazon Drive since it’s cheaper than Google Drive, but the client I would use, Arq, only does encrypted backups. This is probably a smart move in general, but I decided the ability to browse online and share specific files was going to likely be more convenient and valuable, and the Google Drive interface for that made the most sense since it would integrate well with my Google Documents.

Google Documents backup

I am currently using the app Cloudpull to back up my Google Apps data to a local backups folder. That includes my email, calendar, contacts and documents. Since I would now be syncing all my local documents to my Google Drive, it would be silly and wasteful to have Cloudpull redownload all that data that originated on my local computer. I could disable “docs” for my main Google account, but then I would not get backups of my Google Docs, Google Sheets, etc., files.

With the Google Drive client, those files are apparently not actually synced, but rather the client creates files that simply link to the documents online. This is fine if you trust Google to always be available and never lose a file. I also have a bridge to sell you.

Cloudpull manages to convert all the proprietary Google docs files to Microsoft Office variants in the backup. I want to maintain this behavior, but don’t want to segregate all the Google format files into special folders to track separately. Cloudpull has an option under Preferences > Google Accounts > Just Google Docs, Sheets, and Slides. This seems be what I want, but when I tried it, the backup size seemed to be clearly larger than it should be were it solely backing up the Google format files. I will need to revisit that. For now I will let it back up everything it’s backing up, erring on the side of safety.

Cloudpull: Just Google Docs, Sheets, and Slides

Cloudpull: Just Google Docs, Sheets, and Slides

On a related note, Google provides an option to edit Google Docs files offline, which apparently must be handled through a magical back end in Chrome browser using the Google Docs offline Chrome extension. It’s not clear to me what files will be stored locally and in what format. I would guess just the Google format documents are downloaded in some format, but I would also not be surprised if I ended up with Chrome using terabytes of space as a result. Since I am mainly concerned with having an editable backup in the event Google gets wiped off the face of the earth, I am not going to bother investigating the offline editing capability now, either.

Google Drive client problems

For my initial setup, I installed the Google Drive Mac client and saw it created a Google Drive folder under my user folder. My data is all on a separate volume from my main system volume, and I wanted to change the name. I was able to delete the Google Drive folder, quit and reopen the Google Drive app, and then select from the prompt a new folder to use. I picked my Documents folder on my data volume, and I moved a few other folders into Documents for simplicity. (I struggle to decide the most logical folder structure, but since Google Drive must sync one root folder, my mind was made up on those folders still hanging out next to Documents!)

The client started downloading my existing Google Drive files to the Documents folder. I changed the settings to exclude two larger folders, my TitaniumBackup folder my Nexus 6P backs up to and another folder I use to store files I shared with others, most of which are redundant with what I would be soon uploading, and which I looked forward to streamlining. The client also indexed all the files to be uploaded, of which there are apparently about 500,000. At a rate of about 50GB per day, I figured my documents would be uploaded in about two weeks.

The first morning after, I was disappointed to see the client was not running. I restarted it, and it initially reported being completely synced, even though I knew that was impossible. For a minute I feared all my documents had been deleted (I made sure to sync to my Drobo first.), but they were still there. After about 10 minutes, the Google Drive client reported it was uploading files. I guess it takes some time to switch from thinking it is done to scanning for files. It would be nice if it instead reported it was scanning instead of claiming completion.

Google Drive sync complete

Google Drive sync complete

About a day later, I found this message on the screen:

Sorry, Google Drive needs to quit.

An unknown issue occurred and Google Drive needs to quit. Error: 6248

Sorry, Google Drive needs to quit

Sorry, Google Drive needs to quit

The “Learn more” link was unhelpful.

I restarted the client and gave it another chance. The same thing happened after some number of hours, several times. Several days later, I think I managed to upload only a gigabyte or two of files.

Moving virtual machine images to sparse bundles

I suspected the Google Drive client might be somehow choking on my Windows 7 virtual machine, which is stored in a roughly 40GB Parallels image. I was not sure if that was a single large file or already distributed among smaller files. A quick investigation showed my Windows 7.pvm file was in fact a directory of smaller files, but the bulk of the 40GB was a single file representing the Windows filesystem. For what it’s worth, the Google’s “Files you can store in Google Drive” says it supports “All other files: Up to 5 TB.”

It occurred to me I should be able to move the entire PVM file to a sparse bundle backed volume, which would turn that huge file into many 8MB files and hopefully be easier for the Google Drive client to manage. I had no idea what performance implications that might have, so I did a quick search to see if this strategy was standard or at least done before. I found the blog post “Efficient backups: storing VMs in a sparse bundle” that describes exactly what I had in mind, so that was good enough for me.

I’ll see if the Google Drive client works better now.


Before I finished writing this post, the client already crashed. So apparently it was not the large virtual machine file it was choking on.

I checked the Console, and there are many items under System Reports named like Google Drive_2017-06-18+195436_CharlieDesktop.cpu_resource.diag containing similar content, notably a line similar to:

90s cpu time over 112 seconds (80% cpu average), exceeding limit of 50% cpu over 180 seconds

For the record, here is more of the error report:

Amazon Drive client

I was disappointed I apparently could not do something similar to what I did for the Google Drive client to get it to make my Documents folder its root. The Amazon Drive client can select an arbitrary location to store the synced folder, which is more user friendly than the Google Drive client’s assumption you want a Google Drive folder directly inside your user folder. But, no matter the folder you select in the Amazon client, it creates a new subfolder called Amazon Drive. So it seems if I am to use the unlimited photo storage option, I will need to move my photos folder inside that Amazon Drive folder.

I have not yet dealt with that, as I want to get my documents strategy straightened out first, but I suspect I will be able to maintain my current directory tree (and my Adobe Lightroom setup) by either making /Volumes/Striped/Pictures a hard link to /Volumes/Striped/Amazon Drive/Pictures or more likely by making the former a mount point of the latter.

Strategies for folder structure:

  • Soft link to master folder within synced folder

    Google Drive client will not copy a folder that is a symlink, so you cannot back up an external folder by creating a symlink in the Google Drive folder. One workaround is doing the opposite. (I have not checked Amazon Drive’s handling of symlinks.)

  • Mount master folder within synced folder to external mount point

    User ultra points out:

    Another workaround is mounting your directory to the Google Drive folder. You can use the bind option in /etc/fstab

    /your/directory /home/user/Google\040Drive/directory none bind 0 0

    (\040 is the space character in fstab)

  • Hard linked folders

    A hard linked folder is a pointer to the same disk location as another folder. They appear to be two separate folders, but the contents are in fact automatically synchronized since they are physically the same folders. Hard links are difficult to make on Macs since Apple crippled the ln utility. It can apparently be done (hardlink-osx), but there are problems with deleting files and more.

Once I figure out my documents, I intend to try the folder mounting method to deal with my photos, and then I will see about how Amazon Drive counts video files and decide what to do with the rest.

All the other data

For the remaining 13+ terabytes of video and backups, I intend to keep syncing to my Drobo and to at least one offsite backup that I will handle myself instead of in the cloud. I am thinking I’ll clone my hard drives and send them to my mom to put in a NAS attached to her router. Then I can simply rsync to it or perhaps use Arq and do those backups in an encrypted fashion (though if I do that, I should first do it locally on my network of course).

Life is wonderful!

Join the movement!

Show your support by signing up to be among the lucky few notified when I manage to blog. This could be as often as once a day or as infrequently as yearly!

Help get me elected by purchasing products mentioned in this entry!

blog comments powered by Disqus