Dancing with myself

Every time I go on a trip I plan to spend half a day “setting up my laptop”. Mostly this means copying files back and forth until it somewhat resembles my main machine, and hoping I haven’t forgotten anything (say, for instance, the time I went to the RH Summit and forgot to bring the VPN key. Sigh).

I’m much too lazy to set up rsync for my desktop configuration for this purpose, and anyway I suspect that I’d spend as much time tweaking any rsync script as I do just copying things around. Instead I’ve spent my time more usefully, thinking about how this could be automated for KDE or Gnome.

What I’m thinking about in particular is a new role for kde.org or gnome.org: give everybody who uses the desktop a little space on the web site, and automatically encrypt and upload certain bits of data; then automatically download and synchronize it when the user logs in and has a network connection.

Initially this could just be a few things relating to my identity: the contents of my keyring (including passwords for web sites), information about my various mail accounts, my gaim accounts, newsgroups I use and information about what articles I’ve read, my blog list in RSSOwl, my calendar, my sticky notes, my .cvspass file, probably even my mozilla bookmarks.

I think that is actually pretty minimal and that over time we’d find more things to add — just go through the list of programs you use daily and it is pretty easy to see bits of configuration that relate to your identity, as opposed to machine- or session-local ephemera. But initially just starting with one or two of these to work out the concept would be fine.

The synchronization phase is the only tricky point. I’m often using both my machines at once, and if I make an account on some website using my main machine, and make another account around the same time using my laptop, I think it is reasonable to expect that the results will be merged — that I won’t lose one or the other.

This means that simply copying config files around in a naive manner is probably not workable. I don’t think there are any big problems solving this; in most cases I care about, it boils down to computing the union of two lists.

In the unusual case where the two configurations refer to one account with different passwords, I suppose we could defer to the user at synchronization time. I doubt this happens often.

In the bigger view I think this is just the first step toward integrating the desktops with their respective web sites. There are plenty more ways this could be done.

11 Comments

  • SSH identity. IRC network list and nicks and NickServ passwords I use in respecitve networks. .subversion/auth.

  • Could something like the Opensync syncronisation framework be useful with this? They are getting all the sync and merge stuff sorted all you would need is a webdav server somewhere to act as the master, as you say gnome.org or somewhere, and then you could just make a plugin for each type of service you want to sync. A simple generic one that does files, more complex ones for things like gnome-keyring and bookmarks.
    This will be great I can’t wait!

  • iFolder

  • I like Google’s BrowserSync for Firefox. That just saves browser state, but so much of my time is spent in Firefox that it takes care of most things. Google’s making some progress here, but I’m not sure if they know what they’re doing; it *looks* like they’re making it so your computer is just an abstraction, that you can use from any laptop or desktop machine in the world, but it isn’t really there yet, just mail/browser/calendar.

    The startup I used to work for was trying to make a device that did this for you; conflict resolution was handled through file versioning, and on client computers the sync happened in the background. I think this is still a great idea, partly because having a dedicated server to handle this makes so much of this easier, but it needed to bake longer than it did. For this to be really useful, it would need to sync over the web, where our product just worked on the local network.

  • whats ifolder

  • I keep being tempted to write code for this — basically just as little tool that sits in the background and does period commits of your home directory (or some “interesting” subset) to monotone, and then promiscuously replicates them to interesting places (e.g., a server you set up somewhere, or via an opportunistic side-channel when you ssh places, or probably both). I’m really tired of having to think about transferring files between school and home, and it was even worse when I had a laptop…

    (I guess if anyone wants to encourage me to do this, buying me a new laptop might do it ;-).)

  • Yeah, the problem does share some attributes with version control. I’m not sure that’s the way I would go for a solution, though. First, VC systems aren’t typically encrypting data — and for this I would want the server not only to password-protect the data, but I’d also want it to only ever see encrypted binary blobs in the first place. Second, VC systems are typically working with a text-based merging model; for me this fails because I don’t know, or want to know, the file formats of key rings, bookmark files, etc.
    I think these considerations tend to rule out iFolder as well. Certainly with iFolder I would have to know what files to share in the first place. And offhand I would assume that existing Gnome programs aren’t especially careful about separating identity-related state from other state, meaning that in all likelihood I’d wind up with weirdness. (BTW, other tom — see iFolder.com)
    OpenSync does look promising for this area.

  • Maybe Gnome Storage would provide something in this space, too.

    The other night watching Veronica Mars I learned about Apple’s “.Mac” accounts. Apple appears to have solved all this and more. Typical.

  • Oh, but I already know how to build an encrypted server-only VCS store :-). Anyway, I wasn’t really planning to worry about the giant centralized server anyway; I can set up a private server for myself, or just use ssh without any server. Using an untrusted server is cool, but you don’t need it for initial userbase bootstrap.

    Another difference is that I’m actually more interested in non-identity data — I think it’d be _really handy_ if I could write at home for a while, then when I get to school open up the same document and keep writing. (And automatically get VCS for one-off papers I write for school, etc., which I otherwise can’t be bothered to do.)

    For more structured formats, you could somehow explode the data when you store into the VCS — I’ve thought about this most in the context of storing mail. A tool could notice that it is dealing with a maildir, and translate the “read”, “replied”, etc. bits into mtn attrs, and get the advantages of the attr merging algorithm, which is exactly the right algorithm for this. There really aren’t that many merge problems at a theoretical level (scalar merge, tree merge, sequence merge (~textual merge), maybe set merge?), and for most of them by far the best implementations are in VCS tools.

    Anyway, though, the _important_ claim I’m making is that with monotone, there’s a leverage point here — a place where a few hundred lines of code could radically improve user experience. You can sand off the sharp edges at leisure.

  • [...] to mod­ify all the impor­tant apps to take advan­tage when a server side is avail­able. Tom Tromey is think­ing about it, and I’m also encour­aged by Abi­Word [...]

Join the Discussion

You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>