From owner-freebsd-stable@freebsd.org Thu Sep 15 19:09:52 2016 Return-Path: Delivered-To: freebsd-stable@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 31E15BDCF1D for ; Thu, 15 Sep 2016 19:09:52 +0000 (UTC) (envelope-from slw@zxy.spb.ru) Received: from zxy.spb.ru (zxy.spb.ru [195.70.199.98]) (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 EBDD01AD; Thu, 15 Sep 2016 19:09:51 +0000 (UTC) (envelope-from slw@zxy.spb.ru) Received: from slw by zxy.spb.ru with local (Exim 4.86 (FreeBSD)) (envelope-from ) id 1bkc2e-000IGW-Nt; Thu, 15 Sep 2016 22:09:48 +0300 Date: Thu, 15 Sep 2016 22:09:48 +0300 From: Slawa Olhovchenkov To: John Baldwin Cc: freebsd-stable@freebsd.org Subject: Re: nginx and FreeBSD11 Message-ID: <20160915190948.GY2840@zxy.spb.ru> References: <20160907191348.GD22212@zxy.spb.ru> <1823460.vTm8IvUQsF@ralph.baldwin.cx> <20160915174948.GW2840@zxy.spb.ru> <15357564.UUkYdbUZHc@ralph.baldwin.cx> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <15357564.UUkYdbUZHc@ralph.baldwin.cx> User-Agent: Mutt/1.5.24 (2015-08-30) X-SA-Exim-Connect-IP: X-SA-Exim-Mail-From: slw@zxy.spb.ru X-SA-Exim-Scanned: No (on zxy.spb.ru); SAEximRunCond expanded to false X-BeenThere: freebsd-stable@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: Production branch of FreeBSD source code List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 15 Sep 2016 19:09:52 -0000 On Thu, Sep 15, 2016 at 11:54:12AM -0700, John Baldwin wrote: > > > Index: vfs_aio.c > > > =================================================================== > > > --- vfs_aio.c (revision 305811) > > > +++ vfs_aio.c (working copy) > > > @@ -787,6 +787,8 @@ aio_process_rw(struct kaiocb *job) > > > * aio_aqueue() acquires a reference to the file that is > > > * released in aio_free_entry(). > > > */ > > > + KASSERT(curproc->p_vmspace == job->userproc->p_vmspace, > > > + ("%s: vmspace mismatch", __func__)); > > > if (cb->aio_lio_opcode == LIO_READ) { > > > auio.uio_rw = UIO_READ; > > > if (auio.uio_resid == 0) > > > @@ -1054,6 +1056,8 @@ aio_switch_vmspace(struct kaiocb *job) > > > { > > > > > > vmspace_switch_aio(job->userproc->p_vmspace); > > > + KASSERT(curproc->p_vmspace == job->userproc->p_vmspace, > > > + ("%s: vmspace mismatch", __func__)); > > > } > > > > > > If this panics, then vmspace_switch_aio() is not working for > > > some reason. > > > > This issuse caused rare, this panic produced with issuse or on any aio > > request? (this is production server) > > It would panic in the case that we are going to write into the wrong > process (so about as rare as your issue). Can I configure automatic reboot (not halted) in this case?