From owner-freebsd-stable@freebsd.org Mon Jun 3 16:55:40 2019 Return-Path: Delivered-To: freebsd-stable@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 4384315B6FE5 for ; Mon, 3 Jun 2019 16:55:40 +0000 (UTC) (envelope-from stefan.hegnauer@gmx.ch) Received: from mout.gmx.net (mout.gmx.net [212.227.15.18]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (Client CN "mout.gmx.net", Issuer "TeleSec ServerPass DE-2" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id E9C2D8A221; Mon, 3 Jun 2019 16:55:38 +0000 (UTC) (envelope-from stefan.hegnauer@gmx.ch) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=gmx.net; s=badeba3b8450; t=1559580931; bh=Ehcy60KYn+KwXIE3LMuVhDgotr8lCgcNplh8R22CkGw=; h=X-UI-Sender-Class:Subject:To:References:Cc:From:Date:In-Reply-To; b=DWL/J+mJsmwMYVHmZUi3qpn5IsaZ39czJ+kKoia86HkQdWASEGdxF0Q6YsOfDCE6K Qb3XXkzSiqZZIdVOKwgq+W3BNUd7gwjIU2JgMdVB9K5hjXaJSNybAs67RNci24su/H vh59yYD/5w5WuSI5OAKj94HRmawivliXy4+791xs= X-UI-Sender-Class: 01bb95c1-4bf8-414a-932a-4f6e2808ef9c Received: from [192.168.20.50] ([84.226.167.60]) by mail.gmx.com (mrgmx005 [212.227.17.190]) with ESMTPSA (Nemesis) id 1Ml6qM-1gr6MW3zqu-00lUiL; Mon, 03 Jun 2019 18:50:17 +0200 Subject: Re: ps -J0 broken? To: freebsd-stable@freebsd.org References: Cc: kostikbel@gmail.com, kevans@freebsd.org, re@freebsd.org From: Stefan Hegnauer Openpgp: preference=signencrypt Message-ID: Date: Mon, 3 Jun 2019 18:50:16 +0200 User-Agent: Mozilla/5.0 (Windows NT 10.0; WOW64; rv:60.0) Gecko/20100101 Thunderbird/60.7.0 MIME-Version: 1.0 In-Reply-To: Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit Content-Language: en-GB X-Provags-ID: V03:K1:59mjzLmWs8Os9pUGz2KQrG9HSeftGOYOBsjOC3UvlJHMioIwZPA LlwDiGQjemK7UHSlMvKGjm+P3hLxuf7zUA/GXAeSniMVLgwWtpqU5gFMwgR6/di9bWWhqsi NRluBW9YIMahrIuSyxYnwR/trkuEdw9xUJ8f0yH2uupNpB/I27qYZVIv+papFFMv3oOHzzy zqKtIg+nSBQ6LbBg2pq0w== X-Spam-Flag: NO X-UI-Out-Filterresults: notjunk:1;V03:K0:mpu8LYvx3r0=:GRGEZ3f4GE2Y1ADfcz3W3A ieaKxmBC/VFpLx1ooP1vvT7H1G6BVyIQiJ/BhrnPU/Ec/FJexWh0z/bqCNgLZLkLUhF44xOFd lkGK46hMs3GUQMBuPbiHPcU4jHzcVvEUjGQ8SGW0U/Pssg7S8rkBn83tBgT0CiJrqIxbfD5Il SMTn5e7Tpp0XMKjWxdpVCx5OEd0s+GojfeBCtVG3kFgqTfzs24U3sR/EGDS8ovmF7f4Uuk12f Wf80vkNZwLZN5FI0Gt8AEXOXiIOQsYl2sNtpr497W/LYagNawrQL9NxDkUiL6M6Idi+tOCb9i N6xuGZJwP/h7G6XiU4BwUMmwahbCqVUSrOMcJaX0YOb2L9rfU2zMJLn0NW8hnIRVKuioNvKCN WFpFbhkdrtBmuaUjnUfm0coS63yti91Z3kQvBedmXaiDNCuoMiVY4WkCBuaDMfDTi2PNp8nYb q83reV68eyUvggUKg2kJuKKUP+QyX4/5KCdLzO5UoQgTAhWAQ5vHB3pEdsRxpEx7cBv3L3rzl N3eIl6YtQhIMO1OtITjpxTmUaU+EzSYdQg/y24QI1M7vh57vRL07KDE4Yn7KiSicAUGnlDbaA uyCc0jjCNwSMAUL0sQPiU8hsUTeYMoRpmhBzKf5ZfsioTs3jXXc89T0PFpCpMfRzzSDXECALF +EPzPVBSe6x8Q+QyixCs6dfwqwA0zNYgw1iEOx3NjsJYWNfbawIK0XEe6CmnqI0djsR3Npo6o pdH78kN9jLK6+7hx7LeGf0hNm5qIfqGeP1xz818fE5ltirT59zRshN/ILZWWiz33bdeSDTFeg 5TUXo7/Pqb9R2DfwG9cW4zhcGphERYDgqynh0y6ybj/ENHdOSlWzWUffSqZSk0TeLjbUjyUaN JqLdfcWs/Ml19uK1qEIH9daHCxdx6dTylifcrhXmHtxg9tqxpNsocH7kvh8dP5bVSbq+RdzqL DiocwStH57/FWrbG5HURchNG124lthAq+8Nvz9QPafvK85ti7nsXa X-Rspamd-Queue-Id: E9C2D8A221 X-Spamd-Bar: --- Authentication-Results: mx1.freebsd.org; dkim=pass header.d=gmx.net header.s=badeba3b8450 header.b=DWL/J+mJ; spf=pass (mx1.freebsd.org: domain of stefan.hegnauer@gmx.ch designates 212.227.15.18 as permitted sender) smtp.mailfrom=stefan.hegnauer@gmx.ch X-Spamd-Result: default: False [-3.31 / 15.00]; ARC_NA(0.00)[]; RCVD_VIA_SMTP_AUTH(0.00)[]; R_DKIM_ALLOW(-0.20)[gmx.net:s=badeba3b8450]; RCVD_TLS_ALL(0.00)[]; FROM_HAS_DN(0.00)[]; RCPT_COUNT_THREE(0.00)[4]; R_SPF_ALLOW(-0.20)[+ip4:212.227.15.0/25]; NEURAL_HAM_LONG(-1.00)[-1.000,0]; MIME_GOOD(-0.10)[text/plain]; TO_DN_NONE(0.00)[]; DMARC_NA(0.00)[gmx.ch]; TO_MATCH_ENVRCPT_SOME(0.00)[]; DKIM_TRACE(0.00)[gmx.net:+]; MX_GOOD(-0.01)[mx00.emig.gmx.net,mx01.emig.gmx.net]; RCVD_IN_DNSWL_NONE(0.00)[18.15.227.212.list.dnswl.org : 127.0.3.0]; NEURAL_HAM_SHORT(-0.74)[-0.743,0]; NEURAL_HAM_MEDIUM(-1.00)[-1.000,0]; IP_SCORE(-1.06)[ip: (-6.37), ipnet: 212.227.0.0/16(-1.46), asn: 8560(2.56), country: DE(-0.00)]; FROM_EQ_ENVFROM(0.00)[]; SUBJECT_ENDS_QUESTION(1.00)[]; MIME_TRACE(0.00)[0:+]; ASN(0.00)[asn:8560, ipnet:212.227.0.0/16, country:DE]; FREEMAIL_CC(0.00)[gmail.com]; MID_RHS_MATCH_FROM(0.00)[]; RCVD_COUNT_TWO(0.00)[2] X-BeenThere: freebsd-stable@freebsd.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Production branch of FreeBSD source code List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 03 Jun 2019 16:55:40 -0000 On 02.06.2019 15:51, Kyle Evans wrote: >> On Sun, Jun 2, 2019 at 8:05 AM Konstantin Belousov wrote: >>> On Sun, Jun 02, 2019 at 02:30:49PM +0200, Stefan Hegnauer wrote: >>>> Hi, >>>> >>>> after a recent full update to 12.0-STABLE r348382 it seems that '/bin/ps >>>> -J 0' is broken: 'ps: Invalid jail id: 0'. >>>> It did work on stable for the last couple years prior to this update >>>> (last update without this error was about 5 weeks ago), and should still >>>> work according to ps(1): >>>> -J Display information about processes which match the specified >>>> jail IDs. This may be either the jid or name of the jail. >>>> **Use** >>>> ** -J 0 to display only host processes*.* This flag implies >>>> -x by >>>> default. >>>> >>>> My system runs several jails with JID's currently in the range 80-100. >>>> The source code of ps did not change for the last 7 month as far as I >>>> can tell. A fresh 'make clean & make & make install' of just ps did not >>>> help either, which was not really surprising to me. >>>> Any pointers where to look further? >>> Is your libjail up to date ? Do you have r348297 ? >> kern_jail_get refuses to do lookups for jid=0, presumably because >> prison 0 is special. I'll commit quick fix- libjail should go back to >> just return (jid) if jid == 0, because this will always exist. It's a >> trivial patch, I intend to request permission for immediate MFC to >> both stable/1{1,2} from re@ because it restores previous working >> behavior for this. > Thanks. I will follow up as soon as the patch is in stable/12 and I had > a chance to test it. > I am happy to report success - with r348538 the old behaviour is restored. Thank you all for the extremely quick reaction! -Stefan