Share the Knowledge!

Description

Works for both dropbox 0.7.x and 0.8.x and on all platforms (Windows / Mac / Linux) – tested on 0.7.110 on Windows and 0.8.112 on Linux.

Won’t work with dropbox 1.2.x or dropbox 1.3.x because of the new encrypted config database.

Primary use-case is on headless Linux servers.

Download

Download herehttp://dl.dropbox.com/u/340607/dropbox_set_lansync.py

For Python < 2.6 Usershttp://pastebin.com/qu5YrrLg

Usage

First of all you need to install pyDropboxValues, then place dropbox_set_lansync.py in the same place and make it executable.

Backup your current config database, in case these instructions don’t work properly

pyDropboxValues.py _backup

If something goes wrong and dropbox doesn’t work correctly, you can then just delete the modified config database and copy/rename the backup into place.

You can then disable or enable LAN Sync by stopping dropbox, then running

dropbox_set_lansync.py on

or

dropbox_set_lansync.py off

and then starting dropbox again. On a Linux computer, you can use ‘dropbox stop’ and ‘dropbox start’ to start and stop the dropbox daemon.

Quick solution

A quick solution to turn off LAN sync without installing scripts is to use the command line sqlite3 client:

sqlite3 .dropbox/config.db "replace into config (key,value) values('p2p_enabled','0')"

For config database version 0 (has no config.db, but a dropbox.db) the value needs to be base64 encoded. Make a backup copy of the database file before modifying it.

Share the Knowledge!

Helpful(0) Unhelpful(1)
  • niels390

    “Won’t work with dropbox 1.2.x or dropbox 1.3.x because of the new encrypted config database”

    –> Is there an alternative for this situation?

    • XRulescu

      I`ll like to know this too.