Last Updated: February 25, 2016
·
444
· didi

Prelink : Accelerate the applications launch

Most of the applications need shared libraries. They are loaded everytime an application is started. For programs with a lot of dependencies, this operation is quite long. The fact is the libraries doesn't change everytime so the bind operation is often the same. That's why Prelink records those links and thus is saving time.

======

  1. Prelink is in the repository "Universe".
    Then install the package apt://prelink.

  2. Edit /etc/default/prelink with root and modify
    PRELINKING=unknown by PRELINKING=yes

    sudo sed -i 's/PRELINKING=unknown/PRELINKING=yes/' /etc/default/prelink
  3. Launch Prelink for the first time, a quite long operation :

    sudo /etc/cron.daily/prelink

Then Prelink is launched daily.

After an update of a library, Prelink is lauched on all the software using it.

Prelink can be launched automaticaly after the installation of a new software :

  1. Create the file /etc/apt/apt.conf.d/98prelink

  2. Add the line :

    DPkg::Post-Invoke {"echo Prelinking, Please wait...;/etc/cron.daily/prelink";}

To desactivate Prelink, just replace PRELINKING=yes by no.

Check the man page.

Source