Debian Bug report logs - #10975
electric-fence: mprotect() failed: Invalid argument

version graph

Package: electric-fence; Maintainer for electric-fence is Matthew Vernon <matthew@debian.org>; Source for electric-fence is src:electric-fence (PTS, buildd, popcon).

Reported by: <joost@rulcmc.leidenuniv.nl>

Date: Tue, 1 Jul 1997 13:33:02 UTC

Severity: normal

Found in version 2.0.5-3

Bug is archived. No further changes may be made.

Toggle useless messages

View this report as an mbox folder, status mbox, maintainer mbox


Report forwarded to debian-bugs-dist@lists.debian.org, Siggy Brentrup <bsb@debian.org>:
Bug#10975; Package electric-fence. (full text, mbox, link).


Acknowledgement sent to <joost@rulcmc.leidenuniv.nl>:
New bug report received and forwarded. Copy sent to Siggy Brentrup <bsb@debian.org>. (full text, mbox, link).


Message #5 received at submit@bugs.debian.org (full text, mbox, reply):

From: <joost@rulcmc.leidenuniv.nl>
To: submit@bugs.debian.org
Subject: electric-fence: mprotect() failed: Invalid argument
Date: Tue, 1 Jul 1997 15:20:00 +0200 (CEST)
Package: electric-fence
Version: 2.0.5-3

When linking an g++ programme with electric fence that has no
(known, anyway) bugs in it, I get:

   $ ./fakeroot 
   
     Electric Fence 2.0.5 Copyright (C) 1987-1995 Bruce Perens.
   
   ElectricFence Exiting: mprotect() failed: Invalid argument

The reason I claim my programme has no bugs in it, is because the
the error message comes right after Electric fence writes it's
opening message to the screen. Here's a strace:


   open("/lib/libc.so.6", O_RDONLY)        = 3
   mmap(0, 4096, PROT_READ, MAP_PRIVATE, 3, 0) = 0x4007f000
   munmap(0x4007f000, 4096)                = 0
   mmap(0, 646832, PROT_READ|PROT_EXEC, MAP_PRIVATE, 3, 0) = 0x4007f000
   mprotect(0x4010d000, 65200, PROT_NONE)  = 0
   mmap(0x4010d000, 16384, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_FIXED, 3, 0x8d000)
    = 0x4010d000
   mmap(0x40111000, 48816, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_FIXED|MAP_ANONYMOU
   S, -1, 0) = 0x40111000
   close(3)                                = 0
   mprotect(0x4007f000, 581632, PROT_READ|PROT_WRITE) = 0
   mprotect(0x4007f000, 581632, PROT_READ|PROT_EXEC) = 0
   mprotect(0x40046000, 225280, PROT_READ|PROT_WRITE) = 0
   mprotect(0x40046000, 225280, PROT_READ|PROT_EXEC) = 0
   mprotect(0x4000f000, 188416, PROT_READ|PROT_WRITE) = 0
   mprotect(0x4000f000, 188416, PROT_READ|PROT_EXEC) = 0
   personality(PER_LINUX)                  = 0
   getpid()                                = 32163
   write(2, "\n", 1
   write(2, "\n", 1
   )                       = 1
   write(2, " ", 1 )                        = 1
   write(2, " ", 1 )                        = 1
   write(2, "E", 1E)                        = 1
   write(2, "l", 1l)                        = 1
   write(2, "e", 1e)                        = 1
   [ctric Fence 2.0.5 Copyright (C) 1987-1995 Bruce Peren]
   write(2, "s", 1s)                        = 1
   write(2, ".", 1.)                        = 1
   write(2, "\n", 1
   )                       = 1
   mmap(0, 1048576, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 0x401
   1d000
   mprotect(0x4011d001, 1048575, PROT_NONE) = -1 EINVAL (Invalid argument)



And, this might be relevant to:

$ ldd ./fakeroot
        libstdc++.so.272 => /usr/lib/libg++-dbg/libstdc++.so.272 (0x4000f000)
        libg++.so.272 => /usr/lib/libg++-dbg/libg++.so.272 (0x40046000)
        libc.so.6 => /lib/libc.so.6 (0x4007f000)
        /lib/ld-linux.so.2 => /lib/ld-linux.so.2 (0x40000000)

$ dpkg -l libc6{,-dev} ldso libg++272{,-dev}
ii  libc6           2.0.4-1        The GNU C library version 2 (run-time files)
ii  libc6-dev       2.0.4-1        The GNU C library version 2 (development fil
ii  ldso            1.9.2-3        The Linux dynamic linker, library and utilit
ii  libg++272       2.7.2.5-1      The GNU C++ libraries (ELF version).
ii  libg++272-dev   2.7.2.5-1      The GNU C++ libraries (ELF version).


-- System Information
Debian Release: 1.3
Kernel Version: Linux rulcmc 2.0.30 #4 Thu Jun 5 11:50:20 CEST 1997 i486 unknown


Information forwarded to debian-bugs-dist@lists.debian.org, Siggy Brentrup <bsb@debian.org>:
Bug#10975; Package electric-fence. (full text, mbox, link).


Acknowledgement sent to Joey Hess <joey@kite.ml.org>:
Extra info received and forwarded to list. Copy sent to Siggy Brentrup <bsb@debian.org>. (full text, mbox, link).


Message #10 received at 10975@bugs.debian.org (full text, mbox, reply):

From: Joey Hess <joey@kite.ml.org>
To: joost@rulcmc.leidenuniv.nl, 10975@bugs.debian.org
Subject: Re: Bug#10975: electric-fence: mprotect() failed: Invalid argument
Date: Tue, 1 Jul 1997 15:08:07 -0400
joost@rulcmc.leidenuniv.nl:
> When linking an g++ programme with electric fence that has no
> (known, anyway) bugs in it, I get:
> 
>    $ ./fakeroot 
>    
>      Electric Fence 2.0.5 Copyright (C) 1987-1995 Bruce Perens.
>    
>    ElectricFence Exiting: mprotect() failed: Invalid argument

Seems to be a libc6 problem. Electric fence works ok on my libc5 systems,
but on my libc6 system, always exits with the above error.

-- 
see shy jo


Information forwarded to debian-bugs-dist@lists.debian.org, Siggy Brentrup <bsb@debian.org>:
Bug#10975; Package electric-fence. (full text, mbox, link).


Acknowledgement sent to "E.L. Meijer (Eric)" <tgakem@sg10.chem.tue.nl>:
Extra info received and forwarded to list. Copy sent to Siggy Brentrup <bsb@debian.org>. (full text, mbox, link).


Message #15 received at 10975@bugs.debian.org (full text, mbox, reply):

From: "E.L. Meijer (Eric)" <tgakem@sg10.chem.tue.nl>
To: 10975@bugs.debian.org
Subject: comment on bug report
Date: Mon, 10 Nov 1997 11:34:01 +0100 (MET)
Hello,

concerning bug #10975

I have currently the same problem as reported here.

Joey Hess <joey@kite.ml.org> commented that

> Seems to be a libc6 problem. Electric fence works ok on my libc5 systems,
> but on my libc6 system, always exits with the above error.

My system however is completely libc5 and with a g++ program I get the same
message:

>    ElectricFence Exiting: mprotect() failed: Invalid argument

I had the impression that it might be related to problems in the kernel.
I had no luck with 2.0.21, 2.0.26, 2.0.29 and 2.0.30.  I will try with
2.0.31 as soon as a kernel-source package is available.  I'll keep you
informed.

Eric Meijer

-- 
 E.L. Meijer (tgakem@chem.tue.nl)          | tel. office +31 40 2472189
 Eindhoven Univ. of Technology             | tel. lab.   +31 40 2475032
 Lab. for Catalysis and Inorg. Chem. (TAK) | tel. fax    +31 40 2455054


Send a report that this bug log contains spam.


Debian bug tracking system administrator <owner@bugs.debian.org>. Last modified: Tue Apr 16 07:52:08 2024; Machine Name: bembo

Debian Bug tracking system

Debbugs is free software and licensed under the terms of the GNU Public License version 2. The current version can be obtained from https://bugs.debian.org/debbugs-source/.

Copyright © 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson, 2005-2017 Don Armstrong, and many other contributors.