trouble installing ghc 6.6: xargs: /usr/bin/ar: terminated by signal 11

I'm having trouble installing ghc 6.6. On ubuntu, virtual server (user mode linux). Something seems to be killing the process, no idea why. Anyone seen this? I looked around with ps to see if anything looked suspicious. I do have a lot of screens open, but I don't see why that should matter. There is no instance of haskell or gnci running. after running configure with no problem..... ~$ cd ghc-6.6/ ~/ghc-6.6$ sudo make &>makeOut Password: ~/ghc-6.6$ tail -n8 makeOut (echo Control/Concurrent_stub.o System/CPUTime_hsc.o System/Time_hsc.o ; /usr/bin/find Control/Applicative_split Control/Arrow_split Control/Concurrent_split Control/Concurrent/Chan_split ...long mess... Text/PrettyPrint/HughesPJ_split Text/Printf_split Text/Read_split Text/Read/Lex_split Text/Show_split Text/Show/Functions_split -name '*.o' -print) | xargs /usr/bin/ar q libHSbase.a /usr/bin/ar: creating libHSbase.a xargs: /usr/bin/ar: terminated by signal 11 make[2]: *** [libHSbase.a] Error 125 make[2]: *** Deleting file `libHSbase.a' make[1]: *** [all] Error 1 make[1]: Leaving directory `/home/thartman/ghc-6.6/libraries' make: *** [stage1] Error 2 ~/ghc-6.6$ -- View this message in context: http://www.nabble.com/trouble-installing-ghc-6.6%3A-xargs%3A--usr-bin-ar%3A-... Sent from the Haskell - Haskell-Cafe mailing list archive at Nabble.com.

On Sat, Jan 06, 2007 at 03:30:56PM -0800, tphyahoo wrote:
I'm having trouble installing ghc 6.6. On ubuntu, virtual server (user mode linux).
Something seems to be killing the process, no idea why.
Anyone seen this?
xargs: /usr/bin/ar: terminated by signal 11 make[2]: *** [libHSbase.a] Error 125 make[2]: *** Deleting file `libHSbase.a' make[1]: *** [all] Error 1 make[1]: Leaving directory `/home/thartman/ghc-6.6/libraries' make: *** [stage1] Error 2 ~/ghc-6.6$
Is it repeatable? i.e. If you run 'make' again, do you get the same error at the same place? If you answer 'no', swap out all your RAM and try again. Unexplained sig11's are the classic first symptom of failing memory, soon followed by filesystem corruption and data loss. I wish I'd paid attention when I had my first weird crash. :( (there are other possibilities, but they usually won't be fixed by replacing the memory and usually will be repeatable.)

At Sat, 6 Jan 2007 15:41:37 -0800, Stefan O'Rear wrote:
On Sat, Jan 06, 2007 at 03:30:56PM -0800, tphyahoo wrote:
I'm having trouble installing ghc 6.6. On ubuntu, virtual server (user mode linux).
Is it repeatable? i.e. If you run 'make' again, do you get the same error at the same place? If you answer 'no', swap out all your RAM and try again. Unexplained sig11's are the classic first symptom of failing memory, soon followed by filesystem corruption and data loss. I wish I'd paid attention when I had my first weird crash. :(
In my experience bad memory causing signal 11 can even be very repeatable. If you haven't tried a memory test yet, memtest86 and its derivatives are a good place to start. memtest86, memtest86+, and a bunch of other hardware diagnostics can be found on this (free as in beer) cd: http://www.ultimatebootcd.com/ j.

Yes, it's repeatable. As I mentioned, this is an ubuntu, virtual server (user mode linux). I'm thinking this may have to do with the "exoticness" of my system. So, I will repeat this question at the linode forum (linode is my virtual hoster, and the forum there has a lot of knowledgable users), and report back here if I learn anything useful. Worse case, I'm stuck with ghc 6.4 on my server, which I can (grouchily) live with. If anyone out there has installed ghc 6.6 on any kind of virtual linux, or better yet user mode linux (as opposed to XEN, or virtuozzo, or the other flavors), would be useful to know that as well. Thanks for pointing me in a likely right direction. http://www.linode.com/forums/viewtopic.php?p=11420#11420 -- View this message in context: http://www.nabble.com/trouble-installing-ghc-6.6%3A-xargs%3A--usr-bin-ar%3A-... Sent from the Haskell - Haskell-Cafe mailing list archive at Nabble.com.

On Sat, 2007-01-06 at 15:30 -0800, tphyahoo wrote:
I'm having trouble installing ghc 6.6. On ubuntu, virtual server (user mode linux).
Something seems to be killing the process, no idea why.
Anyone seen this?
Yes.
/usr/bin/ar: creating libHSbase.a xargs: /usr/bin/ar: terminated by signal 11
What is happening is that the ghc build system is linking thousands and thousands of tiny .o files into libHSbase.a. GNU ar isn't optimised for this use-case and it takes far more memory than it really needs to. So what happens is that ar takes >500Mb of memory and your virtual machine / virtual server probably isn't configured with that much memory and so the linux kernel OOM killer terminates the ar process. To make this worse, since there are so many .o files, it takes several invocations of ar to link them all. On each invocation ar is building the symbol index (-q is ignored) and this is what takes the most time and memory. It's a good deal quicker to use a custom program (100 lines of Haskell) to build libHSbase.a and then use ranlib just once to build the symbol index. I submitted a patch to gnu binutils to make ar take less memory when linking 1000's of files so it now only takes around 100Mb rather than 500Mb when linking libHSbase.a. That patch is included in version 2.17 I think (in other words most systems don't have it yet). What you can do in the mean time is either configure your virtual machine with more memory or turn off the split-objs feature when you configure ghc. Just add SplitObjs=NO" to your mk/build.mk file (which may not exist to start with). (The Gentoo ebuild does this automatically) Duncan

I've added this useful response to the GHC Building FAQ, here http://hackage.haskell.org/trac/ghc/wiki/Building/FAQ Please continue to add material to this page. Simon | -----Original Message----- | From: haskell-cafe-bounces@haskell.org [mailto:haskell-cafe-bounces@haskell.org] On Behalf Of Duncan | Coutts | Sent: 07 January 2007 13:38 | To: tphyahoo | Cc: haskell-cafe@haskell.org | Subject: Re: [Haskell-cafe] trouble installing ghc 6.6: xargs: /usr/bin/ar: terminated by signal 11 | | On Sat, 2007-01-06 at 15:30 -0800, tphyahoo wrote: | > I'm having trouble installing ghc 6.6. On ubuntu, virtual server (user mode | > linux). | > | > Something seems to be killing the process, no idea why. | > | > Anyone seen this? | | Yes. | | > /usr/bin/ar: creating libHSbase.a | > xargs: /usr/bin/ar: terminated by signal 11 | | | What is happening is that the ghc build system is linking thousands and | thousands of tiny .o files into libHSbase.a. GNU ar isn't optimised for | this use-case and it takes far more memory than it really needs to. So | what happens is that ar takes >500Mb of memory and your virtual | machine / virtual server probably isn't configured with that much memory | and so the linux kernel OOM killer terminates the ar process. | | To make this worse, since there are so many .o files, it takes several | invocations of ar to link them all. On each invocation ar is building | the symbol index (-q is ignored) and this is what takes the most time | and memory. It's a good deal quicker to use a custom program (100 lines | of Haskell) to build libHSbase.a and then use ranlib just once to build | the symbol index. | | I submitted a patch to gnu binutils to make ar take less memory when | linking 1000's of files so it now only takes around 100Mb rather than | 500Mb when linking libHSbase.a. That patch is included in version 2.17 I | think (in other words most systems don't have it yet). | | What you can do in the mean time is either configure your virtual | machine with more memory or turn off the split-objs feature when you | configure ghc. Just add SplitObjs=NO" to your mk/build.mk file (which | may not exist to start with). (The Gentoo ebuild does this | automatically) | | Duncan | | _______________________________________________ | Haskell-Cafe mailing list | Haskell-Cafe@haskell.org | http://www.haskell.org/mailman/listinfo/haskell-cafe

I finally got around to trying this, but still no luck. now getting
missing cmm.h error.
thartman@linodewhyou:~/haskellInstalls/ghc-6.6$ cat mk/build.mk
SplitObjs=NO
after doing sudo make > make.out
thartman@linodewhyou:~/haskellInstalls/ghc-6.6$ tail make.out
------------------------------------------------------------------------
------------------------------------------------------------------------
== make all -r;
in /home/thartman/haskellInstalls/ghc-6.6/rts
------------------------------------------------------------------------
../compiler/ghc-inplace -H16m -O -optc-O2 -static -I. -#include
HCIncludes.h -fvia-C -dcmm-lint -c Apply.cmm -o Apply.o
Apply.cmm:13:17: error: Cmm.h: No such file or directory
make[1]: *** [Apply.o] Error 1
make: *** [stage1] Error 1
thartman@linodewhyou:~/haskellInstalls/ghc-6.6$
anyone seen this?
thanks, thomas.
2007/1/7, Duncan Coutts
On Sat, 2007-01-06 at 15:30 -0800, tphyahoo wrote:
I'm having trouble installing ghc 6.6. On ubuntu, virtual server (user mode linux).
Something seems to be killing the process, no idea why.
Anyone seen this?
Yes.
/usr/bin/ar: creating libHSbase.a xargs: /usr/bin/ar: terminated by signal 11
What is happening is that the ghc build system is linking thousands and thousands of tiny .o files into libHSbase.a. GNU ar isn't optimised for this use-case and it takes far more memory than it really needs to. So what happens is that ar takes >500Mb of memory and your virtual machine / virtual server probably isn't configured with that much memory and so the linux kernel OOM killer terminates the ar process.
To make this worse, since there are so many .o files, it takes several invocations of ar to link them all. On each invocation ar is building the symbol index (-q is ignored) and this is what takes the most time and memory. It's a good deal quicker to use a custom program (100 lines of Haskell) to build libHSbase.a and then use ranlib just once to build the symbol index.
I submitted a patch to gnu binutils to make ar take less memory when linking 1000's of files so it now only takes around 100Mb rather than 500Mb when linking libHSbase.a. That patch is included in version 2.17 I think (in other words most systems don't have it yet).
What you can do in the mean time is either configure your virtual machine with more memory or turn off the split-objs feature when you configure ghc. Just add SplitObjs=NO" to your mk/build.mk file (which may not exist to start with). (The Gentoo ebuild does this automatically)
Duncan

Hello
cmm.h seems to sit in TOPDIR/includes
In the makefile these lines are close
SplitObjs=NO
H_FILES = $(wildcard ../includes/*.h) $(wildcard *.h)
Maybe you accidentally did something with the second while editing the first.
2007/2/20, Thomas Hartman
I finally got around to trying this, but still no luck. now getting missing cmm.h error.
thartman@linodewhyou:~/haskellInstalls/ghc-6.6$ cat mk/build.mk SplitObjs=NO
after doing sudo make > make.out
thartman@linodewhyou:~/haskellInstalls/ghc-6.6$ tail make.out ------------------------------------------------------------------------ ------------------------------------------------------------------------ == make all -r; in /home/thartman/haskellInstalls/ghc-6.6/rts ------------------------------------------------------------------------ ../compiler/ghc-inplace -H16m -O -optc-O2 -static -I. -#include HCIncludes.h -fvia-C -dcmm-lint -c Apply.cmm -o Apply.o
Apply.cmm:13:17: error: Cmm.h: No such file or directory make[1]: *** [Apply.o] Error 1 make: *** [stage1] Error 1 thartman@linodewhyou:~/haskellInstalls/ghc-6.6$
anyone seen this?
thanks, thomas.
2007/1/7, Duncan Coutts
: On Sat, 2007-01-06 at 15:30 -0800, tphyahoo wrote:
I'm having trouble installing ghc 6.6. On ubuntu, virtual server (user mode linux).
Something seems to be killing the process, no idea why.
Anyone seen this?
Yes.
/usr/bin/ar: creating libHSbase.a xargs: /usr/bin/ar: terminated by signal 11
What is happening is that the ghc build system is linking thousands and thousands of tiny .o files into libHSbase.a. GNU ar isn't optimised for this use-case and it takes far more memory than it really needs to. So what happens is that ar takes >500Mb of memory and your virtual machine / virtual server probably isn't configured with that much memory and so the linux kernel OOM killer terminates the ar process.
To make this worse, since there are so many .o files, it takes several invocations of ar to link them all. On each invocation ar is building the symbol index (-q is ignored) and this is what takes the most time and memory. It's a good deal quicker to use a custom program (100 lines of Haskell) to build libHSbase.a and then use ranlib just once to build the symbol index.
I submitted a patch to gnu binutils to make ar take less memory when linking 1000's of files so it now only takes around 100Mb rather than 500Mb when linking libHSbase.a. That patch is included in version 2.17 I think (in other words most systems don't have it yet).
What you can do in the mean time is either configure your virtual machine with more memory or turn off the split-objs feature when you configure ghc. Just add SplitObjs=NO" to your mk/build.mk file (which may not exist to start with). (The Gentoo ebuild does this automatically)
Duncan
_______________________________________________ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe
participants (7)
-
Daniil Elovkov
-
Duncan Coutts
-
Jeremy Shaw
-
Simon Peyton-Jones
-
Stefan O'Rear
-
Thomas Hartman
-
tphyahoo