Et toi, p2?

Whenever I think of p2, I just can’t shake the image of the little dog in the stories we used to make up in French class in elementary school. “Pauvre Pitou. Il a sauté par la fenêtre…” But I digress…

Today I did a little experiment with p2. I downloaded one of the Ganymede M7 packages and installed in into a shared location on my file system. This particular system has Fedora 8 Linux installed, so I opted to put Eclipse in the “/opt” directory. Anybody can read from this directory, but only root can write.

I then launched Eclipse as a non-root user and opened the “Software Updates and Add-ons” dialog and added a bunch of stuff from the Ganymede update site. From a user’s perspective, everything just worked. p2 uses some smarts to pick the best mirror from those available, and downloads all the required bits and pieces using multiple threads. Overall, the experience was pretty seamless.

Under the covers, there was more going on. Of course, running as non-root, p2 couldn’t write the downloaded files into my /opt/eclipse/... directory, so it created a hidden directory in my user home, /home/wayne/.eclipse with all the new stuff. It also stores my configuration there.

This is good stuff. If I really was sharing this workstation with others, I’d want to share the bulk of the common plug-ins, but have the ability to customize my own experience by adding my own additional plug-ins without having the custom experience of other users imposed on me. I understand that the p2 framework provides support for updating the shared installation, but this isn’t exposed in the user interface yet. In fact, it probably doesn’t make sense for it to be exposed in the workbench, a separate (perhaps headless) application might be more appropriate for that anyway.

I don’t know if the p2 developers thought of everything, but they sure thought of a lot of things.

This entry was posted in Equinox. Bookmark the permalink.

5 Responses to Et toi, p2?

  1. Nicolas Bihan says:

    What means “Et tu, P2” ?
    If you mean : “Are you P2 ?” -> Es-tu P2 ?

    And what’s the Ganymede update site adress please ? I downloaded RC1 and there is no update site by default…

    By the way, I’m French, so maybe my English is like your French 😉

  2. Perhaps Wayne was alluding to “Et tu, Brute?”. Though I’m not sure how appropriate that is since the phrase refers to bretrayal and Wayne seems to be happy with this particular p2 experience 🙂

  3. Wayne Beaton says:

    I had meant to write something like “And you, Pitou?”. My original thought was that it was a little funny. Perhaps it’s just too much of an inside joke (FWIW, all the stories we made up in French class had tragic endings).

    In retrospect, it was a bad choice. I see nothing but a rosy future for p2.

  4. Nicolas Bihan says:


    ok, so “Et toi, P2”. But looks like a private joke 🙂

    I had some good experiences with P2 too (pauvre Pitou 😉 ). I just still looking for a “user manual” to be sure that I’m not missing features.

  5. Karl Trygve Kalleberg says:

    Fortunately for us straddlers still using 3.3 and older, the scenario you describe also mostly works with the older, pre-p2, members of the 3.x series. You might sometimes have to help the update manager along by suggesting another install directory than /opt for new plugins, but it’s not an entirely crummy experience.

    Stuffing the configuration into ~/.eclipse is also nothing new. That being pointed out, it’s reassuing that this stuff still works, because Eclipse on Linux would be a real pain without it.

    What I always had trouble with 3.3 and lower was updating “platform” plugins. Say, getting newer versions of the JDT, when going from 3.3.0 to 3.3.1. That never worked very well in the 3.3 Update Manager for me, as the update manager insisted on placing the upgrade in /usr where I don’t have write privileges as a normal user. (Arguably, it’s a system admin task to keep the platform plugins in sync, but the Update Manager knows no distinction and will happily suggest upgrades for any plugin when you search for updates).

    Also, another dirty little secret: Should you ever accidentally start Eclipse 3.3 (and older) as root, it’ll start nuking your configuration directory in /opt or /usr or wherever you installed Eclipse. Not a pretty sight:/

Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out /  Change )

Google+ photo

You are commenting using your Google+ account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )


Connecting to %s