How to find out when Debian or Ubuntu package installed or updated

h‮‬ttps://www.lautturi.com
How to find out when Debian or Ubuntu package installed or updated

To find out when a Debian or Ubuntu package was installed or updated, you can use the dpkg command with the --list option, followed by the name of the package you are interested in. For example, to find out when the openssh-server package was installed or updated, you can run the following command:

dpkg --list openssh-server

This will show you the package name, version, and installation status, as well as the date and time that the package was installed or updated. For example, the output might look something like this:

ii  openssh-server 1:7.9p1-10ubuntu0.1 all secure shell (SSH) server, for secure access from remote machines

In this example, the ii at the beginning of the line indicates that the package is installed and configured. The date and time of the installation or update are not shown in the output of this command, but you can use the dpkg command with the --info option to see more detailed information about the package, including the installation date and time.

To do this, you can run the following command:

dpkg --info openssh-server

This will show you a detailed list of information about the package, including the installation date and time. For example, the output might look something like this:

Package: openssh-server
Status: install ok installed
Priority: optional
Section: net
Installed-Size: 940
Maintainer: Ubuntu Developers <ubuntu-devel-discuss@lists.ubuntu.com>
Architecture: all
Source: openssh
Version: 1:7.9p1-10ubuntu0.1
Depends: libc6 (>= 2.29), libcom-err2, libcwrap2, libedit2 (>= 3.1-20080528-1), libgssapi-krb5-2 (>= 1.15), libk5crypto3 (>= 1.15), libkrb5-3 (>= 1.15), libldap-2.4-2 (>= 2.4.7), libpam0g (>= 0.99.7.1), libpcre3, libselinux1 (>= 2.3), libssl1.1 (>= 1.1.1), libsystemd0, openssh-client, zlib1g (>= 1:1.2.3.3)
Recommends: ssh-import-id, ucf
Suggests: ssh-askpass, molly-guard, keychain
Conflicts: dropbear (<< 2007.55-2)
Replaces: dropbear (<< 2007.55-2)
Provides: ssh-server
Pre-Depends: dpkg (>= 1.14.6)
Description: secure shell (SSH) server, for secure access from remote machines
 OpenSSH is a free version of the Secure Shell (SSH) protocol family of tools for remotely controlling, or transferring files between, computers. SSH is a secure protocol used as the primary means of connecting to and managing Linux servers remotely.
 .
 This package provides the OpenSSH server.
Original-Maintainer: Debian OpenSSH Maintainers <debian-ssh@lists.debian.org>
Homepage: https://www.openssh.com/
Bugs: https://bugs.launchpad.net/
Created Time:2017-10-28 21:39:03  Author:lautturi