How to reduce 3rd party repository priority in apt

1

2

I'm using Debian Testing together with the Deb Multimedia (previously Debian Multimedia) repository for testing. I want to reduce the priority of the deb-multimedia packages so it only installs certain packages. I've tried with:

Package: *
Pin: release o="Unofficial Multimedia Packages"
Pin-Priority: 10

and

Package: *
Pin: origin "mirror.home-dn.net"
Pin-Priority: 10

But neither works, the packages still have the default priority (500).

The Release file from the repository looks like this:

Archive: testing
Version: None
Component: main
Origin: Unofficial Multimedia Packages
Label: Unofficial Multimedia Packages
Architecture: amd64

What am I doing wrong?

Edit: It worked when I used the Version information instead:

Package: *
Pin: release v=None
Pin-Priority: 10

But I still don't know the reason the other filters didn't work.

solarc

Posted 2012-06-21T19:45:41.137

Reputation: 475

Answers

2

What I did for my system was this:

Package: *
Pin: origin "deb-multimedia.org"
Pin-Priority: 10

You have to be able to precisely specify which files to pin. Using the URL of the repo is the best way to be sure, as the name might change unexpectedly.

Remember to use the full site name you've used in your sources.list (and sources.list.d/* files)

lornix

Posted 2012-06-21T19:45:41.137

Reputation: 9 633

Thanks for your answer. I am using the mirror.home-dn.net mirror, will try to change that to deb-multimedia.org, maybe apt uses the url of the original repository? – solarc – 2012-06-28T00:35:31.143

I tried again today and it worked using Pin: origin "mirror.home-dn.net", don't know what happened. For the record, apt-cache policy will output all the information necessary for the Pin part instead of hunting Release files. – solarc – 2012-07-05T16:06:45.417

Congrats! Glad it's working. – lornix – 2012-07-05T16:33:15.180