Advertisement
Guest User

needrestart ubuntu 20.04/22.04 diff

a guest
Sep 20th, 2023
74
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Diff 34.38 KB | None | 0 0
  1. diff -u needrestart-3.4/ChangeLog needrestart-3.5/ChangeLog
  2. --- needrestart-3.4/ChangeLog   2019-02-05 22:35:46.000000000 +0100
  3. +++ needrestart-3.5/ChangeLog   2023-09-20 14:53:21.000000000 +0200
  4. @@ -1,4 +1,92 @@
  5. -needrestart (3.4) unstable; urgency=high
  6. +needrestart 3.6
  7. +
  8. +  * Features:
  9. +    - [Core] Add support for runit.
  10. +      (Debian Bug#972685 by Lorenzo Puliti <plorenzo@disroot.org>)
  11. +
  12. +  * Changes:
  13. +    - [Cont] Improve LXD container support.
  14. +      (github pull request #188 by James TD Smith @ahktenzero)
  15. +    - [Cont] Update cgroup regex for LXC 4.0.
  16. +      (github pull request #215 by James TD Smith @ahktenzero)
  17. +    - [Core] Support systemd manager restart on Ubuntu 20.04+.
  18. +      (github pull request #195 by Lars Kollstedt @LarsKollstedt)
  19. +    - [Core] Do not restart bluetooth.service by default.
  20. +      (github pull request #209 by Erik Tews @eriktews)
  21. +    - [Core] Do not restart elogind by default.
  22. +      (github issue #205 by @HumanG33k)
  23. +    - [Kernel] Replace strings(1) by GNU grep to drop binutils dependency.
  24. +      (Debian Bug#986507 by Trent W. Buck <trentbuck@gmail.com>)
  25. +
  26. +  * Fixes:
  27. +    - [Core] Fix comment for default value of `skip_mapfiles`.
  28. +      (github pull request #179 by @iasdeoupxe)
  29. +    - [Interp] Fix detection for ruby script started from relative paths.
  30. +      (github pull request #182 by Alexander Neumann @rtpt-alex)
  31. +    - [Core] Fix typos.
  32. +      (github pull request #189 by @wwuck)
  33. +      (github pull request #193 by Stefan Weil @stweil)
  34. +    - [Core] Fix verbose/verbosity confusion in needrestart.conf.
  35. +      (github pull request #197 by Jan-Philipp Litza @jplitza)
  36. +    - [Core] Ignore memfd files like used by nvidia's binary drivers.
  37. +      (github pull request #200 by Jan Visser @starquake)
  38. +    - [Core] Ignore all memfd mappings.
  39. +      (Debian Bug#972685 by Michail Bachmann <m.bachmann@cms.hu-berlin.de>)
  40. +    - [Core] Ignore Java Native Access mappings.
  41. +      (github issue #142 by @nirgal)
  42. +      (github issue #185 by Ivan Zaera @izaera)
  43. +
  44. + -- Thomas Liske <thomas@fiasko-nw.net>  
  45. +
  46. +needrestart 3.5
  47. +
  48. +  * Features:
  49. +    - [uCode] Check for pending AMD microcode updates (experimental).
  50. +      (Debian Bug#886611 by Paul Wise <pabs@debian.org>)
  51. +      (github issue #150 by Tom Reynolds @tomreyn and Mark Wagie @yochananmarqos)
  52. +
  53. +  * Changes:
  54. +    - [Core] Add network.service to blacklist.
  55. +      (github pull request #145 by Marc Dequènes (Duck) @duck-rh)
  56. +    - [uCode] Check microcode revision of each individual CPUs.
  57. +    - [Kernel] Support kernel image filename filtering required for Raspbian.
  58. +      (github issue #146 by @takichikawa)
  59. +      (github issue #155 by Fenhl @fenhl and Christian @git-developer)
  60. +    - [uCode] Support local override for iucode_tool call.
  61. +      (github issue #148 by @mphilipps and Marc Dequènes (Duck) @duck-rh)
  62. +    - [notify] Add app name to notify-send call.
  63. +      (github issue #76 by @Vladimir-csp)
  64. +
  65. +  * Fixes:
  66. +    - [Core] Do not restart networking.service.
  67. +      (Debian Bug#922725 by Timo Sigurdsson <public_timo.s@silentcreek.de>).
  68. +    - [Core] Fix typo in man page for env variable DEBIAN_FRONT(END).
  69. +      (Debian Bug#922864 by Lee Garrett <debian@rocketjump.eu>)
  70. +      (Debian Bug#923853 by Petter Reinholdtsen <pere@hungry.com>)
  71. +    - [Interp] Restore cwd when skipping processes with unavailable cwd.
  72. +      (github issue #147 by Stavros Ntentos @stdedos)
  73. +    - [Core] Remove leading zero before testing in map_files.
  74. +      (Debian Bug#928225 by Alexander Galanin <al@galanin.nnov.ru>)
  75. +    - [Core] Fix typos in ex/needrestart.conf.
  76. +      (github pull request #163 by Simon Brand @brandsimon)
  77. +    - [UI] Don't fail when terminal has zero columns width.
  78. +      (github pull request #167 by @libnoon)
  79. +    - [Core] Ignore mapped files not found on filesystem (stat) to suppress
  80. +      chroot false positives.
  81. +      (github issue #158 by @mphilipps)
  82. +      (github issue #152 by Ivan Kurnosov @zerkms and @djl)
  83. +    - [Core] Supress warnings from Proc::ProcessTable.
  84. +      (github issue #170 by @mphilipps)
  85. +    - [CONT] Fix docker detection on CentOS 7.
  86. +      (github issue #165 by Christian Ruppert @idl0r)
  87. +    - [notify] Fix notify-send not working with dbus-user-session.
  88. +      (github issue #76 by @Vladimir-csp)
  89. +    - [Core] Ignore mapped files in temporary directories.
  90. +      (Debian Bug#925408 by Donald Pellegrino <donald.a.pellegrino@gmail.com>)
  91. +
  92. + -- Thomas Liske <thomas@fiasko-nw.net>  Sun, 22 Mar 2020 17:36:57 +0100
  93. +
  94. +needrestart 3.4
  95.  
  96.    * Features:
  97.      - [L10n] Add Czech localization.
  98. @@ -31,9 +119,9 @@
  99.      - [Core] Do not restart oneshot services from systemd-cron.
  100.        (Debian Bug#917073 by Antti Salmela <asalmela@iki.fi>)
  101.  
  102. - -- Thomas Liske <thomas@fiasko-nw.net>  
  103. + -- Thomas Liske <thomas@fiasko-nw.net>  Tue, 05 Feb 2019 22:43:12 +0100
  104.  
  105. -needrestart (3.3) unstable; urgency=high
  106. +needrestart 3.3
  107.  
  108.    * Fixes:
  109.      - [Core] Configuration file is ignored.
  110. @@ -46,7 +134,7 @@
  111.  
  112.   -- Thomas Liske <thomas@fiasko-nw.net>  Sun, 24 Jun 2018 13:32:47 +0200
  113.  
  114. -needrestart (3.2) unstable; urgency=medium
  115. +needrestart 3.2
  116.  
  117.    * Changes:
  118.      - [Kernel] Include /boot/kernel* while looking for linux
  119. @@ -74,7 +162,7 @@
  120.  
  121.   -- Thomas Liske <thomas@fiasko-nw.net>  Sat, 16 Jun 2018 17:42:51 +0200
  122.  
  123. -needrestart (3.1) unstable; urgency=high
  124. +needrestart 3.1
  125.  
  126.    * Changes:
  127.      - [uCode] Handle microcode upgrades in early boot initrd images,
  128. @@ -91,7 +179,7 @@
  129.  
  130.   -- Thomas Liske <thomas@fiasko-nw.net>  Thu, 29 Mar 2018 23:22:55 +0200
  131.  
  132. -needrestart (3.0) unstable; urgency=medium
  133. +needrestart 3.0
  134.  
  135.    * Features:
  136.      - [Core] Possible to suspend needrestart in apt-get hook using
  137. @@ -180,7 +268,7 @@
  138.  
  139.   -- Thomas Liske <thomas@fiasko-nw.net>  Fri, 23 Feb 2018 13:38:46 +0100
  140.  
  141. -needrestart (2.11) unstable; urgency=medium
  142. +needrestart 2.11
  143.  
  144.    * Features:
  145.      - [Core] Allow special treatment to restart services (i.e. dbus).
  146. @@ -208,7 +296,7 @@
  147.  
  148.   -- Thomas Liske <thomas@fiasko-nw.net>  Tue, 17 Jan 2017 15:59:36 +0100
  149.  
  150. -needrestart (2.10) unstable; urgency=medium
  151. +needrestart 2.10
  152.  
  153.    * Features:
  154.      - [Interp] Allow ignoring of interpreted files.
  155. @@ -232,7 +320,7 @@
  156.  
  157.   -- Thomas Liske <thomas@fiasko-nw.net>  Thu, 03 Nov 2016 23:37:05 +0100
  158.  
  159. -needrestart (2.9) unstable; urgency=medium
  160. +needrestart 2.9
  161.  
  162.    * Changes:
  163.      - [l10n] Add RU translation for notify.d stuff.
  164. @@ -268,7 +356,7 @@
  165.  
  166.   -- Thomas Liske <thomas@fiasko-nw.net>  Sat, 03 Sep 2016 14:52:41 +0200
  167.  
  168. -needrestart (2.8) unstable; urgency=medium
  169. +needrestart 2.8
  170.  
  171.    * Changes:
  172.      - [Core] Restart SysV init services on systemd using systemctl.
  173. @@ -306,7 +394,7 @@
  174.  
  175.   -- Thomas Liske <thomas@fiasko-nw.net>  Mon, 16 May 2016 18:45:51 +0200
  176.  
  177. -needrestart (2.7) unstable; urgency=medium
  178. +needrestart 2.7
  179.  
  180.    * [Bug] Ignore init rc being symlinks to upstart-job.
  181.      (github issue #16 by Jonas Genannt @hggh)
  182. @@ -328,7 +416,7 @@
  183.  
  184.   -- Thomas Liske <thomas@fiasko-nw.net>  Sun, 06 Mar 2016 14:46:45 +0100
  185.  
  186. -needrestart (2.6) unstable; urgency=high
  187. +needrestart 2.6
  188.  
  189.    * [Bug] Do not notify system users via email.
  190.      (Debian Bug#812399 by Marc Haber <mh+debian-packages@zugschlus.de>)
  191. @@ -341,14 +429,14 @@
  192.  
  193.   -- Thomas Liske <thomas@fiasko-nw.net>  Wed, 17 Feb 2016 22:14:32 +0100
  194.  
  195. -needrestart (2.5) unstable; urgency=medium
  196. +needrestart 2.5
  197.  
  198.    * [Bug] Fix broken kernel detection due to syntax error.
  199.      (Debian Bug#810031 by Martin Steigerwald <martin@lichtvoll.de>)
  200.  
  201.   -- Thomas Liske <thomas@fiasko-nw.net>  Tue, 05 Jan 2016 23:17:53 +0100
  202.  
  203. -needrestart (2.4) unstable; urgency=medium
  204. +needrestart 2.4
  205.  
  206.    * [Bug] Drop unused dependency on File::Slurp.
  207.      (Debian Bug#799733 by Christoph Anton Mitterer <calestyo@scientia.net>)
  208. @@ -365,7 +453,7 @@
  209.  
  210.   -- Thomas Liske <thomas@fiasko-nw.net>  Fri, 01 Jan 2016 21:54:47 +0100
  211.  
  212. -needrestart (2.3) unstable; urgency=medium
  213. +needrestart 2.3
  214.  
  215.    * [Bug] Add lightdm to override.
  216.      (Debian Bug#791649 by Martin Steigerwald <martin@lichtvoll.de>)
  217. @@ -386,7 +474,7 @@
  218.  
  219.   -- Thomas Liske <thomas@fiasko-nw.net>  Sat, 19 Sep 2015 20:38:19 +0200
  220.  
  221. -needrestart (2.2) unstable; urgency=medium
  222. +needrestart 2.2
  223.  
  224.    * [regression] Processes using chroot were always detected as obsolete
  225.      since missing binaries in /proc/PID/root/.
  226. @@ -394,7 +482,7 @@
  227.  
  228.   -- Thomas Liske <thomas@fiasko-nw.net>  Tue, 26 May 2015 23:56:11 +0200
  229.  
  230. -needrestart (2.1) unstable; urgency=medium
  231. +needrestart 2.1
  232.  
  233.    * [Bug] Ignore /usr/bin/apt-get.
  234.      (Debian Bug#784237 by Thijs Kinkhorst <thijs@debian.org>)
  235. @@ -428,7 +516,7 @@
  236.  
  237.   -- Thomas Liske <thomas@fiasko-nw.net>  Fri, 22 May 2015 01:45:17 +0200
  238.  
  239. -needrestart (2.0) unstable; urgency=medium
  240. +needrestart 2.0
  241.  
  242.    * [regression] List commands in list mode.
  243.      (Debian Bug#764042 by Paul Wise <pabs@debian.org>)
  244. @@ -454,7 +542,7 @@
  245.  
  246.   -- Thomas Liske <thomas@fiasko-nw.net>  Fri, 23 Jan 2015 00:46:13 +0100
  247.  
  248. -needrestart (1.2) unstable; urgency=medium
  249. +needrestart 1.2
  250.  
  251.    * Prepare po-debconf usage and add German translation.
  252.      (Debian Bug#761068 by David Prévot <taffit@debian.org>)
  253. @@ -474,7 +562,7 @@
  254.  
  255.   -- Thomas Liske <thomas@fiasko-nw.net>  Sun, 28 Sep 2014 23:48:42 +0200
  256.  
  257. -needrestart (1.1) unstable; urgency=medium
  258. +needrestart 1.1
  259.  
  260.    * Ignore DHCP clients.
  261.      (Debian Bug#752111 by Axel Beckert <abe@debian.org>)
  262. @@ -483,7 +571,7 @@
  263.  
  264.   -- Thomas Liske <thomas@fiasko-nw.net>  Sat, 16 Aug 2014 09:57:29 +0200
  265.  
  266. -needrestart (1.0) unstable; urgency=medium
  267. +needrestart 1.0
  268.  
  269.    * Fix grammar errors and use a additional debconf template.
  270.      (Debian Bug#748652 by Justin B Rye <justin.byam.rye@gmail.com>)
  271. @@ -506,7 +594,7 @@
  272.  
  273.   -- Thomas Liske <thomas@fiasko-nw.net>  Tue, 17 Jun 2014 15:21:15 +0200
  274.  
  275. -needrestart (0.9) unstable; urgency=medium
  276. +needrestart 0.9
  277.  
  278.    * Drop external dependency on strings command from binutils.
  279.    * Fix "uninitialized value" by apparent kernel threads.
  280. @@ -525,7 +613,7 @@
  281.  
  282.   -- Thomas Liske <thomas@fiasko-nw.net>  Sun, 11 May 2014 22:48:42 +0200
  283.  
  284. -needrestart (0.8) unstable; urgency=low
  285. +needrestart 0.8
  286.  
  287.    * Fix non-numeric argument on progress_prep call.
  288.      (Debian Bug#744961 by Cristian Ionescu-Idbohrn
  289. @@ -543,7 +631,7 @@
  290.  
  291.   -- Thomas Liske <thomas@fiasko-nw.net>  Sun, 27 Apr 2014 10:15:35 +0200
  292.  
  293. -needrestart (0.7) unstable; urgency=medium
  294. +needrestart 0.7
  295.  
  296.    * Improved rc script detection, e.g.: previous releases failed to
  297.      detect apache2's init script after upgrading libssl1.0.0.
  298. @@ -568,7 +656,7 @@
  299.  
  300.   -- Thomas Liske <thomas@fiasko-nw.net>  Mon, 14 Apr 2014 21:50:15 +0200
  301.  
  302. -needrestart (0.6) unstable; urgency=low
  303. +needrestart 0.6
  304.  
  305.    * Add lightdm to blacklist.
  306.      (Debian Bug#735027 by Michael Gilbert <mgilbert@debian.org>)
  307. @@ -582,7 +670,7 @@
  308.  
  309.   -- Thomas Liske <thomas@fiasko-nw.net>  Mon, 07 Apr 2014 22:52:18 +0200
  310.  
  311. -needrestart (0.5) unstable; urgency=low
  312. +needrestart 0.5
  313.  
  314.    * Ignore mapped files in /tmp.
  315.    * Handle LSB tags case insensitivly.
  316. @@ -594,7 +682,7 @@
  317.  
  318.   -- Thomas Liske <thomas@fiasko-nw.net>  Thu, 02 Jan 2014 19:55:49 +0100
  319.  
  320. -needrestart (0.4) unstable; urgency=low
  321. +needrestart 0.4
  322.  
  323.    * Fix spelling:
  324.      - typo in debconf template (s/restartet/restarted/;)
  325. @@ -615,7 +703,7 @@
  326.  
  327.   -- Thomas Liske <thomas@fiasko-nw.net>  Thu, 28 Nov 2013 19:30:06 +0100
  328.  
  329. -needrestart (0.3) unstable; urgency=low
  330. +needrestart 0.3
  331.  
  332.    * Fix typo reported by Patrick Matthäi.
  333.    * Add man page provided by Patrick Matthäi (Debian).
  334. @@ -633,7 +721,7 @@
  335.  
  336.   -- Thomas Liske <thomas@fiasko-nw.net>  Sat, 14 Sep 2013 12:55:16 +0200
  337.  
  338. -needrestart (0.2) unstable; urgency=low
  339. +needrestart 0.2
  340.  
  341.    * Support (l)ist only, (i)nteractive restart and
  342.      (a)utomaticly restart modes.
  343. @@ -645,7 +733,7 @@
  344.  
  345.   -- Thomas Liske <thomas@fiasko-nw.net>  Tue, 02 Apr 2013 21:51:48 +0200
  346.  
  347. -needrestart (0.1) unstable; urgency=low
  348. +needrestart 0.1
  349.  
  350.    * Initial release.
  351.  
  352. diff -u needrestart-3.4/COPYING needrestart-3.5/COPYING
  353. --- needrestart-3.4/COPYING 2019-02-05 22:35:46.000000000 +0100
  354. +++ needrestart-3.5/COPYING 2023-09-20 14:53:21.000000000 +0200
  355. @@ -1,12 +1,12 @@
  356. -           GNU GENERAL PUBLIC LICENSE
  357. -              Version 2, June 1991
  358. +                    GNU GENERAL PUBLIC LICENSE
  359. +                       Version 2, June 1991
  360.  
  361. - Copyright (C) 1989, 1991 Free Software Foundation, Inc.
  362. -     51 Franklin Street, Fifth Floor, Boston, MA  02110-1301  USA
  363. + Copyright (C) 1989, 1991 Free Software Foundation, Inc.,
  364. + 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
  365.   Everyone is permitted to copy and distribute verbatim copies
  366.   of this license document, but changing it is not allowed.
  367.  
  368. -               Preamble
  369. +                            Preamble
  370.  
  371.    The licenses for most software are designed to take away your
  372.  freedom to share and change it.  By contrast, the GNU General Public
  373. @@ -15,7 +15,7 @@
  374.  General Public License applies to most of the Free Software
  375.  Foundation's software and to any other program whose authors commit to
  376.  using it.  (Some other Free Software Foundation software is covered by
  377. -the GNU Library General Public License instead.)  You can apply it to
  378. +the GNU Lesser General Public License instead.)  You can apply it to
  379.  your programs, too.
  380.  
  381.    When we speak of free software, we are referring to freedom, not
  382. @@ -55,8 +55,8 @@
  383.  
  384.    The precise terms and conditions for copying, distribution and
  385.  modification follow.
  386. -
  387. -           GNU GENERAL PUBLIC LICENSE
  388. +
  389. +                    GNU GENERAL PUBLIC LICENSE
  390.     TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION
  391.  
  392.    0. This License applies to any program or other work which contains
  393. @@ -110,7 +110,7 @@
  394.      License.  (Exception: if the Program itself is interactive but
  395.      does not normally print such an announcement, your work based on
  396.      the Program is not required to print an announcement.)
  397. -
  398. +
  399.  These requirements apply to the modified work as a whole.  If
  400.  identifiable sections of that work are not derived from the Program,
  401.  and can be reasonably considered independent and separate works in
  402. @@ -168,7 +168,7 @@
  403.  access to copy the source code from the same place counts as
  404.  distribution of the source code, even though third parties are not
  405.  compelled to copy the source along with the object code.
  406. -
  407. +
  408.    4. You may not copy, modify, sublicense, or distribute the Program
  409.  except as expressly provided under this License.  Any attempt
  410.  otherwise to copy, modify, sublicense or distribute the Program is
  411. @@ -225,7 +225,7 @@
  412.  
  413.  This section is intended to make thoroughly clear what is believed to
  414.  be a consequence of the rest of this License.
  415. -
  416. +
  417.    8. If the distribution and/or use of the Program is restricted in
  418.  certain countries either by patents or by copyrighted interfaces, the
  419.  original copyright holder who places the Program under this License
  420. @@ -255,7 +255,7 @@
  421.  of preserving the free status of all derivatives of our free software and
  422.  of promoting the sharing and reuse of software generally.
  423.  
  424. -               NO WARRANTY
  425. +                            NO WARRANTY
  426.  
  427.    11. BECAUSE THE PROGRAM IS LICENSED FREE OF CHARGE, THERE IS NO WARRANTY
  428.  FOR THE PROGRAM, TO THE EXTENT PERMITTED BY APPLICABLE LAW.  EXCEPT WHEN
  429. @@ -277,9 +277,9 @@
  430.  PROGRAMS), EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE
  431.  POSSIBILITY OF SUCH DAMAGES.
  432.  
  433. -            END OF TERMS AND CONDITIONS
  434. -
  435. -       How to Apply These Terms to Your New Programs
  436. +                     END OF TERMS AND CONDITIONS
  437. +
  438. +            How to Apply These Terms to Your New Programs
  439.  
  440.    If you develop a new program, and you want it to be of the greatest
  441.  possible use to the public, the best way to achieve this is to make it
  442. @@ -303,17 +303,16 @@
  443.      MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
  444.      GNU General Public License for more details.
  445.  
  446. -    You should have received a copy of the GNU General Public License
  447. -    along with this program; if not, write to the Free Software
  448. -    Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301  USA
  449. -
  450. +    You should have received a copy of the GNU General Public License along
  451. +    with this program; if not, write to the Free Software Foundation, Inc.,
  452. +    51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
  453.  
  454.  Also add information on how to contact you by electronic and paper mail.
  455.  
  456.  If the program is interactive, make it output a short notice like this
  457.  when it starts in an interactive mode:
  458.  
  459. -    Gnomovision version 69, Copyright (C) year  name of author
  460. +    Gnomovision version 69, Copyright (C) year name of author
  461.      Gnomovision comes with ABSOLUTELY NO WARRANTY; for details type `show w'.
  462.      This is free software, and you are welcome to redistribute it
  463.      under certain conditions; type `show c' for details.
  464. @@ -336,5 +335,5 @@
  465.  This General Public License does not permit incorporating your program into
  466.  proprietary programs.  If your program is a subroutine library, you may
  467.  consider it more useful to permit linking proprietary applications with the
  468. -library.  If this is what you want to do, use the GNU Library General
  469. +library.  If this is what you want to do, use the GNU Lesser General
  470.  Public License instead of this License.
  471. Common subdirectories: needrestart-3.4/debian and needrestart-3.5/debian
  472. Common subdirectories: needrestart-3.4/ex and needrestart-3.5/ex
  473. Common subdirectories: needrestart-3.4/.github and needrestart-3.5/.github
  474. Common subdirectories: needrestart-3.4/hooks and needrestart-3.5/hooks
  475. Common subdirectories: needrestart-3.4/lib and needrestart-3.5/lib
  476. diff -u needrestart-3.4/Makefile needrestart-3.5/Makefile
  477. --- needrestart-3.4/Makefile    2019-02-05 22:35:46.000000000 +0100
  478. +++ needrestart-3.5/Makefile    2023-09-20 14:53:21.000000000 +0200
  479. @@ -1,7 +1,7 @@
  480.  LOCALEDIR=/usr/share/locale
  481.  
  482.  all: mo-files
  483. -   cd perl && perl Makefile.PL PREFIX=$(PREFIX) INSTALLDIRS=vendor
  484. +   cd perl && perl Makefile.PL PREFIX=$(PREFIX) INSTALLDIRS=vendor
  485.     cd perl && $(MAKE)
  486.  
  487.  install: all
  488. @@ -11,6 +11,7 @@
  489.     cp hooks/* "$(DESTDIR)/etc/needrestart/hook.d/"
  490.     cp ex/needrestart.conf "$(DESTDIR)/etc/needrestart/"
  491.     cp ex/notify.conf "$(DESTDIR)/etc/needrestart/"
  492. +   cp ex/iucode.sh "$(DESTDIR)/etc/needrestart/"
  493.     mkdir -p "$(DESTDIR)/etc/needrestart/conf.d"
  494.     cp ex/conf.d/* "$(DESTDIR)/etc/needrestart/conf.d/"
  495.     mkdir -p "$(DESTDIR)/etc/needrestart/notify.d"
  496. Common subdirectories: needrestart-3.4/man and needrestart-3.5/man
  497. diff -u needrestart-3.4/needrestart needrestart-3.5/needrestart
  498. --- needrestart-3.4/needrestart 2023-09-20 14:56:45.563176846 +0200
  499. +++ needrestart-3.5/needrestart 2023-09-20 14:53:21.000000000 +0200
  500. @@ -8,7 +8,7 @@
  501.  #   Thomas Liske <thomas@fiasko-nw.net>
  502.  #
  503.  # Copyright Holder:
  504. -#   2013 - 2018 (C) Thomas Liske [http://fiasko-nw.net/~thomas/]
  505. +#   2013 - 2020 (C) Thomas Liske [http://fiasko-nw.net/~thomas/]
  506.  #
  507.  # License:
  508.  #   This program is free software; you can redistribute it and/or modify
  509. @@ -46,6 +46,7 @@
  510.  
  511.  my $LOGPREF = '[main]';
  512.  my $is_systemd = -d q(/run/systemd/system);
  513. +my $is_runit = -e q(/run/runit.stopit);
  514.  my $is_tty = (-t *STDERR || -t *STDOUT || -t *STDIN);
  515.  my $is_vm;
  516.  my $is_container;
  517. @@ -90,7 +91,8 @@
  518.     a   (a)utomatically restart
  519.      -b     enable batch mode
  520.      -p          enable nagios plugin mode
  521. -    -f <fe>    overwrite debconf frontend (DEBIAN_FRONTEND, debconf(7))
  522. +    -f <fe>    override debconf frontend (DEBIAN_FRONTEND, debconf(7))
  523. +    -t <seconds> tolerate interpreter process start times within this value
  524.      -u <ui>     use preferred UI package (-u ? shows available packages)
  525.  
  526.    By using the following options only the specified checks are performed:
  527. @@ -113,7 +115,7 @@
  528.    Thomas Liske <thomas\@fiasko-nw.net>
  529.  
  530.  Copyright Holder:
  531. -  2013 - 2018 (C) Thomas Liske [http://fiasko-nw.net/~thomas/]
  532. +  2013 - 2020 (C) Thomas Liske [http://fiasko-nw.net/~thomas/]
  533.  
  534.  Upstream:
  535.    https://github.com/liske/needrestart
  536. @@ -143,18 +145,20 @@
  537.      blacklist_mappings => [],
  538.      override_rc => {},
  539.      override_cont => {},
  540. -    skip_mapfiles => 0,
  541. +    skip_mapfiles => -1,
  542.      interpscan => 1,
  543.      kernelhints => 1,
  544. +    kernelfilter => qr(.),
  545.      ucodehints => 1,
  546.      q(nagios-status) => {
  547. -   services => 1,
  548. -   kernel => 2,
  549. -   ucode => 2,
  550. -   sessions => 2,
  551. -   containers => 1,
  552. +    services => 1,
  553. +    kernel => 2,
  554. +    ucode => 2,
  555. +    sessions => 2,
  556. +    containers => 1,
  557.      },
  558.      has_pam_systemd => 1,
  559. +    tolerance => 2,
  560.  );
  561.  
  562.  # backup ARGV (required for Debconf)
  563. @@ -171,9 +175,10 @@
  564.  our $opt_l;
  565.  our $opt_p;
  566.  our $opt_q;
  567. +our $opt_t;
  568.  our $opt_u;
  569.  our $opt_w;
  570. -unless(getopts('c:vr:nm:bf:klpqu:w')) {
  571. +unless(getopts('c:vr:nm:bf:klpqt:u:w')) {
  572.      HELP_MESSAGE;
  573.      exit 1;
  574.  }
  575. @@ -186,7 +191,7 @@
  576.  
  577.  die "ERROR: Could not read config file '$opt_c'!\n" unless(-r $opt_c || $opt_b);
  578.  
  579. -# overwrite debconf frontend
  580. +# override debconf frontend
  581.  $ENV{DEBIAN_FRONTEND} = $opt_f if($opt_f);
  582.  
  583.  # be quiet
  584. @@ -218,10 +223,13 @@
  585.  die "ERROR: Unknown restart option '$opt_r'!\n" unless($opt_r =~ /^(l|i|a)$/);
  586.  $is_tty = 0 if($opt_r eq 'i' && exists($ENV{DEBIAN_FRONTEND}) && $ENV{DEBIAN_FRONTEND} eq 'noninteractive');
  587.  $opt_r = 'l' if(!$is_tty && $opt_r eq 'i');
  588. +# always run in batch mode if we run noninteractive
  589. +$opt_b++ if(exists($ENV{DEBIAN_FRONTEND}) && $ENV{DEBIAN_FRONTEND} eq 'noninteractive');
  590.  
  591.  $opt_m = $nrconf{ui_mode} unless(defined($opt_m));
  592.  die "ERROR: Unknown UI mode '$opt_m'!\n" unless($opt_m =~ /^(e|a)$/);
  593.  $opt_r = 'l' if($opt_m eq 'e');
  594. +$opt_t = $nrconf{tolerance} unless(defined($opt_t));
  595.  
  596.  $nrconf{defno}++ if($opt_n);
  597.  $opt_b++ if($opt_p);
  598. @@ -385,6 +393,14 @@
  599.         (qw(systemctl restart), qq($rc.service));
  600.         }
  601.     }
  602. +   elsif($is_runit && -d qq(/etc/sv/$rc)) {
  603. +       if(-e qq(/etc/service/$rc)) {
  604. +       (qw(sv restart), $rc);
  605. +       }
  606. +       else {
  607. +       (q(service), $rc, q(restart));
  608. +       }
  609. +   }
  610.     else {
  611.         (q(invoke-rc.d), $rc, q(restart));
  612.     }
  613. @@ -427,6 +443,7 @@
  614.  
  615.  my %restart;
  616.  my %sessions;
  617. +my @guests;
  618.  my @easy_hints;
  619.  
  620.  if(defined($opt_l)) {
  621. @@ -439,20 +456,20 @@
  622.      sub findppid($@) {
  623.     my $uid = shift;
  624.     my ($pid, @pids) = @_;
  625. -  
  626. +
  627.     if($ptable->{$pid}->{ppid} == 1) {
  628.         return $pid
  629.         if($ptable->{$pid}->{uid} == $uid);
  630. -      
  631. +
  632.         return undef;
  633.     }
  634. -  
  635. +
  636.     foreach my $pid (@pids) {
  637.         my $ppid = &findppid($uid, $pid);
  638. -      
  639. +
  640.         return $ppid if($ppid);
  641.     }
  642. -  
  643. +
  644.     return $pid;
  645.      }
  646.  
  647. @@ -509,9 +526,7 @@
  648.             my @paths = ("/proc/$pid/map_files/$maddr", "/proc/$pid/root/$path");
  649.             my ($testp) = grep { -e $_; } @paths;
  650.             unless($testp) {
  651. -               unless($path =~ m@^(/var)?/tmp/@ ||
  652. -                  $path =~ m@^(/var)?/run/@ ||
  653. -                  $nrconf{skip_mapfiles} == -1) {
  654. +               unless($nrconf{skip_mapfiles} == -1) {
  655.                 print STDERR "$LOGPREF #$pid uses non-existing $path\n" if($nrconf{verbosity} > 1);
  656.                 $restart++;
  657.                 last;
  658. @@ -556,11 +571,11 @@
  659.     }
  660.  
  661.     unless($restart || !$nrconf{interpscan}) {
  662. -       $restart++ if(needrestart_interp_check($nrconf{verbosity} > 1, $pid, $exe, $nrconf{blacklist_interp}));
  663. +       $restart++ if(needrestart_interp_check($nrconf{verbosity} > 1, $pid, $exe, $nrconf{blacklist_interp}, $opt_t));
  664.     }
  665.  
  666.     # handle containers (LXC, docker, etc.)
  667. -   next if($restart && needrestart_cont_check($nrconf{verbosity} > 1, $pid, $exe));
  668. +   next if($restart && needrestart_cont_check($nrconf{verbosity} > 1, $pid, $exe, $opt_t));
  669.  
  670.     # restart needed?
  671.     next unless($restart);
  672. @@ -605,7 +620,7 @@
  673.  
  674.      if(scalar keys %stage2 && !$uid) {
  675.     $ui->progress_prep(scalar keys %stage2, __ 'Scanning candidates...');
  676. -   foreach my $pid (sort {$a <=> $b} keys %stage2) {
  677. +   PIDLOOP: foreach my $pid (sort {$a <=> $b} keys %stage2) {
  678.         $ui->progress_step;
  679.  
  680.         # skip myself
  681. @@ -624,7 +639,7 @@
  682.  
  683.         if($is_systemd) {
  684.         # systemd manager
  685. -       if($pid == 1 && $exe =~ m@^/lib/systemd/systemd@) {
  686. +       if($pid == 1 && $exe =~ m@^(/usr)?/lib/systemd/systemd@) {
  687.             print STDERR "$LOGPREF #$pid is systemd manager\n" if($nrconf{verbosity} > 1);
  688.             $restart{q(systemd-manager)}++;
  689.             next;
  690. @@ -649,6 +664,25 @@
  691.                 push(@{ $sessions{$1}->{'user manager service'}->{ $ptable->{$pid}->{fname} } }, $pid);
  692.                 next;
  693.                 }
  694. +               if($value =~ m@/machine.slice/machine.qemu(.*).scope@) {
  695. +               for my $cmdlineidx (0 .. $#{$ptable->{$pid}->{cmdline}} ) {
  696. +                   if ( ${$ptable->{$pid}->{cmdline}}[$cmdlineidx] eq "-name") {
  697. +                       foreach ( split(/,/, ${$ptable->{$pid}->{cmdline}}[$cmdlineidx+1]) ) {
  698. +                           if ( index($_, "guest=") == 0 ) {
  699. +                               my @namearg = split(/=/, $_, 2);
  700. +                               if ($#{namearg} == 1) {
  701. +                                   print STDERR "$LOGPREF #$pid detected as VM guest '$namearg[1]' in group '$value'\n" if($nrconf{verbosity} > 1);
  702. +                                   push(@guests, __x("'{name}' with pid {pid}", name => $namearg[1], pid=>$pid) );
  703. +                               }
  704. +                               next PIDLOOP;
  705. +                           }
  706. +                       }
  707. +                   }
  708. +               }
  709. +               print STDERR "$LOGPREF #$pid detected as VM guest with unknown name in group '$value'\n" if($nrconf{verbosity} > 1);
  710. +               push(@guests, __x("'Unkown VM' with pid {pid}", pid=>$pid) );
  711. +               next;
  712. +               }
  713.                 elsif($value =~ m@/([^/]+\.service)$@) {
  714.                 ($1);
  715.                 }
  716. @@ -718,7 +752,7 @@
  717.                 print STDERR "$LOGPREF no LSB headers found at $v[1]\n" if($nrconf{verbosity} > 1);
  718.                 push(@nopids, $v[1]);
  719.             }
  720. -           # In the run-levels S and 1 no daemons are being started (normaly).
  721. +           # In the run-levels S and 1 no daemons are being started (normally).
  722.             # We don't call any rc.d script not started in the current run-level.
  723.             elsif($lsb{'default-start'} =~ /$runlevel/) {
  724.                 # If a pidfile has been found, try to look for the daemon and ignore
  725. @@ -749,10 +783,11 @@
  726.         }
  727.  
  728.         # No perfect hit - call any rc scripts instead.
  729. +       print STDERR "$LOGPREF #$pid running $hook no perfect hit found $found pids $#nopids\n" if($nrconf{verbosity} > 1);
  730.         if(!$found && $#nopids > -1) {
  731.             foreach my $rc (@nopids) {
  732.             if($is_systemd && exists($restart{"$rc.service"})) {
  733. -               print STDERR "$LOGPREF #$pid rc.d script $rc seems to be superseeded by $rc.service\n" if($nrconf{verbosity} > 1);
  734. +               print STDERR "$LOGPREF #$pid rc.d script $rc seems to be superseded by $rc.service\n" if($nrconf{verbosity} > 1);
  735.             }
  736.             else {
  737.                 $restart{$rc}++;
  738. @@ -810,7 +845,7 @@
  739.  }
  740.  
  741.  if(defined($opt_k)) {
  742. -    my ($kresult, %kvars) = ($nrconf{kernelhints} || $opt_b ? nr_kernel_check($nrconf{verbosity} > 1, $ui) : ());
  743. +    my ($kresult, %kvars) = ($nrconf{kernelhints} || $opt_b ? nr_kernel_check($nrconf{verbosity} > 1, $nrconf{kernelfilter}, $ui) : ());
  744.  
  745.      if(defined($kresult)) {
  746.     if($opt_b) {
  747. @@ -970,7 +1005,7 @@
  748.                  $nagios{sstr} .= " (!!)";
  749.              }
  750.          }
  751. -      
  752. +
  753.         foreach my $rc (sort { lc($a) cmp lc($b) } keys %restart) {
  754.         # always combine restarts in one systemctl command
  755.         local $nrconf{systemctl_combine} = 1 unless($opt_r eq 'l');
  756. @@ -1253,6 +1288,25 @@
  757.         }
  758.     }
  759.      }
  760. +
  761. +   ## GUESTS
  762. +   $ui->vspace();
  763. +   if (! @guests) {
  764. +       $ui->notice(__ 'No VM guests are running outdated hypervisor (qemu) binaries on this host.') unless($opt_b || $opt_m eq 'e');
  765. +   }
  766. +   else {
  767. +       if($opt_m eq 'e') {
  768. +           push(@easy_hints, __ 'outdated VM guests');
  769. +       }
  770. +       else {
  771. +           unless($opt_p || $opt_b) {
  772. +               $ui->notice(__ 'VM guests are running outdated hypervisor (qemu) binaries on this host:');
  773. +               foreach ( @guests ) {
  774. +               $ui->notice(" $_");
  775. +               }
  776. +           }
  777. +       }
  778. +   }
  779.  }
  780.  
  781.  # easy mode: print hint on outdated stuff
  782. @@ -1262,6 +1316,27 @@
  783.      $ui->announce_ehint(EHINT => ($h ? join(' ', $h, __ 'and', '') : '') . $t);
  784.  }
  785.  
  786. +my @sessions_list;
  787. +if(scalar %sessions) {
  788. +    # build a sorted list of user @ session strings
  789. +    #
  790. +    # used in the nagios and batch outputs below
  791. +    @sessions_list = map {
  792. +        my $uid = $_;
  793. +        my $user = uid2name($uid);
  794. +        my @ret;
  795. +
  796. +        foreach my $sess (sort keys %{ $sessions{$uid} }) {
  797. +            push(@ret, "$user \@ $sess");
  798. +        }
  799. +
  800. +        @ret;
  801. +    }
  802. +    sort {
  803. +        ncmp(uid2name($a), uid2name($b));
  804. +    } keys %sessions
  805. +}
  806. +
  807.  # nagios plugin output
  808.  if($opt_p) {
  809.      my %states = (
  810. @@ -1270,7 +1345,7 @@
  811.     2 => q(CRIT),
  812.     3 => q(UNKN),
  813.     );
  814. -    my ($ret) = reverse sort
  815. +    my ($ret) = reverse sort
  816.     (($opt_k ? $nagios{kret} : ()), ($opt_w ? $nagios{mret} : ()),
  817.     ($opt_l ? ($nagios{sret}, $nagios{cret}, $nagios{uret}) : ()));
  818.  
  819. @@ -1281,11 +1356,11 @@
  820.            ($opt_l ? "Containers: $nagios{cstr}" : ()),
  821.            ($opt_l ? "Sessions: $nagios{ustr}" : ()),
  822.     ), '|', join(' ',
  823. -          ($opt_k ? "Kernel=$nagios{kperf};0;;0;2" : ()),
  824. -          ($opt_w ? "Microcode=$nagios{mperf};0;;0;1" : ()),
  825. -          ($opt_l ? "Services=$nagios{sperf};;0;0" : ()),
  826. -          ($opt_l ? "Containers=$nagios{cperf};;0;0" : ()),
  827. -          ($opt_l ? "Sessions=$nagios{uperf};0;;0" : ()),
  828. +          ( ($opt_k && $nagios{kret} != 3) ? "Kernel=$nagios{kperf};0;;0;2" : ()),
  829. +          ( ($opt_w && $nagios{mret} != 3) ? "Microcode=$nagios{mperf};0;;0;1" : ()),
  830. +          ( ($opt_l && $nagios{sret} != 3) ? "Services=$nagios{sperf};;0;0" : ()),
  831. +          ( ($opt_l && $nagios{cret} != 3) ? "Containers=$nagios{cperf};;0;0" : ()),
  832. +          ( ($opt_l && $nagios{uret} != 3) ? "Sessions=$nagios{uperf};0;;0" : ()),
  833.     ), "\n";
  834.  
  835.      if(scalar %restart) {
  836. @@ -1298,22 +1373,14 @@
  837.      }
  838.  
  839.      if(scalar %sessions) {
  840. -   print "Sessions:", join("\n- ", '',
  841. -               map {
  842. -                   my $uid = $_;
  843. -                   my $user = uid2name($uid);
  844. -                   my @ret;
  845. -
  846. -                   foreach my $sess (sort keys %{ $sessions{$uid} }) {
  847. -                   push(@ret, "$user \@ $sess");
  848. -                   }
  849. -
  850. -                   @ret;
  851. -               }
  852. -               sort {
  853. -                   ncmp(uid2name($a), uid2name($b));
  854. -               } keys %sessions), "\n";
  855. +   print "Sessions:", join("\n- ", '', @sessions_list), "\n";
  856.      }
  857.  
  858.      exit $ret;
  859.  }
  860. +
  861. +if ($opt_b and scalar %sessions) {
  862. +    for my $sess (@sessions_list) {
  863. +       print "NEEDRESTART-SESS: $sess\n";
  864. +    }
  865. +}
  866. Binary files needrestart-3.4/.needrestart.swp and needrestart-3.5/.needrestart.swp differ
  867. diff -u needrestart-3.4/NEWS needrestart-3.5/NEWS
  868. --- needrestart-3.4/NEWS    2019-02-05 22:35:46.000000000 +0100
  869. +++ needrestart-3.5/NEWS    2023-09-20 14:53:21.000000000 +0200
  870. @@ -80,7 +80,7 @@
  871.  blacklisting
  872.  ------------
  873.  
  874. -It might be a bad idea to (auto) restart certain daemons. Therefor
  875. +It might be a bad idea to (auto) restart certain daemons. Therefore
  876.  a new config option is available to ignore binaries by matching
  877.  a regex. The supplied default configuration ignores dbus, NetworkManager
  878.  and various display managers.
  879. Common subdirectories: needrestart-3.4/.pc and needrestart-3.5/.pc
  880. Common subdirectories: needrestart-3.4/perl and needrestart-3.5/perl
  881. Common subdirectories: needrestart-3.4/po and needrestart-3.5/po
  882. diff -u needrestart-3.4/README.batch.md needrestart-3.5/README.batch.md
  883. --- needrestart-3.4/README.batch.md 2019-02-05 22:35:46.000000000 +0100
  884. +++ needrestart-3.5/README.batch.md 2023-09-20 14:53:21.000000000 +0200
  885. @@ -12,11 +12,13 @@
  886.  NEEDRESTART-SVC: systemd-journald.service
  887.  NEEDRESTART-SVC: systemd-machined.service
  888.  NEEDRESTART-CONT: LXC web1
  889. +NEEDRESTART-SESS: metabase @ user manager service
  890. +NEEDRESTART-SESS: root @ session #28017
  891.  ```
  892.  
  893.  Batch mode can be used to use the results of needrestart in other scripts.
  894.  While needrestart is run in batch mode it will never show any UI dialogs
  895. -nor restart anything. The output format is complient to the
  896. +nor restart anything. The output format is compliant with the
  897.  *apt-dater protocol*[1].
  898.  
  899.  [1] https://github.com/DE-IBH/apt-dater-host/blob/master/doc/
  900. diff -u needrestart-3.4/README.Cont.md needrestart-3.5/README.Cont.md
  901. --- needrestart-3.4/README.Cont.md  2019-02-05 22:35:46.000000000 +0100
  902. +++ needrestart-3.5/README.Cont.md  2023-09-20 14:53:21.000000000 +0200
  903. @@ -21,11 +21,13 @@
  904.  NeedRestart::CONT::LXC
  905.  ----------------------
  906.  
  907. -Recognized by: cgroup path (`/lxc/*`)
  908. +Recognized by: cgroup path (`/lxc/*` || `/lxc.payload/*`)
  909.  
  910.  For each container which should be restarted needrestart calls
  911.  `lxc-stop --reboot --name $NAME`.
  912.  
  913. +This package also supports LXD containers, which are restarted by `lxc restart
  914. +$NAME` or `lxc restart --project=$PROJECT $NAME` for containers in projects.
  915.  
  916.  NeedRestart::CONT::machined
  917.  ---------------------------
  918. diff -u needrestart-3.4/README.md needrestart-3.5/README.md
  919. --- needrestart-3.4/README.md   2019-02-05 22:35:46.000000000 +0100
  920. +++ needrestart-3.5/README.md   2023-09-20 14:53:21.000000000 +0200
  921. @@ -34,13 +34,13 @@
  922.  * *rpm*
  923.  * *pacman*
  924.  
  925. -The *service* command is used to run the tradiditional System V init script.
  926. +The *service* command is used to run the traditional System V init script.
  927.  
  928.  
  929.  Frontends
  930.  ---------
  931.  
  932. -*needrestart* uses a modular aproach based on perl packages providing
  933. +*needrestart* uses a modular approach based on perl packages providing
  934.  the user interface. The following frontends are shipped:
  935.  
  936.  * *NeedRestart::UI::Debconf* using *debconf*
  937. @@ -50,9 +50,13 @@
  938.  Kernel & Microcode
  939.  ------------------
  940.  
  941. -*needrestart* 0.8 brings a obsolete kernel detection feature. In *needrestart*
  942. -3.0 a [processor microcode update detection feature](README.uCode.md) for Intel
  943. -CPUs has been added.
  944. +*needrestart* 0.8 brings a obsolete kernel detection feature. Since
  945. +*needrestart* 3.5 it is possible to filter kernel image filenames (required on
  946. +[Raspberry Pi](README.raspberry.md)).
  947. +
  948. +In *needrestart* 3.0 a [processor microcode update detection
  949. +feature](README.uCode.md) for Intel CPUs has been added. Since *needrestart* 3.5
  950. +the AMD CPU support has been added.
  951.  
  952.  
  953.  Interpreters
  954. Only in needrestart-3.5/: README.raspberry.md
  955. diff -u needrestart-3.4/README.uCode.md needrestart-3.5/README.uCode.md
  956. --- needrestart-3.4/README.uCode.md 2019-02-05 22:35:46.000000000 +0100
  957. +++ needrestart-3.5/README.uCode.md 2020-03-22 17:40:19.000000000 +0100
  958. @@ -5,7 +5,18 @@
  959.  bugs. Needrestart checks if the current running microcode signature matches
  960.  the most recent version available on the host.
  961.  
  962. -The detection is currently only supported for Intel CPUs.
  963. +The detection is currently only supported for AMD and Intel CPUs.
  964. +
  965. +
  966. +AMD
  967. +---
  968. +
  969. +Needrestart decodes the AMD ucode firmware files to check for updates. This
  970. +requires to know the cpu's CPUID value. The most reliable way is to use the
  971. +cpuid kernel module (modprobe cpuid).
  972. +
  973. +As a fallback the CPUID is calculated from /proc/cpuinfo. The calculation
  974. +might be wrong and should be avoided by loading the cpuinfo kernel module.
  975.  
  976.  
  977.  Intel
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement