From owner-freebsd-bugs@freebsd.org Tue Sep 11 03:12:07 2018 Return-Path: Delivered-To: freebsd-bugs@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id D52ED10A6E59 for ; Tue, 11 Sep 2018 03:12:06 +0000 (UTC) (envelope-from koro@kzxiv.net) Received: from out1-smtp.messagingengine.com (out1-smtp.messagingengine.com [66.111.4.25]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 8212482512 for ; Tue, 11 Sep 2018 03:12:06 +0000 (UTC) (envelope-from koro@kzxiv.net) Received: from compute3.internal (compute3.nyi.internal [10.202.2.43]) by mailout.nyi.internal (Postfix) with ESMTP id 7DAC921F1B; Mon, 10 Sep 2018 23:12:05 -0400 (EDT) Received: from mailfrontend1 ([10.202.2.162]) by compute3.internal (MEProxy); Mon, 10 Sep 2018 23:12:05 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=kzxiv.net; h=cc :content-transfer-encoding:content-type:date:from:in-reply-to :message-id:mime-version:references:subject:to:x-me-sender :x-me-sender:x-sasl-enc; s=fm2; bh=qxoyQfCYYrwXmbeqdkbYGB1cpE4Yd b7eNVUCWHnXND8=; b=hjNB0gc18tFEMrzShrJXV1JtEAzU/utsR+DZe4vSD1wjJ t8A7WzLWZm9kix2wdymKJnSHW3P0pvwtE8a5RfFDihJhNoubVphvNxw1ur13pi4V q/KamBLpr5WX9xIybSEYPdTzWSTUjqtdaV3MeDFF5r+sORzZZ36VMe3PXXWMSnxQ kjh8nhKuUi3+nxaIGtjbDKxhelvEGJrzQIgsCxs4/MSC8ODkeDS7hN2jbvc84Gs4 MJ1np9WkZq/2Ts2SibLRryFPtm3/MZ7eWLSGg27OKf64TecSgSVws49EhlzIUkIR 40LaDS90pbcsqIRRMLfwyu6Unrri89wQZK1Ff+fLw== DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= messagingengine.com; h=cc:content-transfer-encoding:content-type :date:from:in-reply-to:message-id:mime-version:references :subject:to:x-me-sender:x-me-sender:x-sasl-enc; s=fm3; bh=qxoyQf CYYrwXmbeqdkbYGB1cpE4Ydb7eNVUCWHnXND8=; b=RDCPQe6Bb7htJ8ksHYkJQl Ca9f71/uTkLHmvbBVPMocHxoIitW3MHQC9Ejim74E42w8FsszikE6Z5h6aw5P8CO IIi88Xx0FCxxnlo2O14KZzhF5dCFl321NLizej464E76Uw0Cg94tip4eu3E6hwNQ yamRyD9lOKZxMMabqeYpO9wJ8TOmOW68QY/TqeEqDDGCR95EtlmgLB5oYrElrO+C 54ChR61Ao5HipHsn1JZaonAYk39EAfhQKf+8XY0SiqtDapENOCwCWfuvB61SBXWf EQUnPO3Y3jh7OaExlsqEuiejcJ3iv2IS0nk+1JRDDir6ZIct0XqmMqe7cWmun7Cg == X-ME-Proxy: X-ME-Sender: Received: from amduscia.kzxiv.net (198-200-119-16.cpe.distributel.net [198.200.119.16]) by mail.messagingengine.com (Postfix) with ESMTPA id CD1B0E455C; Mon, 10 Sep 2018 23:12:04 -0400 (EDT) Subject: Re: [Bug 230757] [syscons] random wrong color for kernel messages To: freebsd-bugs@freebsd.org References: <20180820194127.C1023@besplex.bde.org> Cc: brde@optusnet.com.au From: Koro Message-ID: Date: Mon, 10 Sep 2018 23:12:04 -0400 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:60.0) Gecko/20100101 Thunderbird/60.0 MIME-Version: 1.0 In-Reply-To: <20180820194127.C1023@besplex.bde.org> Content-Type: text/plain; charset=utf-8; format=flowed Content-Language: en-US-large Content-Transfer-Encoding: 7bit X-BeenThere: freebsd-bugs@freebsd.org X-Mailman-Version: 2.1.27 Precedence: list List-Id: Bug reports List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 11 Sep 2018 03:12:07 -0000 > In FreeBSD-11: > - for boot messages, configure SC_KERNEL_CONS_ATTR to anything except its > default of FG_WHITE (0xf). > - after booting, use the hw.syscons.kattr sysctl to change the array of > MAXCPU kernel attributes to whatever you want (all FG_WHITE to get the > old behaviour). sysctl(8) doesn't handle arrays very well, so it takes > rarely-used options to even print the values in the array. I tried doing this real quick, but it did not change a thing: #include #include #include #include int main(int argc, char** argv) { char kattr[256]; memset(kattr, 0x0f, 256); if (sysctlbyname("hw.syscons.kattr", NULL, 0, kattr, 256) == -1) { perror("sysctl"); return 1; } return 0; } It doesn't error out, but it does not change a thing, I still kept getting colored messages. Maybe I misunderstood your instructions? This is on 11.2-RELEASE by the way. > But don't turn it off. Try using better colors (don't use dark gray). > Even I like colorized kernel messages, and I stopped using colorized ls > 25 years ago. It's not so bad with only dark gray (though it looks a bit broken), but once you add more CPUs, it starts looking like an xmas tree. I too, like my consoles to be gray and boring and disable colored ls. And also, unless one actively works on the kernel, I fail to see the need to know from which CPU did a specific kernel message originate. - Koro