Skip to main content

Dropbox Nov 2018 workaround

So Dropbox is no longer supporting anything besides ext4 on linux as of Nov 7th 2018.  Here's how to work around that WITHOUT superuser permissions.


First, create a sparse file of whatever size you'd like for your Dropbox folder.
$ truncate -s 5G ~/.Dropbox.img

Now we need to format this as ext4, But we want to make sure that we own the created file system, not the default of root.
$ mkfs.ext4 -E root_owner=$(id -u $USER):$(id -g $USER) ~/.Dropbox.img

Setup the loopback device with our EXT4 image
$ udisksctl loop-setup -f ~/.Dropbox.img

You may need to mount the device if it hasn't been already:
$ udisksctl mount -b $CREATED_LOOP_DEVICE

Check where our filesystem is mounted:
$ mount | grep Dropbox.img

Move any existing data from the previous dropbox folder to the new location:
$ mv ~/Dropbox/{.,}* /$MOUNTPOINT/OF/DROPBOX/IMAGE/UUID$

Link our new folder back to the dropbox folder
$ ln -s  /$MOUNTPOINT/OF/DROPBOX/IMAGE/UUID$/ ~/Dropbox

You can now start dropbox and sync away, the device will need to be mounted before dropbox is started.

Here's a script that could be used to set this up every time before dropbox is run:

 #!/usr/bin/env bash  
 #Dropbox local loopback file system workaround  
 LOOPFILE=$HOME/.Dropbox.img  
 LOOPSIZE=5G  
 #Check if the loopback file exists  
 if [ ! -f $LOOPFILE ]; then  
      # Create the loopback file  
      truncate -s 5G $LOOPFILE  
      # Create the filesystem  
      mkfs.ext4 -E root_owner=$(id -u $USER):$(id -g $USER) $LOOPFILE  
      #setup the loopback device  
      LOOPDEVICE="$(udisksctl loop-setup -f $LOOPFILE | awk '{print $5}' | sed 's/.$//')"  
      #Check if our loop file is mounted  
      if [ ! $(mount | grep -q $LOOPFILE) ]; then  
           #mount our loop file  
           udisksctl mount -b $LOOPDEVICE  
      fi  
      # get our mount point  
      MOUNT="$(mount | grep Dropbox.img | awk '{print $3}')"  
      # Move any existing data from our original folder to the new location  
      mv ~/Dropbox/{.,}* $MOUNT  
      # Remove the old Dropbox folder  
      rmdir ~/Dropbox  
      # Link the new mount to our Dropbox folder  
      ln -s  $MOUNT ~/Dropbox  
 else  
      # Check if our loop has been created  
      if [ ! $(udisksctl dump | grep -q test) ]; then  
           #setup the loopback device  
           LOOPDEVICE="$(udisksctl loop-setup -f $LOOPFILE | awk '{print $5}' | sed 's/.$//')"  
      fi  
      #Check if our loop file is mounted  
     if [ ! mount | grep -q $LOOPFILE ]; then  
           #Find the loop file  
           LOOPDEVICE="$(udisksctl dump | grep -e ' Device:.*loop.*\| BackingFile:' | grep -B1 $LOOPFILE | head -1 | awk '{print $2}')"  
          #mount our loop file  
         udisksctl mount -b $LOOPDEVICE  
     fi  
 fi  
 # now launch dropbox  
 dropbox  


Comments

Popular posts from this blog

8Bitdo NES 30 Pro on linux

This post will go over the setup I had to do to get my   8Bitdo  NES30 Pro controller working on my Arch linux desktop with steam.  This results in the system loading the xboxdrv automatically when the controller is connected, and unloading once finished. Firmware Update The first thing to tackle was the firmware update on the controller,  This may not be needed, but I like to keep my devices up to date. After some googling, I was able to find a program called fwupd  that's able to update the controller via a USB connection.  It's available for Arch in the community repo. The basic syntax of the command is: fwupdmgr get-devices fwupdmgr refresh fwupdmgr get-updatessudo fwupdmgr update The controller will need to be put into 'Firmware update mode'.  Be aware that the final command will also update all eligible firmware on your system, so If you don't want that, please dig into the documentation Bluetooth Connection G...

The Saga of EA Customer support part 5

Jan 5, 2017  (14 Days after the initial contact) At 2:24 AM I was sent the following in reply to my 3rd ticket where I stated that I was going to become a nuisance. Thank you for contacting Electronic Arts Customer Experience. I sincerely apologize for the delay caused in responding to your issue and appreciate your patience. This is ***** from the Game team following up your incident.  I would like to inform you that your case was escalated to the dedicated team. In this case I suggest you to wait for email from the specialist team.  Should you have any further questions regarding this or any other issues, please do not hesitate to let us know. You can also find answers to common questions on our Help Center at http://help.ea.com , or ask our community experts by visiting Answer HQ at http://answers.ea.co This reply also closed the ticket. At 5:26 PM I replied with the following: Hi, Thank you for taking the time to update me on this issue. However:...

The Saga of EA Customer support part 2

Dec 24, 2016 (2 days after initial contact) I completed my task set out by the CSR from my previous contact, what I had interpreted as being complete the next quest, and in this case I chose the complete 25 games to unlock the final zombie hero.  Over the course of those 25 games I played some multiplayer and increased my Rank and League.  I completed several additional Quests, as well as several single player Missions. None of that had worked, and now the final zombie hero did not unlock either.  Time to contact support and tell them that the issue had not resolved. At 1:52 PM I sent Support the following email: Hi. I've completed up until the next quest where the reward was unlocking the last zombie hero. I still have not received the last starting plant hero, as well I have not revcieved the last starting zombie hero from the last completed quest. My hero's thus far are: Green shadow Solar flare Night cap - revcieved from 6.99 starter bundle S...