Help:DropBox

From LabWiki
Jump to: navigation, search

DropBox

Drop box is service that lets you share files easily between your laptop and the Demography Lab network. For 2GB or less, the service is free. The useful/cool thing about DropBox is that any changes you make to files in the special directory are automatically synchronized across all of the machines that you use it on.

To use dropbox you must have a dropbox account. Let's assume that you already have one, then all you need to do is configure the dropbox client on the Demography Lab server.

IT MIGHT BE USEFUL TO KNOW that dropbox runs differently here

It might be useful to know that we run Dropox slightly differently in order to trick it into working correctly. The principle difficulty with Dropbox in a networked environment is this:

  1. dropbox does not start up until the user logs into the ONE machine on which dropbox runs.
  2. dropbox only perceives that files have changed if those files live on a disk that is physically owned by the server.

In order that dropbox work as we would like: that is, it should start up when you log in AND it should update files to the cloud regardless of how you modify them... We do the following:

  1. we set up a special share for you called /data/Dropbox0/<userid> which is physically owned by the noMachine server, quigley, but is shared to all machines
  2. we trick dropbox into thinking that /data/Dropbox0/<userid> is your home directory.
  3. we wrote a local program implements all of this without you *having* to be aware...unless something goes wrong. That program is launched by the caja-dropbox menu item or by typeing

caja-dropbox start -i on the command line.

Note that what this means is that in order for dropbox to perform -- once it is setup -- you will need to be logged in via noMachine. Once you are logged in via noMachine, dropbox will do its magic even when you do your work on a different server.

Setting up DropBox on the Demography Lab server FOR THE FIRST TIME

These directions assume that you have NEVER tried to setup dropbox at the Demography Lab before BE honest -- if this is not you, this will not work. Instead you should strat with the instructions for Removing Dropbox then come back here to install it fresh.



If you have not already done so, install DropBox on your personal computer and sign up for a DropBox account at http://dropbox.com. The instructions below are for setting up dropbox on the Demography Lab server. It does not make a lot sense to do this unless you are already running it on you personal computer.

Important It is unwise, insecure and unhygienic to simply connect your entire Dropbox folder to the DemographyLab server. The directions below instruct you to share only a folders that you need in order to do science. Nothing good can come of storing your massive collection of pirated videos on the Demography server.

  1. Determine which of your Dropbox folder(s) you would like to sync to the DemogLab server. These folder(s) should already exist in your Dropbox cloud ' and on your personal laptop or whatever computer you own.
  2. Log on to quigley using noMachine. Quigley is the only demography lab server that runs dropbox. From the desktop on quigley ... click on the DropBox-caja menu item under Applications->Internet to launch dropbox.
  3. give you email address and password that you use with dropbox DropboxSignin.png
  1. After signing in look carefully for the x Avanced Settings option and select it. It's NOT the big obvious button.DropboxSignin-Advanced.png
  1. On the Advanced setup options panel leave everything as it is EXCEPT choose the selective sync option: DropboxSignin-Selective.png This should give

you the opportunity to select a subset of your dropbox folders for syncing on the Demography Lab servers.

Soon you should be told that your computer is linked and the directories that you chose to sync will soon be copied into your Dropbox folder.


If you did everything correctly and the wind was at your back, then you should have a working dropbox set up. The indications of this happy situation are the following:

  1. That dropbox did not emit any terrifying error messages.
  2. That the upper right corner of your desktop has one of these: DropboxIcon.png
  3. That you have a symlink from ~/Dropbox --> /data/Dropbox0/userid/Dropbox
    ls -l Dropbox
    and there are at least a few files in it
  4. That you have a file called ~/.config/autostart/dropbox.desktop
    ls -l ~/.config/autostart/dropbox.desktop

Oooops I screwed up my dropbox setup and now I am sad

If you failed to follow the detailed instructions above or if your the victim of consiracy that always screws this sort of thing up for you or if you set up dropbox a long time ago and it just doesn't work right anymore... then here's how you start over:


Removing dropbox so you can start over

Do this carefully and avoid catastrophic loss of data:

  1. turn off dropbox on the server by typing into a terminal:
    caja-dropbox stop
  2. THE SECOND AND MOST IMPORTANT STEP is to unlink the demography server from the dropbox cloud. To do this:
    • sign in to http://dropbox.com
    • look for your name in the upper right corner of the dropbox web site. It hides a menu that includes such things as "Add account photo", "Settings", "Install", "upgrade" ... choose Settings
    • The screen should now have three tabs: "profile", "account" and "security" Choose Security
    • Scroll down until you see the list of "devices" that are syncing: DropboxUnlink.png
    • find the device that IS the demography server (probably quigley) then click on the corresponding 'X' way over to the right of this screen fragment.
    • dropbox will warn you and confirm that the server is no longer linked.
    • It would be unwise to proceed until you are sure that the above steps went correctly
  3. Remove all signs of dropbox from your home directory. These are pretty powerful commands so type them very carefully or drag and drop -- if you screw it up you could delete your life's work.
    /bin/rm -rf ~/.dropbox ~/.dropbox-dist ~/Dropbox ~/.config/autostart/dropbox.desktop

In most cases you are done deleting dropbox -- but in case you are special please read on.


  1. If you set up Dropbox a long time ago -- or are the sort of person who likes to do things differently -- you might have put your Dropbox folder somewhere other than your home directory (its default location). If so you will need to track it down and destroy it. The most likely nonstandard location is /data/commons. To find it and destroy it :
    • ls /data/commons/${USER}/Dropbox ( typing ${USER} is the same as typing your username. For me that's 'carlm' NOT $carlm.)
    If the above command revealed an existing Dropbox folder then destroy it by typing
    • cd /data/commons/${USER} (cd to your /data/commons directory)
    • /bin/rm -rf ./Dropbox (be careful with this command OK?)
  2. If something went wrong in a previous attempt to setup Dropbox in the correct location (/data/Dropbox0/${USER} then you will want to delete the evidence of your previous attempt. If you are not sure type this to find out:
    • ls /data/Dropbox0/${USER}
    If the above command revealed an existing /data/Dropbox0/${USER} directory then delete it with the following commands
    • cd /data/Drobox0
    • /bin/rm -rf ${USER} ({${USER} or your username...same thing)


Congratulations you have undone dropbox. To (re)install see Installing for the first time

Troubleshooting Dropbox

Dropbox only runs on the noMachine server (currently qugley). And it only works properly if the following are true -- so pretend you are talking to a call center in Bangalor and consider each possiblility below:

  • you are logged into quigley via noMachine
  • your Dropbox folder is stored in /data/Dropbox0/userid. ( ls -l /data/Dropbox0/${USER} )
  • dropbox is running on your desktop:
    1. look for this icon:DropboxIcon.png
    2. ( caja-dropbox status )
    3. you can start dropbox from the Applications->Internet menu or from the terminal: caja-dropbox start -i
    4. to make dropbox autostart whenever you login: cp /data/Dropbox0/dropbox.desktop ~/.config/autostart
  • your dropbox account is setup to sync one or more folders with our noMachine server: click on this icon:DropboxIcon.png and explore ... maybe visit dropbox.com
  • you have not exceeded your dropbox account capacity (2GB for the free version)


If the above does not clear up the problem, then probably the best and fastest way forward is to start over. See Removing Dropbox for information on how to remove dropbox and Setup for instructions on re(installing)