public inbox for stable@vger.kernel.org
 help / color / mirror / Atom feed
* Say that it was Linux that printed "Out of memory"
@ 2023-11-26  2:40 Dan Jacobson
  2023-11-26  8:48 ` Greg KH
  0 siblings, 1 reply; 5+ messages in thread
From: Dan Jacobson @ 2023-11-26  2:40 UTC (permalink / raw)
  To: stable

In https://github.com/szabgab/perlmaven.com/issues/583 we see to find 
the simple answer to "What printed 'Out of memory', one must consult the 
experts.

Therefore the "Out of memory" message needs to be prefixed with the name 
of the kernel, or something. Anything. Thanks.

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: Say that it was Linux that printed "Out of memory"
  2023-11-26  2:40 Say that it was Linux that printed "Out of memory" Dan Jacobson
@ 2023-11-26  8:48 ` Greg KH
  2023-11-26  9:20   ` Willy Tarreau
  2023-11-26 13:15   ` Dan Jacobson
  0 siblings, 2 replies; 5+ messages in thread
From: Greg KH @ 2023-11-26  8:48 UTC (permalink / raw)
  To: Dan Jacobson; +Cc: stable

On Sun, Nov 26, 2023 at 10:40:36AM +0800, Dan Jacobson wrote:
> In https://github.com/szabgab/perlmaven.com/issues/583 we see to find the
> simple answer to "What printed 'Out of memory', one must consult the
> experts.
> 
> Therefore the "Out of memory" message needs to be prefixed with the name of
> the kernel, or something. Anything. Thanks.

Prefixed exactly where?  The kernel already does report all of this to
the kernel log, saying what program was killed due to out of memory
issues.

thanks,

greg k-h

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: Say that it was Linux that printed "Out of memory"
  2023-11-26  8:48 ` Greg KH
@ 2023-11-26  9:20   ` Willy Tarreau
  2023-11-26 13:25     ` Dan Jacobson
  2023-11-26 13:15   ` Dan Jacobson
  1 sibling, 1 reply; 5+ messages in thread
From: Willy Tarreau @ 2023-11-26  9:20 UTC (permalink / raw)
  To: Greg KH; +Cc: Dan Jacobson, stable

On Sun, Nov 26, 2023 at 08:48:50AM +0000, Greg KH wrote:
> On Sun, Nov 26, 2023 at 10:40:36AM +0800, Dan Jacobson wrote:
> > In https://github.com/szabgab/perlmaven.com/issues/583 we see to find the
> > simple answer to "What printed 'Out of memory', one must consult the
> > experts.
> > 
> > Therefore the "Out of memory" message needs to be prefixed with the name of
> > the kernel, or something. Anything. Thanks.
> 
> Prefixed exactly where?  The kernel already does report all of this to
> the kernel log, saying what program was killed due to out of memory
> issues.

From what I can see on the original article featuring a simple perl
script at https://perlmaven.com/out-of-memory it says "on the terminal".
As such, it's just the perl interpreter that faced ENOMEM and printed
the corresponding message before quitting. One will note that there is
absolutely no capture provided in the article nor the reporter to ease
understanding, but as a rule of thumb the kernel will not print stuff
in the user's terminal, it will only appear in logs where it's indeed
prefixed. And no need for an "expert" to figure that ;-)

Willy

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: Say that it was Linux that printed "Out of memory"
  2023-11-26  8:48 ` Greg KH
  2023-11-26  9:20   ` Willy Tarreau
@ 2023-11-26 13:15   ` Dan Jacobson
  1 sibling, 0 replies; 5+ messages in thread
From: Dan Jacobson @ 2023-11-26 13:15 UTC (permalink / raw)
  To: Greg KH; +Cc: stable

Prefixed to STDERR, right before the words Out of Memory.
Well at least bash error messages make it clear they are from bash.
Perl is in the habit of assuming everybody knows its messages come from 
perl.
And now the kernel assumes people can guess they come from the kernel.
Anyway, I bet half the people who see this message,
https://www.google.com/search?q=perl+out+of+memory
assume it is perl making it.
And... not everybody looks or can look at kernel logs.

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: Say that it was Linux that printed "Out of memory"
  2023-11-26  9:20   ` Willy Tarreau
@ 2023-11-26 13:25     ` Dan Jacobson
  0 siblings, 0 replies; 5+ messages in thread
From: Dan Jacobson @ 2023-11-26 13:25 UTC (permalink / raw)
  To: Willy Tarreau; +Cc: Greg KH, stable

OK, sorry. I now filed
https://github.com/Perl/perl5/issues/21672
to make sure they say "Perl: " in front of such messages.

^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2023-11-26 13:33 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2023-11-26  2:40 Say that it was Linux that printed "Out of memory" Dan Jacobson
2023-11-26  8:48 ` Greg KH
2023-11-26  9:20   ` Willy Tarreau
2023-11-26 13:25     ` Dan Jacobson
2023-11-26 13:15   ` Dan Jacobson

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox