Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

FreeBSD 12.0 -> 12.1 upgrade breaks passenger-install-apache2-module #2240

Closed
PeterMozesMerl opened this issue Dec 22, 2019 · 12 comments
Closed

Comments

@PeterMozesMerl
Copy link

PeterMozesMerl commented Dec 22, 2019

Issue

I can’t reinstall Passenger 6.0.4 after FreeBSD upgrade

Steps

I upgraded my test servers from FreeBSD 12.0 to 12.1. I followed the official handbook as usual.

I installed Ruby 2.6.5 using RVM. The same version has been running before the upgrade. It’s the latest public version.

All my Rails gems were installed, and 1,000+ Rails tests passed.

When I try to install Passenger, the following happens. Note that my systems are as close to the default FreeBSD install as possible (I’m using the default compilers, etc).

c++ -o buildout/apache2/module_libboost_oxt/boost/tss_null.o  -Isrc/cxx_supportlib -Isrc/cxx_supportlib/vendor-copy -Isrc/cxx_supportlib/vendor-modified -fPIC -I/usr/local/include/apr-1 -I/usr/local/include/apr-1 -I/usr/include -I/usr/local/include -I/usr/local/include/db5 -pipe -DLIBICONV_PLUG -fstack-protector-strong -fno-strict-aliasing -I/usr/local/include/apache24 -D_REENTRANT -I/usr/local/include -Wall -Wextra -Wno-unused-parameter -Wno-parentheses -Wpointer-arith -Wwrite-strings -Wno-long-long -Wno-missing-field-initializers -Wno-ambiguous-member-template -fvisibility=hidden -DVISIBILITY_ATTRIBUTE_SUPPORTED -DHAVE_ACCEPT4 -DHAS_SFENCE -DHAS_LFENCE -DPASSENGER_DEBUG -DBOOST_DISABLE_ASSERTS -g -fno-limit-debug-info -Wno-unused-local-typedefs -Wno-format-nonliteral -DHAS_UNORDERED_MAP -c src/cxx_supportlib/vendor-modified/boost/libs/thread/src/tss_null.cpp
mkdir -p buildout/apache2/module_libboost_oxt/oxt
c++ -o buildout/apache2/module_libboost_oxt/oxt/system_calls.o  -Isrc/cxx_supportlib -Isrc/cxx_supportlib/vendor-copy -Isrc/cxx_supportlib/vendor-modified -fPIC -I/usr/local/include/apr-1 -I/usr/local/include/apr-1 -I/usr/include -I/usr/local/include -I/usr/local/include/db5 -pipe -DLIBICONV_PLUG -fstack-protector-strong -fno-strict-aliasing -I/usr/local/include/apache24 -D_REENTRANT -I/usr/local/include -Wall -Wextra -Wno-unused-parameter -Wno-parentheses -Wpointer-arith -Wwrite-strings -Wno-long-long -Wno-missing-field-initializers -Wno-ambiguous-member-template -fvisibility=hidden -DVISIBILITY_ATTRIBUTE_SUPPORTED -DHAVE_ACCEPT4 -DHAS_SFENCE -DHAS_LFENCE -DPASSENGER_DEBUG -DBOOST_DISABLE_ASSERTS -g -fno-limit-debug-info -Wno-unused-local-typedefs -Wno-format-nonliteral -DHAS_UNORDERED_MAP -c src/cxx_supportlib/oxt/system_calls.cpp
src/cxx_supportlib/oxt/system_calls.cpp:153:2: error: reference to 'this_thread' is ambiguous
        CHECK_INTERRUPTION(
        ^
src/cxx_supportlib/oxt/system_calls.cpp:135:9: note: expanded from macro 'CHECK_INTERRUPTION'
                        && (!this_thread::syscalls_interruptable() \
                             ^
/usr/include/c++/v1/__threading_support:465:11: note: candidate found by name lookup is 'std::__1::this_thread'
namespace this_thread
          ^
src/cxx_supportlib/vendor-modified/boost/thread/pthread/condition_variable.hpp:30:15: note: candidate found by name lookup is 'boost::this_thread'
    namespace this_thread
              ^
src/cxx_supportlib/oxt/system_calls.cpp:153:2: error: reference to 'this_thread' is ambiguous
        CHECK_INTERRUPTION(
        ^
src/cxx_supportlib/oxt/system_calls.cpp:136:31: note: expanded from macro 'CHECK_INTERRUPTION'
                            || !(_intr_requested = this_thread::interruption_requested())) \
                                                   ^
/usr/include/c++/v1/__threading_support:465:11: note: candidate found by name lookup is 'std::__1::this_thread'
namespace this_thread
          ^
src/cxx_supportlib/vendor-modified/boost/thread/pthread/condition_variable.hpp:30:15: note: candidate found by name lookup is 'boost::this_thread'
    namespace this_thread
              ^
src/cxx_supportlib/oxt/system_calls.cpp:153:2: error: reference to 'this_thread' is ambiguous
        CHECK_INTERRUPTION(
        ^
src/cxx_supportlib/oxt/system_calls.cpp:143:7: note: expanded from macro 'CHECK_INTERRUPTION'
                 && this_thread::syscalls_interruptable() \
                    ^
/usr/include/c++/v1/__threading_support:465:11: note: candidate found by name lookup is 'std::__1::this_thread'
namespace this_thread
          ^
src/cxx_supportlib/vendor-modified/boost/thread/pthread/condition_variable.hpp:30:15: note: candidate found by name lookup is 'boost::this_thread'
    namespace this_thread
              ^
src/cxx_supportlib/oxt/system_calls.cpp:165:2: error: reference to 'this_thread' is ambiguous
        CHECK_INTERRUPTION(
        ^
src/cxx_supportlib/oxt/system_calls.cpp:135:9: note: expanded from macro 'CHECK_INTERRUPTION'
                        && (!this_thread::syscalls_interruptable() \
                             ^
/usr/include/c++/v1/__threading_support:465:11: note: candidate found by name lookup is 'std::__1::this_thread'
namespace this_thread
          ^
src/cxx_supportlib/vendor-modified/boost/thread/pthread/condition_variable.hpp:30:15: note: candidate found by name lookup is 'boost::this_thread'
    namespace this_thread
              ^
src/cxx_supportlib/oxt/system_calls.cpp:165:2: error: reference to 'this_thread' is ambiguous
        CHECK_INTERRUPTION(
        ^
src/cxx_supportlib/oxt/system_calls.cpp:136:31: note: expanded from macro 'CHECK_INTERRUPTION'
                            || !(_intr_requested = this_thread::interruption_requested())) \
                                                   ^
/usr/include/c++/v1/__threading_support:465:11: note: candidate found by name lookup is 'std::__1::this_thread'
namespace this_thread
          ^
src/cxx_supportlib/vendor-modified/boost/thread/pthread/condition_variable.hpp:30:15: note: candidate found by name lookup is 'boost::this_thread'
    namespace this_thread
              ^
src/cxx_supportlib/oxt/system_calls.cpp:165:2: error: reference to 'this_thread' is ambiguous
        CHECK_INTERRUPTION(
        ^
src/cxx_supportlib/oxt/system_calls.cpp:143:7: note: expanded from macro 'CHECK_INTERRUPTION'
                 && this_thread::syscalls_interruptable() \
                    ^
/usr/include/c++/v1/__threading_support:465:11: note: candidate found by name lookup is 'std::__1::this_thread'
namespace this_thread
          ^
src/cxx_supportlib/vendor-modified/boost/thread/pthread/condition_variable.hpp:30:15: note: candidate found by name lookup is 'boost::this_thread'
    namespace this_thread
              ^
src/cxx_supportlib/oxt/system_calls.cpp:177:2: error: reference to 'this_thread' is ambiguous
        CHECK_INTERRUPTION(
        ^
src/cxx_supportlib/oxt/system_calls.cpp:135:9: note: expanded from macro 'CHECK_INTERRUPTION'
                        && (!this_thread::syscalls_interruptable() \
                             ^
/usr/include/c++/v1/__threading_support:465:11: note: candidate found by name lookup is 'std::__1::this_thread'
namespace this_thread
          ^
src/cxx_supportlib/vendor-modified/boost/thread/pthread/condition_variable.hpp:30:15: note: candidate found by name lookup is 'boost::this_thread'
    namespace this_thread
              ^
src/cxx_supportlib/oxt/system_calls.cpp:177:2: error: reference to 'this_thread' is ambiguous
        CHECK_INTERRUPTION(
        ^
src/cxx_supportlib/oxt/system_calls.cpp:136:31: note: expanded from macro 'CHECK_INTERRUPTION'
                            || !(_intr_requested = this_thread::interruption_requested())) \
                                                   ^
/usr/include/c++/v1/__threading_support:465:11: note: candidate found by name lookup is 'std::__1::this_thread'
namespace this_thread
          ^
src/cxx_supportlib/vendor-modified/boost/thread/pthread/condition_variable.hpp:30:15: note: candidate found by name lookup is 'boost::this_thread'
    namespace this_thread
              ^
src/cxx_supportlib/oxt/system_calls.cpp:177:2: error: reference to 'this_thread' is ambiguous
        CHECK_INTERRUPTION(
        ^
src/cxx_supportlib/oxt/system_calls.cpp:143:7: note: expanded from macro 'CHECK_INTERRUPTION'
                 && this_thread::syscalls_interruptable() \
                    ^
/usr/include/c++/v1/__threading_support:465:11: note: candidate found by name lookup is 'std::__1::this_thread'
namespace this_thread
          ^
src/cxx_supportlib/vendor-modified/boost/thread/pthread/condition_variable.hpp:30:15: note: candidate found by name lookup is 'boost::this_thread'
    namespace this_thread
              ^
src/cxx_supportlib/oxt/system_calls.cpp:189:2: error: reference to 'this_thread' is ambiguous
        CHECK_INTERRUPTION(
        ^
src/cxx_supportlib/oxt/system_calls.cpp:135:9: note: expanded from macro 'CHECK_INTERRUPTION'
                        && (!this_thread::syscalls_interruptable() \
                             ^
/usr/include/c++/v1/__threading_support:465:11: note: candidate found by name lookup is 'std::__1::this_thread'
namespace this_thread
          ^
src/cxx_supportlib/vendor-modified/boost/thread/pthread/condition_variable.hpp:30:15: note: candidate found by name lookup is 'boost::this_thread'
    namespace this_thread
              ^
src/cxx_supportlib/oxt/system_calls.cpp:189:2: error: reference to 'this_thread' is ambiguous
        CHECK_INTERRUPTION(
        ^
src/cxx_supportlib/oxt/system_calls.cpp:136:31: note: expanded from macro 'CHECK_INTERRUPTION'
                            || !(_intr_requested = this_thread::interruption_requested())) \
                                                   ^
/usr/include/c++/v1/__threading_support:465:11: note: candidate found by name lookup is 'std::__1::this_thread'
namespace this_thread
          ^
src/cxx_supportlib/vendor-modified/boost/thread/pthread/condition_variable.hpp:30:15: note: candidate found by name lookup is 'boost::this_thread'
    namespace this_thread
              ^
src/cxx_supportlib/oxt/system_calls.cpp:189:2: error: reference to 'this_thread' is ambiguous
        CHECK_INTERRUPTION(
        ^
src/cxx_supportlib/oxt/system_calls.cpp:143:7: note: expanded from macro 'CHECK_INTERRUPTION'
                 && this_thread::syscalls_interruptable() \
                    ^
/usr/include/c++/v1/__threading_support:465:11: note: candidate found by name lookup is 'std::__1::this_thread'
namespace this_thread
          ^
src/cxx_supportlib/vendor-modified/boost/thread/pthread/condition_variable.hpp:30:15: note: candidate found by name lookup is 'boost::this_thread'
    namespace this_thread
              ^
src/cxx_supportlib/oxt/system_calls.cpp:201:2: error: reference to 'this_thread' is ambiguous
        CHECK_INTERRUPTION(
        ^
src/cxx_supportlib/oxt/system_calls.cpp:135:9: note: expanded from macro 'CHECK_INTERRUPTION'
                        && (!this_thread::syscalls_interruptable() \
                             ^
/usr/include/c++/v1/__threading_support:465:11: note: candidate found by name lookup is 'std::__1::this_thread'
namespace this_thread
          ^
src/cxx_supportlib/vendor-modified/boost/thread/pthread/condition_variable.hpp:30:15: note: candidate found by name lookup is 'boost::this_thread'
    namespace this_thread
              ^
src/cxx_supportlib/oxt/system_calls.cpp:201:2: error: reference to 'this_thread' is ambiguous
        CHECK_INTERRUPTION(
        ^
src/cxx_supportlib/oxt/system_calls.cpp:136:31: note: expanded from macro 'CHECK_INTERRUPTION'
                            || !(_intr_requested = this_thread::interruption_requested())) \
                                                   ^
/usr/include/c++/v1/__threading_support:465:11: note: candidate found by name lookup is 'std::__1::this_thread'
namespace this_thread
          ^
src/cxx_supportlib/vendor-modified/boost/thread/pthread/condition_variable.hpp:30:15: note: candidate found by name lookup is 'boost::this_thread'
    namespace this_thread
              ^
src/cxx_supportlib/oxt/system_calls.cpp:201:2: error: reference to 'this_thread' is ambiguous
        CHECK_INTERRUPTION(
        ^
src/cxx_supportlib/oxt/system_calls.cpp:143:7: note: expanded from macro 'CHECK_INTERRUPTION'
                 && this_thread::syscalls_interruptable() \
                    ^
/usr/include/c++/v1/__threading_support:465:11: note: candidate found by name lookup is 'std::__1::this_thread'
namespace this_thread
          ^
src/cxx_supportlib/vendor-modified/boost/thread/pthread/condition_variable.hpp:30:15: note: candidate found by name lookup is 'boost::this_thread'
    namespace this_thread
              ^
src/cxx_supportlib/oxt/system_calls.cpp:213:2: error: reference to 'this_thread' is ambiguous
        CHECK_INTERRUPTION(
        ^
src/cxx_supportlib/oxt/system_calls.cpp:135:9: note: expanded from macro 'CHECK_INTERRUPTION'
                        && (!this_thread::syscalls_interruptable() \
                             ^
/usr/include/c++/v1/__threading_support:465:11: note: candidate found by name lookup is 'std::__1::this_thread'
namespace this_thread
          ^
src/cxx_supportlib/vendor-modified/boost/thread/pthread/condition_variable.hpp:30:15: note: candidate found by name lookup is 'boost::this_thread'
    namespace this_thread
              ^
src/cxx_supportlib/oxt/system_calls.cpp:213:2: error: reference to 'this_thread' is ambiguous
        CHECK_INTERRUPTION(
        ^
src/cxx_supportlib/oxt/system_calls.cpp:136:31: note: expanded from macro 'CHECK_INTERRUPTION'
                            || !(_intr_requested = this_thread::interruption_requested())) \
                                                   ^
/usr/include/c++/v1/__threading_support:465:11: note: candidate found by name lookup is 'std::__1::this_thread'
namespace this_thread
          ^
src/cxx_supportlib/vendor-modified/boost/thread/pthread/condition_variable.hpp:30:15: note: candidate found by name lookup is 'boost::this_thread'
    namespace this_thread
              ^
src/cxx_supportlib/oxt/system_calls.cpp:213:2: error: reference to 'this_thread' is ambiguous
        CHECK_INTERRUPTION(
        ^
src/cxx_supportlib/oxt/system_calls.cpp:143:7: note: expanded from macro 'CHECK_INTERRUPTION'
                 && this_thread::syscalls_interruptable() \
                    ^
/usr/include/c++/v1/__threading_support:465:11: note: candidate found by name lookup is 'std::__1::this_thread'
namespace this_thread
          ^
src/cxx_supportlib/vendor-modified/boost/thread/pthread/condition_variable.hpp:30:15: note: candidate found by name lookup is 'boost::this_thread'
    namespace this_thread
              ^
src/cxx_supportlib/oxt/system_calls.cpp:225:2: error: reference to 'this_thread' is ambiguous
        CHECK_INTERRUPTION(
        ^
src/cxx_supportlib/oxt/system_calls.cpp:135:9: note: expanded from macro 'CHECK_INTERRUPTION'
                        && (!this_thread::syscalls_interruptable() \
                             ^
/usr/include/c++/v1/__threading_support:465:11: note: candidate found by name lookup is 'std::__1::this_thread'
namespace this_thread
          ^
src/cxx_supportlib/vendor-modified/boost/thread/pthread/condition_variable.hpp:30:15: note: candidate found by name lookup is 'boost::this_thread'
    namespace this_thread
              ^
fatal error: too many errors emitted, stopping now [-ferror-limit=]
20 errors generated.
rake aborted!
Command failed with status (1): [c++ -o buildout/apache2/module_libboost_oxt/oxt/system_calls.o  -Isrc/cxx_supportlib -Isrc/cxx_supportlib/vendor-copy -Isrc/cxx_supportlib/vendor-modified -fPIC -I/usr/local/include/apr-1 -I/usr/local/include/apr-1 -I/usr/include -I/usr/local/include -I/usr/local/include/db5 -pipe -DLIBICONV_PLUG -fstack-protector-strong -fno-strict-aliasing -I/usr/local/include/apache24 -D_REENTRANT -I/usr/local/include -Wall -Wextra -Wno-unused-parameter -Wno-parentheses -Wpointer-arith -Wwrite-strings -Wno-long-long -Wno-missing-field-initializers -Wno-ambiguous-member-template -fvisibility=hidden -DVISIBILITY_ATTRIBUTE_SUPPORTED -DHAVE_ACCEPT4 -DHAS_SFENCE -DHAS_LFENCE -DPASSENGER_DEBUG -DBOOST_DISABLE_ASSERTS -g -fno-limit-debug-info -Wno-unused-local-typedefs -Wno-format-nonliteral -DHAS_UNORDERED_MAP -c src/cxx_supportlib/oxt/system_calls.cpp]
/usr/home/mage/.rvm/gems/ruby-2.6.3/gems/passenger-6.0.4/build/support/cplusplus.rb:53:in `run_compiler'
/usr/home/mage/.rvm/gems/ruby-2.6.3/gems/passenger-6.0.4/build/support/cplusplus.rb:104:in `compile_cxx'
/usr/home/mage/.rvm/gems/ruby-2.6.3/gems/passenger-6.0.4/build/support/cplusplus.rb:162:in `block in define_cxx_object_compilation_task'
Tasks: TOP => apache2 => buildout/apache2/mod_passenger.so => buildout/apache2/module_libboost_oxt.a => buildout/apache2/module_libboost_oxt/oxt/system_calls.o
(See full trace by running task with --trace)

--------------------------------------------

It looks like something went wrong

Please read our documentation for troubleshooting tips:

   https://www.phusionpassenger.com/library/install/apache/
   https://www.phusionpassenger.com/library/admin/apache/troubleshooting/

If that doesn't help, please use our support facilities. We'll do our best to help you.

   https://www.phusionpassenger.com/support
@CamJN
Copy link
Contributor

CamJN commented Dec 23, 2019

This will be fixed by this commit: d0d660b which will be included in the next release.

@PeterMozesMerl
Copy link
Author

PeterMozesMerl commented Dec 23, 2019

So cool. Thanks

@PeterMozesMerl
Copy link
Author

PeterMozesMerl commented Dec 24, 2019

Temporary fix:

# pkg install gcc
$ export CC=gcc9
$ export CXX=g++9
$ export CPP=cpp9
$ passenger-install-apache2-module

@mkastner
Copy link

mkastner commented Dec 27, 2019

Just wondering: Will this also be fixed for the nginx module? I get the same error when trying to build nginx on FreeBSD 12.1. with the passenger module option enabled.

@PeterMozesMerl
Copy link
Author

PeterMozesMerl commented Dec 30, 2019

The temporal fix with GCC can be a pain as soon as you have ports installed (it means source compilation instead of binary packages).

Most of the time, I don’t have anything from ports. Right now the pkg (binary package) version of PostgreSQL 12 is still 12rc while the ports/stable version is 12.1. It made no sense to install RC version of PostgreSQL on new production servers. So, I did it with ports.

But the binary version of GCC downgrades ICU which breaks both Node and PostgreSQL. I had to compile (install from ports) all of these together that took me several hours mostly due to the compilation of GCC itself.

Without PostgreSQL 12 it wouldn’t be an issue, I guess. It’s just bad timing and unlucky combination. However, Rails + PostgreSQL + Node + Passenger is a reasonable setup on a webserver. And FreeBSD 12.0 is already complaining about "end of life" (no security upgrades) as the supported stable version is 12.1.

I hope the fix will be released as a gem soon.

@lindensmith
Copy link

lindensmith commented Jan 5, 2020

Temporary fix:

# pkg install gcc
$ export CC=gcc9
$ export CXX=g++9
$ export CPP=cpp9
$ passenger-install-apache2-module

I'm installing on a new server (AWS running FreeBSD 12.1) and having problems even after doing the above. I originally got the ambiguous thread failure and then applied the above instructions and now get the following (with both Ruby 2.6.5 and 2.7, installed with rvm):

In file included from src/agent/Watchdog/WatchdogMain.cpp:66:
src/agent/Shared/ApiServerUtils.h:264:8: note: synthesized method 'Passenger::BufferedIO::BufferedIO(const Passenger::BufferedIO&)' first required here
  264 | struct ApiServerInternalHttpResponse {
      |        ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~
src/agent/Shared/ApiServerUtils.h:351:32: note: synthesized method 'Passenger::ApiServerInternalHttpResponse<Passenger::Core::ApiServer::ApiServer, Passenger::ServerKit::HttpClient<Passenger::Core::ApiServer::Request>, Passenger::Core::ApiServer::Request>::ApiServerInternalHttpResponse(const Passenger::ApiServerInternalHttpResponse<Passenger::Core::ApiServer::ApiServer, Passenger::ServerKit::HttpClient<Passenger::Core::ApiServer::Request>, Passenger::Core::ApiServer::Request>&)' first required here
  351 |     libev->runLater(boost::bind(
      |                     ~~~~~~~~~~~^
  352 |      apiServerMakeInternalHttpRequestCallbackWrapper<Server, Client, Request>,
      |      ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
  353 |      req.callback, resp));
      |      ~~~~~~~~~~~~~~~~~~~        
In file included from src/cxx_supportlib/vendor-modified/boost/bind/bind.hpp:2127,
                 from src/cxx_supportlib/vendor-modified/boost/bind.hpp:22,
                 from src/cxx_supportlib/vendor-modified/boost/thread/detail/thread.hpp:30,
                 from src/cxx_supportlib/vendor-modified/boost/thread/thread_only.hpp:22,
                 from src/cxx_supportlib/vendor-modified/boost/thread/thread.hpp:12,
                 from src/cxx_supportlib/vendor-modified/boost/thread.hpp:13,
                 from src/cxx_supportlib/oxt/thread.hpp:28,
                 from src/agent/Watchdog/WatchdogMain.cpp:29:
src/cxx_supportlib/vendor-modified/boost/bind/bind_cc.hpp:35:91: note:   initializing argument 3 of 'boost::_bi::bind_t<R, R (*)(B1, B2), typename boost::_bi::list_av_2<A1, A2>::type> boost::bind(R (*)(B1, B2), A1, A2) [with R = void; B1 = boost::function<void(Passenger::ApiServerInternalHttpResponse<Passenger::Core::ApiServer::ApiServer, Passenger::ServerKit::HttpClient<Passenger::Core::ApiServer::Request>, Passenger::Core::ApiServer::Request>)>; B2 = Passenger::ApiServerInternalHttpResponse<Passenger::Core::ApiServer::ApiServer, Passenger::ServerKit::HttpClient<Passenger::Core::ApiServer::Request>, Passenger::Core::ApiServer::Request>; A1 = boost::function<void(Passenger::ApiServerInternalHttpResponse<Passenger::Core::ApiServer::ApiServer, Passenger::ServerKit::HttpClient<Passenger::Core::ApiServer::Request>, Passenger::Core::ApiServer::Request>)>; A2 = Passenger::ApiServerInternalHttpResponse<Passenger::Core::ApiServer::ApiServer, Passenger::ServerKit::HttpClient<Passenger::Core::ApiServer::Request>, Passenger::Core::ApiServer::Request>; typename boost::_bi::list_av_2<A1, A2>::type = boost::_bi::list2<boost::_bi::value<boost::function<void(Passenger::ApiServerInternalHttpResponse<Passenger::Core::ApiServer::ApiServer, Passenger::ServerKit::HttpClient<Passenger::Core::ApiServer::Request>, Passenger::Core::ApiServer::Request>)> >, boost::_bi::value<Passenger::ApiServerInternalHttpResponse<Passenger::Core::ApiServer::ApiServer, Passenger::ServerKit::HttpClient<Passenger::Core::ApiServer::Request>, Passenger::Core::ApiServer::Request> > >]'
   35 |     BOOST_BIND(BOOST_BIND_ST R (BOOST_BIND_CC *f) (B1, B2) BOOST_BIND_NOEXCEPT, A1 a1, A2 a2)
      |                                                                                        ~~~^~
g++9: fatal error: Killed signal terminated program cc1plus
compilation terminated.

@PeterMozesMerl
Copy link
Author

PeterMozesMerl commented Jan 5, 2020

@lindensmith I find it strange because I have been running it on three production servers for a while already.

Since our setups seem similar (RVM, Ruby 2.6.5, Apache), my first guess is it might be a difference between the modules we compile. What checkboxes did you have on?

On my servers, by default Ruby and Node are checked, and the two others aren’t. I always turn off the Node since I’m not using it. It’s installed only for the Rails asset generation.

If you had both checked, and you don’t need Passenger for Node, try turning it off, and be sure only Ruby is checked.

@lindensmith
Copy link

lindensmith commented Jan 6, 2020

I only had Ruby checked - I don't have Node installed, and I'm only just getting the virtual machine set up. there may be other things that got installed in the course of your setup that are slightly different - I hadn't installed much at all on the server yet. I hadn't even installed any other gems. I've installed a few more things, and just retried with 2.6.5 and 2.7 and it dies slightly differently in the two. I might just roll back to FreeBSD 11 for this setup, since I don't have anything on it yet.

from 2.6.5:

In file included from src/agent/Watchdog/WatchdogMain.cpp:66:
src/agent/Shared/ApiServerUtils.h:194:17: warning: implicitly-declared 'constexpr Passenger::ApplicationPool2::ApiKey& Passenger::ApplicationPool2::ApiKey::operator=(const Passenger::ApplicationPool2::ApiKey&)' is deprecated [-Wdeprecated-copy]
  194 |     auth.apiKey = ApplicationPool2::ApiKey::makeSuper();
      |     ~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
In file included from src/agent/Shared/ApiServerUtils.h:79,
                 from src/agent/Watchdog/WatchdogMain.cpp:66:
src/agent/Shared/ApplicationPoolApiKey.h:105:2: note: because 'Passenger::ApplicationPool2::ApiKey' has user-provided 'Passenger::ApplicationPool2::ApiKey::ApiKey(const Passenger::ApplicationPool2::ApiKey&)'
  105 |  ApiKey(const ApiKey &other) {
      |  ^~~~~~
g++9: fatal error: Killed signal terminated program cc1plus
compilation terminated.
rake aborted!
Command failed with status (1): [g++9 -o buildout/support-binaries/WatchdogMain.o  -Isrc/agent -Isrc/cxx_supportlib -Isrc/cxx_supportlib/vendor-copy -Isrc/cxx_supportlib/vendor-modified -Isrc/cxx_supportlib/vendor-modified/libev -Isrc/cxx_supportlib/vendor-copy/libuv/include -Isrc/cxx_supportlib/vendor-copy/websocketpp -I/usr/local/include -DHAS_CURL_EASY_RESET -D_REENTRANT -I/usr/local/include -Wall -Wextra -Wno-unused-parameter -Wno-parentheses -Wpointer-arith -Wwrite-strings -Wno-long-long -Wno-missing-field-initializers -feliminate-unused-debug-symbols -feliminate-unused-debug-types -fvisibility=hidden -DVISIBILITY_ATTRIBUTE_SUPPORTED -DHAVE_ACCEPT4 -DHAS_SFENCE -DHAS_LFENCE -DPASSENGER_DEBUG -DBOOST_DISABLE_ASSERTS -ggdb -Wno-unused-local-typedefs -Wno-format-nonliteral -DHAS_UNORDERED_MAP -c src/agent/Watchdog/WatchdogMain.cpp]
/usr/home/ec2-user/.rvm/gems/ruby-2.6.5/gems/passenger-6.0.4/build/support/cplusplus.rb:53:in `run_compiler'
/usr/home/ec2-user/.rvm/gems/ruby-2.6.5/gems/passenger-6.0.4/build/support/cplusplus.rb:104:in `compile_cxx'
/usr/home/ec2-user/.rvm/gems/ruby-2.6.5/gems/passenger-6.0.4/build/support/cplusplus.rb:162:in `block in define_cxx_object_compilation_task'
Tasks: TOP => apache2 => buildout/support-binaries/PassengerAgent => buildout/support-binaries/WatchdogMain.o
(See full trace by running task with --trace)

from 2.7:

In file included from src/cxx_supportlib/ConfigKit/Utils.h:34,
                 from src/cxx_supportlib/ConfigKit/Schema.h:41,
                 from src/cxx_supportlib/ConfigKit/Store.h:43,
                 from src/agent/Shared/Fundamentals/Initialization.h:33,
                 from src/agent/Watchdog/WatchdogMain.cpp:65:
src/cxx_supportlib/DataStructures/StringKeyTable.h: In instantiation of 'void Passenger::StringKeyTable<T, MoveSupport>::copyOrMoveValue(const T&, T&, const Passenger::SKT_DisableMoveSupport&) [with T = Passenger::HashedStaticString; MoveSupport = Passenger::SKT_DisableMoveSupport]':
src/cxx_supportlib/DataStructures/StringKeyTable.h:279:6:   required from 'Passenger::StringKeyTable<T, MoveSupport>::Cell* Passenger::StringKeyTable<T, MoveSupport>::realInsert(const Passenger::HashedStaticString&, ValueType, bool) [with ValueType = const Passenger::HashedStaticString&; LocalMoveSupport = Passenger::SKT_DisableMoveSupport; T = Passenger::HashedStaticString; MoveSupport = Passenger::SKT_DisableMoveSupport]'
src/cxx_supportlib/DataStructures/StringKeyTable.h:447:75:   required from 'Passenger::StringKeyTable<T, MoveSupport>::Cell* Passenger::StringKeyTable<T, MoveSupport>::insert(const Passenger::HashedStaticString&, const T&, bool) [with T = Passenger::HashedStaticString; MoveSupport = Passenger::SKT_DisableMoveSupport]'
src/cxx_supportlib/WrapperRegistry/Registry.h:202:33:   required from here
src/cxx_supportlib/DataStructures/StringKeyTable.h:233:10: warning: implicitly-declared 'constexpr Passenger::HashedStaticString& Passenger::HashedStaticString::operator=(const Passenger::HashedStaticString&)' is deprecated [-Wdeprecated-copy]
  233 |   target = source;
      |   ~~~~~~~^~~~~~~~
In file included from src/cxx_supportlib/LoggingKit/Logging.h:33,
                 from src/cxx_supportlib/LoggingKit/LoggingKit.h:30,
                 from src/cxx_supportlib/ConfigKit/Schema.h:38,
                 from src/cxx_supportlib/ConfigKit/Store.h:43,
                 from src/agent/Shared/Fundamentals/Initialization.h:33,
                 from src/agent/Watchdog/WatchdogMain.cpp:65:
src/cxx_supportlib/DataStructures/HashedStaticString.h:56:2: note: because 'Passenger::HashedStaticString' has user-provided 'Passenger::HashedStaticString::HashedStaticString(const Passenger::HashedStaticString&)'
   56 |  HashedStaticString(const HashedStaticString &b)
      |  ^~~~~~~~~~~~~~~~~~
g++9: fatal error: Killed signal terminated program cc1plus
compilation terminated.

@PeterMozesMerl
Copy link
Author

PeterMozesMerl commented Jan 6, 2020

@lindensmith I don’t code in either C or C++ so my hint might be ridiculous.

I can’t see any error message in your log except for "error: Killed signal terminated program cc1plus"

My log was full of error messages like "error: reference to 'this_thread' is ambiguous

At first glance, it looks like your machine ran out of memory, and the OS killed the compiler process.

@CamJN
Copy link
Contributor

CamJN commented Jan 6, 2020

@PeterMozesMerl @lindensmith yup the compiler was killed by an external actor, whether that was the kernel or something else isn't specified but it's not a passenger problem per se.

@lindensmith
Copy link

lindensmith commented Jan 15, 2020

@PeterMozesMerl @CamJN
I finally got back to this after dealing with other issues for a few days. It does appear to have been memory. I was getting the error on an AWS t2.micro, and when I upped it to a t2.mini it installed successfully.

@VVD
Copy link

VVD commented Dec 20, 2020

It's fixed already.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

6 participants