[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Doubt about apt pinning



Hi all!

At the moment I'm using Debian GNU/Linux Squeeze in my workstation and
to doing tests on VoIP I'm needing to install the Twinkle package
specifically in its version of the stable branch. According to what I
was reading, this is possible to be done with pinning and I was reading
the man pages of apt_preferences, but not yet I know clearly how the the
priorities works, reason why I would like if somebody can help me to
understand how it works. 

For example, I was trying creating the /etc/apt/preferences file with
the following content:

Package: twinkle
Pin: release a=stable
Pin-Priority: 900

Then, I verify the priorities:

# apt-cache policy twinkle
twinkle:
  Instalados: (ninguno)
  Candidato: 1:1.2-3
  Pin del paquete: 1:1.2-3
  Tabla de versión:
     1:1.4.2-2 900
        500 http://debian.freesoftware.org testing/main Packages
        100 /var/lib/dpkg/status
     1:1.2-3 900
        500 http://ftp.us.debian.org stable/main Packages

According to man pages of apt_preferences, if it doesn't have defined a
"target release", to installed packages a priority of 100 is assigned
and to the rest is assigned 500. I think for that reason there is a
'500' associated to each reposity. Although the candidate is the package
for stable as I try that it is, is not clear to me why are associated
the priority 900 as much for testing as for stable.

Independent of this doubt, according to which I was testing, the package
of the stable branch are installed and it stays, that it is what I
wanted; that is to say, if I do upgrade, beyond which the package of
testing has a newer version, it isn't updated the installed one of the
stable branch. 

Continuing with my understanding of how the priorities works, I tried
adding in my sources.list the unstable repository and adding a block in
the preferences file:

Package: twinkle
Pin: release a=stable
Pin-Priority: 900

Package: twinkle
Pin: release a=unstable
Pin-Priority: 950

Here I pose a similar doubt to which I exposed above: why the value 950
appears associated to each version if I assigned in the preferences file
a priority of 900 to the version of stable branch and 950 to the version
of the unestable branch? 

Like additional data, I see that /var/lib/dpkg/status moved of place
with value 100. This suggests to me that this file has a listing of all
the installed packages and since those that are under this condition we
said that a priority of 100 is assigned to them, I imagine that this is
the form in which Debian says to us 'all the packages that are in this
file have priority of 100'. Bah, in fact, instead of the _last_
installed, would be the last ones that sometimes could be installed,
since later I did 'remove'.


Thanks in advance for your reply.

Regards,
Daniel
-- 
Fingerprint: BFB3 08D6 B4D1 31B2 72B9  29CE 6696 BF1B 14E6 1D37
Powered by Debian GNU/Linux Squeeze - Linux user #188.598

Attachment: signature.asc
Description: Digital signature


Reply to: