1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86
|
/**
\page pg_zypp-solv-vendorchange Solver - Vendor protection
\author Michael Andres <ma@suse.de>
\section zypp-solv-vendorchange Vendor protection rule
Tracing a packages origin \c libzypp uses the packages \c vendor string. The \c vendor string is part of the rpm header and thus defined at the time the package was built. It stays the same, no matter which repository was used to ship the package. Using \c rpm is one way to retrieve a packages \c vendor string:
\code
$ rpm -q --qf '%{name} \tvendor: %{vendor}\n' libzypp nautilus libdvdread3
libzypp vendor: openSUSE
nautilus vendor: obs://build.opensuse.org/GNOME
libdvdread3 vendor: http://packman.links2linux.de
\endcode
Also several \c zypper commands will display a packages \c vendor:
\code
$ zypper info libzypp
Information for package libzypp:
Repository: openSUSE-11.4-Update
Name: libzypp
Version: 8.12.6-0.2.1
Arch: x86_64
Vendor: openSUSE <===
Installed: Yes
Status: up-to-date
Installed Size: 7.0 MiB
Summary: Package, Patch, Pattern, and Product Management
Description:
Package, Patch, Pattern, and Product Management
\endcode
\subsection zypp-solv-vendorchange-rule The vendor protection rule is quite simple:
\note When looking for an installed packages \e update \e candidate, we are looking for a package originated by the \e same \e vendor (not repository!) as the \e installed one.
\section zypp-solv-vendorchange-tune Vendor protection tuning
The \e brute \e force method is to turn off all vendor protection in \c /etc/zypp/zypp.conf:
\code
##
## EXPERTS ONLY: Per default the solver will not replace packages of
## different vendors, unless you explicitly ask to do so. Setting this
## option to TRUE will disable this vendor check (unless the application
## explicitly re-enables it). Packages will then be considered based on
## repository priority and version only. This may easily damage your system.
##
## CHANGING THE DEFAULT IS NOT RECOMMENDED.
##
## Valid values: boolean
## Default value: false
##
solver.allowVendorChange = true
\endcode
\subsection zypp-solv-vendorchange-equiv Groups of equivalent vendor strings
A built in example for this is the \c vendor string \c SuSE. All vendor strings starting (case insensitive) with \c "suse", are considered to be the \e same \e vendor and their packages may replace each other without asking.
You may define your own classes of equivalent \c vendor strings by creating an entry in the \c /etc/zypp/vendors.d directory. For each group of \c vendor strings create a file, name it as you like, with the following content:
\code
[main]
## A comma separated list of equivalent vendor string (prefixes!)
## Example:
## vendors = suse,opensuse
vendors = <PUT YOUR LIST HERE>
\endcode
\note A built in rule unifying \c "suse" and \c "opensuse" was disabled in libzypp-16.7.1. The above example would recreate it.
\note Within the \c "opensuse*" namespace exact matches (case insensitive) are required. The above example will allow switching between \c "suse*" and \c "opensuse" but not e.g. \c "opensuse build service".
\section zypp-solv-vendorchange-Impl Related classes
\li \ref zypp::VendorAttr (vendor string equivalence and \c vendors.d parser)
*/
|