SUSE Manager/zypp commands

From MicroFocusInternationalWiki
Revision as of 11:29, 12 August 2016 by Mbrookhuis (Talk | contribs) (Created page with "SUSE Manager Main Page = Usefull zypp utilities = == User story == On SLES11 SP4 (and maybe also earlier) and SLES12 SPx there are 2 useful zypp-commands t...")

(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to: navigation, search

SUSE Manager Main Page

Usefull zypp utilities

User story

On SLES11 SP4 (and maybe also earlier) and SLES12 SPx there are 2 useful zypp-commands that can help to get information from a package and in which channels it is available. Also there is another utility that shows which process are using deleted files.

zypp-NameReqPrv

DESCRIPTION

Investigate packages and dependencies in solver test-cases

Load all enabled repositories (without refresh) and search for occurrences of regular expression NAME in package names or dependencies. In case DIR denotes a directory containing a solver test-case, repositories and settings provided by the test-case are loaded instead. A solver test-case is an abstract of repositories, packages, hardware and dependency resolution related settings which can be created by using zyppers --debug-solver option. Attached to a bug report the test-case helps investigating the reported behavior. Options and output of this command are tailored to this use-case and may change as needed. Reported matches show the packages internal id, name, version and architecture, priority and name of the providing repository, vendor, buildtime and the locations matching NAME.

examples:

# zypp-NameReqPrv -D vim
*** Load system at '/'
*** load target '@System'
sat::repo(@System){prio -99.0, size 1213}
*** load repo 'SLES12-SP1-12.1-0'       sat::repo(SLES12-SP1-12.1-0){prio -99.1, size 5214}
*** load repo 'SLES12-SP1-Pool' sat::repo(SUSE_Linux_Enterprise_Server_12_SP1_x86_64:SLES12-SP1-Pool){prio -99.2, size 3509}
*** load repo 'SLES12-SP1-Updates'      sat::repo(SUSE_Linux_Enterprise_Server_12_SP1_x86_64:SLES12-SP1-Updates){prio -99.2, size 2380}
*** load repo 'SUSE-Manager-Server-3.0-Pool'    sat::repo(SUSE_Manager_Server_3.0_x86_64:SUSE-Manager-Server-3.0-Pool){prio -99.2, size 216}
*** load repo 'SUSE-Manager-Server-3.0-Updates' sat::repo(SUSE_Manager_Server_3.0_x86_64:SUSE-Manager-Server-3.0-Updates){prio -99.2, size 84}
DUMP vim {
==============================
(1093)vim-7.4.326-2.62.x86_64(@System)
 PROVIDES (8){
  vi
  vim_client
  config(vim) == 7.4.326-2.62
  vim == 7.4.326-2.62
  vim(x86-64) == 7.4.326-2.62
  vim-base == 7.4.326-2.62
  vim-enhanced == 7.4.326-2.62
  vim-python == 7.4.326-2.62
}
 PREREQUIRES (2){
  fileutils
  sh-utils
}
 REQUIRES (28){
  /bin/sh
  libc.so.6()(64bit)
  libc.so.6(GLIBC_2.2.5)(64bit)
  libc.so.6(GLIBC_2.4)(64bit)
  libc.so.6(GLIBC_2.3.4)(64bit)
  libc.so.6(GLIBC_2.14)(64bit)
  libc.so.6(GLIBC_2.3)(64bit)
  libpthread.so.0()(64bit)
  libpthread.so.0(GLIBC_2.2.5)(64bit)
  libc.so.6(GLIBC_2.7)(64bit)
  libc.so.6(GLIBC_2.15)(64bit)
  libdl.so.2()(64bit)
  libdl.so.2(GLIBC_2.2.5)(64bit)
  libm.so.6()(64bit)
  libm.so.6(GLIBC_2.2.5)(64bit)
  libc.so.6(GLIBC_2.11)(64bit)
  perl(:MODULE_COMPAT_5.18.2)
  libtinfo.so.5()(64bit)
  libacl.so.1()(64bit)
  libacl.so.1(ACL_1.0)(64bit)
  libperl.so()(64bit)
  rpmlib(CompressedFileNames) <= 3.0.4-1
  rpmlib(PayloadFilesHavePrefix) <= 4.0-1
  rpmlib(PayloadIsLzma) <= 4.4.6-1
  perl == 5.18.2
  config(vim) == 7.4.326-2.62
  fileutils
  sh-utils
}
 OBSOLETES (3){
  vim-base < 7.4.326-2.62
  vim-enhanced < 7.4.326-2.62
  vim-python < 7.4.326-2.62
}
 RECOMMENDS (1){
  vim-data == 7.4.326-2.62
}
==============================
(4479)vim-7.4.326-2.62.x86_64(SLES12-SP1-12.1-0)
 PROVIDES (8){
  vi
  vim_client
  config(vim) == 7.4.326-2.62
  vim == 7.4.326-2.62
  vim(x86-64) == 7.4.326-2.62
  vim-base == 7.4.326-2.62
  vim-enhanced == 7.4.326-2.62
  vim-python == 7.4.326-2.62
}
 PREREQUIRES (2){
  fileutils
  sh-utils
}
 REQUIRES (28){
  libc.so.6()(64bit)
  libc.so.6(GLIBC_2.2.5)(64bit)
  libc.so.6(GLIBC_2.4)(64bit)
  libc.so.6(GLIBC_2.3.4)(64bit)
  libc.so.6(GLIBC_2.14)(64bit)
  /bin/sh
  libc.so.6(GLIBC_2.3)(64bit)
  libpthread.so.0()(64bit)
  libpthread.so.0(GLIBC_2.2.5)(64bit)
  libc.so.6(GLIBC_2.7)(64bit)
  libm.so.6()(64bit)
  libm.so.6(GLIBC_2.2.5)(64bit)
  libc.so.6(GLIBC_2.15)(64bit)
  libdl.so.2()(64bit)
  libdl.so.2(GLIBC_2.2.5)(64bit)
  libc.so.6(GLIBC_2.11)(64bit)
  perl(:MODULE_COMPAT_5.18.2)
  libtinfo.so.5()(64bit)
  libacl.so.1()(64bit)
  libacl.so.1(ACL_1.0)(64bit)
  libperl.so()(64bit)
  rpmlib(CompressedFileNames) <= 3.0.4-1
  rpmlib(PayloadFilesHavePrefix) <= 4.0-1
  rpmlib(PayloadIsLzma) <= 4.4.6-1
  perl == 5.18.2
  config(vim) == 7.4.326-2.62
  fileutils
  sh-utils
}
 OBSOLETES (3){
  vim-base < 7.4.326-2.62
  vim-enhanced < 7.4.326-2.62
  vim-python < 7.4.326-2.62
}
 RECOMMENDS (1){
  vim-data == 7.4.326-2.62
}
==============================
(9693)vim-7.4.326-2.62.x86_64(SUSE_Linux_Enterprise_Server_12_SP1_x86_64:SLES12-SP1-Pool)
 PROVIDES (8){
  vi
  vim_client
  config(vim) == 7.4.326-2.62
  vim == 7.4.326-2.62
  vim(x86-64) == 7.4.326-2.62
  vim-base == 7.4.326-2.62
  vim-enhanced == 7.4.326-2.62
  vim-python == 7.4.326-2.62
}
 PREREQUIRES (2){
  fileutils
  sh-utils
}
 REQUIRES (16){
  /bin/sh
  libpthread.so.0()(64bit)
  libpthread.so.0(GLIBC_2.2.5)(64bit)
  libm.so.6()(64bit)
  libm.so.6(GLIBC_2.2.5)(64bit)
  libc.so.6(GLIBC_2.15)(64bit)
  libdl.so.2()(64bit)
  libdl.so.2(GLIBC_2.2.5)(64bit)
  perl(:MODULE_COMPAT_5.18.2)
  libtinfo.so.5()(64bit)
  libacl.so.1()(64bit)
  libacl.so.1(ACL_1.0)(64bit)
  libperl.so()(64bit)
  perl == 5.18.2
  fileutils
  sh-utils
}
 OBSOLETES (3){
  vim-base < 7.4.326-2.62
  vim-enhanced < 7.4.326-2.62
  vim-python < 7.4.326-2.62
}
 RECOMMENDS (1){
  vim-data == 7.4.326-2.62
}
} <pre/>

<pre> zypp-NameReqPrv '^vim$'
*** Load system at '/'
*** load target '@System'
sat::repo(@System){prio -99.0, size 1213}
*** load repo 'SLES12-SP1-12.1-0'       sat::repo(SLES12-SP1-12.1-0){prio -99.1, size 5214}
*** load repo 'SLES12-SP1-Pool' sat::repo(SUSE_Linux_Enterprise_Server_12_SP1_x86_64:SLES12-SP1-Pool){prio -99.2, size 3509}
*** load repo 'SLES12-SP1-Updates'      sat::repo(SUSE_Linux_Enterprise_Server_12_SP1_x86_64:SLES12-SP1-Updates){prio -99.2, size 2380}
*** load repo 'SUSE-Manager-Server-3.0-Pool'    sat::repo(SUSE_Manager_Server_3.0_x86_64:SUSE-Manager-Server-3.0-Pool){prio -99.2, size 216}
*** load repo 'SUSE-Manager-Server-3.0-Updates' sat::repo(SUSE_Manager_Server_3.0_x86_64:SUSE-Manager-Server-3.0-Updates){prio -99.2, size 84}
^vim$ [in_______] {
   1093  vim-7.4.326-2.62.x86_64  (99)@System  1412783076
                                  SUSE LLC <https://www.suse.com/>
                                  nam: vim
   4479  vim-7.4.326-2.62.x86_64  (99)SLES12-SP1-12.1-0             1412783076
                                  SUSE LLC <https://www.suse.com/>
                                  nam: vim
   6116  vim-7.4.326-2.62.src     (99)SLES12-SP1-12.1-0             1412783076
                                  SUSE
                                  nam: vim
   9693  vim-7.4.326-2.62.x86_64  (99)SLES12-SP1-Pool               1412783076
                                  SUSE LLC <https://www.suse.com/>
                                  nam: vim
} <pre/>































== Cause ==

We disable locale selection to only allow english. The language selection also affects the locale.

== Possible solutions ==

Allow locale selection, only ship english translations, should still force english language.

== Other technical details ==

if you want to get dd/mm/yyyy there you could select english/UK
> with this trick:
 
    echo "update rhnuserinfo u set preferred_locale='en_GB' where u.user_id in (select c.id from web_contact c where c.login='admin')" | spacewalk-sql --select-mode-direct -

(mind the "en_GB" and "admin" and replace them with the right user/locale)