lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:	Wed, 05 Nov 2014 15:30:30 -0500
From:	Austin S Hemmelgarn <ahferroin7@...il.com>
To:	Theodore Ts'o <tytso@....edu>, Martin Tournoij <martin@...242.net>,
	linux-kernel@...r.kernel.org
Subject: Re: [RFC] The SIGINFO signal from BSD

On 2014-11-05 15:14, Theodore Ts'o wrote:
> On Wed, Nov 05, 2014 at 02:31:12PM -0500, Austin S Hemmelgarn wrote:
>>>
>>> SIGINFO prints the status of the process to the terminal; BSD cp, for example,
>>> shows show much data it's copied:
>>>
>>>      $ cp large_file /dev/null
>>>      <press ^t>
>>>      load: 1.39  cmd: cp 85837 [running] 3.91r 0.00u 0.98s 8% 2340k
>>>      large_file -> /dev/null  15%
>>>
>>> As you see, it shows the current load, pid, process status, memory usage, as
>>> well as how much of the file has been copied. Many other BSD tools print similar
>>> statistics (mv, tar, dd, sleep, fetch, etc.).
>>
>> You have to understand however, that the reason that SIGINFO works like that
>> on *BSD is that the kernel and core userspace are developed together,
>> whereas on Linux, they are maintained entirely separately. Outside of core
>> userspace components, using SIGINFO that way on *BSD is just convention.
>
> Actually, the first line:
>
> 	load: 1.39  cmd: cp 85837 [running] 3.91r 0.00u 0.98s 8% 2340k
>
> is actually printed by the kernel.  It's actually something which is
> implemented in the BSD N_TTY line displine.  We never implemented it
> (at least when I was maintaining the tty subsystem) mostly out of
> laziness.  Part of the reason is that the main reason was that main
> reason why people (at least systems programmers / kernel programers
> like me) used ^T was to debug an apparently hung system, and for
> Linux, we had a much more powerful system using the magic-sysrq key.
>
I hadn't realized that it was actually the kernel printing that, but 
then I've never really looked all that deep into the BSD source code.
Ironically, the magic-sysrq key is one of the big reasons I've 
personally chosen to stay with Linux over any of the BSD derivatives. :)


Download attachment "smime.p7s" of type "application/pkcs7-signature" (2455 bytes)

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ