Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S934407AbbHDOJz (ORCPT ); Tue, 4 Aug 2015 10:09:55 -0400 Received: from mail-lb0-f175.google.com ([209.85.217.175]:35047 "EHLO mail-lb0-f175.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S932310AbbHDOJy (ORCPT ); Tue, 4 Aug 2015 10:09:54 -0400 MIME-Version: 1.0 In-Reply-To: References: Date: Tue, 4 Aug 2015 16:09:52 +0200 Message-ID: Subject: Re: kdbus: to merge or not to merge? From: David Herrmann To: Linus Torvalds Cc: Andy Lutomirski , "linux-kernel@vger.kernel.org" , Djalal Harouni , Greg KH , Havoc Pennington , "Eric W. Biederman" , One Thousand Gnomes , Tom Gundersen , Daniel Mack , "Kalle A. Sandstrom" , Borislav Petkov , cee1 Content-Type: text/plain; charset=UTF-8 Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1610 Lines: 43 Hi On Tue, Aug 4, 2015 at 3:46 PM, Linus Torvalds wrote: > On Tue, Aug 4, 2015 at 1:58 AM, David Herrmann wrote: >> >> You lack a call to sd_bus_unref() here. > > I assume it was intentional. Why would Andy talk about "scaling" otherwise? > > And the worry was why the kdbus version killed the machine, but the > userspace version did not. That's a rather big difference, and not a > good one. Neither test 'kills' the machine: * The userspace version will be killed by the OOM killer after about 20s running (depending how much memory you have). * The kernel version runs for 1024 iterations (maximum kdbus connections per user) and then produces errors. In fact, the kernel version is even more stable than the user-space version, and bails out much earlier. Run it on a VT and everything works just fine. The only issue you get with kdbus is the compat-bus-daemon, which assert()s as a side-effect of accept4() failing. In other words, the compat bus-daemon gets ENFILE if you open that many connections, then assert()s and thus kills all other proxy connections. This has the side effect, that Xorg loses access to your graphics device and thus your screen 'freezes'. Also networkmanager bails out and stops network connections. This is a bug in the proxy (which is already fixed). Thanks David -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/