From owner-freebsd-hackers@freebsd.org Tue Jan 26 19:32:19 2016 Return-Path: Delivered-To: freebsd-hackers@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 69557A460A9 for ; Tue, 26 Jan 2016 19:32:19 +0000 (UTC) (envelope-from superbisquit@gmail.com) Received: from mail-vk0-x22c.google.com (mail-vk0-x22c.google.com [IPv6:2607:f8b0:400c:c05::22c]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (Client CN "smtp.gmail.com", Issuer "Google Internet Authority G2" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 22C028AB for ; Tue, 26 Jan 2016 19:32:19 +0000 (UTC) (envelope-from superbisquit@gmail.com) Received: by mail-vk0-x22c.google.com with SMTP id e185so97874990vkb.1 for ; Tue, 26 Jan 2016 11:32:19 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :cc:content-type; bh=/Jd6z4ojpfBe8j7QkCut2VADgK/zLb36m3eGJAR1F1s=; b=wpbC+eJLh8YjAuYx0Ljk3hlA14TFTtMyYRX5KTxpuJL+UTuoL4EnF3yiASR9a/B2Nd vK1ZzGkYifbE58ZxwWIPY8nAMNDjtcBREbuAW9vpGdmMK+PFULgdVX6QtFT9achTkf9l X8mIkGFtR2mIg42KmTfqmJll0RAix6FgUBo9RITJFosEBSvkxU4AzXE696DV4R3sngIp ad7Y/B7u+l/esuigA637el/ErJ8GGQbUWLyP7cFTBNib6BWOxS8tnqguH6IBInZ45Krs gvKhp40hqcS7HulHI5nCqNazb6RfCIAmLsz7cj5TiuySsNei6tWvBTVa395YMdORvhY3 gbqw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:mime-version:in-reply-to:references:date :message-id:subject:from:to:cc:content-type; bh=/Jd6z4ojpfBe8j7QkCut2VADgK/zLb36m3eGJAR1F1s=; b=DWTHuQrRBPaQ6DQh/NoaM7tHE9fUtK2Iqx/uVV7ll5fCxOIuWbPADQqymoiJOSI+4O Haz0hcDd01BuEOVfVFmDm0bodpch3avkbA9roW6F0OGGHaIOSELJasqwMfcNYD21sZbe UtAdwR+dW63M3g3ffQXuvsleXCMlOU12rOIdXGdFtuqZeBU+UUPaHeGiq7w+IEqXNUww kMiDmVKBqacLcPjDrAMn6kpbeiiMvKkUV68/qSBrKR3c26bBCMAT82c2PrFVhwiAlKbw uouTQ6eU0lHJqtEZXJ05Jtq9szselOzodrR/DKKsT6QcUpqjXZBcrxw2BR78Btk8G8Zk ZBuw== X-Gm-Message-State: AG10YOSKCSQhc0W1BvQbUdredGXV83rtcnnmVrk4TnxbpRqD8pmU5iYARQgI5qhUiVEYcOusnVaaxBtZn8rPKA== MIME-Version: 1.0 X-Received: by 10.31.132.140 with SMTP id g134mr15785374vkd.94.1453836738117; Tue, 26 Jan 2016 11:32:18 -0800 (PST) Received: by 10.103.37.196 with HTTP; Tue, 26 Jan 2016 11:32:18 -0800 (PST) In-Reply-To: <56A21C0A.7060904@toco-domains.de> References: <56A21205.9030202@mu.org> <56A21C0A.7060904@toco-domains.de> Date: Tue, 26 Jan 2016 14:32:18 -0500 Message-ID: Subject: Re: Now I am aware From: Joe Nosay To: Torsten Zuehlsdorff Cc: Alfred Perlstein , FreeBSD Hackers Content-Type: text/plain; charset=UTF-8 X-Content-Filtered-By: Mailman/MimeDel 2.1.20 X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.20 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 26 Jan 2016 19:32:19 -0000 If you wish to point out my faults, then do so as men and women by telling me directly and not behind my back. It is the way of cowards to make comments from far away and to not approach the person. Your software may be open; but, your minds are as closed in the opposite respect. You have little regard to those who have lost people for the sake of the companies and countries you work for currently. You live a life of unearned privilege and never think of the actual total human output and work over the time of homo sapiens existence. If your societies and technology were to fall today, you would become feral and savage in the most negative ways. Your species has destroyed much of this planet and you are prone to war and strife. You could meet me at the entrance of University of Maryland Eastern Shore campus, across from the NASA Wallops Island facility, or across the street from the University of Salisbury in Salisbury , Maryland. I will be very glad to have a sensible and diplomatic debate with you; however, if you come towards me with the intention of harming, mocking, discrediting, or any other negative activity, I may be very well inclined to defend myself and beat the living fucking shit out of any and all of you who cross my path the wrong way. You have my location and an invitation to act sensible along with a well expressed warning of not crossing boundaries. On Fri, Jan 22, 2016 at 7:09 AM, Torsten Zuehlsdorff < mailinglists@toco-domains.de> wrote: > You can have a look in Google-Cache: > > http://webcache.googleusercontent.com/search?q=cache:https://forums.freebsd.org/threads/making-it-public.54392/%23post-309037&ie=utf-8&oe=utf-8&gws_rd=cr&ei=rhuiVrbMKIOGaLvOuZAN > > But this will not last very long. > > > On 22.01.2016 12:27, Alfred Perlstein wrote: > >> I can't access this link... what was there? >> >> On 1/19/16 9:21 AM, Joe Nosay wrote: >> >>> of how self-centered and selfish all of you are. >>> >>> >>> >>> https://forums.freebsd.org/threads/making-it-public.54392/#post-309037 >>> _______________________________________________ >>> freebsd-hackers@freebsd.org mailing list >>> https://lists.freebsd.org/mailman/listinfo/freebsd-hackers >>> To unsubscribe, send any mail to >>> "freebsd-hackers-unsubscribe@freebsd.org" >>> >>> >> _______________________________________________ >> freebsd-hackers@freebsd.org mailing list >> https://lists.freebsd.org/mailman/listinfo/freebsd-hackers >> To unsubscribe, send any mail to "freebsd-hackers-unsubscribe@freebsd.org >> " >> > _______________________________________________ > freebsd-hackers@freebsd.org mailing list > https://lists.freebsd.org/mailman/listinfo/freebsd-hackers > To unsubscribe, send any mail to "freebsd-hackers-unsubscribe@freebsd.org" > From owner-freebsd-hackers@freebsd.org Tue Jan 26 19:34:40 2016 Return-Path: Delivered-To: freebsd-hackers@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id ED9EAA46183 for ; Tue, 26 Jan 2016 19:34:40 +0000 (UTC) (envelope-from superbisquit@gmail.com) Received: from mail-vk0-x22c.google.com (mail-vk0-x22c.google.com [IPv6:2607:f8b0:400c:c05::22c]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (Client CN "smtp.gmail.com", Issuer "Google Internet Authority G2" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id A68D8BAA for ; Tue, 26 Jan 2016 19:34:40 +0000 (UTC) (envelope-from superbisquit@gmail.com) Received: by mail-vk0-x22c.google.com with SMTP id e64so98944443vkg.0 for ; Tue, 26 Jan 2016 11:34:40 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :cc:content-type; bh=0kIhWVQMOfg674QdEgYs1gei+c68PHOA4eP4tag29yQ=; b=Zv0i2VMxw/6lZ+VaXO+ggXeTbgRJjJDb0oh3D8cvqsphk6Jqx1el6A8tC098XA7uPP eBcjxO24zpDpw6JoWu6WA+C0k9ZAQTANxXn3s2CCcvH/2kkupz+TDSRbdQXnjMduBZ+z mHj+XzXiVKz+GJlhHYP3iI6F4AIXMXs3HR25RszSvZE7fyQQislCXUl8oR9KO4F86li+ PfrSl9H8eZsNIdC5vWsBQoO/aUy/r03VzC2z+JJhS9JTGoqlwVk2KPz93Wqu6pVAkO7m xl+BydZky6pTnIIbeCQZSx7mjMustcqUNTbgLmKmvyfN/ctQw+5aBgxhEe1sCYRo+Z79 CQZA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:mime-version:in-reply-to:references:date :message-id:subject:from:to:cc:content-type; bh=0kIhWVQMOfg674QdEgYs1gei+c68PHOA4eP4tag29yQ=; b=FuWaoV7wMlWvhlexnWGrnm5FDXccz/P62YHdMYPqgAaj8LcUys62PgzYcf5RT42Vuz Krey0T/LqxXj8GylgeZoyYUaXiivIrA8O3YKhmSfR4kHplso5qxBXRrB7NbabSRq7SpM YhYwkRSnAJiPV11CtsB/gjjvB+NAduxlzUfvDOwp/x+5fJnhMSV7GmtW4gqOTkfoxM6P UMj1oZZcMrp7arIOabfYzJLGHcoXDiRtc398YpmEgF8bqoOyVY4Av6W5TpqPXGpQP8TI yZMKYJDwx9kZTVP1NJFTjVZC4L+gpBVaqjGIEVWM2/vl4GnRWKGi4OBn7ZVatn1+Rkq4 jSlw== X-Gm-Message-State: AG10YOQqryYfTgpuHm7DGoudkg9Hqz5SCR6xq6cIyNu67D4q2tSw7LyxxKqAePDiGmZJBBAVcHXS8RgbeIfV2A== MIME-Version: 1.0 X-Received: by 10.31.141.10 with SMTP id p10mr16060135vkd.93.1453836879835; Tue, 26 Jan 2016 11:34:39 -0800 (PST) Received: by 10.103.37.196 with HTTP; Tue, 26 Jan 2016 11:34:39 -0800 (PST) In-Reply-To: References: <56A21205.9030202@mu.org> <56A21C0A.7060904@toco-domains.de> Date: Tue, 26 Jan 2016 14:34:39 -0500 Message-ID: Subject: Re: Now I am aware From: Joe Nosay To: Torsten Zuehlsdorff Cc: Alfred Perlstein , FreeBSD Hackers Content-Type: text/plain; charset=UTF-8 X-Content-Filtered-By: Mailman/MimeDel 2.1.20 X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.20 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 26 Jan 2016 19:34:41 -0000 Don't fuck up. On Tue, Jan 26, 2016 at 2:32 PM, Joe Nosay wrote: > If you wish to point out my faults, then do so as men and women by telling > me directly and not behind my back. It is the way of cowards to make > comments from far away and to not approach the person. > Your software may be open; but, your minds are as closed in the opposite > respect. > You have little regard to those who have lost people for the sake of the > companies and countries you work for currently. > You live a life of unearned privilege and never think of the actual total > human output and work over the time of homo sapiens existence. > If your societies and technology were to fall today, you would become > feral and savage in the most negative ways. > Your species has destroyed much of this planet and you are prone to war > and strife. > > You could meet me at the entrance of University of Maryland Eastern Shore > campus, across from the NASA Wallops Island facility, or across the street > from the University of Salisbury in Salisbury , Maryland. > I will be very glad to have a sensible and diplomatic debate with you; > however, if you come towards me with the intention of harming, mocking, > discrediting, or any other negative activity, I may be very well inclined > to defend myself and beat the living fucking shit out of any and all of you > who cross my path the wrong way. > > > You have my location and an invitation to act sensible along with a well > expressed warning of not crossing boundaries. > > > > On Fri, Jan 22, 2016 at 7:09 AM, Torsten Zuehlsdorff < > mailinglists@toco-domains.de> wrote: > >> You can have a look in Google-Cache: >> >> http://webcache.googleusercontent.com/search?q=cache:https://forums.freebsd.org/threads/making-it-public.54392/%23post-309037&ie=utf-8&oe=utf-8&gws_rd=cr&ei=rhuiVrbMKIOGaLvOuZAN >> >> But this will not last very long. >> >> >> On 22.01.2016 12:27, Alfred Perlstein wrote: >> >>> I can't access this link... what was there? >>> >>> On 1/19/16 9:21 AM, Joe Nosay wrote: >>> >>>> of how self-centered and selfish all of you are. >>>> >>>> >>>> >>>> https://forums.freebsd.org/threads/making-it-public.54392/#post-309037 >>>> _______________________________________________ >>>> freebsd-hackers@freebsd.org mailing list >>>> https://lists.freebsd.org/mailman/listinfo/freebsd-hackers >>>> To unsubscribe, send any mail to >>>> "freebsd-hackers-unsubscribe@freebsd.org" >>>> >>>> >>> _______________________________________________ >>> freebsd-hackers@freebsd.org mailing list >>> https://lists.freebsd.org/mailman/listinfo/freebsd-hackers >>> To unsubscribe, send any mail to " >>> freebsd-hackers-unsubscribe@freebsd.org" >>> >> _______________________________________________ >> freebsd-hackers@freebsd.org mailing list >> https://lists.freebsd.org/mailman/listinfo/freebsd-hackers >> To unsubscribe, send any mail to "freebsd-hackers-unsubscribe@freebsd.org >> " >> > > From owner-freebsd-hackers@freebsd.org Tue Jan 26 22:28:49 2016 Return-Path: Delivered-To: freebsd-hackers@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 2739AA46DD1; Tue, 26 Jan 2016 22:28:49 +0000 (UTC) (envelope-from vangyzen@FreeBSD.org) Received: from smtp.vangyzen.net (hotblack.vangyzen.net [IPv6:2607:fc50:1000:7400:216:3eff:fe72:314f]) by mx1.freebsd.org (Postfix) with ESMTP id 0F7DC3B6; Tue, 26 Jan 2016 22:28:49 +0000 (UTC) (envelope-from vangyzen@FreeBSD.org) Received: from sweettea.beer.town (unknown [76.164.8.130]) by smtp.vangyzen.net (Postfix) with ESMTPSA id 668945648E; Tue, 26 Jan 2016 16:28:48 -0600 (CST) From: Eric van Gyzen Subject: Hot-Plug PCIe Support X-Enigmail-Draft-Status: N1110 To: freebsd-hackers@freebsd.org, freebsd-current@freebsd.org, freebsd-arch@freebsd.org Reply-To: freebsd-hackers@freebsd.org Message-ID: <56A7F31C.3030209@FreeBSD.org> Date: Tue, 26 Jan 2016 16:28:44 -0600 User-Agent: Mozilla/5.0 (X11; FreeBSD amd64; rv:38.0) Gecko/20100101 Thunderbird/38.5.0 MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.20 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 26 Jan 2016 22:28:49 -0000 FreeBSD Folks: I am currently scoping the effort to add hot-plug PCIe support to FreeBSD. Is anyone else currently working on this or aware of any design, code, or other effort available outside the tree? FYI, here are perhaps the most interesting references I could find: https://wiki.freebsd.org/PCIHotplug https://wiki.freebsd.org/IdeasPage#Implementing_PCI-Hotplug_and_ExpressCard_support https://lists.freebsd.org/pipermail/freebsd-current/2015-April/055290.html https://lists.freebsd.org/pipermail/freebsd-ia32/2010-February/date.html Please reply on freebsd-hackers@FreeBSD.org to minimize cross-posting. Thanks in advance. Eric From owner-freebsd-hackers@freebsd.org Tue Jan 26 22:31:56 2016 Return-Path: Delivered-To: freebsd-hackers@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 91865A6E099 for ; Tue, 26 Jan 2016 22:31:56 +0000 (UTC) (envelope-from oliver.pinter@hardenedbsd.org) Received: from mail-wm0-x235.google.com (mail-wm0-x235.google.com [IPv6:2a00:1450:400c:c09::235]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (Client CN "smtp.gmail.com", Issuer "Google Internet Authority G2" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 2F22BA47 for ; Tue, 26 Jan 2016 22:31:56 +0000 (UTC) (envelope-from oliver.pinter@hardenedbsd.org) Received: by mail-wm0-x235.google.com with SMTP id r129so123763183wmr.0 for ; Tue, 26 Jan 2016 14:31:56 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=hardenedbsd-org.20150623.gappssmtp.com; s=20150623; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :cc:content-type; bh=cU3Ht0C5f6v3qQt5Z2LLH7BXA49Ea6D5VS/5ITDqqdU=; b=fwtswwk4KlO2Qql8en+AreqfB/XRXAg5hJl/JoYSjXcslJFP18NXrSnRZAJ3pVNxcc 8uXx650/ea66RNOU78zIfJ3leHVMqhB/DP2xjgzKjqhusilu5UyG+XAvBG3qbgLehyaz xQ1RKlIKaEPE1KINJBX8sjys/J8LVlNHl9O1G1DzZ32bjKhMjEbsYyB9tLxY2kWkpm7W r/5SMgV6Ixiw1GsX0LrQIw320xrb0F60e9OYpwUdYdCmvxP7cnNRMOkTjEz1+lT31GFe arEolzvHALwp5sZ3fKEOqux6fjNXXcfQ7ijlcjYF8OorQn7nI5wMQ89Hu0JXdAodUtGk a5hA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:mime-version:in-reply-to:references:date :message-id:subject:from:to:cc:content-type; bh=cU3Ht0C5f6v3qQt5Z2LLH7BXA49Ea6D5VS/5ITDqqdU=; b=WL5cphyj9p2dIjW6e1HvNNrJvfeNFb8EXV1xNL9q/qEfrDMWivYB/gfohzIKzvzdBv +ICrMumDEiv4Z61FbQCJ00fxS5NjYLol760/WBDGGFHT79uPoLTcNwF7W5Dz1Wt2zlnB qObSaNI3J4xqyxDeGRFiTKhrjWBZkCDPuQ5Z4Ab1paU75Mjv0dwNlyDDgPcmde7W3Qne A3rMKPVSTtyySXrNV5rhK5FV1sNeR/FoVZWI1rPy0dWT9T9VyYlvi/P8yA7GvE1EHZ08 5w9xK1n8tsAwf0X3aLHo47YbmOJBYpASbLPLimJM/sp9xIi4NSBgjqwLrNRlE30Ys42q RpIg== X-Gm-Message-State: AG10YOQCK/aKfXiOSqf/dsdV2j4xRP9WJJitvBi0rHdWkuOnQuSxHnbF+JssDnhFS09ZU9CXBe/F4UVitVTbVkSv MIME-Version: 1.0 X-Received: by 10.28.228.87 with SMTP id b84mr25883753wmh.81.1453847514708; Tue, 26 Jan 2016 14:31:54 -0800 (PST) Received: by 10.194.82.6 with HTTP; Tue, 26 Jan 2016 14:31:54 -0800 (PST) In-Reply-To: <56A7F31C.3030209@FreeBSD.org> References: <56A7F31C.3030209@FreeBSD.org> Date: Tue, 26 Jan 2016 23:31:54 +0100 Message-ID: Subject: Re: Hot-Plug PCIe Support From: Oliver Pinter To: freebsd-hackers@freebsd.org Cc: freebsd-current@freebsd.org, freebsd-arch@freebsd.org, jmg@freebsd.org Content-Type: text/plain; charset=UTF-8 X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.20 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 26 Jan 2016 22:31:56 -0000 On 1/26/16, Eric van Gyzen wrote: > FreeBSD Folks: > > I am currently scoping the effort to add hot-plug PCIe support to > FreeBSD. Is anyone else currently working on this or aware of any > design, code, or other effort available outside the tree? > > FYI, here are perhaps the most interesting references I could find: > > https://wiki.freebsd.org/PCIHotplug > > https://wiki.freebsd.org/IdeasPage#Implementing_PCI-Hotplug_and_ExpressCard_support > > https://lists.freebsd.org/pipermail/freebsd-current/2015-April/055290.html > > https://lists.freebsd.org/pipermail/freebsd-ia32/2010-February/date.html > > Please reply on freebsd-hackers@FreeBSD.org to minimize cross-posting. > > Thanks in advance. Hi! Added John-Mark to the CC, if I'm not wrong, I stared to play with them. > > Eric > _______________________________________________ > freebsd-current@freebsd.org mailing list > https://lists.freebsd.org/mailman/listinfo/freebsd-current > To unsubscribe, send any mail to "freebsd-current-unsubscribe@freebsd.org" > From owner-freebsd-hackers@freebsd.org Wed Jan 27 01:58:40 2016 Return-Path: Delivered-To: freebsd-hackers@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 39F25A6E132; Wed, 27 Jan 2016 01:58:40 +0000 (UTC) (envelope-from adrian.chadd@gmail.com) Received: from mail-io0-x235.google.com (mail-io0-x235.google.com [IPv6:2607:f8b0:4001:c06::235]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (Client CN "smtp.gmail.com", Issuer "Google Internet Authority G2" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 07CA91E9E; Wed, 27 Jan 2016 01:58:40 +0000 (UTC) (envelope-from adrian.chadd@gmail.com) Received: by mail-io0-x235.google.com with SMTP id f81so4189157iof.0; Tue, 26 Jan 2016 17:58:40 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :cc:content-type; bh=7SX96HW3bKGb9Rngz1txKYWjJA1r98yiO/njSAL+Lwc=; b=rORGBnJEE0zkaeL6/TkzJnTQivMRso7fikBQO00Ec8tCf8WHHYQA6uXibuT5grivLH CK5niSZOLhvdSaKwMXpPcWDfDOuPGhrS2YmzVBSsAm7z3R7611JBObecozlQnYj1jRUs jcJpLvJERC9CjPhTnzXJ8SpvZBxmmPIj4AeflIMtZin/oXXpvVCNT1vweqXOqbOstMTz WKqRIM5NNtpAGOA7O4jHRaNztJPppFKZyVctIab8B3uN2b9WEeqMaO13wN6iaFgprpG6 oLpGwXeFGgsQC6zzZLaxx6m1a0PU/p9xy+e+XMm8RI5Diwt12omu3QvE8nYiCh31Za8n 9Vvw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:mime-version:in-reply-to:references:date :message-id:subject:from:to:cc:content-type; bh=7SX96HW3bKGb9Rngz1txKYWjJA1r98yiO/njSAL+Lwc=; b=giCv5VtDc0L7wIdbADT3uhBOWcwx2Xt+eqAYKCQjfmtNVPKbTrlIxQNRl7w2GPd/uu LdD+cRs3XijjPy72Q7VdbGn0g5W/oNjPUcxQmPPfjJ+o+t/rZYLgiXVqdgclpSTdoBnw af2ULw/IvkbWXUkog9Qvd7fcwduZgVoc3f+9uqi14KaYgS+MhqTNq1TV7y6QJ7LaZs5m nyH4Y+8rooWDDBRk5k/3Bf1JL+nk/igXWhLah30tI3mqHbmrrCEWsB2Fr/FBgo8zZ+6b tU+ycfKi/kzNX/GZxbTvrBFLRsLP71ctRr1cC3QUW9paX+ulS7K29ukFIijfAH4V0Ifz AwJg== X-Gm-Message-State: AG10YOTXA9q4Fotwva7auxPVsK0ZfYPMV07Yr/7LKlAclYmRODYCwBW5ReTw0vj7fHhqkZHAOC1HCNvc0iAQBw== MIME-Version: 1.0 X-Received: by 10.107.10.217 with SMTP id 86mr25091254iok.75.1453859919407; Tue, 26 Jan 2016 17:58:39 -0800 (PST) Received: by 10.36.121.16 with HTTP; Tue, 26 Jan 2016 17:58:39 -0800 (PST) In-Reply-To: <56A7F31C.3030209@FreeBSD.org> References: <56A7F31C.3030209@FreeBSD.org> Date: Tue, 26 Jan 2016 17:58:39 -0800 Message-ID: Subject: Re: Hot-Plug PCIe Support From: Adrian Chadd To: "freebsd-hackers@freebsd.org" Cc: freebsd-current , "freebsd-arch@freebsd.org" Content-Type: text/plain; charset=UTF-8 X-Mailman-Approved-At: Wed, 27 Jan 2016 03:36:34 +0000 X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.20 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 27 Jan 2016 01:58:40 -0000 please grab the pciehp work that jmg has done and push it along to completion. Pretty please in fact. -a On 26 January 2016 at 14:28, Eric van Gyzen wrote: > FreeBSD Folks: > > I am currently scoping the effort to add hot-plug PCIe support to > FreeBSD. Is anyone else currently working on this or aware of any > design, code, or other effort available outside the tree? > > FYI, here are perhaps the most interesting references I could find: > > https://wiki.freebsd.org/PCIHotplug > > https://wiki.freebsd.org/IdeasPage#Implementing_PCI-Hotplug_and_ExpressCard_support > > https://lists.freebsd.org/pipermail/freebsd-current/2015-April/055290.html > > https://lists.freebsd.org/pipermail/freebsd-ia32/2010-February/date.html > > Please reply on freebsd-hackers@FreeBSD.org to minimize cross-posting. > > Thanks in advance. > > Eric > _______________________________________________ > freebsd-current@freebsd.org mailing list > https://lists.freebsd.org/mailman/listinfo/freebsd-current > To unsubscribe, send any mail to "freebsd-current-unsubscribe@freebsd.org" From owner-freebsd-hackers@freebsd.org Wed Jan 27 06:21:47 2016 Return-Path: Delivered-To: freebsd-hackers@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 5C694A6F7ED for ; Wed, 27 Jan 2016 06:21:47 +0000 (UTC) (envelope-from araujobsdport@gmail.com) Received: from mail-oi0-x22c.google.com (mail-oi0-x22c.google.com [IPv6:2607:f8b0:4003:c06::22c]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (Client CN "smtp.gmail.com", Issuer "Google Internet Authority G2" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 2480E1100 for ; Wed, 27 Jan 2016 06:21:47 +0000 (UTC) (envelope-from araujobsdport@gmail.com) Received: by mail-oi0-x22c.google.com with SMTP id p187so119288049oia.2 for ; Tue, 26 Jan 2016 22:21:47 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:reply-to:date:message-id:subject:from:to:content-type; bh=+W5zigTWoBRmKANIZ5bfq1WqG/K8qusJvqcq2YKd6gM=; b=dOSyKWscL3LtBHskIu0wk2C+ySiLkMlPs5JHJ8VoMx80ltQbrGs+Rs2oDvQYMa3NOS JzSpFqST9zBnzTYzhBGEcvE73/bzH2akvADnV4v1GZ9l0erN3Rbw4LqqQJY25Tulw/SI Y6A23DxlbSVFR62ah1vHBM8FJi6fszKHSEF1SZh4kLn5Qh6yaGlTznUoYWD0Kks/HpNt HK8Lwb/5MyfBoA7mNiUlgnfUzEiajsAZG/nqNbubjqXlAFb4NZqDY6I1UazonXepIO/l aitLB+dc6UiQfBMSkerFEz4kpELwxW1/H1AilJHhIiTbtTXVvOFtO4bksQ91WmUoqKlJ Jsqw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:mime-version:reply-to:date:message-id:subject :from:to:content-type; bh=+W5zigTWoBRmKANIZ5bfq1WqG/K8qusJvqcq2YKd6gM=; b=PQU/Q600jukyPcH9T6FcYdMsTt3vUC7VIuM3WKIAabI2OkI9QHdhC6PMSwdxJEvf2Z zZP42DGzccZe0tJ6TPa76SAsA/vRTX5duJHBL27W5T77yStHjoYUNNQKFmSisWAB436n pJBod3mkNv4LBbc2ES2LP0XVTYV64+JfnMRHbknwcrK4skJx+2Ez3/boa7Qb0PNdFuah Q1CWgudmOeLVMsxF9rm546SRbxor7IuuO3RJDWLvRSIqUlzcSTBnQ1AOguJ8o0CCjUkn UqM56uE0lo7GfLTp7CugxxlXEugCCr3uAxXHq+8Shy1P/qfZR/rwS3BLeMrVciCcI4A7 7AUw== X-Gm-Message-State: AG10YOSWKtMN2eolsFQn0r82ELCSn/HJ8jgIS39Xf+p/DsLLwZl2mtE1clR3UWN1CRqHcc7Z6REzNjJ2JKdTrw== MIME-Version: 1.0 X-Received: by 10.202.197.82 with SMTP id v79mr2970259oif.60.1453875706292; Tue, 26 Jan 2016 22:21:46 -0800 (PST) Received: by 10.182.40.194 with HTTP; Tue, 26 Jan 2016 22:21:46 -0800 (PST) Reply-To: araujo@FreeBSD.org Date: Wed, 27 Jan 2016 14:21:46 +0800 Message-ID: Subject: syslogd(8) with OOM Killer protection From: Marcelo Araujo To: freebsd-hackers@freebsd.org Content-Type: text/plain; charset=UTF-8 X-Content-Filtered-By: Mailman/MimeDel 2.1.20 X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.20 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 27 Jan 2016 06:21:47 -0000 Hi guys, I would like to know your opinion about this REVIEW[1]. The basic idea is protect by default the syslogd(8) against been killed by OOM with an option to disable the protection. Some people like the idea, other people would prefer something more global where we can protect any daemon by the discretion of our choice. Thoughts? [1] https://reviews.freebsd.org/D4973 Best, -- -- Marcelo Araujo (__)araujo@FreeBSD.org \\\'',)http://www.FreeBSD.org \/ \ ^ Power To Server. .\. /_) From owner-freebsd-hackers@freebsd.org Wed Jan 27 06:33:10 2016 Return-Path: Delivered-To: freebsd-hackers@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 0B8BFA6FDBC for ; Wed, 27 Jan 2016 06:33:10 +0000 (UTC) (envelope-from wlosh@bsdimp.com) Received: from mail-qg0-x233.google.com (mail-qg0-x233.google.com [IPv6:2607:f8b0:400d:c04::233]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (Client CN "smtp.gmail.com", Issuer "Google Internet Authority G2" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id BE7421D90 for ; Wed, 27 Jan 2016 06:33:09 +0000 (UTC) (envelope-from wlosh@bsdimp.com) Received: by mail-qg0-x233.google.com with SMTP id b35so157755221qge.0 for ; Tue, 26 Jan 2016 22:33:09 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=bsdimp-com.20150623.gappssmtp.com; s=20150623; h=mime-version:sender:in-reply-to:references:date:message-id:subject :from:to:cc:content-type; bh=2tLKvgc5Lqk/nnUVNMtpszlr+5Hkfi6JQw6Fgperrqs=; b=n8G30lpPK7j7ZonD7r+nh3xt9mWdJYR/H3mAD1WVVq6sUGOtR+BsJ171vrBzM+Mnra ixmjQQnem40sc5I3PAase/JuRjGcbKjrvtt3XW6bEdLvdzXixTR+S34hAHW177n8De/Y Em83hNpO6xE6qeOa/xuh90bFiuRWzFBk8Vu0+oBk1QVwG2awLkgRvosEwMm72bX0/8EG u6R5RgkzIYYDK2oc/KO52T05mA/tlGqimu81PiZ3ydTpT568kdXp/nbJEO7ITTLx2wBy PP2F3EmSPDK6qa4ZQb5PRmbfInF4zqV7nf/g0R3/QPsiteHGByOYZxeNIjzdJzLGHdOw zPgA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:mime-version:sender:in-reply-to:references:date :message-id:subject:from:to:cc:content-type; bh=2tLKvgc5Lqk/nnUVNMtpszlr+5Hkfi6JQw6Fgperrqs=; b=ILr5605ObxjYwBwsPiAjyidKxfzSrZPwpD0HQYtw116ni05IPrPxOW+bPPQeGErVaJ LgxwHkjLh0D5jXLogKEpfvtrdnomaP6l998hkeledhjodcPYFTwDWJqu6q0QxfnRSYwP gvVynRkebpnC1zljSxozjfdnPucq40RR/2hWTv48vd3ZUxpFkClbX8cg0g34vNPvZG2b c2nTAlg/ZUeB1O95CWN7l59L+9hNDbzvJfHNVX+blCpT/P7sFdJYQxMXKQrMTpswTskd IeN9vtrkwacTQiteXQzZdzqF0gvjV2lfxok/J5XAvVLED8aepRUMexxb65BlqZYWTfjl eIbw== X-Gm-Message-State: AG10YOQ79a5goukezG1HiHtKfCdgF560ZcVPnkXnK0Bz/IRFf8/zUfnC4hrEAmNtb9b/eXVIK4isfXtk1ab8Aw== MIME-Version: 1.0 X-Received: by 10.140.109.247 with SMTP id l110mr33079979qgf.52.1453876388814; Tue, 26 Jan 2016 22:33:08 -0800 (PST) Sender: wlosh@bsdimp.com Received: by 10.140.30.166 with HTTP; Tue, 26 Jan 2016 22:33:08 -0800 (PST) X-Originating-IP: [50.253.99.174] In-Reply-To: References: <56A7F31C.3030209@FreeBSD.org> Date: Tue, 26 Jan 2016 23:33:08 -0700 X-Google-Sender-Auth: 7-XXkam3y4UwcxutlMyEoBYDEAk Message-ID: Subject: Re: Hot-Plug PCIe Support From: Warner Losh To: Adrian Chadd Cc: "freebsd-hackers@freebsd.org" , freebsd-current , "freebsd-arch@freebsd.org" Content-Type: text/plain; charset=UTF-8 X-Content-Filtered-By: Mailman/MimeDel 2.1.20 X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.20 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 27 Jan 2016 06:33:10 -0000 It's mostly done, but needs a careful review by PCI domain experts. I've been doing it a little at a time, but have been crunched for time. Since $DAYJOB doesn't care about hot plug, it's a lower priority than all the things related or semi-related to it. Warner On Tue, Jan 26, 2016 at 6:58 PM, Adrian Chadd wrote: > please grab the pciehp work that jmg has done and push it along to > completion. Pretty please in fact. > > > -a > > > On 26 January 2016 at 14:28, Eric van Gyzen wrote: > > FreeBSD Folks: > > > > I am currently scoping the effort to add hot-plug PCIe support to > > FreeBSD. Is anyone else currently working on this or aware of any > > design, code, or other effort available outside the tree? > > > > FYI, here are perhaps the most interesting references I could find: > > > > https://wiki.freebsd.org/PCIHotplug > > > > > https://wiki.freebsd.org/IdeasPage#Implementing_PCI-Hotplug_and_ExpressCard_support > > > > > https://lists.freebsd.org/pipermail/freebsd-current/2015-April/055290.html > > > > https://lists.freebsd.org/pipermail/freebsd-ia32/2010-February/date.html > > > > Please reply on freebsd-hackers@FreeBSD.org to minimize cross-posting. > > > > Thanks in advance. > > > > Eric > > _______________________________________________ > > freebsd-current@freebsd.org mailing list > > https://lists.freebsd.org/mailman/listinfo/freebsd-current > > To unsubscribe, send any mail to " > freebsd-current-unsubscribe@freebsd.org" > _______________________________________________ > freebsd-arch@freebsd.org mailing list > https://lists.freebsd.org/mailman/listinfo/freebsd-arch > To unsubscribe, send any mail to "freebsd-arch-unsubscribe@freebsd.org" > From owner-freebsd-hackers@freebsd.org Wed Jan 27 07:11:15 2016 Return-Path: Delivered-To: freebsd-hackers@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 1242CA6E9F5 for ; Wed, 27 Jan 2016 07:11:15 +0000 (UTC) (envelope-from allanjude@freebsd.org) Received: from mx1.scaleengine.net (mx1.scaleengine.net [209.51.186.6]) by mx1.freebsd.org (Postfix) with ESMTP id E25931072 for ; Wed, 27 Jan 2016 07:11:14 +0000 (UTC) (envelope-from allanjude@freebsd.org) Received: from [10.1.1.2] (unknown [10.1.1.2]) (Authenticated sender: allanjude.freebsd@scaleengine.com) by mx1.scaleengine.net (Postfix) with ESMTPSA id 452D0D3A7 for ; Wed, 27 Jan 2016 07:11:08 +0000 (UTC) Subject: Re: syslogd(8) with OOM Killer protection To: freebsd-hackers@freebsd.org References: From: Allan Jude Message-ID: <56A86D91.3040709@freebsd.org> Date: Wed, 27 Jan 2016 02:11:13 -0500 User-Agent: Mozilla/5.0 (Windows NT 6.1; WOW64; rv:38.0) Gecko/20100101 Thunderbird/38.5.1 MIME-Version: 1.0 In-Reply-To: Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="tlkENKVR0oTkP9DcHuRCWUJmuqrquIRh4" X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.20 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 27 Jan 2016 07:11:15 -0000 This is an OpenPGP/MIME signed message (RFC 4880 and 3156) --tlkENKVR0oTkP9DcHuRCWUJmuqrquIRh4 Content-Type: text/plain; charset=windows-1252 Content-Transfer-Encoding: quoted-printable On 2016-01-27 01:21, Marcelo Araujo wrote: > Hi guys, >=20 > I would like to know your opinion about this REVIEW[1]. > The basic idea is protect by default the syslogd(8) against been killed= by > OOM with an option to disable the protection. >=20 > Some people like the idea, other people would prefer something more glo= bal > where we can protect any daemon by the discretion of our choice. >=20 > Thoughts? >=20 >=20 > [1] https://reviews.freebsd.org/D4973 >=20 >=20 > Best, >=20 I do like the idea of generalizing it, say via rc.subr So you can just do: someapp_protect=3DYES (and maybe syslogd has this enabled by default in /etc/defaults/rc.conf) and it prefixes the start command with protect -i.= --=20 Allan Jude --tlkENKVR0oTkP9DcHuRCWUJmuqrquIRh4 Content-Type: application/pgp-signature; name="signature.asc" Content-Description: OpenPGP digital signature Content-Disposition: attachment; filename="signature.asc" -----BEGIN PGP SIGNATURE----- Version: GnuPG v2.0.22 (MingW32) iQIcBAEBAgAGBQJWqG2RAAoJEBmVNT4SmAt+aZ4QAJOE2Y/u2Jo/DBMjOPhy1rXq EvzhwvwIHiE+0tK7u0oBSG46/E1uugN/ugz8Yo9SekeKHdXQEXHnCls+/KulOaJ9 lYvc4fiY/U0N8qzqaIeurldt33ZNgGneORL+slgWyU/amr2eLC/en5DQZX1d9/rQ aSceY8JDZ8z+1sxZlEA/9ujxhDynh7IsD3xhHlhBvHNCYcD92BuRPtStRrAv55Ul QYmRlRdGnXDTTRZeZewZ2BWMu5Kbyx3czrebZEaUk/bJOH9Mvec1khOm1IG6fJid OKxd5dihsOpNut6pmogsIWHxXmr/J9FOOK7hb/OxNjQWy6IFxgqwW2pbIg35PX57 kn6Q/FnAnP38ZGSMrPTZBDcw/T4a17U0wFhhlGaGQUgIfI/JG0eGbR4qK+EvHdE7 V8FPuimVLAAqDsJQ52skxQZCqvb5+x5dXfOQiZtxpiCy9+QAUyLmTviAEg1tFlfu OTA8eNLvwelR45nn85B0NGJ6ufxSX63UFkatEqGLVLcx/32+s5qim6CLZmRvrIKS TIxdIBed2rrG6L9wzFxbGm1OjwFsvLGXQm2TK2OfiV3xV8ndswUdNTPZKWo8MIc5 zLYbFqsYRmuZb8lQg/SDUlP0b4UBBMar2MHKNsV+vmSefoHkYZk9sm3M4uAioN37 2ueSBZTsmY6ECI5brUKB =Uux7 -----END PGP SIGNATURE----- --tlkENKVR0oTkP9DcHuRCWUJmuqrquIRh4-- From owner-freebsd-hackers@freebsd.org Wed Jan 27 07:28:56 2016 Return-Path: Delivered-To: freebsd-hackers@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id DB88AA6F281 for ; Wed, 27 Jan 2016 07:28:55 +0000 (UTC) (envelope-from baptiste.daroussin@gmail.com) Received: from mail-wm0-x22a.google.com (mail-wm0-x22a.google.com [IPv6:2a00:1450:400c:c09::22a]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (Client CN "smtp.gmail.com", Issuer "Google Internet Authority G2" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 7F2F11DCF; Wed, 27 Jan 2016 07:28:55 +0000 (UTC) (envelope-from baptiste.daroussin@gmail.com) Received: by mail-wm0-x22a.google.com with SMTP id 123so138306658wmz.0; Tue, 26 Jan 2016 23:28:55 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=sender:date:from:to:cc:subject:message-id:references:mime-version :content-type:content-disposition:in-reply-to:user-agent; bh=GDocPPXAv2nwOF+m+AhT2b/3Ty1KESzrhHKngEuqD6c=; b=MDenLqt/DuEQvi8wM76LAnO6W4mcCLybRyt1QLY7wJCpROWrPbsbMd7pcQxI4oODUN kKAx2bqNHWp+T/AiqmnpWVb7tMko9iHEPCeVNZ3I98j0n6FaG9jo/vcYcrtW+NETP3/k LC6k9JX8wSOo83FdjwBpGHfUGARwykrBKY2C3aMaE7oEhIGKfH9DE7nc/CSjqdBu3g4U Y8iIJHj1dkjv9DDbHp6WhXZNZ4ruM/CLeokePfbPDdhr0Zhlz8iQxIic4bZ0VM+Zhaim tmi2vcMn/b4Gv11ZnFK5VORECPywHoD6H4YiAFV4CkwrEdhSaDwj4QtrRJHJa1kzjx2d VPqg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:sender:date:from:to:cc:subject:message-id :references:mime-version:content-type:content-disposition :in-reply-to:user-agent; bh=GDocPPXAv2nwOF+m+AhT2b/3Ty1KESzrhHKngEuqD6c=; b=mLtiSeJEtA/48V+2+nntatIxeVxHpkwjAb73kjjxoMSnwtNS0HD8bAkZpDp5dV3n9V qc6MVjRlcPDFLqU6qv/SY7sAk6/drDWZ8+6EVwVTmLXg8wrVPiDhnSSNL3XxEeM8S6S6 Z+mCoo550F8qWr36IGiXsHj3X3cN1m18nwOVQgsKUm9hajlqu36B71FegLOGkDz45A4d OYIKJ1y78v4r3zc/16HjRyJ0mH/jo8Ymtfjq6VOjHKRTx/KA+tN0qUD5ktd26ra4A0VP 9UvIOSZf848Yk8Y8a4e5RSqhBwalZwiu9l9NyygoO1JNO84l/vFKf71WryO1JZjtPPAv XNaA== X-Gm-Message-State: AG10YOT79pMHJz/3x2fOw0kW/t1NxIw0IrelJX1P51VTbrhL1+j0HSlGeEQk+lxEe9Opeg== X-Received: by 10.28.90.67 with SMTP id o64mr26947008wmb.38.1453879733598; Tue, 26 Jan 2016 23:28:53 -0800 (PST) Received: from ivaldir.etoilebsd.net ([2001:41d0:8:db4c::1]) by smtp.gmail.com with ESMTPSA id z127sm6854749wme.2.2016.01.26.23.28.52 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Tue, 26 Jan 2016 23:28:52 -0800 (PST) Sender: Baptiste Daroussin Date: Wed, 27 Jan 2016 08:28:50 +0100 From: Baptiste Daroussin To: Allan Jude Cc: freebsd-hackers@freebsd.org Subject: Re: syslogd(8) with OOM Killer protection Message-ID: <20160127072850.GG35911@ivaldir.etoilebsd.net> References: <56A86D91.3040709@freebsd.org> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha256; protocol="application/pgp-signature"; boundary="zGQnqpIoxlsbsOfg" Content-Disposition: inline In-Reply-To: <56A86D91.3040709@freebsd.org> User-Agent: Mutt/1.5.24 (2015-08-30) X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.20 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 27 Jan 2016 07:28:56 -0000 --zGQnqpIoxlsbsOfg Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Wed, Jan 27, 2016 at 02:11:13AM -0500, Allan Jude wrote: > On 2016-01-27 01:21, Marcelo Araujo wrote: > > Hi guys, > >=20 > > I would like to know your opinion about this REVIEW[1]. > > The basic idea is protect by default the syslogd(8) against been killed= by > > OOM with an option to disable the protection. > >=20 > > Some people like the idea, other people would prefer something more glo= bal > > where we can protect any daemon by the discretion of our choice. > >=20 > > Thoughts? > >=20 > >=20 > > [1] https://reviews.freebsd.org/D4973 > >=20 > >=20 > > Best, > >=20 >=20 > I do like the idea of generalizing it, say via rc.subr >=20 > So you can just do: >=20 > someapp_protect=3DYES (and maybe syslogd has this enabled by default in > /etc/defaults/rc.conf) and it prefixes the start command with protect -i. >=20 I do support that idea, I think it is will be useful to more people. Bapt --zGQnqpIoxlsbsOfg Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- Version: GnuPG v2 iQIcBAEBCAAGBQJWqHGyAAoJEGOJi9zxtz5a8CIP/iYPjERo7LRI9bYP7voFhAVK M1kRJ2Cu1nC47xLBZv4Nn5I4rYluh+yl2rNW51rNtQc2FsaB9thpbI+VjyLHrbcs X7s2bLRIPzK/y6Bf4aNdIrjDINcM+cHcEY4us5lGn8gupB9m1MTEyaaY1FibEAd0 PbW3ge27b4znieGsftUT4sHPnTqEuErVoLZtJ6tdQoSvcmWBbNq8enEUf0CEb5L4 NDS59e7XWvsf2GCItLKnWN0bzo9ifhej0u87yl4fx7duSAWy5IBZWP4Q+m/B0rTd +04S8JkTJWSpHFfZdBZnQQx1oov/YVeKpxBN4mNrkFbrxGT3+NBqJmngyJNt5HRY NalYqZfs3NW/BeBcoHR0FjRvWdkIK7lSC5HQZhH4Y7ZqKo//UeWI9w4lNgV+hiA4 byYAJH38bW37eMQpVUi5+adDgCB0VWYAbghQEYVi+e5NFfNT5dAXT+gA5sJcmH39 sFe6Ru/QOPzQJFGeHEZ1Lu+S4NklQ9jhQ/EpJOCQ3y/JjF6NXg1pC4DvQECRgU/y YCiByGTQ9MgaTqhN3McaHpGxGN2yGidM3rdXSUoJPW87Ot+CfvBGakCvn2V3AGsW 4BD4rjlfzTZJxqfYEIislNK8RZdok3S4q1KW2mUWd10UostQlJzKUaCKW873C827 nS5nxTGSkPPNnmUwgYaT =nLr1 -----END PGP SIGNATURE----- --zGQnqpIoxlsbsOfg-- From owner-freebsd-hackers@freebsd.org Wed Jan 27 08:27:08 2016 Return-Path: Delivered-To: freebsd-hackers@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id A24C9A6EEA3 for ; Wed, 27 Jan 2016 08:27:08 +0000 (UTC) (envelope-from timp87@gmail.com) Received: from mail-wm0-x22b.google.com (mail-wm0-x22b.google.com [IPv6:2a00:1450:400c:c09::22b]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (Client CN "smtp.gmail.com", Issuer "Google Internet Authority G2" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 3CC7617EB; Wed, 27 Jan 2016 08:27:08 +0000 (UTC) (envelope-from timp87@gmail.com) Received: by mail-wm0-x22b.google.com with SMTP id n5so14302523wmn.0; Wed, 27 Jan 2016 00:27:08 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :cc:content-type; bh=+ox8q0n/qjHkfPGOcBDB4WD1QwQiRJgcgKtU0azXeag=; b=dh0gVa6/Irk7iiqgEku2i5g54+fiswPmpTWCHHGf7Fo1GcZ8m+Yp9f/2v16EpFNNRD LheQUkCrO3Ku9WfKps/OhXCoWqfYLiI4jxbnFFg+F1bVG6YEAGrpJCaNw7jP752uTfoE CwjBv1K2IJis/7wmFlbGtWr9CxHpDeXj+dDEL1G8DHlEjtp9fSNPDT61//s51YBKStkI M7IXhcBeL4N1El8WtEZig6rBpRufN12LB+uAqdOpER44im/UgjH31kZtnAtkkVmIojr5 7aYQKNEA1KsFWLIuyro7tXwvfOIJGoO3P/Xcu6fo51tpVT3pkV5MWmoJl/Qdhc+bVVmt G/YA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:mime-version:in-reply-to:references:date :message-id:subject:from:to:cc:content-type; bh=+ox8q0n/qjHkfPGOcBDB4WD1QwQiRJgcgKtU0azXeag=; b=Ku0sfTEXAa9kKNVxZhK+k9/bWSCZO3Vc7cQORw8wZgC1a3vHrSV0T5LM1L0GPZvFgf YwyyHm0ib+bdRhZfHJdsEum1BXl7iEnvJ4PInQc60Rqaz6pCkD+hLFbAPSKdIewMnF5X qYQzJrp7tLPfnbPMemXbc0MrThAJHd4+yzIIhUE0/38ftAN1gwPFb3LciwnOjB40yAjp xI4PpWocf9hUobaxCI0Z50tMLm8kvfNctFVkzKu0o4L+laoLoteD17HDtiz6EOlyxV+U FINnbuHXZI+z067jBGIX0BPlYNy4GItGPSK9jD1mzC/ZvuvH1NDRJJVJoLX40V6mLpcX HZ4g== X-Gm-Message-State: AG10YOScd3GSxpw3HMwq7vfcAzStW+vaTQnCsCQlt1I6jU+NbOeN3rVO3dXAAuvrsq/blw4S0Erz2v1bs5ZgEA== MIME-Version: 1.0 X-Received: by 10.194.161.166 with SMTP id xt6mr29996823wjb.98.1453883226735; Wed, 27 Jan 2016 00:27:06 -0800 (PST) Received: by 10.28.89.129 with HTTP; Wed, 27 Jan 2016 00:27:06 -0800 (PST) In-Reply-To: <20160127072850.GG35911@ivaldir.etoilebsd.net> References: <56A86D91.3040709@freebsd.org> <20160127072850.GG35911@ivaldir.etoilebsd.net> Date: Wed, 27 Jan 2016 11:27:06 +0300 Message-ID: Subject: Re: syslogd(8) with OOM Killer protection From: Pavel Timofeev To: Baptiste Daroussin Cc: Allan Jude , freebsd-hackers@freebsd.org Content-Type: text/plain; charset=UTF-8 X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.20 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 27 Jan 2016 08:27:08 -0000 2016-01-27 10:28 GMT+03:00 Baptiste Daroussin : > On Wed, Jan 27, 2016 at 02:11:13AM -0500, Allan Jude wrote: >> On 2016-01-27 01:21, Marcelo Araujo wrote: >> > Hi guys, >> > >> > I would like to know your opinion about this REVIEW[1]. >> > The basic idea is protect by default the syslogd(8) against been killed by >> > OOM with an option to disable the protection. >> > >> > Some people like the idea, other people would prefer something more global >> > where we can protect any daemon by the discretion of our choice. >> > >> > Thoughts? >> > >> > >> > [1] https://reviews.freebsd.org/D4973 >> > >> > >> > Best, >> > >> >> I do like the idea of generalizing it, say via rc.subr >> >> So you can just do: >> >> someapp_protect=YES (and maybe syslogd has this enabled by default in >> /etc/defaults/rc.conf) and it prefixes the start command with protect -i. >> > I do support that idea, I think it is will be useful to more people. > > Bapt I'm one that people. I find this generilized way very usefull. I have least a couple of daemons that it'd never wanted to be OOMed on my machines. Besides syslogd, I'd protect sshd and even crond in some cases. From owner-freebsd-hackers@freebsd.org Wed Jan 27 10:35:41 2016 Return-Path: Delivered-To: freebsd-hackers@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 93AAAA6F9A2 for ; Wed, 27 Jan 2016 10:35:41 +0000 (UTC) (envelope-from crest@rlwinm.de) Received: from smtp.rlwinm.de (smtp.rlwinm.de [IPv6:2a01:4f8:201:31ef::e]) (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 630551B2D for ; Wed, 27 Jan 2016 10:35:41 +0000 (UTC) (envelope-from crest@rlwinm.de) Received: from crest.local (unknown [87.253.189.132]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.rlwinm.de (Postfix) with ESMTPSA id ACFA6F550 for ; Wed, 27 Jan 2016 11:35:38 +0100 (CET) Subject: Re: syslogd(8) with OOM Killer protection To: freebsd-hackers@freebsd.org References: <56A86D91.3040709@freebsd.org> <20160127072850.GG35911@ivaldir.etoilebsd.net> From: Jan Bramkamp Message-ID: <56A89D7A.8080906@rlwinm.de> Date: Wed, 27 Jan 2016 11:35:38 +0100 User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.11; rv:38.0) Gecko/20100101 Thunderbird/38.5.1 MIME-Version: 1.0 In-Reply-To: Content-Type: text/plain; charset=windows-1252; format=flowed Content-Transfer-Encoding: 7bit X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.20 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 27 Jan 2016 10:35:41 -0000 On 27/01/16 09:27, Pavel Timofeev wrote: > 2016-01-27 10:28 GMT+03:00 Baptiste Daroussin : >> On Wed, Jan 27, 2016 at 02:11:13AM -0500, Allan Jude wrote: >>> On 2016-01-27 01:21, Marcelo Araujo wrote: >>>> Hi guys, >>>> >>>> I would like to know your opinion about this REVIEW[1]. >>>> The basic idea is protect by default the syslogd(8) against been killed by >>>> OOM with an option to disable the protection. >>>> >>>> Some people like the idea, other people would prefer something more global >>>> where we can protect any daemon by the discretion of our choice. >>>> >>>> Thoughts? >>>> >>>> >>>> [1] https://reviews.freebsd.org/D4973 >>>> >>>> >>>> Best, >>>> >>> >>> I do like the idea of generalizing it, say via rc.subr >>> >>> So you can just do: >>> >>> someapp_protect=YES (and maybe syslogd has this enabled by default in >>> /etc/defaults/rc.conf) and it prefixes the start command with protect -i. >>> >> I do support that idea, I think it is will be useful to more people. >> >> Bapt > > I'm one that people. I find this generilized way very usefull. > I have least a couple of daemons that it'd never wanted to be OOMed on > my machines. Besides syslogd, I'd protect sshd and even crond in some > cases. I would prefer to implement the a flag keeping cron (and all other base system daemons) from double-forking and run it under a process supervisor like daemontools. From owner-freebsd-hackers@freebsd.org Wed Jan 27 06:32:13 2016 Return-Path: Delivered-To: freebsd-hackers@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 99D44A6FCC9 for ; Wed, 27 Jan 2016 06:32:13 +0000 (UTC) (envelope-from adrian.chadd@gmail.com) Received: from mail-io0-x235.google.com (mail-io0-x235.google.com [IPv6:2607:f8b0:4001:c06::235]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (Client CN "smtp.gmail.com", Issuer "Google Internet Authority G2" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 66AD81D12; Wed, 27 Jan 2016 06:32:13 +0000 (UTC) (envelope-from adrian.chadd@gmail.com) Received: by mail-io0-x235.google.com with SMTP id 1so9135325ion.1; Tue, 26 Jan 2016 22:32:13 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :cc:content-type; bh=SsGwI6wMU4ESaiZVjDby4aYucEjLzJT1NfGjG64ZYp0=; b=ih4lAPz05gPNXAI00v5EanVZWxIVSNWrUrVMariE8R3GaMornvhHpmPDiP8zykBUQ7 MsAIJ31F1YuLWSKNbxfm3VjljEOLFVjYJvfp5igN/xNfUAihebCzUqq6vADOSf89lznU 6veycwjXkR6HN2cr72athre5p9hJ4XKFBzoMoypZJAeU1KKfvFh4iY0I4beQEB4m/QlX ytRFL00ImYIqkNF4EJ3stF+0oZ3nnsAuw4ckKggyDWCXe9Ks9YKG5JlU3YoxGbQ+HlIZ S81euCE+cZv1bQza4ZiGZij1N9v9/uCQEz1gnURPJt1jKG3OGe4y4lJjX8q+rBIJi1oJ bmHQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:mime-version:in-reply-to:references:date :message-id:subject:from:to:cc:content-type; bh=SsGwI6wMU4ESaiZVjDby4aYucEjLzJT1NfGjG64ZYp0=; b=MX8yYRsu3UOac8Xir7f1MwHL6RD2G9rvLkmKU6zwdFHqR73H4J0b9QNujMa4xT/Aom 2th41czGdtB3fAe4rbfv5FPshwtfOExnVECLLl4lHPNy6ktnYLvUW2+9sMRtmBjkKbR1 R10rOM5/o9VJwP4Sceo7f3OgHLSXp6ftsMo4l/6ZlN/uv45awelrYbfXrSYUl1HeFHJQ ocDgq2FgI6F4VdTuS/Jv1JQtqNwMpvlYDaK2DOqAX5Lkn+r8EhbxQK7G9eFy7oplzjk4 mrwqM8QO4XiaePd48wYlSTF7S6GJ7zC1UI7jpiclOZF4/VLJhOOB6mUsC9hXwKu/+yWe 0knw== X-Gm-Message-State: AG10YOQil+F2kLk6kdieaaoCeFGpAY8AZjGk7EVvhWb/DzbljHFaBtV7Qh52KRIZ3ToQZrKgkJhy7O/csnEtsw== MIME-Version: 1.0 X-Received: by 10.107.162.146 with SMTP id l140mr24878041ioe.123.1453876332875; Tue, 26 Jan 2016 22:32:12 -0800 (PST) Received: by 10.36.121.16 with HTTP; Tue, 26 Jan 2016 22:32:12 -0800 (PST) In-Reply-To: References: Date: Tue, 26 Jan 2016 22:32:12 -0800 Message-ID: Subject: Re: syslogd(8) with OOM Killer protection From: Adrian Chadd To: Marcelo Araujo Cc: "freebsd-hackers@freebsd.org" Content-Type: text/plain; charset=UTF-8 X-Mailman-Approved-At: Wed, 27 Jan 2016 12:02:15 +0000 X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.20 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 27 Jan 2016 06:32:13 -0000 I like it,how's it not done via some command line tool that we can run any tool with? -a On 26 January 2016 at 22:21, Marcelo Araujo wrote: > Hi guys, > > I would like to know your opinion about this REVIEW[1]. > The basic idea is protect by default the syslogd(8) against been killed by > OOM with an option to disable the protection. > > Some people like the idea, other people would prefer something more global > where we can protect any daemon by the discretion of our choice. > > Thoughts? > > > [1] https://reviews.freebsd.org/D4973 > > > Best, > -- > > -- > Marcelo Araujo (__)araujo@FreeBSD.org > \\\'',)http://www.FreeBSD.org \/ \ ^ > Power To Server. .\. /_) > _______________________________________________ > freebsd-hackers@freebsd.org mailing list > https://lists.freebsd.org/mailman/listinfo/freebsd-hackers > To unsubscribe, send any mail to "freebsd-hackers-unsubscribe@freebsd.org" From owner-freebsd-hackers@freebsd.org Wed Jan 27 12:07:36 2016 Return-Path: Delivered-To: freebsd-hackers@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id CF7A2A6F782 for ; Wed, 27 Jan 2016 12:07:36 +0000 (UTC) (envelope-from mailinglists@toco-domains.de) Received: from toco-domains.de (mail.toco-domains.de [176.9.39.170]) (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 9913F1EC7; Wed, 27 Jan 2016 12:07:36 +0000 (UTC) (envelope-from mailinglists@toco-domains.de) Received: from [0.0.0.0] (mail.toco-domains.de [IPv6:2a01:4f8:150:50a5::6]) by toco-domains.de (Postfix) with ESMTPA id 6E09C1B22068; Wed, 27 Jan 2016 13:07:28 +0100 (CET) Subject: Re: syslogd(8) with OOM Killer protection To: Pavel Timofeev , Baptiste Daroussin References: <56A86D91.3040709@freebsd.org> <20160127072850.GG35911@ivaldir.etoilebsd.net> Cc: freebsd-hackers@freebsd.org, Allan Jude From: Torsten Zuehlsdorff Message-ID: <56A8B300.5080503@toco-domains.de> Date: Wed, 27 Jan 2016 13:07:28 +0100 User-Agent: Mozilla/5.0 (X11; FreeBSD amd64; rv:38.0) Gecko/20100101 Thunderbird/38.5.0 MIME-Version: 1.0 In-Reply-To: Content-Type: text/plain; charset=windows-1252; format=flowed Content-Transfer-Encoding: 7bit X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.20 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 27 Jan 2016 12:07:36 -0000 On 27.01.2016 09:27, Pavel Timofeev wrote: > 2016-01-27 10:28 GMT+03:00 Baptiste Daroussin : >> On Wed, Jan 27, 2016 at 02:11:13AM -0500, Allan Jude wrote: >>> On 2016-01-27 01:21, Marcelo Araujo wrote: >>>> Hi guys, >>>> >>>> I would like to know your opinion about this REVIEW[1]. >>>> The basic idea is protect by default the syslogd(8) against been killed by >>>> OOM with an option to disable the protection. >>>> >>>> Some people like the idea, other people would prefer something more global >>>> where we can protect any daemon by the discretion of our choice. >>>> >>>> Thoughts? >>>> >>>> >>>> [1] https://reviews.freebsd.org/D4973 >>>> >>>> >>>> Best, >>>> >>> >>> I do like the idea of generalizing it, say via rc.subr >>> >>> So you can just do: >>> >>> someapp_protect=YES (and maybe syslogd has this enabled by default in >>> /etc/defaults/rc.conf) and it prefixes the start command with protect -i. >>> >> I do support that idea, I think it is will be useful to more people. >> >> Bapt > > I'm one that people. I find this generilized way very usefull. > I have least a couple of daemons that it'd never wanted to be OOMed on > my machines. Besides syslogd, I'd protect sshd and even crond in some > cases. I would like a generalized way too. The first i thought to protect is my database. I never want to get it killed. Greetings, Torsten From owner-freebsd-hackers@freebsd.org Wed Jan 27 12:16:10 2016 Return-Path: Delivered-To: freebsd-hackers@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id E543DA6FB66 for ; Wed, 27 Jan 2016 12:16:10 +0000 (UTC) (envelope-from maxim.konovalov@gmail.com) Received: from mp2.macomnet.net (mp2.macomnet.net [195.128.64.6]) (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 6E91412F0; Wed, 27 Jan 2016 12:16:09 +0000 (UTC) (envelope-from maxim.konovalov@gmail.com) Received: from localhost (localhost [127.0.0.1]) by mp2.macomnet.net (8.15.2/8.15.2) with ESMTP id u0RCC0K4036432; Wed, 27 Jan 2016 15:12:00 +0300 (MSK) (envelope-from maxim.konovalov@gmail.com) Date: Wed, 27 Jan 2016 15:12:00 +0300 (MSK) From: Maxim Konovalov To: Pavel Timofeev cc: Baptiste Daroussin , freebsd-hackers@freebsd.org, Allan Jude Subject: Re: syslogd(8) with OOM Killer protection In-Reply-To: Message-ID: References: <56A86D91.3040709@freebsd.org> <20160127072850.GG35911@ivaldir.etoilebsd.net> User-Agent: Alpine 2.20 (BSF 67 2015-01-07) MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII X-Mailman-Approved-At: Wed, 27 Jan 2016 12:33:09 +0000 X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.20 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 27 Jan 2016 12:16:11 -0000 [...] > I'm one that people. I find this generilized way very usefull. > I have least a couple of daemons that it'd never wanted to be OOMed on > my machines. Besides syslogd, I'd protect sshd and even crond in some > cases. While I agree with the generalization idea via protect(1) or similar tool just a sidenote, sshd already has this feature: >From sshd.c: /* Avoid killing the process in high-pressure swapping environments. */ if (!inetd_flag && madvise(NULL, 0, MADV_PROTECT) != 0) debug("madvise(): %.200s", strerror(errno)); -- Maxim Konovalov From owner-freebsd-hackers@freebsd.org Wed Jan 27 14:08:10 2016 Return-Path: Delivered-To: freebsd-hackers@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 1AAE9A6F65E for ; Wed, 27 Jan 2016 14:08:10 +0000 (UTC) (envelope-from ian@freebsd.org) Received: from pmta2.delivery6.ore.mailhop.org (pmta2.delivery6.ore.mailhop.org [54.200.129.228]) (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 F29FD1497 for ; Wed, 27 Jan 2016 14:08:09 +0000 (UTC) (envelope-from ian@freebsd.org) Received: from ilsoft.org (unknown [73.34.117.227]) by outbound2.ore.mailhop.org (Halon Mail Gateway) with ESMTPSA; Wed, 27 Jan 2016 14:09:06 +0000 (UTC) Received: from rev (rev [172.22.42.240]) by ilsoft.org (8.15.2/8.14.9) with ESMTP id u0RE86RR031139; Wed, 27 Jan 2016 07:08:06 -0700 (MST) (envelope-from ian@freebsd.org) Message-ID: <1453903686.42081.32.camel@freebsd.org> Subject: Re: syslogd(8) with OOM Killer protection From: Ian Lepore To: Allan Jude , freebsd-hackers@freebsd.org Date: Wed, 27 Jan 2016 07:08:06 -0700 In-Reply-To: <56A86D91.3040709@freebsd.org> References: <56A86D91.3040709@freebsd.org> Content-Type: text/plain; charset="us-ascii" X-Mailer: Evolution 3.16.5 FreeBSD GNOME Team Port Mime-Version: 1.0 Content-Transfer-Encoding: 7bit X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.20 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 27 Jan 2016 14:08:10 -0000 On Wed, 2016-01-27 at 02:11 -0500, Allan Jude wrote: > On 2016-01-27 01:21, Marcelo Araujo wrote: > > Hi guys, > > > > I would like to know your opinion about this REVIEW[1]. > > The basic idea is protect by default the syslogd(8) against been > > killed by > > OOM with an option to disable the protection. > > > > Some people like the idea, other people would prefer something more > > global > > where we can protect any daemon by the discretion of our choice. > > > > Thoughts? > > > > > > [1] https://reviews.freebsd.org/D4973 > > > > > > Best, > > > > I do like the idea of generalizing it, say via rc.subr > > So you can just do: > > someapp_protect=YES (and maybe syslogd has this enabled by default in > /etc/defaults/rc.conf) and it prefixes the start command with protect > -i. > Maybe the setting could be named *_oomprotect to make it clear what kind of protection is being configured? -- Ian From owner-freebsd-hackers@freebsd.org Wed Jan 27 16:36:59 2016 Return-Path: Delivered-To: freebsd-hackers@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id EAD8AA70409 for ; Wed, 27 Jan 2016 16:36:59 +0000 (UTC) (envelope-from wblock@wonkity.com) Received: from wonkity.com (wonkity.com [67.158.26.137]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client CN "wonkity.com", Issuer "wonkity.com" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id BD4141A75; Wed, 27 Jan 2016 16:36:59 +0000 (UTC) (envelope-from wblock@wonkity.com) Received: from wonkity.com (localhost [127.0.0.1]) by wonkity.com (8.15.2/8.15.2) with ESMTPS id u0RGawh2064067 (version=TLSv1.2 cipher=DHE-RSA-AES256-GCM-SHA384 bits=256 verify=NO); Wed, 27 Jan 2016 09:36:58 -0700 (MST) (envelope-from wblock@wonkity.com) Received: from localhost (wblock@localhost) by wonkity.com (8.15.2/8.15.2/Submit) with ESMTP id u0RGawC2064064; Wed, 27 Jan 2016 09:36:58 -0700 (MST) (envelope-from wblock@wonkity.com) Date: Wed, 27 Jan 2016 09:36:58 -0700 (MST) From: Warren Block To: Allan Jude cc: freebsd-hackers@freebsd.org Subject: Re: syslogd(8) with OOM Killer protection In-Reply-To: <56A86D91.3040709@freebsd.org> Message-ID: References: <56A86D91.3040709@freebsd.org> User-Agent: Alpine 2.20 (BSF 67 2015-01-07) MIME-Version: 1.0 Content-Type: text/plain; format=flowed; charset=US-ASCII X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-4.4.3 (wonkity.com [127.0.0.1]); Wed, 27 Jan 2016 09:36:58 -0700 (MST) X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.20 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 27 Jan 2016 16:37:00 -0000 On Wed, 27 Jan 2016, Allan Jude wrote: > On 2016-01-27 01:21, Marcelo Araujo wrote: >> Hi guys, >> >> I would like to know your opinion about this REVIEW[1]. >> The basic idea is protect by default the syslogd(8) against been killed by >> OOM with an option to disable the protection. >> >> Some people like the idea, other people would prefer something more global >> where we can protect any daemon by the discretion of our choice. >> >> Thoughts? >> >> >> [1] https://reviews.freebsd.org/D4973 >> >> >> Best, >> > > I do like the idea of generalizing it, say via rc.subr > > So you can just do: > > someapp_protect=YES (and maybe syslogd has this enabled by default in > /etc/defaults/rc.conf) and it prefixes the start command with protect -i. Possibly simpler to provide a list in one setting than an individual setting for each daemon. With ideas from other posters: oomprotect_daemons="crond syslogd" From owner-freebsd-hackers@freebsd.org Wed Jan 27 16:40:34 2016 Return-Path: Delivered-To: freebsd-hackers@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 3A64AA70574 for ; Wed, 27 Jan 2016 16:40:34 +0000 (UTC) (envelope-from araujobsdport@gmail.com) Received: from mail-ob0-x22a.google.com (mail-ob0-x22a.google.com [IPv6:2607:f8b0:4003:c01::22a]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (Client CN "smtp.gmail.com", Issuer "Google Internet Authority G2" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 0085D1D7D; Wed, 27 Jan 2016 16:40:34 +0000 (UTC) (envelope-from araujobsdport@gmail.com) Received: by mail-ob0-x22a.google.com with SMTP id ba1so11815281obb.3; Wed, 27 Jan 2016 08:40:33 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:reply-to:in-reply-to:references:date:message-id :subject:from:to:cc:content-type; bh=2QpWt+OFvldkDzK/hgNv138Ni0dyj2qi4TwJp5iN9g8=; b=y9rMAXEfc+XXZuo24IF0t/t0Igeva+6T2Da4GJV/G4QOKWMPaufZyet2FLiXCpcR7J 9RaZmth9/xwoEJn7nsZ1j8se/AVv8ql06VzHExsK2Hhjuss7WnEjSHa1MG3izq2Nu5wT J64Tvqw7/8lu7geJqIGGhENOCUY/thGFrSgSNGPt0z8k9dvA2sUYbVRYf5luaTQKQOne lczQg7IRjp8aCRfoe28vj7XAYGsFdlqyw2HMfzeG7h+tQPHy7C4EMhXmQOWTGaozYTQd ssi9dvn2ZiiMqNyrqTINekPLtTeAEoGt0Gdr5/wjoDwy1iEBRLwDceee9cVw9D3fBN3k 01jg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:mime-version:reply-to:in-reply-to:references :date:message-id:subject:from:to:cc:content-type; bh=2QpWt+OFvldkDzK/hgNv138Ni0dyj2qi4TwJp5iN9g8=; b=XGFonshgcELrHcVVtVQXZOlcGHArXZgoPcdzuiNNtaZNnE5zVvNRb9BEDe3Cogejvv dR0wm8IGARyqysC0op2o/1qgaskX/hHAhmeUSik107hvbvq7gs3s6b10cxZzj/agO6eA k1TLxE0EunOWZ133Ic4wPAOUjA30oO0OBYul/OlkZn19F65Ny/xXVX/sLPRCynJ1rjYt xhXB2pFupJProE7TGaIRHSI0bWuoLKR8Rn4EfU3fanTU/iMem99NpldktnLkHcsV2N5W thNnvrvCK5LS+bAFF4YjRoC8h/vDdXhdAHcItF+9shOQWdTzGiYCa8EGrB9LMYCmxg8k lk1A== X-Gm-Message-State: AG10YOQxtP7UlRkzB1o3OhmPRHtOOhjgIXbcIPwZNfVmlOjWlwrtmyl9mav7KkpBsUSq74mumJKtpnHlS5NQtg== MIME-Version: 1.0 X-Received: by 10.60.226.136 with SMTP id rs8mr22362063oec.31.1453912833318; Wed, 27 Jan 2016 08:40:33 -0800 (PST) Received: by 10.182.40.194 with HTTP; Wed, 27 Jan 2016 08:40:32 -0800 (PST) Received: by 10.182.40.194 with HTTP; Wed, 27 Jan 2016 08:40:32 -0800 (PST) Reply-To: araujo@FreeBSD.org In-Reply-To: References: <56A86D91.3040709@freebsd.org> Date: Thu, 28 Jan 2016 00:40:32 +0800 Message-ID: Subject: Re: syslogd(8) with OOM Killer protection From: Marcelo Araujo To: Warren Block Cc: freebsd-hackers@freebsd.org, Allan Jude Content-Type: text/plain; charset=UTF-8 X-Content-Filtered-By: Mailman/MimeDel 2.1.20 X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.20 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 27 Jan 2016 16:40:34 -0000 On Jan 28, 2016 12:37 AM, "Warren Block" wrote: > > On Wed, 27 Jan 2016, Allan Jude wrote: > >> On 2016-01-27 01:21, Marcelo Araujo wrote: >>> >>> Hi guys, >>> >>> I would like to know your opinion about this REVIEW[1]. >>> The basic idea is protect by default the syslogd(8) against been killed by >>> OOM with an option to disable the protection. >>> >>> Some people like the idea, other people would prefer something more global >>> where we can protect any daemon by the discretion of our choice. >>> >>> Thoughts? >>> >>> >>> [1] https://reviews.freebsd.org/D4973 >>> >>> >>> Best, >>> >> >> I do like the idea of generalizing it, say via rc.subr >> >> So you can just do: >> >> someapp_protect=YES (and maybe syslogd has this enabled by default in >> /etc/defaults/rc.conf) and it prefixes the start command with protect -i. > > > Possibly simpler to provide a list in one setting than an individual setting for each daemon. With ideas from other posters: > > oomprotect_daemons="crond syslogd" > > Yes, it sounds more reasonable and easy to understand! Gonna check what I can do with it. Thanks everybody for the feedback! Best, _______________________________________________ > freebsd-hackers@freebsd.org mailing list > https://lists.freebsd.org/mailman/listinfo/freebsd-hackers > To unsubscribe, send any mail to "freebsd-hackers-unsubscribe@freebsd.org" From owner-freebsd-hackers@freebsd.org Wed Jan 27 16:47:32 2016 Return-Path: Delivered-To: freebsd-hackers@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 5DE31A707FE; Wed, 27 Jan 2016 16:47:32 +0000 (UTC) (envelope-from jhb@freebsd.org) Received: from bigwig.baldwin.cx (bigwig.baldwin.cx [IPv6:2001:470:1f11:75::1]) (using TLSv1 with cipher DHE-RSA-CAMELLIA256-SHA (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 3CE4B12D2; Wed, 27 Jan 2016 16:47:32 +0000 (UTC) (envelope-from jhb@freebsd.org) Received: from ralph.baldwin.cx (c-73-231-226-104.hsd1.ca.comcast.net [73.231.226.104]) by bigwig.baldwin.cx (Postfix) with ESMTPSA id C0D97B93C; Wed, 27 Jan 2016 11:47:30 -0500 (EST) From: John Baldwin To: freebsd-arch@freebsd.org Cc: Warner Losh , Adrian Chadd , "freebsd-hackers@freebsd.org" , freebsd-current Subject: Re: Hot-Plug PCIe Support Date: Wed, 27 Jan 2016 08:47:27 -0800 Message-ID: <3676083.ysX5rbmR19@ralph.baldwin.cx> User-Agent: KMail/4.14.3 (FreeBSD/10.2-STABLE; KDE/4.14.3; amd64; ; ) In-Reply-To: References: <56A7F31C.3030209@FreeBSD.org> MIME-Version: 1.0 Content-Transfer-Encoding: 7Bit Content-Type: text/plain; charset="us-ascii" X-Greylist: Sender succeeded SMTP AUTH, not delayed by milter-greylist-4.2.7 (bigwig.baldwin.cx); Wed, 27 Jan 2016 11:47:30 -0500 (EST) X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.20 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 27 Jan 2016 16:47:32 -0000 On Tuesday, January 26, 2016 11:33:08 PM Warner Losh wrote: > It's mostly done, but needs a careful review by PCI domain experts. I've > been doing it a little at a time, but have been crunched for time. Since > $DAYJOB doesn't care about hot plug, it's a lower priority than all the > things related or semi-related to it. As I noted in the review on phabricator, it needs to be rearranged. It currently puts a bunch of code in the PCI bus that instead belongs in the PCI-PCI bridge (all the interrupt handling, MSI, etc. are properties of the bridge and should be handled in their rather than magic fields in the pci_dinfo of the bridge in the parent PCI bus). It is not a lot of code and probably wouldn't take long to finish. I had been waiting to let jmg@ finish it. https://reviews.freebsd.org/D3932 > Warner > > > On Tue, Jan 26, 2016 at 6:58 PM, Adrian Chadd > wrote: > > > please grab the pciehp work that jmg has done and push it along to > > completion. Pretty please in fact. > > > > > > -a > > > > > > On 26 January 2016 at 14:28, Eric van Gyzen wrote: > > > FreeBSD Folks: > > > > > > I am currently scoping the effort to add hot-plug PCIe support to > > > FreeBSD. Is anyone else currently working on this or aware of any > > > design, code, or other effort available outside the tree? > > > > > > FYI, here are perhaps the most interesting references I could find: > > > > > > https://wiki.freebsd.org/PCIHotplug > > > > > > > > https://wiki.freebsd.org/IdeasPage#Implementing_PCI-Hotplug_and_ExpressCard_support > > > > > > > > https://lists.freebsd.org/pipermail/freebsd-current/2015-April/055290.html > > > > > > https://lists.freebsd.org/pipermail/freebsd-ia32/2010-February/date.html > > > > > > Please reply on freebsd-hackers@FreeBSD.org to minimize cross-posting. > > > > > > Thanks in advance. > > > > > > Eric > > > _______________________________________________ > > > freebsd-current@freebsd.org mailing list > > > https://lists.freebsd.org/mailman/listinfo/freebsd-current > > > To unsubscribe, send any mail to " > > freebsd-current-unsubscribe@freebsd.org" > > _______________________________________________ > > freebsd-arch@freebsd.org mailing list > > https://lists.freebsd.org/mailman/listinfo/freebsd-arch > > To unsubscribe, send any mail to "freebsd-arch-unsubscribe@freebsd.org" > > > _______________________________________________ > freebsd-arch@freebsd.org mailing list > https://lists.freebsd.org/mailman/listinfo/freebsd-arch > To unsubscribe, send any mail to "freebsd-arch-unsubscribe@freebsd.org" -- John Baldwin From owner-freebsd-hackers@freebsd.org Wed Jan 27 16:48:03 2016 Return-Path: Delivered-To: freebsd-hackers@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id C8CF7A708A8 for ; Wed, 27 Jan 2016 16:48:03 +0000 (UTC) (envelope-from mailinglists@toco-domains.de) Received: from toco-domains.de (mail.toco-domains.de [IPv6:2a01:4f8:150:50a5::6]) (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 9507E1606 for ; Wed, 27 Jan 2016 16:48:03 +0000 (UTC) (envelope-from mailinglists@toco-domains.de) Received: from [0.0.0.0] (mail.toco-domains.de [IPv6:2a01:4f8:150:50a5::6]) by toco-domains.de (Postfix) with ESMTPA id 2B2791B220AB for ; Wed, 27 Jan 2016 17:48:01 +0100 (CET) Subject: Re: syslogd(8) with OOM Killer protection To: freebsd-hackers@freebsd.org References: <56A86D91.3040709@freebsd.org> From: Torsten Zuehlsdorff Message-ID: <56A8F4C0.9090200@toco-domains.de> Date: Wed, 27 Jan 2016 17:48:00 +0100 User-Agent: Mozilla/5.0 (X11; FreeBSD amd64; rv:38.0) Gecko/20100101 Thunderbird/38.5.0 MIME-Version: 1.0 In-Reply-To: Content-Type: text/plain; charset=windows-1252; format=flowed Content-Transfer-Encoding: 7bit X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.20 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 27 Jan 2016 16:48:03 -0000 On 27.01.2016 17:36, Warren Block wrote: >>> I would like to know your opinion about this REVIEW[1]. >>> The basic idea is protect by default the syslogd(8) against been >>> killed by >>> OOM with an option to disable the protection. >>> >>> Some people like the idea, other people would prefer something more >>> global >>> where we can protect any daemon by the discretion of our choice. >>> >>> Thoughts? >>> >>> >>> [1] https://reviews.freebsd.org/D4973 >>> >>> >>> Best, >>> >> >> I do like the idea of generalizing it, say via rc.subr >> >> So you can just do: >> >> someapp_protect=YES (and maybe syslogd has this enabled by default in >> /etc/defaults/rc.conf) and it prefixes the start command with protect -i. > > Possibly simpler to provide a list in one setting than an individual > setting for each daemon. With ideas from other posters: > > oomprotect_daemons="crond syslogd" I like this approach! Greetings, Torsten From owner-freebsd-hackers@freebsd.org Wed Jan 27 16:52:34 2016 Return-Path: Delivered-To: freebsd-hackers@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 48A05A70AAB for ; Wed, 27 Jan 2016 16:52:34 +0000 (UTC) (envelope-from allanjude@freebsd.org) Received: from mx1.scaleengine.net (mx1.scaleengine.net [209.51.186.6]) by mx1.freebsd.org (Postfix) with ESMTP id 2B2661A7E for ; Wed, 27 Jan 2016 16:52:34 +0000 (UTC) (envelope-from allanjude@freebsd.org) Received: from [10.1.1.2] (unknown [10.1.1.2]) (Authenticated sender: allanjude.freebsd@scaleengine.com) by mx1.scaleengine.net (Postfix) with ESMTPSA id 34C06DF80 for ; Wed, 27 Jan 2016 16:52:33 +0000 (UTC) Subject: Re: syslogd(8) with OOM Killer protection To: freebsd-hackers@freebsd.org References: <56A86D91.3040709@freebsd.org> From: Allan Jude Message-ID: <56A8F5D4.2070901@freebsd.org> Date: Wed, 27 Jan 2016 11:52:36 -0500 User-Agent: Mozilla/5.0 (Windows NT 6.1; WOW64; rv:38.0) Gecko/20100101 Thunderbird/38.5.1 MIME-Version: 1.0 In-Reply-To: Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="qrWDUXPvAWKPUkWs4FVaKV9hXetQoV6gN" X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.20 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 27 Jan 2016 16:52:34 -0000 This is an OpenPGP/MIME signed message (RFC 4880 and 3156) --qrWDUXPvAWKPUkWs4FVaKV9hXetQoV6gN Content-Type: text/plain; charset=windows-1252 Content-Transfer-Encoding: quoted-printable On 2016-01-27 11:36, Warren Block wrote: > On Wed, 27 Jan 2016, Allan Jude wrote: >=20 >> On 2016-01-27 01:21, Marcelo Araujo wrote: >>> Hi guys, >>> >>> I would like to know your opinion about this REVIEW[1]. >>> The basic idea is protect by default the syslogd(8) against been >>> killed by >>> OOM with an option to disable the protection. >>> >>> Some people like the idea, other people would prefer something more >>> global >>> where we can protect any daemon by the discretion of our choice. >>> >>> Thoughts? >>> >>> >>> [1] https://reviews.freebsd.org/D4973 >>> >>> >>> Best, >>> >> >> I do like the idea of generalizing it, say via rc.subr >> >> So you can just do: >> >> someapp_protect=3DYES (and maybe syslogd has this enabled by default i= n >> /etc/defaults/rc.conf) and it prefixes the start command with protect = -i. >=20 > Possibly simpler to provide a list in one setting than an individual > setting for each daemon. With ideas from other posters: >=20 > oomprotect_daemons=3D"crond syslogd" > _______________________________________________ > freebsd-hackers@freebsd.org mailing list > https://lists.freebsd.org/mailman/listinfo/freebsd-hackers > To unsubscribe, send any mail to "freebsd-hackers-unsubscribe@freebsd.o= rg" The only reason I went for daemon_protect=3D"YES" was for ease of implementation. It would just be another command prefix like: _nice, _fib, or _env --=20 Allan Jude --qrWDUXPvAWKPUkWs4FVaKV9hXetQoV6gN Content-Type: application/pgp-signature; name="signature.asc" Content-Description: OpenPGP digital signature Content-Disposition: attachment; filename="signature.asc" -----BEGIN PGP SIGNATURE----- Version: GnuPG v2.0.22 (MingW32) iQIcBAEBAgAGBQJWqPXYAAoJEBmVNT4SmAt+Ca4QANKA6ZmMCSqEDnYpZS5DKEzo nXXu87mfHGT26Dy7fAXKqnCvfxsDTkDiM4ryYHHQASZX5NENcmpdUdjwd1uegDOu ZBR/eBR2NHheLEutOO2/irpTeM72Cke8Zr5Dwu6qteC4Mps47qcSNH5iH32BDrV0 akVbY+Xe0MtZ7Jhu/EwrNfsV4AR1iBq7uccZOB8z+Jitqq2rv6fn/4mDYbQZCRKS qIBZ8NKsTw3vMYz6+MUEOs+sJa41oepMFDnB5sTpIe4sKKPOxcfI+ZlHAp3ZBaDv Pa0Gbe3IZObPIBXApWkCzbKbDzZQ3sWWtYTB0IJ+KQvn7hXhZAg6Mj0Gvo0v3k94 B+gfI0DuRWvSNCJ7ZUbrw+es32Eir+OM6ckD/NrdSbIw6Ce+KrsHSkCR5KRvA4Qp zI8KS/ho1/T0QFRmGxGGrJ+MsbdjRgH0u6jZRO/GkwGMPWUjvm8I9NxH6GnWOss9 FFuWredgeSWcOha/3J+LU98xG24f3o4lvsb9Ia989DYaZEB6e7wmKy8bxkSAs27C L4VppAvo4nEEJa/gNh7tiWkyxVgNIOD23IbGgaw1DCY4gqNK1hjqgWExhRG+wlI9 HrTmqnnNWHBvc4M9QMtwUjRjjp6L16gxuYDV6mpuHtW7RpHzLbBKOPl+odGeNt0s 46+7grjAA9sb66uO3duV =qjhC -----END PGP SIGNATURE----- --qrWDUXPvAWKPUkWs4FVaKV9hXetQoV6gN-- From owner-freebsd-hackers@freebsd.org Wed Jan 27 16:55:42 2016 Return-Path: Delivered-To: freebsd-hackers@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 8578AA70BF0 for ; Wed, 27 Jan 2016 16:55:42 +0000 (UTC) (envelope-from asomers@gmail.com) Received: from mail-oi0-x234.google.com (mail-oi0-x234.google.com [IPv6:2607:f8b0:4003:c06::234]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (Client CN "smtp.gmail.com", Issuer "Google Internet Authority G2" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4D9F81C63; Wed, 27 Jan 2016 16:55:42 +0000 (UTC) (envelope-from asomers@gmail.com) Received: by mail-oi0-x234.google.com with SMTP id r14so9282745oie.0; Wed, 27 Jan 2016 08:55:42 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:sender:in-reply-to:references:date:message-id:subject :from:to:cc:content-type; bh=3vtlBBIwt5fufmrPZml9gaGbeIaFSSR7xIsIM0qm3fY=; b=eSUYDdZfnwBqXbYkk7PJJ/H00F+ZpDThBmXD+WSTJ4dLUu9+m+jmZLXB+lEw7PpkmC ePA84FU+lEIBJlC7BIGqwvibYjmJSnx2pwE3SiYv0o/upfL30VRwNJi3nMrY1RjhWk3q Mq1xh+SZU3TiIzPNa3eb/xvpQ1uOuRwIBELMzPJpLkOedLaHj5RogV5lWtc6g0ozaTL6 dlsHqvief2b5zX9jfyjE4Vv/2tS1GpzS9ZjorpK6x2TFNIo1RBiPMAslDrXM6xbfJz/y Qvy8FjS9fXl/SWk4stJhZ691xMBD4rYZAZEWur7TypKmC/TaJSbGub2y9iAXP3C31VCP hdhw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:mime-version:sender:in-reply-to:references:date :message-id:subject:from:to:cc:content-type; bh=3vtlBBIwt5fufmrPZml9gaGbeIaFSSR7xIsIM0qm3fY=; b=e303l8snAAUix1pRyfQe1JkKb4bjSnGCqP51zlF+qJipPRLSFcPcasQQB3ASjuSjWt W3ZVETLUQIa41/oP/qdFNAXy8PWkifV9wjww4ps6aGSuTd2KxTy6j1dwYOtxgOZWlsP5 f5+0Yaeujtgs5oQP/u4An/FYAS3Z4NnO+1lomCNbNXA6DHTr2k4WAFHlWPNKaDKix8QW tGR0rklyc9NWfo0K+7Y7YTKyo9P8NNFymyXuUtnuaDMynpBvplmUUhf9rQxJ5bnLbyul zCLSnSOWKzsMCII2es1GfjyFcKEnYLzLent9hU545sdudefBHNrQJMrnF9jc26+X6/fA NJCA== X-Gm-Message-State: AG10YORbeD2P738BHs3sOEmMENGnuqX/QJMvWN/6rO6FNq84TZlRzq7gKeEiW0ZFkDeMtfRFViB2i7nuli7kYQ== MIME-Version: 1.0 X-Received: by 10.202.85.194 with SMTP id j185mr22078346oib.107.1453913741499; Wed, 27 Jan 2016 08:55:41 -0800 (PST) Sender: asomers@gmail.com Received: by 10.202.69.86 with HTTP; Wed, 27 Jan 2016 08:55:41 -0800 (PST) In-Reply-To: <56A8F5D4.2070901@freebsd.org> References: <56A86D91.3040709@freebsd.org> <56A8F5D4.2070901@freebsd.org> Date: Wed, 27 Jan 2016 09:55:41 -0700 X-Google-Sender-Auth: 5T50ouW2LuhfDYOckWK0gp-yI9g Message-ID: Subject: Re: syslogd(8) with OOM Killer protection From: Alan Somers To: Allan Jude Cc: "freebsd-hackers@freebsd.org" Content-Type: text/plain; charset=UTF-8 X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.20 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 27 Jan 2016 16:55:42 -0000 On Wed, Jan 27, 2016 at 9:52 AM, Allan Jude wrote: > On 2016-01-27 11:36, Warren Block wrote: >> On Wed, 27 Jan 2016, Allan Jude wrote: >> >>> On 2016-01-27 01:21, Marcelo Araujo wrote: >>>> Hi guys, >>>> >>>> I would like to know your opinion about this REVIEW[1]. >>>> The basic idea is protect by default the syslogd(8) against been >>>> killed by >>>> OOM with an option to disable the protection. >>>> >>>> Some people like the idea, other people would prefer something more >>>> global >>>> where we can protect any daemon by the discretion of our choice. >>>> >>>> Thoughts? >>>> >>>> >>>> [1] https://reviews.freebsd.org/D4973 >>>> >>>> >>>> Best, >>>> >>> >>> I do like the idea of generalizing it, say via rc.subr >>> >>> So you can just do: >>> >>> someapp_protect=YES (and maybe syslogd has this enabled by default in >>> /etc/defaults/rc.conf) and it prefixes the start command with protect -i. >> >> Possibly simpler to provide a list in one setting than an individual >> setting for each daemon. With ideas from other posters: >> >> oomprotect_daemons="crond syslogd" >> _______________________________________________ >> freebsd-hackers@freebsd.org mailing list >> https://lists.freebsd.org/mailman/listinfo/freebsd-hackers >> To unsubscribe, send any mail to "freebsd-hackers-unsubscribe@freebsd.org" > > > The only reason I went for daemon_protect="YES" was for ease of > implementation. It would just be another command prefix like: _nice, > _fib, or _env > > -- > Allan Jude > I agree with Allan. We already have a lot of _foo variables. But there aren't any foo_daemons variables. For consistency's sake, we should use _protect or _oomprotect. -Alan From owner-freebsd-hackers@freebsd.org Wed Jan 27 16:59:31 2016 Return-Path: Delivered-To: freebsd-hackers@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 9C3DBA70D2B for ; Wed, 27 Jan 2016 16:59:31 +0000 (UTC) (envelope-from rpokala@mac.com) Received: from mr11p00im-asmtp003.me.com (mr11p00im-asmtp003.me.com [17.110.69.254]) (using TLSv1.2 with cipher DHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 89D2E1E18 for ; Wed, 27 Jan 2016 16:59:31 +0000 (UTC) (envelope-from rpokala@mac.com) Received: from [192.168.1.4] (c-24-6-178-251.hsd1.ca.comcast.net [24.6.178.251]) by mr11p00im-asmtp003.me.com (Oracle Communications Messaging Server 7.0.5.36.0 64bit (built Sep 8 2015)) with ESMTPSA id <0O1M002TYCF0PK30@mr11p00im-asmtp003.me.com> for freebsd-hackers@freebsd.org; Wed, 27 Jan 2016 15:59:25 +0000 (GMT) X-Proofpoint-Virus-Version: vendor=fsecure engine=2.50.10432:,, definitions=2016-01-27_04:,, signatures=0 X-Proofpoint-Spam-Details: rule=notspam policy=default score=0 spamscore=0 clxscore=1011 suspectscore=0 malwarescore=0 phishscore=0 adultscore=0 bulkscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.0.1-1510270003 definitions=main-1601270264 User-Agent: Microsoft-MacOutlook/0.0.0.160109 Date: Wed, 27 Jan 2016 07:59:23 -0800 Subject: Re: syslogd(8) with OOM Killer protection From: Ravi Pokala Sender: "Pokala, Ravi" To: "freebsd-hackers@freebsd.org" Message-id: <9A913658-E90C-4B85-B73B-F3F7D3004344@panasas.com> Thread-topic: syslogd(8) with OOM Killer protection MIME-version: 1.0 Content-type: text/plain; charset=UTF-8 Content-transfer-encoding: 7bit X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.20 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 27 Jan 2016 16:59:31 -0000 -----Original Message----- >Date: Wed, 27 Jan 2016 11:35:38 +0100 >From: Jan Bramkamp >To: freebsd-hackers@freebsd.org >Subject: Re: syslogd(8) with OOM Killer protection >Message-ID: <56A89D7A.8080906@rlwinm.de> >Content-Type: text/plain; charset=windows-1252; format=flowed > >On 27/01/16 09:27, Pavel Timofeev wrote: >>... >> >I would prefer to implement the a flag keeping cron (and all other base >system daemons) from double-forking and run it under a process >supervisor like daemontools. We've recently added that to `syslogd' (r279567, 2015-03-03). I think we also have internal changes (not committed to -HEAD yet) which adds a "run in foreground" option to a few other daemons. -Ravi (rpokala@) From owner-freebsd-hackers@freebsd.org Wed Jan 27 17:52:35 2016 Return-Path: Delivered-To: freebsd-hackers@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 9012AA7021E for ; Wed, 27 Jan 2016 17:52:35 +0000 (UTC) (envelope-from jhb@freebsd.org) Received: from mailman.ysv.freebsd.org (mailman.ysv.freebsd.org [IPv6:2001:1900:2254:206a::50:5]) by mx1.freebsd.org (Postfix) with ESMTP id 752611185 for ; Wed, 27 Jan 2016 17:52:35 +0000 (UTC) (envelope-from jhb@freebsd.org) Received: by mailman.ysv.freebsd.org (Postfix) id 74268A7021C; Wed, 27 Jan 2016 17:52:35 +0000 (UTC) Delivered-To: hackers@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 5B60AA7021A; Wed, 27 Jan 2016 17:52:35 +0000 (UTC) (envelope-from jhb@freebsd.org) Received: from bigwig.baldwin.cx (bigwig.baldwin.cx [IPv6:2001:470:1f11:75::1]) (using TLSv1 with cipher DHE-RSA-CAMELLIA256-SHA (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 1C7B81184; Wed, 27 Jan 2016 17:52:35 +0000 (UTC) (envelope-from jhb@freebsd.org) Received: from ralph.baldwin.cx (c-73-231-226-104.hsd1.ca.comcast.net [73.231.226.104]) by bigwig.baldwin.cx (Postfix) with ESMTPSA id 230BCB94B; Wed, 27 Jan 2016 12:52:34 -0500 (EST) From: John Baldwin To: Wojciech Macek Cc: hackers@freebsd.org, freebsd-arm@freebsd.org, Olivier Houchard , arm64-dev Subject: Re: SCHED_ULE race condition, fix proposal Date: Wed, 27 Jan 2016 09:51:12 -0800 Message-ID: <2587742.rOiGAYXjN1@ralph.baldwin.cx> User-Agent: KMail/4.14.3 (FreeBSD/10.2-STABLE; KDE/4.14.3; amd64; ; ) In-Reply-To: References: MIME-Version: 1.0 Content-Transfer-Encoding: 7Bit Content-Type: text/plain; charset="us-ascii" X-Greylist: Sender succeeded SMTP AUTH, not delayed by milter-greylist-4.2.7 (bigwig.baldwin.cx); Wed, 27 Jan 2016 12:52:34 -0500 (EST) X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.20 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 27 Jan 2016 17:52:35 -0000 On Wednesday, January 27, 2016 06:18:16 PM Wojciech Macek wrote: > Hello, > > I've encountered a very nasty race condition during debugging armv8 HWPMC. > It seems that ULE scheduler can execute the same thread on two different > CPUs at the same time... > > Here is the scenario. > The PMC driver must execute some of the code on the CPU0. To ensure that, a > process migration is triggered as following: > > > thread_lock(curthread); > sched_bind(curthread, cpu); > thread_unlock(curthread); > > KASSERT(curthread->td_oncpu == cpu, > ("[pmc,%d] CPU not bound [cpu=%d, curr=%d]", __LINE__, > cpu, curthread->td_oncpu)); > > > That causes the context switch and (finally) execution of sched_switch() > function. The code correctly detects migration and calls > sched_switch_migrate. That function is supposed to add current thread to > the runqueue of another CPU ("tdn" variable). So it does: > > tdq_lock_pair(tdn, tdq); > tdq_add(tdn, td, flags); > tdq_notify(tdn, td); > TDQ_UNLOCK(tdn); > spinlock_exit(); > > > But that sometimes is causing a crash, because the other CPU is staring to > process mi_switch as soon as the IPI arrives (via tdq_notify) and the > runqueue lock is released. The problem is, that the thread does not contain > valid register set, because its context was not yet stored - that happens > later in machine dependent cpu_switch function. In another words, the > sched_switch run on the CPU we want the thread to migrate onto restores > thread context before it was actually stored on another core - that causes > setting regs/pc/lt to some junk data and crash. > > > I'd like to discuss a possible solution for this. I think it would be > reasonable to extend cpu_switch to be capable of releasing a lock as the > last thing it does after storing everything into the PCB. We could then > remove the "TDQ_UNLOCK(tdn);" from the sched_switch_migrate and be sure > that in the situation of migration nobody is allowed to touch the target > runqueue until the migrating process finishes storing its context. > > But first I'd like to discuss some possible alternatives and maybe find > another solution, because any change in this area will impact all supported > architectures. This belongs on hackers, not developers@. cpu_switch() already does what you describe though in a slightly different way. The thread_lock() of a thread being switched out is set to blocked_lock. cpu_switch() on the new CPU will always spin until cpu_switch updates thread_lock of the old thread to point to the proper runq lock after saving its state in the pcb. arm64 does this here: /* * Release the old thread. This doesn't need to be a store-release * as the above dsb instruction will provide release semantics. */ str x2, [x0, #TD_LOCK] #if defined(SCHED_ULE) && defined(SMP) /* Read the value in blocked_lock */ ldr x0, =_C_LABEL(blocked_lock) ldr x2, [x0] 1: ldar x3, [x1, #TD_LOCK] cmp x3, x2 b.eq 1b #endif Note the thread_lock_block() call just above the block you noted from sched_switch_migrate() to see where td_lock is set to &blocked_lock. If the comment about 'dsb' above is wrong that might explain why you see stale state in the PCB after seeing the new value of td_lock. -- John Baldwin From owner-freebsd-hackers@freebsd.org Wed Jan 27 18:14:32 2016 Return-Path: Delivered-To: freebsd-hackers@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 08B50A70A51 for ; Wed, 27 Jan 2016 18:14:32 +0000 (UTC) (envelope-from cognet@ci0.org) Received: from mailman.ysv.freebsd.org (mailman.ysv.freebsd.org [IPv6:2001:1900:2254:206a::50:5]) by mx1.freebsd.org (Postfix) with ESMTP id EA9301589 for ; Wed, 27 Jan 2016 18:14:31 +0000 (UTC) (envelope-from cognet@ci0.org) Received: by mailman.ysv.freebsd.org (Postfix) id E7B1CA70A50; Wed, 27 Jan 2016 18:14:31 +0000 (UTC) Delivered-To: hackers@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id CD537A70A4F; Wed, 27 Jan 2016 18:14:31 +0000 (UTC) (envelope-from cognet@ci0.org) Received: from kanar.ci0.org (kanar.ci0.org [IPv6:2001:bc8:35e6::1]) (using TLSv1 with cipher DHE-RSA-CAMELLIA256-SHA (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 81A261587; Wed, 27 Jan 2016 18:14:31 +0000 (UTC) (envelope-from cognet@ci0.org) Received: from kanar.ci0.org (pluxor@localhost [127.0.0.1]) by kanar.ci0.org (8.14.9/8.14.8) with ESMTP id u0RIEQS2048903; Wed, 27 Jan 2016 19:14:26 +0100 (CET) (envelope-from cognet@ci0.org) Received: (from doginou@localhost) by kanar.ci0.org (8.14.9/8.14.8/Submit) id u0RIEQmb048902; Wed, 27 Jan 2016 19:14:26 +0100 (CET) (envelope-from cognet@ci0.org) X-Authentication-Warning: kanar.ci0.org: doginou set sender to cognet@ci0.org using -f Date: Wed, 27 Jan 2016 19:14:26 +0100 From: Olivier Houchard To: John Baldwin Cc: Wojciech Macek , hackers@freebsd.org, freebsd-arm@freebsd.org, arm64-dev Subject: Re: SCHED_ULE race condition, fix proposal Message-ID: <20160127181426.GA48838@ci0.org> References: <2587742.rOiGAYXjN1@ralph.baldwin.cx> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <2587742.rOiGAYXjN1@ralph.baldwin.cx> User-Agent: Mutt/1.5.23 (2014-03-12) X-Mailman-Approved-At: Wed, 27 Jan 2016 18:25:52 +0000 X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.20 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 27 Jan 2016 18:14:32 -0000 Hi, I may be reading the arm64 code wrong, but shouldn't : ldr x0, =_C_LABEL(blocked_lock) ldr x2, [x0] be just: ldr x2, =_C_LABEL(blocked_lock) Regards, Olivier On Wed, Jan 27, 2016 at 09:51:12AM -0800, John Baldwin wrote: > On Wednesday, January 27, 2016 06:18:16 PM Wojciech Macek wrote: > > Hello, > > > > I've encountered a very nasty race condition during debugging armv8 HWPMC. > > It seems that ULE scheduler can execute the same thread on two different > > CPUs at the same time... > > > > Here is the scenario. > > The PMC driver must execute some of the code on the CPU0. To ensure that, a > > process migration is triggered as following: > > > > > > thread_lock(curthread); > > sched_bind(curthread, cpu); > > thread_unlock(curthread); > > > > KASSERT(curthread->td_oncpu == cpu, > > ("[pmc,%d] CPU not bound [cpu=%d, curr=%d]", __LINE__, > > cpu, curthread->td_oncpu)); > > > > > > That causes the context switch and (finally) execution of sched_switch() > > function. The code correctly detects migration and calls > > sched_switch_migrate. That function is supposed to add current thread to > > the runqueue of another CPU ("tdn" variable). So it does: > > > > tdq_lock_pair(tdn, tdq); > > tdq_add(tdn, td, flags); > > tdq_notify(tdn, td); > > TDQ_UNLOCK(tdn); > > spinlock_exit(); > > > > > > But that sometimes is causing a crash, because the other CPU is staring to > > process mi_switch as soon as the IPI arrives (via tdq_notify) and the > > runqueue lock is released. The problem is, that the thread does not contain > > valid register set, because its context was not yet stored - that happens > > later in machine dependent cpu_switch function. In another words, the > > sched_switch run on the CPU we want the thread to migrate onto restores > > thread context before it was actually stored on another core - that causes > > setting regs/pc/lt to some junk data and crash. > > > > > > I'd like to discuss a possible solution for this. I think it would be > > reasonable to extend cpu_switch to be capable of releasing a lock as the > > last thing it does after storing everything into the PCB. We could then > > remove the "TDQ_UNLOCK(tdn);" from the sched_switch_migrate and be sure > > that in the situation of migration nobody is allowed to touch the target > > runqueue until the migrating process finishes storing its context. > > > > But first I'd like to discuss some possible alternatives and maybe find > > another solution, because any change in this area will impact all supported > > architectures. > > This belongs on hackers, not developers@. > > cpu_switch() already does what you describe though in a slightly different > way. The thread_lock() of a thread being switched out is set to blocked_lock. > cpu_switch() on the new CPU will always spin until cpu_switch updates > thread_lock of the old thread to point to the proper runq lock after saving > its state in the pcb. arm64 does this here: > > /* > * Release the old thread. This doesn't need to be a store-release > * as the above dsb instruction will provide release semantics. > */ > str x2, [x0, #TD_LOCK] > #if defined(SCHED_ULE) && defined(SMP) > /* Read the value in blocked_lock */ > ldr x0, =_C_LABEL(blocked_lock) > ldr x2, [x0] > 1: > ldar x3, [x1, #TD_LOCK] > cmp x3, x2 > b.eq 1b > #endif > > Note the thread_lock_block() call just above the block you noted from > sched_switch_migrate() to see where td_lock is set to &blocked_lock. > > If the comment about 'dsb' above is wrong that might explain why you see > stale state in the PCB after seeing the new value of td_lock. > > -- > John Baldwin From owner-freebsd-hackers@freebsd.org Wed Jan 27 18:48:28 2016 Return-Path: Delivered-To: freebsd-hackers@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id BD53CA6E4E9 for ; Wed, 27 Jan 2016 18:48:28 +0000 (UTC) (envelope-from kostikbel@gmail.com) Received: from mailman.ysv.freebsd.org (mailman.ysv.freebsd.org [IPv6:2001:1900:2254:206a::50:5]) by mx1.freebsd.org (Postfix) with ESMTP id A7AF213A0 for ; Wed, 27 Jan 2016 18:48:28 +0000 (UTC) (envelope-from kostikbel@gmail.com) Received: by mailman.ysv.freebsd.org (Postfix) id A44BFA6E4E7; Wed, 27 Jan 2016 18:48:28 +0000 (UTC) Delivered-To: hackers@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id A3C7EA6E4E6; Wed, 27 Jan 2016 18:48:28 +0000 (UTC) (envelope-from kostikbel@gmail.com) Received: from kib.kiev.ua (kib.kiev.ua [IPv6:2001:470:d5e7:1::1]) (using TLSv1 with cipher DHE-RSA-CAMELLIA256-SHA (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 3E8FC139E; Wed, 27 Jan 2016 18:48:28 +0000 (UTC) (envelope-from kostikbel@gmail.com) Received: from tom.home (kostik@localhost [127.0.0.1]) by kib.kiev.ua (8.15.2/8.15.2) with ESMTPS id u0RImMXX078527 (version=TLSv1 cipher=DHE-RSA-CAMELLIA256-SHA bits=256 verify=NO); Wed, 27 Jan 2016 20:48:22 +0200 (EET) (envelope-from kostikbel@gmail.com) DKIM-Filter: OpenDKIM Filter v2.10.3 kib.kiev.ua u0RImMXX078527 Received: (from kostik@localhost) by tom.home (8.15.2/8.15.2/Submit) id u0RImMlP078497; Wed, 27 Jan 2016 20:48:22 +0200 (EET) (envelope-from kostikbel@gmail.com) X-Authentication-Warning: tom.home: kostik set sender to kostikbel@gmail.com using -f Date: Wed, 27 Jan 2016 20:48:22 +0200 From: Konstantin Belousov To: Olivier Houchard Cc: John Baldwin , hackers@freebsd.org, arm64-dev , freebsd-arm@freebsd.org Subject: Re: SCHED_ULE race condition, fix proposal Message-ID: <20160127184822.GE74231@kib.kiev.ua> References: <2587742.rOiGAYXjN1@ralph.baldwin.cx> <20160127181426.GA48838@ci0.org> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20160127181426.GA48838@ci0.org> User-Agent: Mutt/1.5.24 (2015-08-30) X-Spam-Status: No, score=-2.0 required=5.0 tests=ALL_TRUSTED,BAYES_00, DKIM_ADSP_CUSTOM_MED,FREEMAIL_FROM,NML_ADSP_CUSTOM_MED autolearn=no autolearn_force=no version=3.4.1 X-Spam-Checker-Version: SpamAssassin 3.4.1 (2015-04-28) on tom.home X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.20 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 27 Jan 2016 18:48:28 -0000 On Wed, Jan 27, 2016 at 07:14:26PM +0100, Olivier Houchard wrote: > Hi, > > I may be reading the arm64 code wrong, but shouldn't : > ldr x0, =_C_LABEL(blocked_lock) > ldr x2, [x0] > > be just: > ldr x2, =_C_LABEL(blocked_lock) You are right, I believe. From owner-freebsd-hackers@freebsd.org Wed Jan 27 19:06:18 2016 Return-Path: Delivered-To: freebsd-hackers@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 3AB22A6ED68 for ; Wed, 27 Jan 2016 19:06:18 +0000 (UTC) (envelope-from wma@semihalf.com) Received: from mailman.ysv.freebsd.org (mailman.ysv.freebsd.org [IPv6:2001:1900:2254:206a::50:5]) by mx1.freebsd.org (Postfix) with ESMTP id 1ADCE1112 for ; Wed, 27 Jan 2016 19:06:18 +0000 (UTC) (envelope-from wma@semihalf.com) Received: by mailman.ysv.freebsd.org (Postfix) id 17DC9A6ED65; Wed, 27 Jan 2016 19:06:18 +0000 (UTC) Delivered-To: hackers@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id F1AB8A6ED63 for ; Wed, 27 Jan 2016 19:06:17 +0000 (UTC) (envelope-from wma@semihalf.com) Received: from mail-ig0-x236.google.com (mail-ig0-x236.google.com [IPv6:2607:f8b0:4001:c05::236]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (Client CN "smtp.gmail.com", Issuer "Google Internet Authority G2" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id C53731110 for ; Wed, 27 Jan 2016 19:06:17 +0000 (UTC) (envelope-from wma@semihalf.com) Received: by mail-ig0-x236.google.com with SMTP id mw1so18648940igb.1 for ; Wed, 27 Jan 2016 11:06:17 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=semihalf-com.20150623.gappssmtp.com; s=20150623; h=mime-version:in-reply-to:references:from:date:message-id:subject:to :cc:content-type; bh=mZb7Cg9biXswox7H7/qDgpQh9w6eLXJpd6+BsxavL8U=; b=zQjQgneo+qDINVbqBikQCPvD776CLR1LONJyfsHQbeb+qWnO0FOqEPMMADXBGKZer2 DxrkMzgeXnZ3veCzlmAAmeCBunUsux/VWMt/AdgDJ30NwQuXqxnUWsf4pP4wLZVLOwIq WF9TzXakGhCWo1W/K2jxjWQ8AdcsBdAiL4tqYOUJCaus7OuMXNKpIfUPd+y+QZ0LJxvV x6WbF0RUwLaFOmZquOVyCIlCJz01HbNDDCM3euxCaV9acdL4SaTo1TmzAwViSbA83wOp CnS7m/A11D6g2tZAU9sAKBSH9lLvsh/UFmfQfnzCEYAh5gV+jboDl0Ncp/Ue1QIHAGeT 66Tg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:mime-version:in-reply-to:references:from:date :message-id:subject:to:cc:content-type; bh=mZb7Cg9biXswox7H7/qDgpQh9w6eLXJpd6+BsxavL8U=; b=gnts/Q2uOkC6d0A/1PEUflh3jXivFVz3ThAVkcPSfk4L4Y5Jzgogc3c4wPi4flxLJz 0TP5vwFTcxWPAK5PlfcEYmH4ocELon0lR1nnKBqv+3fCu9eNefZOrxXZ1jACKi/i2BK4 aPfroLA4OysmjrCYPEV49R207TuySHph9pmi8AWy5m1yQzlRKCm5gG/wOwDSwfjchmYl dzaWDnigZa65rNymxOO6KmKHhB/ltHA+s5DOSQuAaK2mD6uhjOCFfQK7t60Su0O0Ri8m AlF1fhGh143pghmUhxN2ohxDYFC4AZKk6OQHTTTZGrgtV1JJgcY46VDxZ9k5PxN+D6TU 4P8A== X-Gm-Message-State: AG10YOS51xbWRB75zSPCE1CLbW2SO+/0hg7c3Zmi4jG+FYiBN42ZlecBVJcgAG/PKyWvuuZq4NBU29rKipcd6Q== X-Received: by 10.50.136.136 with SMTP id qa8mr30316937igb.39.1453921577007; Wed, 27 Jan 2016 11:06:17 -0800 (PST) MIME-Version: 1.0 Received: by 10.107.154.19 with HTTP; Wed, 27 Jan 2016 11:05:57 -0800 (PST) In-Reply-To: <20160127181426.GA48838@ci0.org> References: <2587742.rOiGAYXjN1@ralph.baldwin.cx> <20160127181426.GA48838@ci0.org> From: Wojciech Macek Date: Wed, 27 Jan 2016 20:05:57 +0100 Message-ID: Subject: Re: SCHED_ULE race condition, fix proposal To: Olivier Houchard Cc: John Baldwin , hackers@freebsd.org, freebsd-arm@freebsd.org, arm64-dev X-Mailman-Approved-At: Wed, 27 Jan 2016 19:31:38 +0000 Content-Type: text/plain; charset=UTF-8 X-Content-Filtered-By: Mailman/MimeDel 2.1.20 X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.20 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 27 Jan 2016 19:06:18 -0000 Holly... Good catch :) Indeed, blocked_lock is not a pointer. I'll check it tommorow at work, but it looks promissing. And the only reason it didn't cause any data abort is that the mutex structure cointains a pointer to a string (name) at the offset 0. Thanks, Wojtek 2016-01-27 19:14 GMT+01:00 Olivier Houchard : > Hi, > > I may be reading the arm64 code wrong, but shouldn't : > ldr x0, =_C_LABEL(blocked_lock) > ldr x2, [x0] > > be just: > ldr x2, =_C_LABEL(blocked_lock) > > Regards, > > Olivier > > On Wed, Jan 27, 2016 at 09:51:12AM -0800, John Baldwin wrote: > > On Wednesday, January 27, 2016 06:18:16 PM Wojciech Macek wrote: > > > Hello, > > > > > > I've encountered a very nasty race condition during debugging armv8 > HWPMC. > > > It seems that ULE scheduler can execute the same thread on two > different > > > CPUs at the same time... > > > > > > Here is the scenario. > > > The PMC driver must execute some of the code on the CPU0. To ensure > that, a > > > process migration is triggered as following: > > > > > > > > > thread_lock(curthread); > > > sched_bind(curthread, cpu); > > > thread_unlock(curthread); > > > > > > KASSERT(curthread->td_oncpu == cpu, > > > ("[pmc,%d] CPU not bound [cpu=%d, curr=%d]", __LINE__, > > > cpu, curthread->td_oncpu)); > > > > > > > > > That causes the context switch and (finally) execution of > sched_switch() > > > function. The code correctly detects migration and calls > > > sched_switch_migrate. That function is supposed to add current thread > to > > > the runqueue of another CPU ("tdn" variable). So it does: > > > > > > tdq_lock_pair(tdn, tdq); > > > tdq_add(tdn, td, flags); > > > tdq_notify(tdn, td); > > > TDQ_UNLOCK(tdn); > > > spinlock_exit(); > > > > > > > > > But that sometimes is causing a crash, because the other CPU is > staring to > > > process mi_switch as soon as the IPI arrives (via tdq_notify) and the > > > runqueue lock is released. The problem is, that the thread does not > contain > > > valid register set, because its context was not yet stored - that > happens > > > later in machine dependent cpu_switch function. In another words, the > > > sched_switch run on the CPU we want the thread to migrate onto restores > > > thread context before it was actually stored on another core - that > causes > > > setting regs/pc/lt to some junk data and crash. > > > > > > > > > I'd like to discuss a possible solution for this. I think it would be > > > reasonable to extend cpu_switch to be capable of releasing a lock as > the > > > last thing it does after storing everything into the PCB. We could then > > > remove the "TDQ_UNLOCK(tdn);" from the sched_switch_migrate and be sure > > > that in the situation of migration nobody is allowed to touch the > target > > > runqueue until the migrating process finishes storing its context. > > > > > > But first I'd like to discuss some possible alternatives and maybe find > > > another solution, because any change in this area will impact all > supported > > > architectures. > > > > This belongs on hackers, not developers@. > > > > cpu_switch() already does what you describe though in a slightly > different > > way. The thread_lock() of a thread being switched out is set to > blocked_lock. > > cpu_switch() on the new CPU will always spin until cpu_switch updates > > thread_lock of the old thread to point to the proper runq lock after > saving > > its state in the pcb. arm64 does this here: > > > > /* > > * Release the old thread. This doesn't need to be a > store-release > > * as the above dsb instruction will provide release semantics. > > */ > > str x2, [x0, #TD_LOCK] > > #if defined(SCHED_ULE) && defined(SMP) > > /* Read the value in blocked_lock */ > > ldr x0, =_C_LABEL(blocked_lock) > > ldr x2, [x0] > > 1: > > ldar x3, [x1, #TD_LOCK] > > cmp x3, x2 > > b.eq 1b > > #endif > > > > Note the thread_lock_block() call just above the block you noted from > > sched_switch_migrate() to see where td_lock is set to &blocked_lock. > > > > If the comment about 'dsb' above is wrong that might explain why you see > > stale state in the PCB after seeing the new value of td_lock. > > > > -- > > John Baldwin > From owner-freebsd-hackers@freebsd.org Wed Jan 27 19:31:59 2016 Return-Path: Delivered-To: freebsd-hackers@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 54636A6F7E9 for ; Wed, 27 Jan 2016 19:31:59 +0000 (UTC) (envelope-from feld@FreeBSD.org) Received: from out5-smtp.messagingengine.com (out5-smtp.messagingengine.com [66.111.4.29]) (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 2F5C0139D for ; Wed, 27 Jan 2016 19:31:58 +0000 (UTC) (envelope-from feld@FreeBSD.org) Received: from compute3.internal (compute3.nyi.internal [10.202.2.43]) by mailout.nyi.internal (Postfix) with ESMTP id 1FF7C21877 for ; Wed, 27 Jan 2016 14:31:58 -0500 (EST) Received: from web6 ([10.202.2.216]) by compute3.internal (MEProxy); Wed, 27 Jan 2016 14:31:58 -0500 DKIM-Signature: v=1; a=rsa-sha1; c=relaxed/relaxed; d= messagingengine.com; h=content-transfer-encoding:content-type :date:from:in-reply-to:message-id:mime-version:references :subject:to:x-sasl-enc:x-sasl-enc; s=smtpout; bh=6SdqbFtA4/HAdJA 4WsMpWk6IFmQ=; b=ZiPP0gTpjhUuRaSZp2lp559QRCxG+D3dWoyFYrE6Rbz4CKE BRbFn+J3v3QREUYkEJQC3qQWswNTQuZevQnUFmmxRUiTjFt45nf3XkXh93y/Rjds ppyK198T12qM7hqNTfUZu5bwmp0cC1UbYldQxEJ8+ZDPParV0Yfau1BAJl90= Received: by web6.nyi.internal (Postfix, from userid 99) id E7D9748762; Wed, 27 Jan 2016 14:31:57 -0500 (EST) Message-Id: <1453923117.431542.504383322.05A41332@webmail.messagingengine.com> X-Sasl-Enc: GHGZo9Su21th7KL9gc9/2t5t4Wx59PLpWaV5G3UUHekj 1453923117 From: Mark Felder To: Jan Bramkamp , freebsd-hackers@freebsd.org MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Content-Type: text/plain X-Mailer: MessagingEngine.com Webmail Interface - ajax-6cda141f Subject: Re: syslogd(8) with OOM Killer protection Date: Wed, 27 Jan 2016 13:31:57 -0600 In-Reply-To: <56A89D7A.8080906@rlwinm.de> References: <56A86D91.3040709@freebsd.org> <20160127072850.GG35911@ivaldir.etoilebsd.net> <56A89D7A.8080906@rlwinm.de> X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.20 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 27 Jan 2016 19:31:59 -0000 On Wed, Jan 27, 2016, at 04:35, Jan Bramkamp wrote: > > I would prefer to implement the a flag keeping cron (and all other base > system daemons) from double-forking and run it under a process > supervisor like daemontools. > There are complications preventing this from being possible in a clean way with rc.subr (stop/status/etc will break), but if we were able to solve them we could offer the ability to run anything we wanted under daemon(8) with the -r flag which will automatically supervise and restart the process if it dies. -- Mark Felder ports-secteam member feld@FreeBSD.org From owner-freebsd-hackers@freebsd.org Wed Jan 27 19:14:46 2016 Return-Path: Delivered-To: freebsd-hackers@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 1DE55A6F0C5 for ; Wed, 27 Jan 2016 19:14:46 +0000 (UTC) (envelope-from zbb@semihalf.com) Received: from mailman.ysv.freebsd.org (mailman.ysv.freebsd.org [IPv6:2001:1900:2254:206a::50:5]) by mx1.freebsd.org (Postfix) with ESMTP id F1DFF172E for ; Wed, 27 Jan 2016 19:14:45 +0000 (UTC) (envelope-from zbb@semihalf.com) Received: by mailman.ysv.freebsd.org (Postfix) id EF197A6F0C3; Wed, 27 Jan 2016 19:14:45 +0000 (UTC) Delivered-To: hackers@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id D3DE5A6F0C1 for ; Wed, 27 Jan 2016 19:14:45 +0000 (UTC) (envelope-from zbb@semihalf.com) Received: from mail-lb0-x230.google.com (mail-lb0-x230.google.com [IPv6:2a00:1450:4010:c04::230]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (Client CN "smtp.gmail.com", Issuer "Google Internet Authority G2" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 56F89172A for ; Wed, 27 Jan 2016 19:14:45 +0000 (UTC) (envelope-from zbb@semihalf.com) Received: by mail-lb0-x230.google.com with SMTP id x4so11226295lbm.0 for ; Wed, 27 Jan 2016 11:14:45 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=semihalf-com.20150623.gappssmtp.com; s=20150623; h=mime-version:in-reply-to:references:from:date:message-id:subject:to :cc:content-type; bh=IB8NEMfbkpKIaCQnIYLIjxV25JoGoOp6BOyQnI8WjLE=; b=R8jUylnKqj+9uQTeni+WLlvgh4IrxwecYKqBqqDBl3AxzTwCNq2JW7lkI4EwJlyIv0 mMWI296XNFElSgh90tkCSNI4Ovjh0F3n+aIJ5DKUAqZEgf73d26V5IYV6kuOd9H15Q+k MIDn0nGukOtHXCGKCQI6RdvwdJiufHoxaep7jMwQEclCoemHAT0TnAgGfgdkXuFthC6Q rULaTvAcksJaP93DUMWg1yoCapi42Bg0W4o0VI+2AOzmYz8W4TjCUQJFIXkMQC75+dbE aGekP6DYRxirYK8ven8CykmoSJDjdwfncfFBkuoVSbC959y6ybFdnZVk41HN/eeUCK26 7krQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:mime-version:in-reply-to:references:from:date :message-id:subject:to:cc:content-type; bh=IB8NEMfbkpKIaCQnIYLIjxV25JoGoOp6BOyQnI8WjLE=; b=JopKYYpZOeOKwXx0qoC9S7iQ1KiczH0uE8UCat8ORn8a7zr8k3wv8HFBDqpadm/juf mC+VsCXUVcvyiMJP+eSHxYfhFz0wKpoXNHnYexe5U8rTRAfIR94+ts20qOVhnqOuVZq+ 3SiBOq/58Jn7PsK6Nx0GL2HN5kIcPcQeMCTcGSBe8w+2ESf0AqlW0KCnykDd2YEUiW5j 0BTawBShgbf3cpHl/gI0OTsTPwxoN5RgP8CBc8/moQcZy1X/3MbORxxdjdM2EcPjwHG5 Iw4nihLnRGqO6q9wVrPq50Ad+7Ja9Edo3bSNXY5mazGC13bntGV+mRRAAbkcZpvQt9Vg J64w== X-Gm-Message-State: AG10YORFVuenO/xVKoiCAA/rSmH2T0ELzrbJHg/DJOqV9mkBvE4eoqqWZ9e2vMNAZFzrOSz8gEcExiE3zvkTEQ== X-Received: by 10.112.209.99 with SMTP id ml3mr11218222lbc.26.1453922083428; Wed, 27 Jan 2016 11:14:43 -0800 (PST) MIME-Version: 1.0 Received: by 10.25.198.7 with HTTP; Wed, 27 Jan 2016 11:14:23 -0800 (PST) In-Reply-To: <20160127184822.GE74231@kib.kiev.ua> References: <2587742.rOiGAYXjN1@ralph.baldwin.cx> <20160127181426.GA48838@ci0.org> <20160127184822.GE74231@kib.kiev.ua> From: Zbigniew Bodek Date: Wed, 27 Jan 2016 20:14:23 +0100 Message-ID: Subject: Re: SCHED_ULE race condition, fix proposal To: Konstantin Belousov Cc: Olivier Houchard , arm64-dev , "freebsd-arm@freebsd.org" , hackers@freebsd.org, John Baldwin X-Mailman-Approved-At: Wed, 27 Jan 2016 19:42:28 +0000 Content-Type: text/plain; charset=UTF-8 X-Content-Filtered-By: Mailman/MimeDel 2.1.20 X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.20 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 27 Jan 2016 19:14:46 -0000 2016-01-27 19:48 GMT+01:00 Konstantin Belousov : > On Wed, Jan 27, 2016 at 07:14:26PM +0100, Olivier Houchard wrote: > > Hi, > > > > I may be reading the arm64 code wrong, but shouldn't : > > ldr x0, =_C_LABEL(blocked_lock) > > ldr x2, [x0] > > > > be just: > > ldr x2, =_C_LABEL(blocked_lock) > > You are right, I believe. > Hah! Great catch! :-) Best regards zbb From owner-freebsd-hackers@freebsd.org Wed Jan 27 22:53:37 2016 Return-Path: Delivered-To: freebsd-hackers@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id DB309A7031C for ; Wed, 27 Jan 2016 22:53:37 +0000 (UTC) (envelope-from vangyzen@FreeBSD.org) Received: from smtp.vangyzen.net (hotblack.vangyzen.net [199.48.133.146]) by mx1.freebsd.org (Postfix) with ESMTP id C44B9AF2 for ; Wed, 27 Jan 2016 22:53:37 +0000 (UTC) (envelope-from vangyzen@FreeBSD.org) Received: from sweettea.beer.town (unknown [76.164.8.130]) by smtp.vangyzen.net (Postfix) with ESMTPSA id B8D875648E; Wed, 27 Jan 2016 16:53:30 -0600 (CST) Subject: Re: EFI/ZFS Update: successful tests, need more complex vdevs To: Steven Hartland , freebsd-hackers@freebsd.org References: <9418E44F-114E-4ABA-A32D-416297BCDA9F@metricspace.net> <56985C6A.6040209@multiplay.co.uk> <5698E483.4000808@multiplay.co.uk> From: Eric van Gyzen X-Enigmail-Draft-Status: N1110 Cc: Eric McCorkle Message-ID: <56A94A68.6000309@FreeBSD.org> Date: Wed, 27 Jan 2016 16:53:28 -0600 User-Agent: Mozilla/5.0 (X11; FreeBSD amd64; rv:38.0) Gecko/20100101 Thunderbird/38.5.0 MIME-Version: 1.0 In-Reply-To: <5698E483.4000808@multiplay.co.uk> Content-Type: text/plain; charset=windows-1252 Content-Transfer-Encoding: 7bit X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.20 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 27 Jan 2016 22:53:37 -0000 On 01/15/2016 06:22, Steven Hartland wrote: > On 15/01/2016 11:51, Renato Botelho wrote: >>> On Jan 15, 2016, at 00:41, Steven Hartland >>> wrote: >>> >>> Just wanted to let everyone know that I just finished committing >>> these changes to the tree. >>> >>> Huge thanks to Eric's for his work on this, as well as everyone else >>> who contributed. >>> >>> I've set the target for MFC of 2 weeks, so I hope to be able to get >>> this into stable/10 before the 10.3 slush, so if you're interested >>> in this change please test a head build > r294068 ASAP. >> Great work, thanks! >> >> Is there a way to move a installed ZFS system to EFI? > > All EFI needs is an valid EFI partition on a GPT disk and the updated > loader.efi so if your devices is GPT based and you have space for an > extra 800k partition then yes. > > The following should be the basic steps you need (untested so backup > your data) > 1. gpart add -t efi -s 800k > 2. gpart bootcode -p /boot/boot1.efifat -i > 3. Ensure your root filesystem has EFI ZFS boot compatible world e.g. > cd /usr/src && make buildworld -jXX && make installworld > > If you have an active MBR then you will likely need to disable this as > EFI seems to ignore disks with active MBR even if they have a valid > EFI partition. > > If you don't have space then you'll need to migrate to a difference > device to change the disk partition layout. I just used the above procedure to convert a Dell PowerEdge R320 to ZFS+EFI. It works. Thanks for your hard work, Eric and Steven. I'm looking forward to this hitting 10.3 (hint hint). smbios.bios.reldate="05/11/2012" smbios.bios.version="1.2.4" smbios.system.maker="Dell Inc." smbios.system.product="PowerEdge R320" machdep.bootmethod: UEFI FreeBSD 11.0-CURRENT #6 r294934M: Wed Jan 27 15:43:59 CST 2016 ... sys/GENERIC => 40 976773088 mfisyspd0 GPT (466G) 40 1024 1 freebsd-boot (512K) 1064 1600 2 efi (800K) 2664 33552832 4 freebsd-swap (16G) 33555496 943217632 3 freebsd-zfs (450G) NAME STATE READ WRITE CKSUM zroot ONLINE 0 0 0 mfisyspd0p3 ONLINE 0 0 0 mfi0 Adapter: Product Name: PERC H310 Mini Firmware: 20.10.1-0084 mfi0 Physical Drives: 0 ( 466G) JBOD SATA E1:S0 (The root pool is just a single SATA disk.) From owner-freebsd-hackers@freebsd.org Wed Jan 27 23:55:19 2016 Return-Path: Delivered-To: freebsd-hackers@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 26877A703DA for ; Wed, 27 Jan 2016 23:55:19 +0000 (UTC) (envelope-from asomers@gmail.com) Received: from mail-ob0-x22f.google.com (mail-ob0-x22f.google.com [IPv6:2607:f8b0:4003:c01::22f]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (Client CN "smtp.gmail.com", Issuer "Google Internet Authority G2" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id E52FB315 for ; Wed, 27 Jan 2016 23:55:18 +0000 (UTC) (envelope-from asomers@gmail.com) Received: by mail-ob0-x22f.google.com with SMTP id vt7so21897120obb.1 for ; Wed, 27 Jan 2016 15:55:18 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:sender:date:message-id:subject:from:to:content-type; bh=OYF1ownZEmvvEbToszBAHFZ5XQ2RqiI7IKjV4E8wMl8=; b=zR4JNvyk8/o1ZD/bac0sVE3CnYa1AmI3AJ27fbvYf3L7vqcbl9ZITn08bgUkB0O7pZ u0VxVbI1dd2FQptk2T3XxzYKrhDCufUzfRPxjs04KSIrNgYR+G4MesJAih9q/Kg/rmBg hIFUCik1MGh8nTo2K/4eqjENvmz+xDimvlqiparGsGBvlIbEOWqXCMjL7neg+CCZUpc+ PLac6WTjBtC8CSfuYYhp4rbBrDGf57X7LL4Dzh909pC4kPjJx4eVChYmdRz/RSmdAO6b 4XcIYuQ80OjE+SZHJLEUk6DychWWjRGw1rkbVv2UlqLIu5utMESvF3/VvdCCzYPLtQ/2 9x6g== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:mime-version:sender:date:message-id:subject:from :to:content-type; bh=OYF1ownZEmvvEbToszBAHFZ5XQ2RqiI7IKjV4E8wMl8=; b=SNsgh0sze44Bk7Wg/eztF6CZ0V5L7yTSyRVYqxf/zQtBEHDTQm8A0AUVVmABwxyg// 38RobrHiN6odNJCRClhJW7rbRi2EcPsoC9qEF6ia8vy42Uqxkzd1CLj1SDm1RYyQq7p2 x9SnFJSP+PLXaMuHFGhFS565kQo1lk20Y6jxNh9X1K1rJpJxRVHZNcvmOGogHkpltuBX qyV9J50AwcDaWT6HAiSG0lfCWm5LypbvDgOIg6yhtJ8pjSNTTvYHsixvQBUybUTEZprH spR7qMoSb7PM05MW8cVTM6SQubJiaEDU9+1+wq4yECI3LnsgklYKHAgTM0BqX0rm8rz/ iZ1A== X-Gm-Message-State: AG10YORn/+BIle2J+7RsWHPseJ2A2cvZj7sbBjVvCq59zilTkQFcTWoUz2dtphzGNJ21lmti2MusTgF7MPq2PQ== MIME-Version: 1.0 X-Received: by 10.182.79.103 with SMTP id i7mr24128291obx.41.1453938918147; Wed, 27 Jan 2016 15:55:18 -0800 (PST) Sender: asomers@gmail.com Received: by 10.202.69.86 with HTTP; Wed, 27 Jan 2016 15:55:18 -0800 (PST) Date: Wed, 27 Jan 2016 16:55:18 -0700 X-Google-Sender-Auth: 3aqQGa4zbeN03QlNzPXEHbcBMIc Message-ID: Subject: aesni doesn't play nice with krb5 From: Alan Somers To: "freebsd-hackers@freebsd.org" Content-Type: text/plain; charset=UTF-8 X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.20 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 27 Jan 2016 23:55:19 -0000 I'm experimenting with Kerberized NFS, but my performance sucks when I use krb5p. I tracked the problem down to an interaction between aesni and krb5: aes_set_key in kcrypto_aes.c registers for a crypto session and requests support for two algorithms: CRYPTO_SHA1_HMAC and CRYPTO_AES_CBC. aesni(4) supports the latter, but not the former. So crypto_select_driver returns cryptosoft and krb5 uses software for both algorithms. It's too bad that aesni doesn't support SHA1, but other software like OpenSSL deals with it by using hardware for AES and software for SHA1. It seems to me like krb5 could be made to do the same by registering for two sessions, one for each algorithm. In fact, it seems like it would be pretty easy to do. The changes would probably be confined strictly to crypto_aes.c. Is there any reason why this wouldn't work? -Alan From owner-freebsd-hackers@freebsd.org Thu Jan 28 00:45:58 2016 Return-Path: Delivered-To: freebsd-hackers@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id EEC88A6F7B7 for ; Thu, 28 Jan 2016 00:45:58 +0000 (UTC) (envelope-from araujobsdport@gmail.com) Received: from mail-ob0-x232.google.com (mail-ob0-x232.google.com [IPv6:2607:f8b0:4003:c01::232]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (Client CN "smtp.gmail.com", Issuer "Google Internet Authority G2" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id B449C1BC5; Thu, 28 Jan 2016 00:45:58 +0000 (UTC) (envelope-from araujobsdport@gmail.com) Received: by mail-ob0-x232.google.com with SMTP id is5so22700463obc.0; Wed, 27 Jan 2016 16:45:58 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:reply-to:in-reply-to:references:date:message-id :subject:from:to:cc:content-type; bh=F1FLkobK2BbK5FX3fZtuJSrbilSvMEswhi92vhyAD2w=; b=sdsbTSQWNtENmOp0QEOOoebu+rI7joT0bvtE5nQP0arxoa5xhU83WCLZ9k8axxcFj8 AOkxPUjv8DLvrPUOSIj1eNlI9bGNYjLXKoXo4pEKcaGrs92hgM+pjAOT8tczmBlxYoaK 5wWdoNOMpK2HWrA++E3Xu4CEH7m/ymxrrs2N/T73pZuSNuKqqlm/tCo2GHE2wXOR/f87 iPUmmsGC5pTlvEbtp/PG4AS7ct5zBak89cQZS9Ew8sNoDrGsEixYR/RYlsl+Q2LyF1jh Wz2CsUzD4OF1tGXq3jM/bUbbuzVSqdOJ5nyP9tIkunyIdAOGcsOzKUydPyWKFZgqoniK M5kw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:mime-version:reply-to:in-reply-to:references :date:message-id:subject:from:to:cc:content-type; bh=F1FLkobK2BbK5FX3fZtuJSrbilSvMEswhi92vhyAD2w=; b=bYmgZv9YwoCKARsfyd4XWx5Sepbi+puB0+h0Vf1a4nBuRT4gjmkiFbxq9MJWIns5q+ 5AegDASyQsJW5aeZyE56c9xRqvWreE1/R8mc9oisdJ9Dr+UA7baxOUune3tE+MFRso2W /Vq560rvnf4e5cOpPjcTLrhKBeGXI53JBwTCBP7BeES7+k98KFBUy8weyj93KV6VlmuJ skpewhhI+VJEq/shzUtjkCz07Ak0pEMb+IRBDqzzXjZKIWGjGvqg6meoIjho/i3OIcYE XPZso04SbLgR3YrntNWf1LKTfQP7xytJMyGSaqRpEyHYByllPfW4Fdhkb3Oo3Cmxc0wk xDQg== X-Gm-Message-State: AG10YOTHk7Ii/7+W9pS+UzCnH/c6vCp+9g3c1kt57AF69Tvrd5JoZg5Dxxtdu4feXTcDCn77AyH06TMJ8PpIOg== MIME-Version: 1.0 X-Received: by 10.182.133.37 with SMTP id oz5mr153386obb.16.1453941957936; Wed, 27 Jan 2016 16:45:57 -0800 (PST) Received: by 10.182.40.194 with HTTP; Wed, 27 Jan 2016 16:45:57 -0800 (PST) Received: by 10.182.40.194 with HTTP; Wed, 27 Jan 2016 16:45:57 -0800 (PST) Reply-To: araujo@FreeBSD.org In-Reply-To: <1453923117.431542.504383322.05A41332@webmail.messagingengine.com> References: <56A86D91.3040709@freebsd.org> <20160127072850.GG35911@ivaldir.etoilebsd.net> <56A89D7A.8080906@rlwinm.de> <1453923117.431542.504383322.05A41332@webmail.messagingengine.com> Date: Thu, 28 Jan 2016 08:45:57 +0800 Message-ID: Subject: Re: syslogd(8) with OOM Killer protection From: Marcelo Araujo To: Mark Felder Cc: freebsd-hackers@freebsd.org, Jan Bramkamp Content-Type: text/plain; charset=UTF-8 X-Content-Filtered-By: Mailman/MimeDel 2.1.20 X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.20 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 28 Jan 2016 00:45:59 -0000 On Jan 28, 2016 3:32 AM, "Mark Felder" wrote: > > > > On Wed, Jan 27, 2016, at 04:35, Jan Bramkamp wrote: > > > > I would prefer to implement the a flag keeping cron (and all other base > > system daemons) from double-forking and run it under a process > > supervisor like daemontools. > > > > There are complications preventing this from being possible in a clean > way with rc.subr (stop/status/etc will break), but if we were able to > solve them we could offer the ability to run anything we wanted under > daemon(8) with the -r flag which will automatically supervise and > restart the process if it dies. The idea is protect against OOM kill. IMHO anything that has auto restart can present a security issue to be exploited. I'm a bit pragmatic, but supervises and restart a daemon without human being intervention can create a security issue. Best, > > -- > Mark Felder > ports-secteam member > feld@FreeBSD.org > _______________________________________________ > freebsd-hackers@freebsd.org mailing list > https://lists.freebsd.org/mailman/listinfo/freebsd-hackers > To unsubscribe, send any mail to "freebsd-hackers-unsubscribe@freebsd.org" From owner-freebsd-hackers@freebsd.org Thu Jan 28 02:21:25 2016 Return-Path: Delivered-To: freebsd-hackers@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 423EFA6FD16 for ; Thu, 28 Jan 2016 02:21:25 +0000 (UTC) (envelope-from stas@FreeBSD.org) Received: from mx0.deglitch.com (mx0.deglitch.com [IPv6:2a00:13c0:63:7194:1::3]) by mx1.freebsd.org (Postfix) with ESMTP id 0BD341CCF; Thu, 28 Jan 2016 02:21:25 +0000 (UTC) (envelope-from stas@FreeBSD.org) Received: from [IPv6:2620:10d:c082:1803:1501:3fff:d17f:e85] (unknown [IPv6:2620:10d:c090:200::f:636d]) by mx0.deglitch.com (Postfix) with ESMTPSA id 5626F8FC0A; Wed, 27 Jan 2016 18:21:14 -0800 (PST) Content-Type: text/plain; charset=us-ascii Mime-Version: 1.0 (Mac OS X Mail 9.2 \(3112\)) Subject: Re: aesni doesn't play nice with krb5 From: Stanislav Sedov In-Reply-To: Date: Wed, 27 Jan 2016 18:21:11 -0800 Cc: "freebsd-hackers@freebsd.org" Content-Transfer-Encoding: 7bit Message-Id: References: To: Alan Somers X-Mailer: Apple Mail (2.3112) X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.20 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 28 Jan 2016 02:21:25 -0000 > On Jan 27, 2016, at 3:55 PM, Alan Somers wrote: > > I'm experimenting with Kerberized NFS, but my performance sucks when I > use krb5p. I tracked the problem down to an interaction between aesni > and krb5: aes_set_key in kcrypto_aes.c registers for a crypto session > and requests support for two algorithms: CRYPTO_SHA1_HMAC and > CRYPTO_AES_CBC. aesni(4) supports the latter, but not the former. So > crypto_select_driver returns cryptosoft and krb5 uses software for > both algorithms. > > It's too bad that aesni doesn't support SHA1, but other software like > OpenSSL deals with it by using hardware for AES and software for SHA1. > It seems to me like krb5 could be made to do the same by registering > for two sessions, one for each algorithm. In fact, it seems like it > would be pretty easy to do. The changes would probably be confined > strictly to crypto_aes.c. Is there any reason why this wouldn't work? > This sounds great to me. Might be worth checking with the upstream Heimdal project to see if they might have some suggestions. But we can definitely apply this change locally in FreeBSD as we're probably affected by this more than other Heimdal consumers (who do not rely on encryption that much). -- Stanislav Sedov ST4096-RIPE From owner-freebsd-hackers@freebsd.org Thu Jan 28 08:43:56 2016 Return-Path: Delivered-To: freebsd-hackers@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 439A3A71912 for ; Thu, 28 Jan 2016 08:43:56 +0000 (UTC) (envelope-from kostikbel@gmail.com) Received: from kib.kiev.ua (kib.kiev.ua [IPv6:2001:470:d5e7:1::1]) (using TLSv1 with cipher DHE-RSA-CAMELLIA256-SHA (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id B5E1C12EA; Thu, 28 Jan 2016 08:43:55 +0000 (UTC) (envelope-from kostikbel@gmail.com) Received: from tom.home (kostik@localhost [127.0.0.1]) by kib.kiev.ua (8.15.2/8.15.2) with ESMTPS id u0S8hosw010277 (version=TLSv1 cipher=DHE-RSA-CAMELLIA256-SHA bits=256 verify=NO); Thu, 28 Jan 2016 10:43:50 +0200 (EET) (envelope-from kostikbel@gmail.com) DKIM-Filter: OpenDKIM Filter v2.10.3 kib.kiev.ua u0S8hosw010277 Received: (from kostik@localhost) by tom.home (8.15.2/8.15.2/Submit) id u0S8hnon010276; Thu, 28 Jan 2016 10:43:49 +0200 (EET) (envelope-from kostikbel@gmail.com) X-Authentication-Warning: tom.home: kostik set sender to kostikbel@gmail.com using -f Date: Thu, 28 Jan 2016 10:43:49 +0200 From: Konstantin Belousov To: Stanislav Sedov Cc: Alan Somers , "freebsd-hackers@freebsd.org" Subject: Re: aesni doesn't play nice with krb5 Message-ID: <20160128084349.GJ74231@kib.kiev.ua> References: MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.5.24 (2015-08-30) X-Spam-Status: No, score=-2.0 required=5.0 tests=ALL_TRUSTED,BAYES_00, DKIM_ADSP_CUSTOM_MED,FREEMAIL_FROM,NML_ADSP_CUSTOM_MED autolearn=no autolearn_force=no version=3.4.1 X-Spam-Checker-Version: SpamAssassin 3.4.1 (2015-04-28) on tom.home X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.20 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 28 Jan 2016 08:43:56 -0000 On Wed, Jan 27, 2016 at 06:21:11PM -0800, Stanislav Sedov wrote: > > > On Jan 27, 2016, at 3:55 PM, Alan Somers wrote: > > > > I'm experimenting with Kerberized NFS, but my performance sucks when I > > use krb5p. I tracked the problem down to an interaction between aesni > > and krb5: aes_set_key in kcrypto_aes.c registers for a crypto session > > and requests support for two algorithms: CRYPTO_SHA1_HMAC and > > CRYPTO_AES_CBC. aesni(4) supports the latter, but not the former. So > > crypto_select_driver returns cryptosoft and krb5 uses software for > > both algorithms. > > > > It's too bad that aesni doesn't support SHA1, but other software like > > OpenSSL deals with it by using hardware for AES and software for SHA1. > > It seems to me like krb5 could be made to do the same by registering > > for two sessions, one for each algorithm. In fact, it seems like it > > would be pretty easy to do. The changes would probably be confined > > strictly to crypto_aes.c. Is there any reason why this wouldn't work? > > > > This sounds great to me. Might be worth checking with the upstream > Heimdal project to see if they might have some suggestions. But we > can definitely apply this change locally in FreeBSD as we're probably > affected by this more than other Heimdal consumers (who do not rely on > encryption that much). > Could somebody clarify whether the session initiator is the code from user or kernel space ? My note is that utilizing AESNI through /dev/crypto is useless, the syscall overhead and kernel bookkeeping eats so much time that even software AES implementations are faster than AESNI through /dev/crypto. From owner-freebsd-hackers@freebsd.org Thu Jan 28 08:48:34 2016 Return-Path: Delivered-To: freebsd-hackers@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id C1C27A719F4 for ; Thu, 28 Jan 2016 08:48:34 +0000 (UTC) (envelope-from stas@freebsd.org) Received: from mx0.deglitch.com (mx0.deglitch.com [62.152.53.178]) by mx1.freebsd.org (Postfix) with ESMTP id 89BD414B4; Thu, 28 Jan 2016 08:48:34 +0000 (UTC) (envelope-from stas@freebsd.org) Received: from [IPv6:2601:646:8401:8465:d9b8:181a:a593:380c] (unknown [IPv6:2601:646:8401:8465:d9b8:181a:a593:380c]) by mx0.deglitch.com (Postfix) with ESMTPSA id 58CE88FC0A; Thu, 28 Jan 2016 00:48:30 -0800 (PST) Content-Type: text/plain; charset=utf-8 Mime-Version: 1.0 (Mac OS X Mail 9.2 \(3112\)) Subject: Re: aesni doesn't play nice with krb5 From: Stanislav Sedov In-Reply-To: <20160128084349.GJ74231@kib.kiev.ua> Date: Thu, 28 Jan 2016 00:48:49 -0800 Cc: Alan Somers , "freebsd-hackers@freebsd.org" Content-Transfer-Encoding: quoted-printable Message-Id: <6329AC49-E26B-4DB8-A897-77FE3C858C86@freebsd.org> References: <20160128084349.GJ74231@kib.kiev.ua> To: Konstantin Belousov X-Mailer: Apple Mail (2.3112) X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.20 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 28 Jan 2016 08:48:34 -0000 > On Jan 28, 2016, at 12:43 AM, Konstantin Belousov = wrote: >=20 > On Wed, Jan 27, 2016 at 06:21:11PM -0800, Stanislav Sedov wrote: >>=20 >>> On Jan 27, 2016, at 3:55 PM, Alan Somers = wrote: >>>=20 >>> I'm experimenting with Kerberized NFS, but my performance sucks when = I >>> use krb5p. I tracked the problem down to an interaction between = aesni >>> and krb5: aes_set_key in kcrypto_aes.c registers for a crypto = session >>> and requests support for two algorithms: CRYPTO_SHA1_HMAC and >>> CRYPTO_AES_CBC. aesni(4) supports the latter, but not the former. = So >>> crypto_select_driver returns cryptosoft and krb5 uses software for >>> both algorithms. >>>=20 >>> It's too bad that aesni doesn't support SHA1, but other software = like >>> OpenSSL deals with it by using hardware for AES and software for = SHA1. >>> It seems to me like krb5 could be made to do the same by registering >>> for two sessions, one for each algorithm. In fact, it seems like it >>> would be pretty easy to do. The changes would probably be confined >>> strictly to crypto_aes.c. Is there any reason why this wouldn't = work? >>>=20 >>=20 >> This sounds great to me. Might be worth checking with the upstream >> Heimdal project to see if they might have some suggestions. But we >> can definitely apply this change locally in FreeBSD as we're probably >> affected by this more than other Heimdal consumers (who do not rely = on >> encryption that much). >>=20 >=20 > Could somebody clarify whether the session initiator is the code > from user or kernel space ? My note is that utilizing AESNI through > /dev/crypto is useless, the syscall overhead and kernel bookkeeping = eats > so much time that even software AES implementations are faster than > AESNI through /dev/crypto. >=20 It=E2=80=99s actually in the kernel: sys/kgssapi/krb5/kcrypto_aes.c. = Please disregard my earlier reply as I somehow assumed we were talking about Heimdal, but now I realized that given it=E2=80=99s NFS encryption, it = obviously isn=E2=80=99t in userspace. -- ST4096-RIPE From owner-freebsd-hackers@freebsd.org Thu Jan 28 08:53:42 2016 Return-Path: Delivered-To: freebsd-hackers@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 0017DA71F07 for ; Thu, 28 Jan 2016 08:53:41 +0000 (UTC) (envelope-from nkoch@demig.de) Received: from demig.de (demig.de [81.169.228.196]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client CN "Parallels Panel", Issuer "Parallels Panel" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 498F41EB2 for ; Thu, 28 Jan 2016 08:53:40 +0000 (UTC) (envelope-from nkoch@demig.de) Received: (qmail 18721 invoked from network); 28 Jan 2016 09:45:15 +0100 Received: from b2b-130-180-89-86.unitymedia.biz (HELO firewall.demig.intra) (130.180.89.86) by demig.de with ESMTPSA (DHE-RSA-AES256-SHA encrypted, authenticated); 28 Jan 2016 09:45:15 +0100 Received: from SRV-FS-2.Demig.intra (nameserver.demig.intra [192.168.148.248]) by firewall.demig.intra (8.14.4/8.14.4) with ESMTP id u0S8iuBS028950 for ; Thu, 28 Jan 2016 09:44:56 +0100 (CET) (envelope-from nkoch@demig.de) Received: from [192.168.148.83] (192.168.148.83) by SRV-FS-2 (192.168.148.248) with Microsoft SMTP Server (TLS) id 14.3.123.3; Thu, 28 Jan 2016 09:44:50 +0100 From: Norbert Koch Subject: impossible to set pata dma mode? To: X-Enigmail-Draft-Status: N1110 Message-ID: <56A9D502.7010809@demig.de> Date: Thu, 28 Jan 2016 09:44:50 +0100 User-Agent: Mozilla/5.0 (Windows NT 5.1; rv:38.0) Gecko/20100101 Thunderbird/38.5.1 MIME-Version: 1.0 Content-Type: text/plain; charset="iso-8859-15" Content-Transfer-Encoding: 7bit X-Scanned-By: MIMEDefang 2.73 on 192.168.148.235 X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.20 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 28 Jan 2016 08:53:42 -0000 Hello. I have to reduce dma mode from udma to wdma2 for a flash device. In the past this was easy using atacontrol but, afaiks it seems to be impossible using camcontrol. camcontrol negotiate ada0 -M wdma ...You can only modify user parameters camcontrol negotiate ada0 -NM wdma Works, but I see no way how those user parameters become active parameters as the driver only reads then in attach as far as I can see. It seems like the ata driver's interface allows to change the current settings (XPT_SET_TRAN_SETTINGS/CTS_TYPE_CURRENT_SETTINGS) so, why is camcontrol so restrictive? Thank you, Norbert Koch From owner-freebsd-hackers@freebsd.org Thu Jan 28 09:03:42 2016 Return-Path: Delivered-To: freebsd-hackers@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 4FFB6A705DE for ; Thu, 28 Jan 2016 09:03:42 +0000 (UTC) (envelope-from nkoch@demig.de) Received: from demig.de (demig.de [81.169.228.196]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client CN "Parallels Panel", Issuer "Parallels Panel" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id B68411423 for ; Thu, 28 Jan 2016 09:03:41 +0000 (UTC) (envelope-from nkoch@demig.de) Received: (qmail 18979 invoked from network); 28 Jan 2016 10:03:37 +0100 Received: from b2b-130-180-89-86.unitymedia.biz (HELO firewall.demig.intra) (130.180.89.86) by demig.de with ESMTPSA (DHE-RSA-AES256-SHA encrypted, authenticated); 28 Jan 2016 10:03:37 +0100 Received: from SRV-FS-2.Demig.intra (nameserver.demig.intra [192.168.148.248]) by firewall.demig.intra (8.14.4/8.14.4) with ESMTP id u0S93J5w029071 for ; Thu, 28 Jan 2016 10:03:19 +0100 (CET) (envelope-from nkoch@demig.de) Received: from [192.168.148.83] (192.168.148.83) by SRV-FS-2 (192.168.148.248) with Microsoft SMTP Server (TLS) id 14.3.123.3; Thu, 28 Jan 2016 10:03:14 +0100 Subject: Re: impossible to set pata dma mode? To: References: <56A9D502.7010809@demig.de> From: Norbert Koch Message-ID: <56A9D951.5040500@demig.de> Date: Thu, 28 Jan 2016 10:03:13 +0100 User-Agent: Mozilla/5.0 (Windows NT 5.1; rv:38.0) Gecko/20100101 Thunderbird/38.5.1 MIME-Version: 1.0 In-Reply-To: <56A9D502.7010809@demig.de> Content-Type: text/plain; charset="windows-1252" Content-Transfer-Encoding: 7bit X-Scanned-By: MIMEDefang 2.73 on 192.168.148.235 X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.20 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 28 Jan 2016 09:03:42 -0000 Modifying camcontrol like below seems to cause no obvious problems (at least for me): --- /usr/src/sbin/camcontrol/camcontrol.c 2013-02-04 11:01:17.000000000 +0100 +++ camcontrol.c 2016-01-28 09:56:29.000000000 +0100 @@ -3617,12 +3617,14 @@ retval = 1; goto ratecontrol_bailout; } +#if 0 if (!user_settings) { warnx("You can modify only user mode " "settings for ATA/SATA"); retval = 1; goto ratecontrol_bailout; } +#endif if (pata) { pata->mode = mode; pata->valid |= CTS_ATA_VALID_MODE; Am 28.01.2016 um 09:44 schrieb Norbert Koch: > Hello. > > I have to reduce dma mode from udma to wdma2 > for a flash device. > > In the past this was easy using atacontrol > but, afaiks it seems to be impossible using camcontrol. > > camcontrol negotiate ada0 -M wdma > ...You can only modify user parameters > > camcontrol negotiate ada0 -NM wdma > Works, but I see no way how those user > parameters become active parameters as the > driver only reads then in attach as far as > I can see. > > It seems like the ata driver's interface > allows to change the current settings > (XPT_SET_TRAN_SETTINGS/CTS_TYPE_CURRENT_SETTINGS) > so, why is camcontrol so restrictive? > > Thank you, > Norbert Koch > _______________________________________________ > freebsd-hackers@freebsd.org mailing list > https://lists.freebsd.org/mailman/listinfo/freebsd-hackers > To unsubscribe, send any mail to "freebsd-hackers-unsubscribe@freebsd.org" -- Dipl.-Ing. Norbert Koch Entwicklung Prozessregler From owner-freebsd-hackers@freebsd.org Thu Jan 28 11:04:43 2016 Return-Path: Delivered-To: freebsd-hackers@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id CCD39A714AA for ; Thu, 28 Jan 2016 11:04:43 +0000 (UTC) (envelope-from killing@multiplay.co.uk) Received: from mail-wm0-x234.google.com (mail-wm0-x234.google.com [IPv6:2a00:1450:400c:c09::234]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (Client CN "smtp.gmail.com", Issuer "Google Internet Authority G2" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 6C1BA1164 for ; Thu, 28 Jan 2016 11:04:43 +0000 (UTC) (envelope-from killing@multiplay.co.uk) Received: by mail-wm0-x234.google.com with SMTP id r129so19317870wmr.0 for ; Thu, 28 Jan 2016 03:04:43 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=multiplay-co-uk.20150623.gappssmtp.com; s=20150623; h=subject:to:references:cc:from:message-id:date:user-agent :mime-version:in-reply-to:content-type; bh=c5cQulv5teeNacavrcItz+jHGbAF8wCGUMJLD8uhhf8=; b=JpJ0999cF5TiP6gw+9698TXAqEsEEPGyygeGLOHFtFMFJZm1SL8LOa7zNcqHvny2jq 2UN9597b8HU8zl6Eo7UDZknfosXE0/dJCzrsN91hHVx2GgHFMVDJYK5RuGulSGAsg6mZ GeCaPAm2kOh3QBZDDb30NEHvYlL8CaMZdUQ3dsLI7cB1+shCyDuZMYN3m7DBUD7jFoC+ HZLnzekNgquClNCLyiXmx1amIWBYZm/KqYzyyOmgBn2yEONJCLMwsGHPAIfDfa0P7nyX SBtXzWfNzf1L3Aa8hRt2dfKHFmcmxq666ahDmSoSaNk+nCAQDon4K9NoRtlFWYTopms1 C7Xw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:subject:to:references:cc:from:message-id:date :user-agent:mime-version:in-reply-to:content-type; bh=c5cQulv5teeNacavrcItz+jHGbAF8wCGUMJLD8uhhf8=; b=L8cRGZOcHHURZUqpUSV71B8FRKijmK/uufEXW6OcGz/PmVyd2ZD1Doj/zkQHVdZECd kg7zhOOZeLEsp/pETJ2pedO/HfokpqQpjMtKT04Zk/HLtjFjIkCj7ApnnW8AV25AvMRI mGQ2xdl2kVtSw5Qzhb8cwf3WQWEqS0DwfcovZD0DkabgJaQAKfyhhhSUPTzPljB8lwZU pkUkUgqTwEtGoh9dfPjRvyyqGaaU5aJsvqtKmYovIJqi+0qtsONGw9o97q0htCitiLk2 3+Sx2jFd/SOFMlomX2uJbYxCHnzKmJX1NEizWgocTBsuuqp0Eblux9AaiWRoHnOEq2W7 Lhlg== X-Gm-Message-State: AG10YOQc7U4mV00Z6uGoDtkDk3Pu2IWyWKdtEDyZhRUOAKRkzURmbeixXxD9yXSlYRKwoF5D X-Received: by 10.28.177.85 with SMTP id a82mr2326268wmf.57.1453979081506; Thu, 28 Jan 2016 03:04:41 -0800 (PST) Received: from [10.10.1.58] (liv3d.labs.multiplay.co.uk. [82.69.141.171]) by smtp.gmail.com with ESMTPSA id 193sm2317440wmg.16.2016.01.28.03.04.39 (version=TLSv1/SSLv3 cipher=OTHER); Thu, 28 Jan 2016 03:04:39 -0800 (PST) Subject: Re: EFI/ZFS Update: successful tests, need more complex vdevs To: krad References: <9418E44F-114E-4ABA-A32D-416297BCDA9F@metricspace.net> <56985C6A.6040209@multiplay.co.uk> Cc: Eric McCorkle , Gabor Radnai , freebsd-hackers@freebsd.org From: Steven Hartland Message-ID: <56A9F5D7.40104@multiplay.co.uk> Date: Thu, 28 Jan 2016 11:04:55 +0000 User-Agent: Mozilla/5.0 (Windows NT 10.0; WOW64; rv:38.0) Gecko/20100101 Thunderbird/38.5.1 MIME-Version: 1.0 In-Reply-To: Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: 7bit X-Content-Filtered-By: Mailman/MimeDel 2.1.20 X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.20 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 28 Jan 2016 11:04:44 -0000 I'm working on the pre-fix MFC's today but given the nature of the changes and the lateness in the release cycle I need to work the re@ on if we can MFC the main changes for 10.3, but its definitely something I want to see happen so fingers crossed... On 28/01/2016 09:31, krad wrote: > Is the MFC still on course? I'm in a position to test on current today > or tomorrow, but am wondering now it its worth waiting a day until > it's in 10-Stable? > > On 15 January 2016 at 02:41, Steven Hartland > wrote: > > Just wanted to let everyone know that I just finished committing > these changes to the tree. > > Huge thanks to Eric's for his work on this, as well as everyone > else who contributed. > > I've set the target for MFC of 2 weeks, so I hope to be able to > get this into stable/10 before the 10.3 slush, so if you're > interested in this change please test a head build > r294068 ASAP. > > Regards > Steve > _______________________________________________ > freebsd-hackers@freebsd.org > mailing list > https://lists.freebsd.org/mailman/listinfo/freebsd-hackers > To unsubscribe, send any mail to > "freebsd-hackers-unsubscribe@freebsd.org > " > > From owner-freebsd-hackers@freebsd.org Thu Jan 28 12:08:04 2016 Return-Path: Delivered-To: freebsd-hackers@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 3AC30A70CFD for ; Thu, 28 Jan 2016 12:08:04 +0000 (UTC) (envelope-from wjw@digiware.nl) Received: from smtp.digiware.nl (unknown [IPv6:2001:4cb8:90:ffff::3]) (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 0586B1035; Thu, 28 Jan 2016 12:08:03 +0000 (UTC) (envelope-from wjw@digiware.nl) Received: from rack1.digiware.nl (unknown [127.0.0.1]) by smtp.digiware.nl (Postfix) with ESMTP id CB613153402; Thu, 28 Jan 2016 13:07:51 +0100 (CET) X-Virus-Scanned: amavisd-new at digiware.nl Received: from smtp.digiware.nl ([127.0.0.1]) by rack1.digiware.nl (rack1.digiware.nl [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id cmsvUaB2Jnpr; Thu, 28 Jan 2016 13:07:32 +0100 (CET) Received: from [IPv6:2001:4cb8:3:1:399a:72bc:fe59:e022] (unknown [IPv6:2001:4cb8:3:1:399a:72bc:fe59:e022]) by smtp.digiware.nl (Postfix) with ESMTP id E119515340D; Thu, 28 Jan 2016 13:07:32 +0100 (CET) Subject: Re: syslogd(8) with OOM Killer protection To: araujo@FreeBSD.org, Warren Block References: <56A86D91.3040709@freebsd.org> Cc: freebsd-hackers@freebsd.org, Allan Jude From: Willem Jan Withagen Organization: Digiware Management b.v. Message-ID: <56AA047D.8070807@digiware.nl> Date: Thu, 28 Jan 2016 13:07:25 +0100 User-Agent: Mozilla/5.0 (Windows NT 10.0; WOW64; rv:38.0) Gecko/20100101 Thunderbird/38.5.1 MIME-Version: 1.0 In-Reply-To: Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: 7bit X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.20 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 28 Jan 2016 12:08:04 -0000 On 27-1-2016 17:40, Marcelo Araujo wrote: > On Jan 28, 2016 12:37 AM, "Warren Block" wrote: >> >> On Wed, 27 Jan 2016, Allan Jude wrote: >> >>> On 2016-01-27 01:21, Marcelo Araujo wrote: >>>> >>>> Hi guys, >>>> >>>> I would like to know your opinion about this REVIEW[1]. >>>> The basic idea is protect by default the syslogd(8) against been killed > by >>>> OOM with an option to disable the protection. >>>> >>>> Some people like the idea, other people would prefer something more > global >>>> where we can protect any daemon by the discretion of our choice. >>>> >>>> Thoughts? >>>> >>>> >>>> [1] https://reviews.freebsd.org/D4973 >>>> >>>> >>>> Best, >>>> >>> >>> I do like the idea of generalizing it, say via rc.subr >>> >>> So you can just do: >>> >>> someapp_protect=YES (and maybe syslogd has this enabled by default in >>> /etc/defaults/rc.conf) and it prefixes the start command with protect -i. >> >> >> Possibly simpler to provide a list in one setting than an individual > setting for each daemon. With ideas from other posters: >> >> oomprotect_daemons="crond syslogd" I would really NOT like that. I'm trying to keep settings per deamon together in a file in /etc/rc.conf.d/, and load configs from there. This makes daemon managment from external tools (puppet etc) a LOT easier. It can just copy a default file into /etc/rc.conf.d if it wants a daemon available on a server. Requiring a collection of damons in one config-options wil make that totally impossible. just my 2 cts., --WjW From owner-freebsd-hackers@freebsd.org Thu Jan 28 09:31:37 2016 Return-Path: Delivered-To: freebsd-hackers@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id C5DBCA6F3AA for ; Thu, 28 Jan 2016 09:31:37 +0000 (UTC) (envelope-from kraduk@gmail.com) Received: from mail-wm0-x22b.google.com (mail-wm0-x22b.google.com [IPv6:2a00:1450:400c:c09::22b]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (Client CN "smtp.gmail.com", Issuer "Google Internet Authority G2" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 7D5CA1A01 for ; Thu, 28 Jan 2016 09:31:37 +0000 (UTC) (envelope-from kraduk@gmail.com) Received: by mail-wm0-x22b.google.com with SMTP id l66so2061835wml.0 for ; Thu, 28 Jan 2016 01:31:37 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :cc:content-type; bh=UXhDbTVf2Kzmf8zAq5V+pP9DSvZYxc31LcdDk6lUTNc=; b=Oqq6RVmiwW7Snmi1kL1+o14AO+YP5mlihqHORn2iXYxJg8LDFd/RXrDa7CBkhmO4oO Wmb+uTa7+S16E7uz8RnjuRue7UBKpLMcjQPBQAGjHXzWS44j+0twjYIS/Mvy0Szu92+z 3SRIIQ083lSxLDVal8w5S5Sr0kNDOgaw6c+Tq02IdX6WcmyEv9w4BlIsyKTWunHBINKl 0lWCF/IA1hEJsWB9/a7p45TfupmVVlGJXnHkbxiyRV9ggYVnZE1ejxHoEdsYnRllDgRm lHB21fSfOE8t1UOAL7JOriASv4YDPWC2tJ/H5ASG5TorGBP5rJIcA43wF04FJD8UnawZ QnVA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:mime-version:in-reply-to:references:date :message-id:subject:from:to:cc:content-type; bh=UXhDbTVf2Kzmf8zAq5V+pP9DSvZYxc31LcdDk6lUTNc=; b=NpXlqxycqK9Q7v0klf4TKnXBc4+OndlrGmc+DOHURn9x8p8r5JTZEp/YVvrg+4NUTw d+Z0FANOJ4kEZH0tlpQTDPJxQT4xHSeIE7mXV8+LHh0vmiZrgE6ZlPJvoDCSrpyIYmci wRptN67ZmvKCgil8Nr7mltGq4KcWIlnfo9HlovOn1Hx6S4SoTN1zWLWCNzAaqEGN3HnC g7i1Qv/ba6ztXWd45OLbtWcNzNZGgCRGkqnQDqmruLwGDCuHqN4Xjtv+fhaU93trZ/nt ki6HUMZzGt1SFmKCMX8rJS7zAOLtlXcEVGvK+pZdq6jZ1bXErCc7QjkVaTt2ARIdDPJv 6b0A== X-Gm-Message-State: AG10YOQ5KJE8PPoRRhLtDwkysDyuj63K2nyroBYmGcLVhvLei/G8jzncnfIRBhMKLBlGe0ikGsBqRsBYku0MEw== MIME-Version: 1.0 X-Received: by 10.194.103.164 with SMTP id fx4mr1996378wjb.56.1453973495881; Thu, 28 Jan 2016 01:31:35 -0800 (PST) Received: by 10.28.55.132 with HTTP; Thu, 28 Jan 2016 01:31:35 -0800 (PST) In-Reply-To: <56985C6A.6040209@multiplay.co.uk> References: <9418E44F-114E-4ABA-A32D-416297BCDA9F@metricspace.net> <56985C6A.6040209@multiplay.co.uk> Date: Thu, 28 Jan 2016 09:31:35 +0000 Message-ID: Subject: Re: EFI/ZFS Update: successful tests, need more complex vdevs From: krad To: Steven Hartland Cc: Eric McCorkle , Gabor Radnai , freebsd-hackers@freebsd.org X-Mailman-Approved-At: Thu, 28 Jan 2016 12:33:16 +0000 Content-Type: text/plain; charset=UTF-8 X-Content-Filtered-By: Mailman/MimeDel 2.1.20 X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.20 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 28 Jan 2016 09:31:37 -0000 Is the MFC still on course? I'm in a position to test on current today or tomorrow, but am wondering now it its worth waiting a day until it's in 10-Stable? On 15 January 2016 at 02:41, Steven Hartland wrote: > Just wanted to let everyone know that I just finished committing these > changes to the tree. > > Huge thanks to Eric's for his work on this, as well as everyone else who > contributed. > > I've set the target for MFC of 2 weeks, so I hope to be able to get this > into stable/10 before the 10.3 slush, so if you're interested in this > change please test a head build > r294068 ASAP. > > Regards > Steve > _______________________________________________ > freebsd-hackers@freebsd.org mailing list > https://lists.freebsd.org/mailman/listinfo/freebsd-hackers > To unsubscribe, send any mail to "freebsd-hackers-unsubscribe@freebsd.org" > From owner-freebsd-hackers@freebsd.org Thu Jan 28 13:05:05 2016 Return-Path: Delivered-To: freebsd-hackers@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 72A4DA70368 for ; Thu, 28 Jan 2016 13:05:05 +0000 (UTC) (envelope-from eugen@grosbein.net) Received: from hz.grosbein.net (hz.grosbein.net [78.47.246.247]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (Client CN "hz.grosbein.net", Issuer "hz.grosbein.net" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 0B5E4178E; Thu, 28 Jan 2016 13:05:04 +0000 (UTC) (envelope-from eugen@grosbein.net) Received: from eg.sd.rdtc.ru (root@eg.sd.rdtc.ru [62.231.161.221]) by hz.grosbein.net (8.14.9/8.14.9) with ESMTP id u0SD4rxx048994 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NOT); Thu, 28 Jan 2016 14:04:54 +0100 (CET) (envelope-from eugen@grosbein.net) X-Envelope-From: eugen@grosbein.net X-Envelope-To: adrian.chadd@gmail.com Received: from eg.sd.rdtc.ru (eugen@localhost [127.0.0.1]) by eg.sd.rdtc.ru (8.15.2/8.15.2) with ESMTP id u0SD4gq3071548; Thu, 28 Jan 2016 20:04:43 +0700 (KRAT) (envelope-from eugen@grosbein.net) Subject: Re: syslogd(8) with OOM Killer protection To: Adrian Chadd , Marcelo Araujo References: Cc: "freebsd-hackers@freebsd.org" From: Eugene Grosbein Message-ID: <56AA11EA.1060903@grosbein.net> Date: Thu, 28 Jan 2016 20:04:42 +0700 User-Agent: Mozilla/5.0 (X11; FreeBSD amd64; rv:38.0) Gecko/20100101 Thunderbird/38.4.0 MIME-Version: 1.0 In-Reply-To: Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit X-Spam-Status: No, score=0.3 required=5.0 tests=BAYES_00,LOCAL_FROM autolearn=no version=3.3.2 X-Spam-Report: * -2.3 BAYES_00 BODY: Bayes spam probability is 0 to 1% * [score: 0.0000] * 2.6 LOCAL_FROM From my domains X-Spam-Checker-Version: SpamAssassin 3.3.2 (2011-06-06) on hz.grosbein.net X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.20 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 28 Jan 2016 13:05:05 -0000 On 27.01.2016 13:32, Adrian Chadd wrote: > I like it,how's it not done via some command line tool that we can run > any tool with? I've already responded to such idea in a comment to my original PR and like to repeat it here. IMHO, it is nearly impossible to correctly implement such protection for arbitrary daemonizing service by means of rc.subr, without modifications of service source code. Currently. We do have protect(1) utility but it only can protect single process it starts or all current/future children of started process and for daemons both cases are wrong: - protection of single process is meaningless because it forks to become daemon and that ceases protection; - protection of all future children is dangerous for daemons capable of running arbitrary subprocesses like syslogd can with "vertical bar" syntax of syslog.conf(5) as those future children may be "runaway" memory hogs. Perhaps, we could have kernel facility that keeps decreasing counter of forks and ceases protection of children when counter reaches zero level. Then teach protect(1) to (re-)set counter value and make rc.subr use it. From owner-freebsd-hackers@freebsd.org Thu Jan 28 13:49:18 2016 Return-Path: Delivered-To: freebsd-hackers@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 44E71A6F4BD for ; Thu, 28 Jan 2016 13:49:18 +0000 (UTC) (envelope-from araujobsdport@gmail.com) Received: from mail-ob0-x22b.google.com (mail-ob0-x22b.google.com [IPv6:2607:f8b0:4003:c01::22b]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (Client CN "smtp.gmail.com", Issuer "Google Internet Authority G2" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 042EC1AF0; Thu, 28 Jan 2016 13:49:18 +0000 (UTC) (envelope-from araujobsdport@gmail.com) Received: by mail-ob0-x22b.google.com with SMTP id is5so35558023obc.0; Thu, 28 Jan 2016 05:49:17 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:reply-to:in-reply-to:references:date:message-id :subject:from:to:cc:content-type; bh=/KY22Ez7U/CGMOvf11mXaGwSPxVO4MegYqlFV6MU5e8=; b=TBFeWqSQO5a1aE9SsQnAwhNxR0ZhRLqAp4N+Irl9DuSUAGV79MgpY/1+mKxSx+WY+c LIZz7wPk5xaEk+g/JnerddCJcUrr7NayvQ0K81aiYD+1V8emOTMkb4MqU8s7PH7w5Z75 mZ2BI/BC26zFK4nA+rVNRGjYp6lHpDOsqS/7ZbxckhrDzYtHRRk32qhCKkh0sClniPE+ 3WDwO+LWk0EhCNPZ4BiazRWOuoWOqhthe0knglwjsCYlo8UMMBD4J/VQpslqnhE80Ehe knilgS70mlbJSHshfXRnHTXPy3w0/wprkcWykseto8HyPCEiHBuRwLIHy9Okf5jqZd1f n2Yg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:mime-version:reply-to:in-reply-to:references :date:message-id:subject:from:to:cc:content-type; bh=/KY22Ez7U/CGMOvf11mXaGwSPxVO4MegYqlFV6MU5e8=; b=E55ooPE0wj5ygdzV6pDnrjWzDokAeQWBIRjSHy5uUiv490Tx27GVM9wmkkdz+EXCF4 acFmM8D3yf47oQOM0VhQ9PC2uO77vl+Gqj79X8zJJHllE0kK6twDj6r32ffvvyKhXFrQ jgXm31BnsXcPr/j6Oekg8eAac91d6NnKhCmDtIydHl/AnnOsUMmirqfbH4VPwPcIsq2E i9I5UZMed4+ptmUWiAJHOkv9RhVpfzDYBKuZUqxZbqT6F0AW7nVX8vMZfM6QoYkAC//g 2G0SGDIoa7kw/X+GMGdgzUHEP/xVn5XIluk35lTH3SfPqYygu2qyEpri/+i/2PG8ISry wzdA== X-Gm-Message-State: AG10YOS4zL7yztd41XkAqy6VwO3Vuv1aVdueaUN7i1QV53l66u+jstqUe02zvx2jOgVB5Sx+i8qObws6VItNtw== MIME-Version: 1.0 X-Received: by 10.182.133.37 with SMTP id oz5mr2285165obb.16.1453988957294; Thu, 28 Jan 2016 05:49:17 -0800 (PST) Received: by 10.182.5.138 with HTTP; Thu, 28 Jan 2016 05:49:17 -0800 (PST) Received: by 10.182.5.138 with HTTP; Thu, 28 Jan 2016 05:49:17 -0800 (PST) Reply-To: araujo@FreeBSD.org In-Reply-To: <56AA11EA.1060903@grosbein.net> References: <56AA11EA.1060903@grosbein.net> Date: Thu, 28 Jan 2016 21:49:17 +0800 Message-ID: Subject: Re: syslogd(8) with OOM Killer protection From: Marcelo Araujo To: Eugene Grosbein Cc: Marcelo Araujo , Adrian Chadd , "freebsd-hackers@freebsd.org" Content-Type: text/plain; charset=UTF-8 X-Content-Filtered-By: Mailman/MimeDel 2.1.20 X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.20 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 28 Jan 2016 13:49:18 -0000 In my research, I might be wrong, there is no clean way to make such protection without intrusive code in every each deamon. I'm still checking!! On Jan 28, 2016 9:05 PM, "Eugene Grosbein" wrote: > On 27.01.2016 13:32, Adrian Chadd wrote: > > I like it,how's it not done via some command line tool that we can run > > any tool with? > > I've already responded to such idea in a comment to my original PR > and like to repeat it here. IMHO, it is nearly impossible to correctly > implement > such protection for arbitrary daemonizing service by means of rc.subr, > without modifications of service source code. Currently. > > We do have protect(1) utility but it only can protect single process it > starts or > all current/future children of started process and for daemons both cases > are wrong: > > - protection of single process is meaningless because it forks to become > daemon and that ceases protection; > - protection of all future children is dangerous for daemons capable of > running arbitrary subprocesses like syslogd can with "vertical bar" syntax > of syslog.conf(5) as those future children may be "runaway" memory hogs. > > Perhaps, we could have kernel facility that keeps decreasing counter of > forks > and ceases protection of children when counter reaches zero level. > Then teach protect(1) to (re-)set counter value and make rc.subr use it. > > From owner-freebsd-hackers@freebsd.org Thu Jan 28 15:45:20 2016 Return-Path: Delivered-To: freebsd-hackers@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 43A0CA71FFD for ; Thu, 28 Jan 2016 15:45:20 +0000 (UTC) (envelope-from ian@freebsd.org) Received: from outbound1b.ore.mailhop.org (outbound1b.ore.mailhop.org [54.200.247.200]) (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 277531F4E for ; Thu, 28 Jan 2016 15:45:19 +0000 (UTC) (envelope-from ian@freebsd.org) Received: from ilsoft.org (unknown [73.34.117.227]) by outbound1.ore.mailhop.org (Halon Mail Gateway) with ESMTPSA; Thu, 28 Jan 2016 15:45:17 +0000 (UTC) Received: from rev (rev [172.22.42.240]) by ilsoft.org (8.15.2/8.14.9) with ESMTP id u0SFjBwr034034; Thu, 28 Jan 2016 08:45:11 -0700 (MST) (envelope-from ian@freebsd.org) Message-ID: <1453995911.1275.14.camel@freebsd.org> Subject: Re: impossible to set pata dma mode? From: Ian Lepore To: Norbert Koch , freebsd-hackers@FreeBSD.org Date: Thu, 28 Jan 2016 08:45:11 -0700 In-Reply-To: <56A9D502.7010809@demig.de> References: <56A9D502.7010809@demig.de> Content-Type: text/plain; charset="us-ascii" X-Mailer: Evolution 3.16.5 FreeBSD GNOME Team Port Mime-Version: 1.0 Content-Transfer-Encoding: 7bit X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.20 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 28 Jan 2016 15:45:20 -0000 On Thu, 2016-01-28 at 09:44 +0100, Norbert Koch wrote: > Hello. > > I have to reduce dma mode from udma to wdma2 > for a flash device. > > In the past this was easy using atacontrol > but, afaiks it seems to be impossible using camcontrol. > > camcontrol negotiate ada0 -M wdma > ...You can only modify user parameters > > camcontrol negotiate ada0 -NM wdma > Works, but I see no way how those user > parameters become active parameters as the > driver only reads then in attach as far as > I can see. > > It seems like the ata driver's interface > allows to change the current settings > (XPT_SET_TRAN_SETTINGS/CTS_TYPE_CURRENT_SETTINGS) > so, why is camcontrol so restrictive? > > Thank you, > Norbert Koch I don't know about changing it on the fly with camcontrol (I've never done that), but you can configure it at boot time with a tunable in loader.conf of the form dev.ada.0.mode="modestr" Where modestr is one of these (from dev/ata/ata-all.c): if (!strcasecmp(str, "PIO0")) return (ATA_PIO0); if (!strcasecmp(str, "PIO1")) return (ATA_PIO1); if (!strcasecmp(str, "PIO2")) return (ATA_PIO2); if (!strcasecmp(str, "PIO3")) return (ATA_PIO3); if (!strcasecmp(str, "PIO4")) return (ATA_PIO4); if (!strcasecmp(str, "WDMA0")) return (ATA_WDMA0); if (!strcasecmp(str, "WDMA1")) return (ATA_WDMA1); if (!strcasecmp(str, "WDMA2")) return (ATA_WDMA2); if (!strcasecmp(str, "UDMA0")) return (ATA_UDMA0); if (!strcasecmp(str, "UDMA16")) return (ATA_UDMA0); if (!strcasecmp(str, "UDMA1")) return (ATA_UDMA1); if (!strcasecmp(str, "UDMA25")) return (ATA_UDMA1); if (!strcasecmp(str, "UDMA2")) return (ATA_UDMA2); if (!strcasecmp(str, "UDMA33")) return (ATA_UDMA2); if (!strcasecmp(str, "UDMA3")) return (ATA_UDMA3); if (!strcasecmp(str, "UDMA44")) return (ATA_UDMA3); if (!strcasecmp(str, "UDMA4")) return (ATA_UDMA4); if (!strcasecmp(str, "UDMA66")) return (ATA_UDMA4); if (!strcasecmp(str, "UDMA5")) return (ATA_UDMA5); if (!strcasecmp(str, "UDMA100")) return (ATA_UDMA5); if (!strcasecmp(str, "UDMA6")) return (ATA_UDMA6); if (!strcasecmp(str, "UDMA133")) return (ATA_UDMA6); -- Ian From owner-freebsd-hackers@freebsd.org Thu Jan 28 16:34:43 2016 Return-Path: Delivered-To: freebsd-hackers@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 2F777A714B4 for ; Thu, 28 Jan 2016 16:34:43 +0000 (UTC) (envelope-from nkoch@demig.de) Received: from demig.de (demig.de [81.169.228.196]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client CN "Parallels Panel", Issuer "Parallels Panel" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 923821AA5 for ; Thu, 28 Jan 2016 16:34:42 +0000 (UTC) (envelope-from nkoch@demig.de) Received: (qmail 27742 invoked from network); 28 Jan 2016 17:33:39 +0100 Received: from b2b-130-180-89-86.unitymedia.biz (HELO firewall.demig.intra) (130.180.89.86) by demig.de with ESMTPSA (DHE-RSA-AES256-SHA encrypted, authenticated); 28 Jan 2016 17:33:38 +0100 Received: from SRV-FS-2.Demig.intra (nameserver.demig.intra [192.168.148.248]) by firewall.demig.intra (8.14.4/8.14.4) with ESMTP id u0SGXPC1032066 for ; Thu, 28 Jan 2016 17:33:25 +0100 (CET) (envelope-from nkoch@demig.de) Received: from [192.168.148.83] (192.168.148.83) by SRV-FS-2 (192.168.148.248) with Microsoft SMTP Server (TLS) id 14.3.123.3; Thu, 28 Jan 2016 17:33:20 +0100 Subject: Re: impossible to set pata dma mode? To: References: <56A9D502.7010809@demig.de> <1453995911.1275.14.camel@freebsd.org> From: Norbert Koch X-Enigmail-Draft-Status: N1110 Message-ID: <56AA42CF.10408@demig.de> Date: Thu, 28 Jan 2016 17:33:19 +0100 User-Agent: Mozilla/5.0 (Windows NT 5.1; rv:38.0) Gecko/20100101 Thunderbird/38.5.1 MIME-Version: 1.0 In-Reply-To: <1453995911.1275.14.camel@freebsd.org> Content-Type: text/plain; charset="windows-1252" Content-Transfer-Encoding: 7bit X-Scanned-By: MIMEDefang 2.73 on 192.168.148.235 X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.20 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 28 Jan 2016 16:34:43 -0000 Am 28.01.2016 um 16:45 schrieb Ian Lepore: Thanks Ian, I know that I can configure this using boot hints. I am having a rather special situation where I need to change these settings after boot. It has to do with pxe booting different FreeBSD versions using an outdated grub which only allows to directly load a kernel without specifying boot parameters. Obviously I can help myself with a modified camcontrol. But I am still curious what the reason for the limitation might be. > On Thu, 2016-01-28 at 09:44 +0100, Norbert Koch wrote: >> Hello. >> >> I have to reduce dma mode from udma to wdma2 >> for a flash device. >> >> In the past this was easy using atacontrol >> but, afaiks it seems to be impossible using camcontrol. >> >> camcontrol negotiate ada0 -M wdma >> ...You can only modify user parameters >> >> camcontrol negotiate ada0 -NM wdma >> Works, but I see no way how those user >> parameters become active parameters as the >> driver only reads then in attach as far as >> I can see. >> >> It seems like the ata driver's interface >> allows to change the current settings >> (XPT_SET_TRAN_SETTINGS/CTS_TYPE_CURRENT_SETTINGS) >> so, why is camcontrol so restrictive? >> >> Thank you, >> Norbert Koch > I don't know about changing it on the fly with camcontrol (I've never > done that), but you can configure it at boot time with a tunable in > loader.conf of the form > > dev.ada.0.mode="modestr" > > Where modestr is one of these (from dev/ata/ata-all.c): > > if (!strcasecmp(str, "PIO0")) return (ATA_PIO0); > if (!strcasecmp(str, "PIO1")) return (ATA_PIO1); > if (!strcasecmp(str, "PIO2")) return (ATA_PIO2); > if (!strcasecmp(str, "PIO3")) return (ATA_PIO3); > if (!strcasecmp(str, "PIO4")) return (ATA_PIO4); > if (!strcasecmp(str, "WDMA0")) return (ATA_WDMA0); > if (!strcasecmp(str, "WDMA1")) return (ATA_WDMA1); > if (!strcasecmp(str, "WDMA2")) return (ATA_WDMA2); > if (!strcasecmp(str, "UDMA0")) return (ATA_UDMA0); > if (!strcasecmp(str, "UDMA16")) return (ATA_UDMA0); > if (!strcasecmp(str, "UDMA1")) return (ATA_UDMA1); > if (!strcasecmp(str, "UDMA25")) return (ATA_UDMA1); > if (!strcasecmp(str, "UDMA2")) return (ATA_UDMA2); > if (!strcasecmp(str, "UDMA33")) return (ATA_UDMA2); > if (!strcasecmp(str, "UDMA3")) return (ATA_UDMA3); > if (!strcasecmp(str, "UDMA44")) return (ATA_UDMA3); > if (!strcasecmp(str, "UDMA4")) return (ATA_UDMA4); > if (!strcasecmp(str, "UDMA66")) return (ATA_UDMA4); > if (!strcasecmp(str, "UDMA5")) return (ATA_UDMA5); > if (!strcasecmp(str, "UDMA100")) return (ATA_UDMA5); > if (!strcasecmp(str, "UDMA6")) return (ATA_UDMA6); > if (!strcasecmp(str, "UDMA133")) return (ATA_UDMA6); > > -- Ian -- Dipl.-Ing. Norbert Koch Entwicklung Prozessregler From owner-freebsd-hackers@freebsd.org Thu Jan 28 17:13:40 2016 Return-Path: Delivered-To: freebsd-hackers@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 29E0CA703AD for ; Thu, 28 Jan 2016 17:13:40 +0000 (UTC) (envelope-from ian@freebsd.org) Received: from outbound1b.ore.mailhop.org (outbound1b.ore.mailhop.org [54.200.247.200]) (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 F32CD1418 for ; Thu, 28 Jan 2016 17:13:39 +0000 (UTC) (envelope-from ian@freebsd.org) Received: from ilsoft.org (unknown [73.34.117.227]) by outbound1.ore.mailhop.org (Halon Mail Gateway) with ESMTPSA; Thu, 28 Jan 2016 17:13:43 +0000 (UTC) Received: from rev (rev [172.22.42.240]) by ilsoft.org (8.15.2/8.14.9) with ESMTP id u0SHDbd9034246; Thu, 28 Jan 2016 10:13:37 -0700 (MST) (envelope-from ian@freebsd.org) Message-ID: <1454001217.1275.19.camel@freebsd.org> Subject: Re: impossible to set pata dma mode? From: Ian Lepore To: Norbert Koch , freebsd-hackers@FreeBSD.org Date: Thu, 28 Jan 2016 10:13:37 -0700 In-Reply-To: <56AA42CF.10408@demig.de> References: <56A9D502.7010809@demig.de> <1453995911.1275.14.camel@freebsd.org> <56AA42CF.10408@demig.de> Content-Type: text/plain; charset="us-ascii" X-Mailer: Evolution 3.16.5 FreeBSD GNOME Team Port Mime-Version: 1.0 Content-Transfer-Encoding: 7bit X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.20 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 28 Jan 2016 17:13:40 -0000 On Thu, 2016-01-28 at 17:33 +0100, Norbert Koch wrote: > Am 28.01.2016 um 16:45 schrieb Ian Lepore: > > > Thanks Ian, I know that I can configure this using > boot hints. > > I am having a rather special situation where I need to > change these settings after boot. It has to do with > pxe booting different FreeBSD versions using an > outdated grub which only allows to directly load > a kernel without specifying boot parameters. > > Obviously I can help myself with a modified > camcontrol. But I am still curious what the > reason for the limitation might be. > > I'll have to leave the cam-related questions for the cam gurus. Do you have a custom kernel for these systems? If so, you can configure tunables by compiling a static environment into the kernel using the 'env' argument described in config(5). I recently committed changes that fix the env directive so that it works on all architectures now. Still maybe not what you need, but worth mentioning. -- Ian > > On Thu, 2016-01-28 at 09:44 +0100, Norbert Koch wrote: > > > Hello. > > > > > > I have to reduce dma mode from udma to wdma2 > > > for a flash device. > > > > > > In the past this was easy using atacontrol > > > but, afaiks it seems to be impossible using camcontrol. > > > > > > camcontrol negotiate ada0 -M wdma > > > ...You can only modify user parameters > > > > > > camcontrol negotiate ada0 -NM wdma > > > Works, but I see no way how those user > > > parameters become active parameters as the > > > driver only reads then in attach as far as > > > I can see. > > > > > > It seems like the ata driver's interface > > > allows to change the current settings > > > (XPT_SET_TRAN_SETTINGS/CTS_TYPE_CURRENT_SETTINGS) > > > so, why is camcontrol so restrictive? > > > > > > Thank you, > > > Norbert Koch > > I don't know about changing it on the fly with camcontrol (I've > > never > > done that), but you can configure it at boot time with a tunable in > > loader.conf of the form > > > > dev.ada.0.mode="modestr" > > > > Where modestr is one of these (from dev/ata/ata-all.c): > > > > if (!strcasecmp(str, "PIO0")) return (ATA_PIO0); > > if (!strcasecmp(str, "PIO1")) return (ATA_PIO1); > > if (!strcasecmp(str, "PIO2")) return (ATA_PIO2); > > if (!strcasecmp(str, "PIO3")) return (ATA_PIO3); > > if (!strcasecmp(str, "PIO4")) return (ATA_PIO4); > > if (!strcasecmp(str, "WDMA0")) return (ATA_WDMA0); > > if (!strcasecmp(str, "WDMA1")) return (ATA_WDMA1); > > if (!strcasecmp(str, "WDMA2")) return (ATA_WDMA2); > > if (!strcasecmp(str, "UDMA0")) return (ATA_UDMA0); > > if (!strcasecmp(str, "UDMA16")) return (ATA_UDMA0); > > if (!strcasecmp(str, "UDMA1")) return (ATA_UDMA1); > > if (!strcasecmp(str, "UDMA25")) return (ATA_UDMA1); > > if (!strcasecmp(str, "UDMA2")) return (ATA_UDMA2); > > if (!strcasecmp(str, "UDMA33")) return (ATA_UDMA2); > > if (!strcasecmp(str, "UDMA3")) return (ATA_UDMA3); > > if (!strcasecmp(str, "UDMA44")) return (ATA_UDMA3); > > if (!strcasecmp(str, "UDMA4")) return (ATA_UDMA4); > > if (!strcasecmp(str, "UDMA66")) return (ATA_UDMA4); > > if (!strcasecmp(str, "UDMA5")) return (ATA_UDMA5); > > if (!strcasecmp(str, "UDMA100")) return (ATA_UDMA5); > > if (!strcasecmp(str, "UDMA6")) return (ATA_UDMA6); > > if (!strcasecmp(str, "UDMA133")) return (ATA_UDMA6); > > > > -- Ian > > From owner-freebsd-hackers@freebsd.org Fri Jan 29 07:45:24 2016 Return-Path: Delivered-To: freebsd-hackers@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 4A617A71D4C for ; Fri, 29 Jan 2016 07:45:24 +0000 (UTC) (envelope-from nkoch@demig.de) Received: from demig.de (demig.de [81.169.228.196]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client CN "Parallels Panel", Issuer "Parallels Panel" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id A5DCA1A53 for ; Fri, 29 Jan 2016 07:45:23 +0000 (UTC) (envelope-from nkoch@demig.de) Received: (qmail 17048 invoked from network); 29 Jan 2016 08:44:19 +0100 Received: from b2b-130-180-89-86.unitymedia.biz (HELO firewall.demig.intra) (130.180.89.86) by demig.de with ESMTPSA (DHE-RSA-AES256-SHA encrypted, authenticated); 29 Jan 2016 08:44:19 +0100 Received: from SRV-FS-2.Demig.intra (nameserver.demig.intra [192.168.148.248]) by firewall.demig.intra (8.14.4/8.14.4) with ESMTP id u0T7hnat039455 for ; Fri, 29 Jan 2016 08:43:49 +0100 (CET) (envelope-from nkoch@demig.de) Received: from [192.168.148.83] (192.168.148.83) by SRV-FS-2 (192.168.148.248) with Microsoft SMTP Server (TLS) id 14.3.123.3; Fri, 29 Jan 2016 08:43:46 +0100 Subject: Re: impossible to set pata dma mode? To: References: <56A9D502.7010809@demig.de> <1453995911.1275.14.camel@freebsd.org> <56AA42CF.10408@demig.de> <1454001217.1275.19.camel@freebsd.org> From: Norbert Koch X-Enigmail-Draft-Status: N1110 Message-ID: <56AB1831.2070907@demig.de> Date: Fri, 29 Jan 2016 08:43:45 +0100 User-Agent: Mozilla/5.0 (Windows NT 5.1; rv:38.0) Gecko/20100101 Thunderbird/38.5.1 MIME-Version: 1.0 In-Reply-To: <1454001217.1275.19.camel@freebsd.org> Content-Type: text/plain; charset="windows-1252" Content-Transfer-Encoding: 7bit X-Scanned-By: MIMEDefang 2.73 on 192.168.148.235 X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.20 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 29 Jan 2016 07:45:24 -0000 Am 28.01.2016 um 18:13 schrieb Ian Lepore: > On Thu, 2016-01-28 at 17:33 +0100, Norbert Koch wrote: >> Am 28.01.2016 um 16:45 schrieb Ian Lepore: >> >> >> Thanks Ian, I know that I can configure this using >> boot hints. >> >> I am having a rather special situation where I need to >> change these settings after boot. It has to do with >> pxe booting different FreeBSD versions using an >> outdated grub which only allows to directly load >> a kernel without specifying boot parameters. >> >> Obviously I can help myself with a modified >> camcontrol. But I am still curious what the >> reason for the limitation might be. >> >> > I'll have to leave the cam-related questions for the cam gurus. > > Do you have a custom kernel for these systems? If so, you can > configure tunables by compiling a static environment into the kernel > using the 'env' argument described in config(5). I recently committed > changes that fix the env directive so that it works on all > architectures now. Still maybe not what you need, but worth > mentioning. > > -- Ian Yes, you are right. I could build a custom kernel with "hints my.hints" or "env my.env", having a line hint.ata.0.mode="WDMA2". Thanks. > >>> On Thu, 2016-01-28 at 09:44 +0100, Norbert Koch wrote: >>>> Hello. >>>> >>>> I have to reduce dma mode from udma to wdma2 >>>> for a flash device. >>>> >>>> In the past this was easy using atacontrol >>>> but, afaiks it seems to be impossible using camcontrol. >>>> >>>> camcontrol negotiate ada0 -M wdma >>>> ...You can only modify user parameters >>>> >>>> camcontrol negotiate ada0 -NM wdma >>>> Works, but I see no way how those user >>>> parameters become active parameters as the >>>> driver only reads then in attach as far as >>>> I can see. >>>> >>>> It seems like the ata driver's interface >>>> allows to change the current settings >>>> (XPT_SET_TRAN_SETTINGS/CTS_TYPE_CURRENT_SETTINGS) >>>> so, why is camcontrol so restrictive? >>>> >>>> Thank you, >>>> Norbert Koch >>> I don't know about changing it on the fly with camcontrol (I've >>> never >>> done that), but you can configure it at boot time with a tunable in >>> loader.conf of the form >>> >>> dev.ada.0.mode="modestr" >>> >>> Where modestr is one of these (from dev/ata/ata-all.c): >>> >>> if (!strcasecmp(str, "PIO0")) return (ATA_PIO0); >>> if (!strcasecmp(str, "PIO1")) return (ATA_PIO1); >>> if (!strcasecmp(str, "PIO2")) return (ATA_PIO2); >>> if (!strcasecmp(str, "PIO3")) return (ATA_PIO3); >>> if (!strcasecmp(str, "PIO4")) return (ATA_PIO4); >>> if (!strcasecmp(str, "WDMA0")) return (ATA_WDMA0); >>> if (!strcasecmp(str, "WDMA1")) return (ATA_WDMA1); >>> if (!strcasecmp(str, "WDMA2")) return (ATA_WDMA2); >>> if (!strcasecmp(str, "UDMA0")) return (ATA_UDMA0); >>> if (!strcasecmp(str, "UDMA16")) return (ATA_UDMA0); >>> if (!strcasecmp(str, "UDMA1")) return (ATA_UDMA1); >>> if (!strcasecmp(str, "UDMA25")) return (ATA_UDMA1); >>> if (!strcasecmp(str, "UDMA2")) return (ATA_UDMA2); >>> if (!strcasecmp(str, "UDMA33")) return (ATA_UDMA2); >>> if (!strcasecmp(str, "UDMA3")) return (ATA_UDMA3); >>> if (!strcasecmp(str, "UDMA44")) return (ATA_UDMA3); >>> if (!strcasecmp(str, "UDMA4")) return (ATA_UDMA4); >>> if (!strcasecmp(str, "UDMA66")) return (ATA_UDMA4); >>> if (!strcasecmp(str, "UDMA5")) return (ATA_UDMA5); >>> if (!strcasecmp(str, "UDMA100")) return (ATA_UDMA5); >>> if (!strcasecmp(str, "UDMA6")) return (ATA_UDMA6); >>> if (!strcasecmp(str, "UDMA133")) return (ATA_UDMA6); >>> >>> -- Ian >> -- Dipl.-Ing. Norbert Koch Entwicklung Prozessregler From owner-freebsd-hackers@freebsd.org Fri Jan 29 09:44:02 2016 Return-Path: Delivered-To: freebsd-hackers@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 118F3A71CBB for ; Fri, 29 Jan 2016 09:44:02 +0000 (UTC) (envelope-from trond@fagskolen.gjovik.no) Received: from smtp.fagskolen.gjovik.no (smtp.fagskolen.gjovik.no [IPv6:2001:700:1100:1:200:ff:fe00:b]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client CN "smtp.fagskolen.gjovik.no", Issuer "Fagskolen i Gj??vik" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 848DC1F93 for ; Fri, 29 Jan 2016 09:44:01 +0000 (UTC) (envelope-from trond@fagskolen.gjovik.no) Received: from mail.fig.ol.no (localhost [127.0.0.1]) by mail.fig.ol.no (8.15.2/8.15.2) with ESMTPS id u0T9hsS7093272 (version=TLSv1.2 cipher=DHE-RSA-AES256-GCM-SHA384 bits=256 verify=NO); Fri, 29 Jan 2016 10:43:55 +0100 (CET) (envelope-from trond@fagskolen.gjovik.no) Received: from localhost (trond@localhost) by mail.fig.ol.no (8.15.2/8.15.2/Submit) with ESMTP id u0T9hsiA093269; Fri, 29 Jan 2016 10:43:54 +0100 (CET) (envelope-from trond@fagskolen.gjovik.no) X-Authentication-Warning: mail.fig.ol.no: trond owned process doing -bs Date: Fri, 29 Jan 2016 10:43:54 +0100 (CET) From: =?ISO-8859-1?Q?Trond_Endrest=F8l?= Sender: Trond.Endrestol@fagskolen.gjovik.no To: krad cc: Steven Hartland , Eric McCorkle , freebsd-hackers@freebsd.org, Gabor Radnai Subject: Re: EFI/ZFS Update: successful tests, need more complex vdevs In-Reply-To: Message-ID: References: <9418E44F-114E-4ABA-A32D-416297BCDA9F@metricspace.net> <56985C6A.6040209@multiplay.co.uk> User-Agent: Alpine 2.20 (BSF 67 2015-01-07) Organization: Fagskolen Innlandet OpenPGP: url=http://fig.ol.no/~trond/trond.key MIME-Version: 1.0 X-Spam-Status: No, score=-1.0 required=5.0 tests=ALL_TRUSTED, AWL autolearn=ham autolearn_force=no version=3.4.1 X-Spam-Checker-Version: SpamAssassin 3.4.1 (2015-04-28) on mail.fig.ol.no Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8BIT X-Content-Filtered-By: Mailman/MimeDel 2.1.20 X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.20 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 29 Jan 2016 09:44:02 -0000 On Thu, 28 Jan 2016 09:31-0000, krad wrote: > Is the MFC still on course? I'm in a position to test on current today or > tomorrow, but am wondering now it its worth waiting a day until it's in > 10-Stable? I just upgraded my UEFI ZFS laptop to stable/10 r295034. The new boot1.efi boot loader is a miracle. Now I can rid myself of the UFS partition previously holding /boot. Thank you all! -- +-------------------------------+------------------------------------+ | Vennlig hilsen, | Best regards, | | Trond Endrestøl, | Trond Endrestøl, | | IT-ansvarlig, | System administrator, | | Fagskolen Innlandet, | Gjøvik Technical College, Norway, | | tlf. mob. 952 62 567, | Cellular...: +47 952 62 567, | | sentralbord 61 14 54 00. | Switchboard: +47 61 14 54 00. | +-------------------------------+------------------------------------+ From owner-freebsd-hackers@freebsd.org Fri Jan 29 18:40:10 2016 Return-Path: Delivered-To: freebsd-hackers@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id DA1ADA726CB for ; Fri, 29 Jan 2016 18:40:10 +0000 (UTC) (envelope-from efimyury@gmail.com) Received: from mail-wm0-x22f.google.com (mail-wm0-x22f.google.com [IPv6:2a00:1450:400c:c09::22f]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (Client CN "smtp.gmail.com", Issuer "Google Internet Authority G2" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 75C471E8F for ; Fri, 29 Jan 2016 18:40:10 +0000 (UTC) (envelope-from efimyury@gmail.com) Received: by mail-wm0-x22f.google.com with SMTP id l66so78858279wml.0 for ; Fri, 29 Jan 2016 10:40:10 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=user-agent:from:to:subject:date:message-id:mime-version :content-type; bh=qmBcWCaXqsn8Cid2UwOZHGKcIBWFZn9H+8pRSHJ9g0k=; b=hTj94HWE/bRVDnAhAJPdLgRcE45KzEGcXBl0iQp3Z94WTJwAl31cmqXoafp9eyApt6 wn2FDyPf97mK+KoXXzQf2g/BsLSxEwcB9/ybRY0/hqVHIspmfvx7UXUQ73mNlZD4JfzQ 6DIzxTV/5CTMWGzH4vtptF+9IUbfhVyxBbs3tR2WA5zhLhTiRYnlA7s/lDgKqbx2UeEM jH/h3UYlbLkqXuGR0fkcp8pGQu+nsOwNIG+LT6hU6nV138zd3l3xZ1w5W4knh2MdjpXF UUS0EmwFRYtfWVQ/0N2h9alRXpLaZUQg/ZNHjs21hTsF0KuZvjWPnafq09eiKuYdqNzz Sz5A== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:user-agent:from:to:subject:date:message-id :mime-version:content-type; bh=qmBcWCaXqsn8Cid2UwOZHGKcIBWFZn9H+8pRSHJ9g0k=; b=T8WqxNyj7wz9be+u7aQg0XnDzCXQelDLlu1YkhV2IsB9b203jRg9AM7uwwRXbhD9Zt EvaEjDGs83dArIy43bu3p3/fvwykYHXpJzIhtCZO+Nidi5wOztpztdpXIYHBh7OeUufu QgTYMgKsILUqc99oNBuXwJcpNKCzK6LqvKWgpahtILed3CLkfseKa6u1mXYt1wyy/X+6 jN5XmSSF79dKUPmDkMeIOme2DvA3AmGfgZkgMeVoKX8gvUz8Fgt7/AlUU/Stx3ZZTjj2 yGyEfLGsvclu6cbnVygZ4yNViS51BCPUn+u/BJfKivrM4v5ghDRTi3vVk5+XrfV3keIh uu8Q== X-Gm-Message-State: AG10YOQS/yDywE6VfdZ6+JXQP65yvKnBQaqX7fG5PtVhvc9/WG7Zph0HxrY1/yajXgrwdA== X-Received: by 10.28.52.134 with SMTP id b128mr9918786wma.99.1454092809007; Fri, 29 Jan 2016 10:40:09 -0800 (PST) Received: from localhost.localdomain ([93.85.24.234]) by smtp.gmail.com with ESMTPSA id b127sm8619586wmh.9.2016.01.29.10.40.07 for (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Fri, 29 Jan 2016 10:40:08 -0800 (PST) User-agent: mu4e 0.9.15; emacs 24.5.1 From: Yury Efimochev To: "freebsd-hackers\@freebsd.org" Subject: strange malloc behavior Date: Fri, 29 Jan 2016 21:40:06 +0300 Message-ID: <87si1gkz5l.fsf@gmail.com> MIME-Version: 1.0 Content-Type: text/plain X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.20 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 29 Jan 2016 18:40:10 -0000 Hi, Recently I faced the following problem. After update from 9.2-RELEASE-p17 to 9.3-RELEASE-p24 on our production server our service started crashing with SIGSEG/SIGBUS on regular basis(roughly once a day). Investigation revealed that crashes were caused by the fact that under certain circumstances malloc may return pointer on same memory for multiple clients from different threads. We suggested that our problem was caused by thread-specific cache, so we disabled it(by adding 'MALLOC_OPTIONS=7h' to our service environment). That fixed crashes, but caused 10-100 'std::bad_alloc' exceptions every day(no 'std::bad_alloc' exceptions before that for months). Did anyone face similar issues? -- Best regards, Yury Efimochev From owner-freebsd-hackers@freebsd.org Sat Jan 30 11:26:35 2016 Return-Path: Delivered-To: freebsd-hackers@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 3B4CEA7374E for ; Sat, 30 Jan 2016 11:26:35 +0000 (UTC) (envelope-from amutu@amutu.com) Received: from mail-yk0-x230.google.com (mail-yk0-x230.google.com [IPv6:2607:f8b0:4002:c07::230]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (Client CN "smtp.gmail.com", Issuer "Google Internet Authority G2" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id F1BA81166 for ; Sat, 30 Jan 2016 11:26:34 +0000 (UTC) (envelope-from amutu@amutu.com) Received: by mail-yk0-x230.google.com with SMTP id r207so54326886ykd.2 for ; Sat, 30 Jan 2016 03:26:34 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=amutu-com.20150623.gappssmtp.com; s=20150623; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :content-type; bh=sGtvMH6hkjgVWl7jqJkxyZgBF620QcXHbkObgXtA5Ms=; b=1kup+uyI46RSKhe2IU2wM2g0vuRTWkyM0GaKv/gLrCe2yGD5nZwdxepV82BEqV9wKj VGKBlLDdAvrAcwGMZn61xq/KeLbzf707dzMr36Gu+GFL9mkP3ghzBbMVRfTuMqOiqYcG Mzpq27R3o+cbbBOjaLEzetdJd/DH/iOTZrDqJDYB165GtFQHu75a8NV1iDMsDmxKnqiw KdlpVUHQES5Clag9l/LhRYg1nY/sJQHZvyLkyWNzhlsg0wDv03FFNkQtV0pdlRsU2uAy XFEWSr4494i+4VVjVjL1yHsckCIv6q9FrK+F42Tf9ICHru2mkdICav74CQE4C6x7+lZP Op0w== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:mime-version:in-reply-to:references:date :message-id:subject:from:to:content-type; bh=sGtvMH6hkjgVWl7jqJkxyZgBF620QcXHbkObgXtA5Ms=; b=c+n+gHfktwWRGEQS+6arsOr+mzX2OgRPZHM9cwT0S9jedBl/4u/bN7nR+0mj/DPXVi cuHLjqBMRpuwfDlDSJCTw7dTuitBTcYvtnBYydi3KVj++g5lJH6kNbANtu4FV1RXPppz 0zQpERwD31UAtRT5z0MkxstdMhC36AGXU/xJOtJBOrdEDsaLT+ceVkWbQaki+NZkDdAX gUbdevlOCN1CgNQLiu6W23lR2pYUq3wsPkO6F3HY1CX5L1+RKwDVGMhT52aPs251aMBN FUlLjwnih1pOeJVK684Z654Z0X1l+64hKu22Hs2gptYjbO7j4ApKNVtqed2SMiyA0lcR qprQ== X-Gm-Message-State: AG10YOQ5Y5IfAOOvZ9Qqsu5NHX7MfuMHDtMU0HQek5fbFLt73agjgKmyxspUbLGcua6pMA== X-Received: by 10.129.38.10 with SMTP id m10mr7771649ywm.183.1454153193844; Sat, 30 Jan 2016 03:26:33 -0800 (PST) Received: from mail-yk0-f173.google.com (mail-yk0-f173.google.com. [209.85.160.173]) by smtp.gmail.com with ESMTPSA id t64sm15511932ywa.45.2016.01.30.03.26.32 for (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Sat, 30 Jan 2016 03:26:33 -0800 (PST) Received: by mail-yk0-f173.google.com with SMTP id a85so97735500ykb.1 for ; Sat, 30 Jan 2016 03:26:32 -0800 (PST) MIME-Version: 1.0 X-Received: by 10.37.41.66 with SMTP id p63mr6741865ybp.183.1454153192659; Sat, 30 Jan 2016 03:26:32 -0800 (PST) Received: by 10.37.79.6 with HTTP; Sat, 30 Jan 2016 03:26:32 -0800 (PST) Received: by 10.37.79.6 with HTTP; Sat, 30 Jan 2016 03:26:32 -0800 (PST) In-Reply-To: <20160130071346.31022.37189@wrigleys.postgresql.org> References: <20160130071346.31022.37189@wrigleys.postgresql.org> Date: Sat, 30 Jan 2016 19:26:32 +0800 X-Gmail-Original-Message-ID: Message-ID: Subject: Fwd: [BUGS] BUG #13900: stop standby failed with writer process hang(happen 3 times in 2 days) From: Jov To: freebsd-hackers@freebsd.org X-Mailman-Approved-At: Sat, 30 Jan 2016 12:21:20 +0000 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable X-Content-Filtered-By: Mailman/MimeDel 2.1.20 X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.20 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 30 Jan 2016 11:26:35 -0000 is there any clue that I can debug the problem? The hang process is still there. ---------- =E8=BD=AC=E5=8F=91=E7=9A=84=E9=82=AE=E4=BB=B6 ---------- =E5=8F=91=E4=BB=B6=E4=BA=BA=EF=BC=9A =E6=97=A5=E6=9C=9F=EF=BC=9A2016=E5=B9=B41=E6=9C=8830=E6=97=A5 3:14 PM =E4=B8=BB=E9=A2=98=EF=BC=9A[BUGS] BUG #13900: stop standby failed with writ= er process hang(happen 3 times in 2 days) =E6=94=B6=E4=BB=B6=E4=BA=BA=EF=BC=9A =E6=8A=84=E9=80=81=EF=BC=9A The following bug has been logged on the website: Bug reference: 13900 Logged by: Jov Email address: amutu@amutu.com PostgreSQL version: 9.3.7 Operating system: FreeBSD 10.2 amd64 Description: I am updating my 3 database from pg9.3 to pg9.5,but may find a bug for the bgwriter of pg9.3.I can't stop all the stand by process,even for immediate stop mode and kill -9,the writer process still there,with ps state "Ds" (D Marks a process in disk (or other short term, uninterruptible) wait) .googl= e say the only method to clean the "Ds" process is rebooting the system. truss say no info for the process,and procstat say the process is calling the poll system call in the kernel. These is the detail info: pg_ctl -D ./slave stop -m fast waiting for server to shut down............................................................... failed pg_ctl: server does not shut down psql postgres psql: FATAL: the database system is shutting down pg_ctl -D ./slave stop -m immediate waiting for server to shut down.... done server stopped ps auxwww | grep postgres jovz 976 0.0 0.3 28840 5232 - Is 17 116 0:00.04 postgres: logger process (postgres) jovz 979 0.0 0.7 196940 13552 - Ds 17 116 0:06.03 postgres: writer process (postgres) log: 2016-01-30 14:23:22.350 CST,,,947,,569b1bc2.3b3,3,,2016-01-17 12:42:42 CST,,0,LOG,00000,"received fast shutdown request",,,,,,,,,"" 2016-01-30 14:23:22.350 CST,,,947,,569b1bc2.3b3,4,,2016-01-17 12:42:42 CST,,0,LOG,00000,"aborting any active transactions",,,,,,,,,"" 2016-01-30 14:25:35.271 CST,,,64815,"",56ac575f.fd2f,1,"",2016-01-30 14:25:35 CST,,0,LOG,00000,"connection received: host=3D[local]",,,,,,,,,"" 2016-01-30 14:25:35.274 CST,"jovz","f",64815,"[local]",56ac575f.fd2f,2,"",2016-01-30 14:25:35 CST,,0,FATAL,57P03,"the database system is shutting down",,,,,,,,,"" 2016-01-30 14:25:38.324 CST,,,64817,"",56ac5762.fd31,1,"",2016-01-30 14:25:38 CST,,0,LOG,00000,"connection received: host=3D[local]",,,,,,,,,"" 2016-01-30 14:25:38.324 CST,"jovz","f",64817,"[local]",56ac5762.fd31,2,"",2016-01-30 14:25:38 CST,,0,FATAL,57P03,"the database system is shutting down",,,,,,,,,"" 2016-01-30 14:47:36.727 CST,,,65457,"",56ac5c88.ffb1,1,"",2016-01-30 14:47:36 CST,,0,LOG,00000,"connection received: host=3D[local]",,,,,,,,,"" 2016-01-30 14:47:36.727 CST,"jovz","postgres",65457,"[local]",56ac5c88.ffb1,2,"",2016-01-30 14:47:3= 6 CST,,0,FATAL,57P03,"the database system is shutting down",,,,,,,,,"" 2016-01-30 14:50:04.564 CST,,,947,,569b1bc2.3b3,5,,2016-01-17 12:42:42 CST,,0,LOG,00000,"received immediate shutdown request",,,,,,,,,"" truss -p 979 ^Ctruss: Unexpect stop in waitpid: Interrupted system call root@fblax:~ # procstat -kk 979 PID TID COMM TDNAME KSTACK 979 100688 postgres - mi_switch+0xe1 sleepq_timedwait_sig+0x8b _cv_timedwait_sig_sbt+0x18b seltdwait+0xa4 kern_poll+0x464 sys_poll+0x61 amd64_syscall+0x357 Xfast_syscall+0xfb root@fb:~ # kill -9 979 root@fb:~ # procstat -kk 979 PID TID COMM TDNAME KSTACK 979 100688 postgres - mi_switch+0xe1 sleepq_timedwait_sig+0x8b _cv_timedwait_sig_sbt+0x18b seltdwait+0xa4 kern_poll+0x464 sys_poll+0x61 amd64_syscall+0x357 Xfast_syscall+0xfb -- Sent via pgsql-bugs mailing list (pgsql-bugs@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-bugs From owner-freebsd-hackers@freebsd.org Sat Jan 30 23:09:31 2016 Return-Path: Delivered-To: freebsd-hackers@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id ECFAAA73BEF for ; Sat, 30 Jan 2016 23:09:31 +0000 (UTC) (envelope-from cse.cem@gmail.com) Received: from mail-yk0-f175.google.com (mail-yk0-f175.google.com [209.85.160.175]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (Client CN "smtp.gmail.com", Issuer "Google Internet Authority G2" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id B896737A; Sat, 30 Jan 2016 23:09:31 +0000 (UTC) (envelope-from cse.cem@gmail.com) Received: by mail-yk0-f175.google.com with SMTP id r207so65143238ykd.2; Sat, 30 Jan 2016 15:09:31 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:mime-version:reply-to:in-reply-to:references :date:message-id:subject:from:to:cc:content-type; bh=P2gxJarKHEEGa9tIu5V9I1yBxPlWszEKg1+TnEDKZ1o=; b=eFN1FECQXRYd/HY4MYx2QpWtqlaFwnzT2KRiEQdFWm/qsHBLaUnJ0QtecMdmGB/G3I 5mBDTQKHgep/vpoDM2QOk7uFW5OGZKPoZHWemHrmLTaEb9ixYbneN4UtFqP96viVGcfr CkaC1n3I7ecPrQVEd/i6UAa5f15J7npUKriYAgwAUOxJK6WvBbJYfN3/TKxG/f45FdvO hlco9ZptrafOdmGcy9RGNwrm8bhF8Uv8GCxuvTmmNE6ofVhnBI2z8ll7gTLzMaw3n5/H BFWHh5Wn8jfb1LKuqJRccwNqcyBV5AibOQTlJOWE/quuw07g1U+dVwyID3b4yf/PhYGj iWXA== X-Gm-Message-State: AG10YOSXk8wcc+SxJS0TCI+GWqRF3G24F/j5XmFChi3pRkdYi7mYTDbn9p9d5ynO+1RRqw== X-Received: by 10.37.12.195 with SMTP id 186mr8443305ybm.154.1454194886244; Sat, 30 Jan 2016 15:01:26 -0800 (PST) Received: from mail-yk0-f182.google.com (mail-yk0-f182.google.com. [209.85.160.182]) by smtp.gmail.com with ESMTPSA id u134sm11525343ywf.48.2016.01.30.15.01.25 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Sat, 30 Jan 2016 15:01:26 -0800 (PST) Received: by mail-yk0-f182.google.com with SMTP id z7so35399141yka.3; Sat, 30 Jan 2016 15:01:25 -0800 (PST) MIME-Version: 1.0 X-Received: by 10.37.5.151 with SMTP id 145mr7963399ybf.16.1454194885538; Sat, 30 Jan 2016 15:01:25 -0800 (PST) Reply-To: cem@FreeBSD.org Received: by 10.37.4.23 with HTTP; Sat, 30 Jan 2016 15:01:25 -0800 (PST) In-Reply-To: References: Date: Sat, 30 Jan 2016 15:01:25 -0800 X-Gmail-Original-Message-ID: Message-ID: Subject: Re: aesni doesn't play nice with krb5 From: Conrad Meyer To: Alan Somers Cc: "freebsd-hackers@freebsd.org" Content-Type: text/plain; charset=UTF-8 X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.20 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 30 Jan 2016 23:09:32 -0000 I have an untested patch to fix this issue: https://reviews.freebsd.org/D5146 . If you have time, please review or test the patch. Thanks, Conrad On Wed, Jan 27, 2016 at 3:55 PM, Alan Somers wrote: > I'm experimenting with Kerberized NFS, but my performance sucks when I > use krb5p. I tracked the problem down to an interaction between aesni > and krb5: aes_set_key in kcrypto_aes.c registers for a crypto session > and requests support for two algorithms: CRYPTO_SHA1_HMAC and > CRYPTO_AES_CBC. aesni(4) supports the latter, but not the former. So > crypto_select_driver returns cryptosoft and krb5 uses software for > both algorithms. > > It's too bad that aesni doesn't support SHA1, but other software like > OpenSSL deals with it by using hardware for AES and software for SHA1. > It seems to me like krb5 could be made to do the same by registering > for two sessions, one for each algorithm. In fact, it seems like it > would be pretty easy to do. The changes would probably be confined > strictly to crypto_aes.c. Is there any reason why this wouldn't work? > > -Alan > _______________________________________________ > freebsd-hackers@freebsd.org mailing list > https://lists.freebsd.org/mailman/listinfo/freebsd-hackers > To unsubscribe, send any mail to "freebsd-hackers-unsubscribe@freebsd.org"