"Updating database of binaries" step very slow under Yosemite?

James Berry jberry at macports.org
Mon Oct 20 15:50:46 PDT 2014


> On Oct 20, 2014, at 3:27 AM, Clemens Lang <cal at macports.org> wrote:
> 
> Hi,
> 
> ----- On 20 Oct, 2014, at 08:18, Lawrence Velázquez larryv at macports.org wrote:
> 
>> On Oct 20, 2014, at 1:22 AM, Leo Singer <aronnax at macports.org> wrote:
>> 
>>> I found that the "Updating database of binaries" step of installing a port
>>> became very slow after I upgraded to Yosemite (i.e., takes many minutes on an
>>> SSD). I am just starting to install my ports again after uninstalling all of
>>> them, so if this operation scales with the number of ports it should be even
>>> faster than usual right now. Has anyone else experienced this?
>> 
>> I've been seeing this also. Good to hear that I'm not imagining it.
> 
> I think our SQLite database isn't performing very will in large transactions
> (such as this one, or activating boost).

I just saw this too...

As a guess, and from a quick look at the code (where I might have missed something), the updates are not wrapped in a SQL  transaction, so the update for each file is triggering an implicit transaction, with a full acid commit and flush to disk, so things are very slow. If this is the case, a transaction should probably be wrapped around either the entire update of binaries, or around smaller sets of them.

Though I don’t think know why that would be any slower with Yosemite.

Another possibility is that something in fileIsBinary got very slow in Yosemite, but that just uses very common file system commands like lstat, open, fread, etc, so that doesn’t seem likely.

James


More information about the macports-users mailing list