From mboxrd@z Thu Jan 1 00:00:00 1970 From: NeilBrown Subject: Re: [md PATCH 09/18] md/raid10: stop print_conf from being too verbose. Date: Fri, 03 Jun 2016 08:48:33 +1000 Message-ID: <87d1nzp5q6.fsf@notabene.neil.brown.name> References: <20160602061319.2939.72280.stgit@noble> <20160602061952.2939.83586.stgit@noble> <22352.32563.81868.525891@quad.stoffel.home> Mime-Version: 1.0 Content-Type: multipart/signed; boundary="=-=-="; micalg=pgp-sha256; protocol="application/pgp-signature" Return-path: In-Reply-To: <22352.32563.81868.525891@quad.stoffel.home> Sender: linux-raid-owner@vger.kernel.org To: John Stoffel Cc: Shaohua Li , linux-raid@vger.kernel.org List-Id: linux-raid.ids --=-=-= Content-Type: text/plain On Fri, Jun 03 2016, John Stoffel wrote: > NeilBrown> raid10 arrays can usefully be very large. When they are, > NeilBrown> the noise generated by print_conf can over-whelm logs. So > NeilBrown> truncate the listing at 16 devices. > > Why is this too noisy and how often does this print_conf() happen? > And why 16 devices? I guess I don't like the magic number of 16 here, > I'd prefer it to be a define, and possibly even something that can by > dynamically changed. print_conf happens whenever a device becomes active in the array, or a device is removed from the array (usually because it has failed). I got 16 by choosing a random number and multiplying by 4 (or maybe by raising 2 to that power) :-) More seriously, I guessed that most arrays were 16 devices or less, so this would not affect most arrays. I definitely don't think it needs a define. I'm very tempted to remove print_conf() completely, but it is sometimes useful. So having it present as long as it isn't a burden seems reasonable. If configuration was important I would change it to use pr_debug(), but then the default would be to not see the messages at all, and they can be useful in diagnosing problems reported on mailing lists. > > But how big a problem is this really? And what about for big RAID5/6 > arrays as well? When you have 2000 devices in your RAID10 and half of them are removed at once, it currently reports on 2,000,000 devices. With the patch it is only 32000. Still possibly too many. If you have 2000 devices in your RAID5/6 and half of them are removed, you have other problems. > > Or would it be also good to condence the output of print_conf() > itself? Probably a very good idea. Maybe the default could print a fixed-size summary and the rest goes in pr_debug()?? > > Of if it's noise, why not just remove it completely? Can this > information be found in /proc/mdstat instead? Its value is historical - trying to understand a past sequence of events. For that, something in the logs beats something in /proc. > > Sorry I havent' looked in the code deeply, but this just struck me as > a change that might not be ideal. Fair enough - your comments are very valid. I'm not really sure what is best. I only know what is worst :-) and want to avoid that. Suggestions very welcome. Thanks, NeilBrown --=-=-= Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- Version: GnuPG v2 iQIcBAEBCAAGBQJXULfBAAoJEDnsnt1WYoG5uP8P/27XZjbAMOFL2GPv3qXlVMs3 5pxyIlKZGg00Trma+EPqcAuOd07Gb87sVWSV089fwMgBVghVv/ob0mDI00toS23Y 82SAlTRcpII7VDqqIIywI/PkO97k5R4ldaJIUXUTZmJDVvaB4SJKg9UMFDTmcjMT sYBQrNfOVsi5QR3+6qhUeoBDfSOyOtVBWOQxMffZzQieDuDP3dY6xkIdq0ITZ5j+ 3O9PxeTZQ84vnZNzSJag4PvA4OiQXb2XWDUcp3coChR6O5Ea7pNiqu8uns4Zbf70 Ge7V+BFdORCly//ASTiUhsLns/PfUWDgNHAudDYaWvUzX6NV8sdxretVdi2ZEleB jRwqMpYC+OSY7uJWEtF61zpeoRBXvUJyCrmAV+xV9+du3uu7I3iRi8z0OBgtN6us NaqZ/BWLPwLB9pgHd2PMBMz1JXg11g1Zj984lQxbkVfIal+qrPseMne4agMq6y8r 82ip3we2E8nVhJzoeA4IyH4E8GUynd5B+MXZwNXPYb6zN5wi8h1M4dQQ2YNK2H99 hDr5pWRLUoP38OwWDgoBYPhaOFGKWBXYzeYEG/6JEYXH1D+pv0tNrkzs32rPiBfQ f3DLJmMjRKRxUjy5EU4wgpPPlT+uq8j6ZqSXClFhI/0X/Eo90Mktvlu0FwJJ6AYI 8VyFxwTCsfi6U9OdUYND =hLxA -----END PGP SIGNATURE----- --=-=-=--