Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1754316AbbLTJ4H (ORCPT ); Sun, 20 Dec 2015 04:56:07 -0500 Received: from out02.mta.xmission.com ([166.70.13.232]:46280 "EHLO out02.mta.xmission.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1754234AbbLTJ4D (ORCPT ); Sun, 20 Dec 2015 04:56:03 -0500 From: ebiederm@xmission.com (Eric W. Biederman) To: Dongsheng Yang Cc: Al Viro , , LKML , References: <56729B3D.1040502@cn.fujitsu.com> <56760F05.3020308@cn.fujitsu.com> <20151220023712.GT20997@ZenIV.linux.org.uk> <567616D6.6060202@cn.fujitsu.com> Date: Sun, 20 Dec 2015 03:47:24 -0600 In-Reply-To: <567616D6.6060202@cn.fujitsu.com> (Dongsheng Yang's message of "Sun, 20 Dec 2015 10:47:50 +0800") Message-ID: <87fuyx1mfn.fsf@x220.int.ebiederm.org> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/24.5 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain X-XM-AID: U2FsdGVkX1+GniqqRL2KGy6Ek48GmIR1ICE/6wEfJnY= X-SA-Exim-Connect-IP: 97.121.81.63 X-SA-Exim-Mail-From: ebiederm@xmission.com X-Spam-Report: * -1.0 ALL_TRUSTED Passed through trusted hosts only via SMTP * 0.0 TVD_RCVD_IP Message was received from an IP address * 0.0 T_TM2_M_HEADER_IN_MSG BODY: No description available. * 0.8 BAYES_50 BODY: Bayes spam probability is 40 to 60% * [score: 0.4943] * -0.0 DCC_CHECK_NEGATIVE Not listed in DCC * [sa01 1397; Body=1 Fuz1=1 Fuz2=1] * 0.0 T_TooManySym_01 4+ unique symbols in subject X-Spam-DCC: XMission; sa01 1397; Body=1 Fuz1=1 Fuz2=1 X-Spam-Combo: ;Dongsheng Yang X-Spam-Relay-Country: X-Spam-Timing: total 901 ms - load_scoreonly_sql: 0.06 (0.0%), signal_user_changed: 4.1 (0.5%), b_tie_ro: 2.9 (0.3%), parse: 1.18 (0.1%), extract_message_metadata: 25 (2.8%), get_uri_detail_list: 2.3 (0.3%), tests_pri_-1000: 7 (0.8%), tests_pri_-950: 2.1 (0.2%), tests_pri_-900: 1.55 (0.2%), tests_pri_-400: 29 (3.2%), check_bayes: 27 (3.0%), b_tokenize: 10 (1.1%), b_tok_get_all: 7 (0.8%), b_comp_prob: 3.9 (0.4%), b_tok_touch_all: 2.8 (0.3%), b_finish: 0.87 (0.1%), tests_pri_0: 546 (60.6%), check_dkim_signature: 0.78 (0.1%), check_dkim_adsp: 113 (12.5%), tests_pri_500: 279 (31.0%), poll_dns_idle: 269 (29.8%), rewrite_mail: 0.00 (0.0%) Subject: Re: [Propose] Isolate core_pattern in mnt namespace. X-Spam-Flag: No X-SA-Exim-Version: 4.2.1 (built Wed, 24 Sep 2014 11:00:52 -0600) X-SA-Exim-Scanned: Yes (on in02.mta.xmission.com) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1915 Lines: 49 Dongsheng Yang writes: > On 12/20/2015 10:37 AM, Al Viro wrote: >> On Sun, Dec 20, 2015 at 10:14:29AM +0800, Dongsheng Yang wrote: >>> On 12/17/2015 07:23 PM, Dongsheng Yang wrote: >>>> Hi guys, >>>> We are working on making core dump behaviour isolated in >>>> container. But the problem is, the /proc/sys/kernel/core_pattern >>>> is a kernel wide setting, not belongs to a container. >>>> >>>> So we want to add core_pattern into mnt namespace. What >>>> do you think about it? >>> >>> Hi Eric, >>> I found your patch about "net: Implement the per network namespace >>> sysctl infrastructure", I want to do the similar thing >>> in mnt namespace. Is that suggested way? >> >> Why mnt namespace and not something else? > > Hi Al, > > Well, because core_pattern indicates the path to store core file. > In different mnt namespace, we would like to change the path with > different value. > > In addition, Let's considering other namespaces: > UTS ns: contains informations of kernel and arch, not proper for core_pattern. > IPC ns: communication informations, not proper for core_pattern > PID ns: core_pattern is not related with pid > net ns: obviousely no. > user ns: not proper too. > > Then I believe it's better to do this in mnt namespace. of course, > core_pattern is just one example. After this infrastructure finished, > we can implement more sysctls as per-mnt if necessary, I think. > > Al, what do you think about this idea? The hard part is not the sysctl. The hard part is starting the usermode helper, in an environment that it can deal with. The mount namespace really provides you with no help there. Eric -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/