runchoom-use-oom_score_adj 1.4 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657
  1. --- perp-2.07/runtools/runchoom.c.orig 2019-12-18 13:00:02.306978796 +0000
  2. +++ perp-2.07/runtools/runchoom.c 2019-12-18 13:01:01.463113686 +0000
  3. @@ -1,5 +1,5 @@
  4. /* runchoom.c
  5. -** run a program after writing "-17\n" to /proc/<pid>/oom_adj
  6. +** run a program after writing "-17\n" to /proc/<pid>/oom_score_adj
  7. ** (abatement for "dreaded linux oom killer")
  8. ** wcm, 2011.03.18 - 2011.03.22
  9. ** ===
  10. @@ -32,7 +32,7 @@
  11. #endif
  12. #ifndef CHOOM_KEY_DEFAULT
  13. -#define CHOOM_KEY_DEFAULT "oom_adj"
  14. +#define CHOOM_KEY_DEFAULT "oom_score_adj"
  15. #endif
  16. /* see proc(5) manual (linux-specific): */
  17. --- perp-2.07/runtools/man/runchoom.8.orig 2013-01-11 15:10:33.000000000 +0000
  18. +++ perp-2.07/runtools/man/runchoom.8 2019-12-18 13:01:10.967139845 +0000
  19. @@ -21,7 +21,7 @@
  20. .SH DESCRIPTION
  21. .B runchoom
  22. writes the string ``-17'' and a newline into the procfile
  23. -.IR /proc/<pid>/oom_adj ,
  24. +.IR /proc/<pid>/oom_score_adj ,
  25. where
  26. .I <pid>
  27. is the process id of
  28. @@ -79,7 +79,7 @@
  29. Normally
  30. .B runchoom
  31. uses the compiled-in default value
  32. -.I oom_adj
  33. +.I oom_score_adj
  34. for the last element of the target procfile.
  35. The
  36. .B \-k
  37. @@ -193,7 +193,7 @@
  38. .RE
  39. .SH NOTES
  40. On a system where the
  41. -.I oom_adj
  42. +.I oom_score_adj
  43. procfile is operative,
  44. the setting installed by
  45. .B runchoom
  46. @@ -210,7 +210,7 @@
  47. .BR perpetrate (5)
  48. runscripts of any selected services to
  49. reset the
  50. -.I oom_adj
  51. +.I oom_score_adj
  52. parameter of a process to a default state:
  53. .PP
  54. .RS