我正在尝试在配置的计算机(puppet)上安装Haskell平台。 "框"我将使用将具有512mb内存并且是Ubuntu 12 64位。首先我通过tarball安装了GHC 7.6.3(所以configure和make install)。那很好。
之后,木偶将下载Haskell平台2013.2。它还将进行配置和安装。但由于可用内存有限,这将失败;
Notice: /Stage[main]/Haskell::Platform/Exec[haskell platform install]/returns: scripts/build.sh
Notice: /Stage[main]/Haskell::Platform/Exec[haskell platform install]/returns: **************************************************
Notice: /Stage[main]/Haskell::Platform/Exec[haskell platform install]/returns: Scanning system for any installed Haskell Platform components...
Notice: /Stage[main]/Haskell::Platform/Exec[haskell platform install]/returns:
Notice: /Stage[main]/Haskell::Platform/Exec[haskell platform install]/returns: Found:
Notice: /Stage[main]/Haskell::Platform/Exec[haskell platform install]/returns: None.
Notice: /Stage[main]/Haskell::Platform/Exec[haskell platform install]/returns:
Notice: /Stage[main]/Haskell::Platform/Exec[haskell platform install]/returns: New packages to install:
Notice: /Stage[main]/Haskell::Platform/Exec[haskell platform install]/returns: HUnit-1.2.5.2 OpenGLRaw-1.3.0.0 GLURaw-1.3.0.0 OpenGL-2.8.0.0 GLUT-2.4.0.0 html-1.0.1.2 parallel-3.2.0.3 primitive-0.5.0.1 random-1.0.1.1 QuickCheck-2.6 alex-3.0.5 split-0.2.2 stm-2.4.2 async-2.0.1.4 syb-0.4.0 haskell-src-1.0.1.5 text-0.11.3.1 attoparsec-0.10.4.0 hashable-1.1.2.5 case-insensitive-1.0.0.1 transformers-0.3.0.0 mtl-2.1.2 fgl-5.4.2.4 happy-1.18.10 parsec-3.1.3 network-2.4.1.2 HTTP-4000.2.8 regex-base-0.93.2 regex-posix-0.95.2 regex-compat-0.95.1 unordered-containers-0.2.3.0 vector-0.10.0.1 xhtml-3000.2.1 cgi-3001.1.7.5 zlib-0.5.4.1 cabal-install-1.16.0.2 haskell-platform-2013.2.0.0
Notice: /Stage[main]/Haskell::Platform/Exec[haskell platform install]/returns:
Notice: /Stage[main]/Haskell::Platform/Exec[haskell platform install]/returns: **************************************************
Notice: /Stage[main]/Haskell::Platform/Exec[haskell platform install]/returns: Building HUnit-1.2.5.2
Notice: /Stage[main]/Haskell::Platform/Exec[haskell platform install]/returns: "/usr/local/bin/ghc" "--make" "Setup" "-o" "Setup" "-package" "Cabal-1.16.0"
Notice: /Stage[main]/Haskell::Platform/Exec[haskell platform install]/returns: Linking Setup ...
Notice: /Stage[main]/Haskell::Platform/Exec[haskell platform install]/returns: collect2: ld terminated with signal 9 [Killed]
Notice: /Stage[main]/Haskell::Platform/Exec[haskell platform install]/returns:
Notice: /Stage[main]/Haskell::Platform/Exec[haskell platform install]/returns: Error:
Notice: /Stage[main]/Haskell::Platform/Exec[haskell platform install]/returns: Compiling the Setup script failed
Notice: /Stage[main]/Haskell::Platform/Exec[haskell platform install]/returns: make: *** [build.stamp] Error 2
所以我用谷歌搜索:" collect2:ld终止了信号9 [Killed]"并得出结论这是一个记忆问题(Why is the linker terminating on me? when i build CLang)。没有问题,如果您将提供Vagrant。我将可用内存增加到2GB,安装程序 FINE
但是我想将它部署到数字海洋,在那里您可以获得有限的内存量。要解决此问题,您还可以创建或增加交换文件的大小。所以我制作了一个4GB的交换文件。并再次运行配置。这失败并出现与以前相同的错误:
collect2: ld terminated with signal 9 [Killed]
我正在使用puppet脚本来创建交换文件:https://gist.github.com/philfreo/6576492
我已经验证了文件的创建,它就在那里。
我错过了什么?