Code Yarns ‍👨‍💻
Tech BlogPersonal Blog

How to share the same Dropbox directory between Windows and Ubuntu

📅 2013-Mar-17 ⬩ ✍️ Ashwin Nanjappa ⬩ 🏷️ dropbox, ubuntu, windows ⬩ 📚 Archive

I use a computer where I dual boot between Windows and Ubuntu. To avoid wasting disk space, I would like to use the same Dropbox directory between both Windows and Ubuntu. Here is how I was able to do this:

  1. I first installed the Dropbox client on Windows. Assume it uses the directory C:\Users\joe\Dropbox in my NTFS partition.

  2. Boot into Ubuntu. Edit /etc/fstab so that the NTFS partition which contains the Dropbox directory on Windows is mounted automatically at boot. I assume it is mounted at /media/my-c-drive

  3. Install the Dropbox client for Ubuntu. During installation, let it pick its default directory as /home/joe/Dropbox

  4. You can see the Dropbox client running in the Panel. Quit it.

  5. Delete the Dropbox directory and replace it with a symbolic link to the Dropbox directory on the NTFS Windows partition:

$ rm -rf /home/joe/Dropbox
$ ln -s /media/my-c-drive/Users/joe/Dropbox /home/joe/Dropbox
  1. Start the Dropbox client again and you are done. It will use the same directory as that used by Windows for syncing.

Note: As you might have suspected, there is a small problem with this technique. Every time you switch between Windows and Ubuntu, the Dropbox client will re-index the contents of its directory. This will happen in the background, but it will consume CPU, disk and network bandwidth. How irritating this is depends on the size of your Dropbox directory. If your Dropbox directory is large, then this type of sharing can only be a temporary solution for these reasons.

Tried with: Windows 8 x64 and Ubuntu 12.04 LTS


© 2023 Ashwin Nanjappa • All writing under CC BY-SA license • 🐘 Mastodon📧 Email