Skip site navigation (1)Skip section navigation (2)
Date:      Wed, 7 Apr 2021 16:08:36 +0300
From:      Slawa Olhovchenkov <slw@zxy.spb.ru>
To:        Poul-Henning Kamp <phk@phk.freebsd.dk>
Cc:        current@freebsd.org
Subject:   Re: console getty uses 1.5% of CPU
Message-ID:  <20210407130836.GA80160@zxy.spb.ru>
In-Reply-To: <69119.1617772960@critter.freebsd.dk>
References:  <69119.1617772960@critter.freebsd.dk>

next in thread | previous in thread | raw e-mail | index | archive | help
On Wed, Apr 07, 2021 at 05:22:40AM +0000, Poul-Henning Kamp wrote:

> I have two 12.2-R systems where the serial console is attached to a terminal server.
> 
> When there are no TCP connections to the terminal server, getty soaks up 1.5% of the
> CPU in the kernel (sleeping in "ttyin"), ktrace shows no system calls.
> 
> When a TCP connection is made to the terminal server, which raises the modem-handshake
> on the DE-9 connector, the CPU usage stops.
> 
> Anybody else seeing something like this ?

Problem of comparing low number?
Top's "getty 1.5% of the CPU" is not "getty eat 1.5% of the ALL CPU
power", this is "getty 1.5% of off all other curerent eats of CPU
power".

T.e. if all system eat 985 ticks of CPU each second and getty eat 15
ticks of CPU each second -- top show 1.5% for getty.
Load is raised to 99_985 ticks for system, getty eat 15 ticks -- top
show 0% ( 15/(99985+15) = .015% ).




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20210407130836.GA80160>