From owner-freebsd-emulation@FreeBSD.ORG Sun Oct 28 17:49:13 2007 Return-Path: Delivered-To: freebsd-emulation@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id F21E816A4A1; Sun, 28 Oct 2007 17:49:12 +0000 (UTC) (envelope-from valera@chikalov.dp.ua) Received: from halik.com.ua (halik.com.ua [193.178.146.121]) by mx1.freebsd.org (Postfix) with ESMTP id EEA6D13C481; Sun, 28 Oct 2007 17:49:11 +0000 (UTC) (envelope-from valera@chikalov.dp.ua) Received: from tiger.novakom.dp.ua (77-109-18-135.dynamic.peoplenet.ua [77.109.18.135]) by halik.com.ua (Postfix) with ESMTP id D624C5C07E; Sun, 28 Oct 2007 19:49:04 +0200 (EET) Message-ID: <4724D99C.3080105@chikalov.dp.ua> Date: Sun, 28 Oct 2007 20:49:00 +0200 From: "Valery V.Chikalov" User-Agent: Thunderbird 2.0.0.6 (X11/20070814) MIME-Version: 1.0 To: Roman Divacky References: <4721AB07.20708@novakom.com.ua> <4723A8D6.6020002@chikalov.dp.ua> <20071028112910.GA84830@freebsd.org> <4724CBCA.30500@chikalov.dp.ua> In-Reply-To: <4724CBCA.30500@chikalov.dp.ua> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Cc: freebsd-emulation@freebsd.org Subject: Re: Linux emulation on FreeBSD AMD64 X-BeenThere: freebsd-emulation@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Development of Emulators of other operating systems List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 28 Oct 2007 17:49:13 -0000 Valery V.Chikalov wrote: > Roman Divacky wrote: >>> >>> and got something like: >>> >>> Oct 27 19:42:59 tiger kernel: mprotect addr:2a27d000, return 0 >>> Oct 27 19:42:59 tiger kernel: mprotect addr:2a7c1000, return 0 >>> Oct 27 19:42:59 tiger kernel: mprotect addr:2a7cd000, return 0 >>> Oct 27 19:42:59 tiger kernel: mprotect addr:2a7e2000, return 0 >>> Oct 27 19:42:59 tiger kernel: mprotect addr:2a7ef000, return 0 >>> Oct 27 19:43:09 tiger kernel: mprotect addr:55c00000, return 13 >>> Oct 27 19:43:09 tiger kernel: mprotect addr:55c81000, return 13 >>> >>> where 13 is EACCES. >> >> can you show what are the "prot" and "len" arguments? >> > > Sure: > > Oct 28 19:47:57 tiger kernel: mprotect addr:2a78b000, len:38376, prot:0, > return 0 > Oct 28 19:47:57 tiger kernel: mprotect addr:2a27d000, len:3682304, > prot:3, return 0 > Oct 28 19:47:57 tiger kernel: mprotect addr:2a27d000, len:3682304, > prot:5, return 0 > Oct 28 19:47:58 tiger kernel: pid 1878 (sqlplus), uid 1002: exited on > signal 11 (core dumped) > Oct 28 19:47:58 tiger kernel: mprotect addr:55c00000, len:4096, prot:1, > return 13 > Oct 28 19:47:58 tiger kernel: mprotect addr:55c81000, len:4096, prot:1, > return 13 > and again: Oct 28 20:35:03 tiger kernel: mprotect addr:2a657000, len:29304, prot:0, bsdprot: 0, return 0 Oct 28 20:35:03 tiger kernel: mprotect addr:2a78b000, len:38376, prot:0, bsdprot: 0, return 0 Oct 28 20:35:03 tiger kernel: mprotect addr:2a27d000, len:3682304, prot:3, bsdprot: 7, return 0 Oct 28 20:35:03 tiger kernel: mprotect addr:2a27d000, len:3682304, prot:5, bsdprot: 5, return 0 Oct 28 20:35:03 tiger kernel: mprotect addr:55c00000, len:4096, prot:1, bsdprot: 5, return 13 Oct 28 20:35:03 tiger kernel: mprotect addr:55c81000, len:4096, prot:1, bsdprot: 5, return 13 Oct 28 20:35:03 tiger kernel: mprotect addr:2a7c1000, len:4720, prot:0, bsdprot: 0, return 0 Oct 28 20:35:03 tiger kernel: mprotect addr:55c00000, len:4096, prot:1, bsdprot: 5, return 13 Oct 28 20:35:03 tiger kernel: mprotect addr:55c81000, len:4096, prot:1, bsdprot: 5, return 13 Oct 28 20:35:03 tiger kernel: mprotect addr:2a279000, len:3400, prot:0, bsdprot: 0, return 0 Oct 28 20:35:03 tiger kernel: mprotect addr:2a27c000, len:980, prot:0, bsdprot: 0, return 0 Oct 28 20:35:03 tiger kernel: mprotect addr:2a600000, len:131672, prot:0, bsdprot: 0, return 0 Oct 28 20:35:03 tiger kernel: mprotect addr:2a623000, len:4340, prot:0, bsdprot: 0, return 0 Oct 28 20:35:03 tiger kernel: mprotect addr:2a647000, len:3892, prot:0, bsdprot: 0, return 0 Oct 28 20:35:03 tiger kernel: mprotect addr:2a657000, len:29304, prot:0, bsdprot: 0, return 0 Oct 28 20:35:03 tiger kernel: mprotect addr:2a78b000, len:38376, prot:0, bsdprot: 0, return 0 Oct 28 20:35:03 tiger kernel: mprotect addr:2a27d000, len:3682304, prot:3, bsdprot: 7, return 0 Oct 28 20:35:03 tiger kernel: mprotect addr:2a27d000, len:3682304, prot:5, bsdprot: 5, return 0 Oct 28 20:35:03 tiger kernel: pid 2102 (sqlplus), uid 1002: exited on signal 11 (core dumped) Oct 28 20:35:04 tiger kernel: pid 2121 (oracle), uid 1002: exited on signal 11 (core dumped) now I did: +// if (bsd_args.prot & (PROT_READ | PROT_WRITE | PROT_EXEC)) +// bsd_args.prot |= PROT_READ | PROT_EXEC; and get: Oct 28 20:41:14 tiger kernel: mprotect addr:2a27c000, len:980, prot:0, bsdprot: 0, return 0 Oct 28 20:41:14 tiger kernel: mprotect addr:2a600000, len:131672, prot:0, bsdprot: 0, return 0 Oct 28 20:41:14 tiger kernel: mprotect addr:2a623000, len:4340, prot:0, bsdprot: 0, return 0 Oct 28 20:41:14 tiger kernel: mprotect addr:2a647000, len:3892, prot:0, bsdprot: 0, return 0 Oct 28 20:41:14 tiger kernel: mprotect addr:2a657000, len:29304, prot:0, bsdprot: 0, return 0 Oct 28 20:41:14 tiger kernel: mprotect addr:2a78b000, len:38376, prot:0, bsdprot: 0, return 0 Oct 28 20:41:14 tiger kernel: mprotect addr:2a27d000, len:3682304, prot:3, bsdprot: 3, return 0 Oct 28 20:41:14 tiger kernel: mprotect addr:2a27d000, len:3682304, prot:5, bsdprot: 5, return 0 Oct 28 20:41:14 tiger kernel: mprotect addr:55c00000, len:4096, prot:1, bsdprot: 1, return 0 Oct 28 20:41:14 tiger kernel: mprotect addr:55c81000, len:4096, prot:1, bsdprot: 1, return 0 Oct 28 20:41:14 tiger kernel: mprotect addr:2a7c1000, len:4720, prot:0, bsdprot: 0, return 0 Oct 28 20:41:14 tiger kernel: mprotect addr:55c00000, len:4096, prot:1, bsdprot: 1, return 0 Oct 28 20:41:14 tiger kernel: mprotect addr:55c81000, len:4096, prot:1, bsdprot: 1, return 0 Oct 28 20:41:14 tiger kernel: pid 2192 (sqlplus), uid 1002: exited on signal 11 (core dumped) Oct 28 20:41:14 tiger kernel: pid 2176 (sqlplus), uid 1002: exited on signal 11 (core dumped) Oct 28 20:41:14 tiger kernel: pid 2158 (bash), uid 1002: exited on signal 11 (core dumped) So, if prot argument leaves unchanged mprotect don't failing. But the result don't became better. Thank you. Valery.