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

Re: Configuring /etc/apt/preferences (mystery solved)



Andrei Badea wrote:

Vincent Lefevre wrote:

On 2004-04-22 23:49:49 +0200, Andrei Badea wrote:

Having a slow Internet connection, I want to set /etc/apt/preferences so that packages from the CDs have a greater priority that those on the network. So I put in preferences:

Package: *
Pin: origin ftp.cz.debian.org
Pin-Priority: 500

IMHO this should set a priority of 500 for all packages from the ftp mirror.



If I've understood correctly, this sets a priority of *at least* 500
for all packages from the ftp mirror. But you may have other rules
setting a higher priority.


I tried to change /etc/apt/preferences to this (one single rule):

Package: *
Pin: origin ftp.cz.debian.org
Pin-Priority: 999

in order to increase the priority, just to see what would happen. Unfortunately nothing, on apt-cache policy I get the same list that I posted before. All sources have the same priority 990. Maybe the "origin" syntax is wrong?

I finally managed to set a greater priority for the CDs. After deleting the default release line from apt.conf

APT::Default-Release "unstable";

and using this single rule in preferences:

Package: *
Pin: origin Debian GNU/Linux 20040218 _Sid_ - fsn.hu unofficial i386 Binary-1 (20040218)
Pin-Priority: 999

the first CD gets a priority of 999 and the others and the ftp source get the default 500 .

To be complete, this is the relevant line (for the first sid CD) from my sources.list:

deb cdrom:[Debian GNU/Linux 20040218 _Sid_ - fsn.hu unofficial i386 Binary-1 (20040218)]/ unstable contrib main non-US/contrib non-US/main non-US/non-free non-free

Hope this helps someone.

--
Andrei



Reply to: