Check Linux Update Time: Quick Commands

To view the update time of the Linux system, you can use one of the following commands:

  1. Use the command ls -lct /var/log/apt/ to check the timestamp of the most recently created files in the directory /var/log/apt/. These files contain log information for system updates.
  2. Use the command ls -lt /var/log/dpkg.log* to view the timestamp of the latest created files in the /var/log/dpkg.log directory. These files contain log information about the installation, upgrade, and removal of all software packages in the system.
  3. To view the latest update time in the file /var/log/apt/history.log, use the command cat /var/log/apt/history.log | grep “Start-Date”.

Please note that these commands may require root privileges to execute.

bannerAds