在RHEL6上运行passenger-install-apache2-module时出错

时间:2014-03-07 18:51:39

标签: ruby apache gem puppet

我正在尝试在RHEL6 64位计算机上设置puppet-dashboard。我能够为Ruby,Gems等安装所有部件,但现在当我尝试运行passenger-install-apache2-module时,它会因此错误而失败 -

/usr/lib/gcc/x86_64-redhat-linux/4.4.7/../../../../include/c++/4.4.7/bits/stl_pair.h:259: error: ‘_GLIBCXX_END_NAMESPACE’ does not name a type
In file included from ext/boost/config/posix_features.hpp:18,
                 from ext/boost/config/platform/linux.hpp:74,
                 from ext/boost/config.hpp:53,
                 from ext/boost/thread/detail/config.hpp:11,
                 from ext/boost/thread/tss.hpp:8,
                 from ext/oxt/system_calls.hpp:28,
                 from ext/common/Utils.cpp:26:
/usr/include/unistd.h:28: error: expected constructor, destructor, or type conversion before ‘extern’
In file included from /usr/lib/gcc/x86_64-redhat-linux/4.4.7/../../../../include/c++/4.4.7/new:40,
                 from /usr/lib/gcc/x86_64-redhat-linux/4.4.7/../../../../include/c++/4.4.7/bits/stl_construct.h:60,
                 from /usr/lib/gcc/x86_64-redhat-linux/4.4.7/../../../../include/c++/4.4.7/memory:51,
                 from ext/boost/config/no_tr1/memory.hpp:21,
                 from ext/boost/smart_ptr/shared_ptr.hpp:27,
                 from ext/boost/shared_ptr.hpp:17,
                 from ext/boost/thread/tss.hpp:9,
                 from ext/oxt/system_calls.hpp:28,
                 from ext/common/Utils.cpp:26:
/usr/lib/gcc/x86_64-redhat-linux/4.4.7/../../../../include/c++/4.4.7/exception:35: error: expected declaration before end of line
rake aborted!
Command failed with status (1): [c++ -Iext -Iext/common -Iext/libev -fPIC -DLINUX=2 -D_REENTRANT -D_GNU_SOURCE -I/usr/include/apr-1 -I/usr/include/apr-1 -g -pipe -Wall -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector --param=ssp-buffer-size=4 -m64 -mtune=generic -Wformat-security -fno-strict-aliasing -I/usr/include/httpd -D_REENTRANT -I/usr/local/include -Wall -Wextra -Wno-unused-parameter -Wno-parentheses -Wpointer-arith -Wwrite-strings -Wno-long-long -Wno-missing-field-initializers -fcommon -feliminate-unused-debug-symbols -feliminate-unused-debug-types -fvisibility=hidden -DVISIBILITY_ATTRIBUTE_SUPPORTED -Wno-attributes -ggdb -DHAS_ALLOCA_H -DHAVE_ACCEPT4 -DHAS_SFENCE -DHAS_LFENCE -DPASSENGER_DEBUG -DBOOST_DISABLE_ASSERTS -o buildout/apache2/module_libpassenger_common/Utils.o -c ext/common/Utils.cpp]

Tasks: TOP => apache2 => buildout/apache2/mod_passenger.so => buildout/apache2/module_libpassenger_common/Utils.o

我搜索了谷歌,似乎交换是类似问题的常见原因,但看起来我应该有足够的 -

             total       used       free     shared    buffers     cached
Mem:       3924852    1794880    2129972          0     349916     626264
-/+ buffers/cache:     818700    3106152
Swap:      4095992     112864    3983128

我对Ruby知之甚少,所以我无法为深度故障排除做太多工作。有人可以帮忙吗?

1 个答案:

答案 0 :(得分:1)

我不确定这个错误意味着什么,但我让乘客继续这样做:

yum install -y httpd httpd-devel mod_ssl ruby-devel rubygems gcc-c++ curl-devel zlib-devel make automake
gem install rack passenger
passenger-install-apache2-module

希望这有帮助