Previously, we have done a tutorial on setting up multiple Dropbox accounts in Windows 7. There is no reason for us to leave out Mac and Linux as well. So here is it, the tutorial to run multiple Dropbox accounts in Mac and Linux.
Note: The below tutorial assumes that you have already installed (and configured) your primary Dropbox account in your computer. The Linux tutorial is based on Ubuntu Lucid and the Mac tutorial is based on OS X 10.6 Snow Leopard.
The default folder for Dropbox is /home/Dropbox. You have to setup another folder and configure another instance of Dropbox to run in that folder.
Firstly, create two custom folders. Both have the same name except that one has a “.” in front of its name (For example .dropbox-mte and dropbox-mte in this tutorial). The folder with the ‘.’ will contain the configuration files while the other one will contain your files to be synced.
Secondly, open the terminal and type the command:
HOME=$HOME/.dropbox-mte /usr/bin/dropbox start -i
The setup window will appear and guide you through the configuration process. When it asks you for the Dropbox location, check the option “I want to choose where to put my Dropbox folder” and select the other folder that you have created.
Run multiple dropbox accounts on startup
In your Linux, open a text editor (gEdit for Ubuntu). Paste the following:
#!/bin/bash HOME=$HOME/.dropbox-mte /usr/bin/dropbox start
Save the file as DropboxAltStarter.sh in your Home folder.
Make it executable:
chmod 755 ~/DropboxAltStarter.sh
Go to System -> Preferences -> Startup Applications. Click Add and include the following:
Name: 2nd instance of Dropbox
The steps for Mac is similar to Linux.
Open the terminal (Utilities -> Terminal) and type the command:
HOME=$HOME/.dropbox-alt /Applications/Dropbox.app/Contents/MacOS/Dropbox &
The setup window will appear and guide you through the configuration process. When it asks you for the Dropbox location, check the option “I want to choose where to put my Dropbox folder” and select the custom folder that you have created.
You should also see two dropbox icons in the taskbar. If you close the terminal, the alternate dropbox account will also exit. Don’t worry, we can set it up to run automatically the next time you boot up.
Run multiple dropbox on startup
To automatically run the second instances of Dropbox on startup, you have to create a small app and add it to the login items. It may sound daunting to create your own app, but it is actually very easy.
In your terminal, type
mkdir -p ~/DropboxAltStarter.app/Contents/MacOS/
This will create the folder DropboxAlStarter.app in your Home directory.
Now, open a text editor (preferably TextWrangler, Text Edit does not work well with this), and paste the following code:
<?xml version="1.0" encoding="UTF-8"?> <!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd"> <plist version="1.0"> <dict> <key>CFBundlePackageType</key> <string>APPL</string> <key>CFBundleExecutable</key> <string>DropboxAltStarter</string> <key>LSUIElement</key> <string>1</string> </dict> </plist>
And save it with the name “Info.plist” inside “DropboxAltStarter.app/Contents” (You might want to save it to the desktop first, and then drag it to the DropboxAltStarter.app/Contents folder).
Open another new text file and paste the following lines:
#!/bin/bash HOME=/Users/$USER/.dropbox-alt /Applications/Dropbox.app/Contents/MacOS/Dropbox
Save the file as DropboxAltStarter (without any extension) in the folder DropboxAltStarter.app/Contents/MacOS.
Back to your terminal, type the following command to make your script executable:
chmod 755 ~/DropboxAltStarter.app/Contents/MacOS/DropboxAltStarter
Testing your app – Double click on the DropboxAltStarter app and see if it activates the second instances of Dropbox. If yes, congratulation, you have just created a Dropbox starter app.
Adding your app to startup item
Now go to System Preferences ->Account. Click on the Login Items tab. Click the “+” button at the bottom of the window.
Navigate to your Home directory and add the DropboxAltStarter app to your startup list.