Page 4 of 4 FirstFirst ... 234
Results 31 to 38 of 38

Thread: List all installed packages?

  1. #31
    Join Date
    Feb 2009
    Location
    Spain
    Posts
    25,547

    Default Re: List all installed packages?

    On 2014-02-28 12:12, Dave Howorth wrote:
    > Ken Schneider wrote:
    >> Since the only user that can install *any* package
    >> is /*root*/ you will never find out who physically sat at the keyboard
    >> and installed a package explicitly unless you are the only user with
    >> access to the physical machine.

    >
    > Creating such a log is what sudo is for, when correctly configured.


    The history file will just list "root", I think. You'll have to
    correlate with the sudo logs.

    It would have to be tested, to see who is logged on the history file
    when using sudo.

    --
    Cheers / Saludos,

    Carlos E. R.
    (from 13.1 x86_64 "Bottle" at Telcontar)

  2. #32

    Default Re: List all installed packages?

    Carlos E. R. wrote:
    > The history file will just list "root", I think. You'll have to
    > correlate with the sudo logs.


    Exactly.

  3. #33
    Join Date
    Mar 2010
    Location
    Dublin, Ireland
    Posts
    19

    Default Re: List all installed packages?

    Quote Originally Posted by wolfi323 View Post
    [...]
    Code:
    2014-02-27 17:56:18|install|kernel-default-devel|3.11.10-7.1|x86_64||repo-update|d329f54734413a14581659752e93dc55f34f6545fed5d459d2acf6f99239ae52|
    2014-02-27 17:56:24|install|kernel-xen-devel|3.11.10-7.1|x86_64||repo-update|073cdfa67e7d2e31982e48b20f4c8573c92486e5a07da059089632631556fa97|
    2014-02-27 17:56:25|install|kernel-syms|3.11.10-7.1|x86_64|root@amiga|repo-update|fc636271cfc13eaf80e8634c63b7166d487f3bd1de67ad247ccc5bfeac5b1962|
    [...] https://bugzilla.novell.com/show_bug.cgi?id=679213
    Thanks. From this I derived the following solution:
    Code:
    grep '|root@'`hostname` /var/log/zypp/history | grep '|install|' | sort -r

  4. #34
    Join Date
    Mar 2010
    Location
    Dublin, Ireland
    Posts
    19

    Default Re: List all installed packages?

    Quote Originally Posted by jowagner View Post
    Code:
    grep '|root@'`hostname` /var/log/zypp/history | grep '|install|' | sort -r
    It seems that this does not list patterns actively selected. For example, I installed the Haskell pattern through yast today but it is not in the list.

    Code:
    grep '|patterns' /var/log/zypp/history
    shows installed patterns but also includes many patterns I did not select myself (presumably, these are dependencies).

    Hope this is useful to others.

  5. #35
    Join Date
    Jun 2008
    Location
    Podunk
    Posts
    26,525
    Blog Entries
    15

    Default Re: List all installed packages?

    Quote Originally Posted by jowagner View Post
    It seems that this does not list patterns actively selected. For example, I installed the Haskell pattern through yast today but it is not in the list.

    Code:
    grep '|patterns' /var/log/zypp/history
    shows installed patterns but also includes many patterns I did not select myself (presumably, these are dependencies).

    Hope this is useful to others.
    Hi
    Use zypper?
    Code:
    zypper se -i
    zypper se -i -t pattern
    zypper se -i|grep patterns
    If you want version numbers and repos, there are extra options that can be used....
    Cheers Malcolm °¿° SUSE Knowledge Partner (Linux Counter #276890)
    SUSE SLE, openSUSE Leap/Tumbleweed (x86_64) | GNOME DE
    If you find this post helpful and are logged into the web interface,
    please show your appreciation and click on the star below... Thanks!

  6. #36
    Join Date
    Nov 2014
    Location
    Kiev, Ukraine
    Posts
    68

    Default Re: List all installed packages?

    Quote Originally Posted by kalantir View Post
    I have a feeling that I'm not really being understood regarding what I'm trying to do with Zypper, so I'm going to try one last time to explain (with greater detail this time).

    When I use pacman on Arch Linux to install software, packages can be flagged in one of two ways. "Explicitly Installed" and "Installed as Dependency". Literally every single installed package is flagged in one of those two ways. An explicitly installed application can still be a dependency for another application, but at the time it was installed, it was not as a dependency (explicitly installed by the user).

    http://pastebin.com/bBTnkcvE
    I've created this pastebin to illustrate what I'm trying to do. This is what the output looks for me when I enter "pacman -Qetq" (Q=Query, e=explicitly installed, t=not required, q=only show package names) on my Arch Linux machine.

    What if
    Code:
    sudo zypper se --installed-only | awk -F\| ' {print $2} '
    ?

    It returns the same structure of software list, compared to your list on pastebin. Is that you wish to achieve?

  7. #37
    Join Date
    Feb 2010
    Location
    Germany
    Posts
    2,478

    Default Re: List all installed packages?

    I suspect that the issue is that " > zypper search --installed-only --details --sort-by-repo" only supplies a complete and sorted list that's fairly useful but, it doesn't indicate which packages have been installed for dependency reasons.

    Flipping through "rpm" I haven't found anything that approaches what maybe needed here even though " # rpm --verify --all" (root user) does display some things which should be reviewed for stable system behaviour.

    The only thing that occurs to me, is to dump the entire list of installed package names and then, package for package, with a script, inspect the "rpm --query --triggeredby <Package Name>" output.

  8. #38
    Join Date
    Feb 2010
    Location
    Germany
    Posts
    2,478

    Default Re: List all installed packages?

    This bash "one-liner" may help:
    Code:
     > zypper search --installed-only --type package --sort-by-repo | cut --delimiter\=' ' --fields\=3 | while read line ; do echo "Package: $line"; rpm --query --triggeredby $line; echo ""; done | less
    Or redirect to a file or, whatever . . .
    The "one-liner" produces output like this (need to search an awful lot!!):
    Code:
    Package: SuSEfirewall2
    no package triggers SuSEfirewall2
    
    Package: a2ps
    no package triggers a2ps
    
    Package: aaa_base
    aaa_base-13.2+git20140911.61c1681-3.1.x86_64
    
    Package: aaa_base-extras
    no package triggers aaa_base-extras
    
    Package: acl
    no package triggers acl
    
    Package: acpica
    no package triggers acpica
    
    Package: adjtimex
    no package triggers adjtimex
    
    Package: adwaita-icon-theme
    no package triggers adwaita-icon-theme
    Code:
    Package: samba-winbind
    no package triggers samba-winbind
    
    Package: samba-winbind-32bit
    no package triggers samba-winbind-32bit
    
    Package: sane-backends
    hplip-3.14.6-2.2.4.x86_64
    
    Package: sane-backends-autoconfig
    no package triggers sane-backends-autoconfig
    
    Package: sash
    no package triggers sash
    
    Package: sbc
    no package triggers sbc

Page 4 of 4 FirstFirst ... 234

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •