successfully installed but not boot @MacOSX(Leopard) + Apache2(MacPort)

15 views
Skip to first unread message

suzukyu

unread,
May 7, 2008, 2:54:30 PM5/7/08
to Phusion Passenger Discussions
passenger-install-apache2-module was successed. but not boot.
When it starts, it becomes 500 Internal Server Error.

Isn't this failing in the preparation of "libboost_thread.a" during
the installation?

------environment---------
MacOSX(Leopard)
Apache2(MacPort)
$ env | grep "^PATH"
PATH=/opt/local/apache2/bin:/opt/local/bin:/opt/local/sbin:/usr/bin:/
bin:/usr/sbin:/sbin:/usr/local/bin:/usr/X11/bin
$ gem list
...
rails (2.0.2, 1.2.6, 1.2.3)
rake (0.8.1, 0.7.3)
...
$ ruby -v
ruby 1.8.6 (2007-09-24 patchlevel 111) [universal-darwin9.0]
$ httpd -v
Server version: Apache/2.2.8 (Unix)
Server built: Apr 20 2008 03:30:34
$ apxs -q CFLAGS
-O2
$ apxs -q INCLUDEDIR
/opt/local/apache2/include
$ ls -p /opt/local/apache2/include
ap_compat.h http_connection.h
mod_dbd.h util_cfgtree.h
ap_config.h http_core.h
mod_include.h util_charset.h
ap_config_auto.h http_log.h
mod_log_config.h util_ebcdic.h
ap_config_layout.h http_main.h
mod_proxy.h util_filter.h
ap_listen.h http_protocol.h
mod_ssl.h util_ldap.h
ap_mmn.h http_request.h
mod_status.h util_md5.h
ap_mpm.h http_vhost.h
mpm.h util_script.h
ap_provider.h httpd.h
mpm_common.h util_time.h
ap_regex.h mod_auth.h
mpm_default.h util_xml.h
ap_regkey.h mod_cgi.h os.h
ap_release.h mod_core.h scoreboard.h
http_config.h mod_dav.h unixd.h
$

-------install log---------
$ sudo passenger-install-apache2-module
Password:
Welcome to the Passenger Apache 2 module installer.

This installer will guide you through the entire installation process.
It
shouldn't take more than 3 minutes in total.

Here's what you can expect from the installation process:

1. The Apache 2 module will be installed for you.
2. You'll learn how to configure Apache.
3. You'll learn how to deploy a Ruby on Rails application.

Don't worry if anything goes wrong. This installer will advise you on
how to
solve any problems.

Press Enter to continue, or Ctrl-C to abort.

Checking for required software...

* GNU C++ compiler... found at /usr/bin/g++
* Ruby development headers... found
* OpenSSL support for Ruby... found
* RubyGems... found
* Rake... found at /usr/bin/rake
* Apache 2... found at /opt/local/apache2/bin/httpd
* Apache 2 development headers... found at /opt/local/apache2/bin/
apxs
* Apache Portable Runtime (APR) development headers... found at /opt/
local/bin/apr-1-config
* fastthread... found
--------------------------------------------

--------------------------------------------
Compiling and installing Apache 2 module...
cd /Library/Ruby/Gems/1.8/gems/passenger-1.0.4
rake clean apache2
(in /Library/Ruby/Gems/1.8/gems/passenger-1.0.4)
### In ext/apache2:
rm -rf Utils.o Logging.o Configuration.o Hooks.o mod_passenger.o
mod_passenger.so

### In ext/passenger:
make clean
rm -f Makefile

### In ext/boost/src:
rm -f libboost_thread.a *.o

### In test:
rm -f Apache2ModuleTests *.o

### In benchmark:
rm -f DummyRequestHandler

### In ext/boost/src:
g++ -O2 -fPIC -I../.. -D_REENTRANT -DNDEBUG -c *.cpp
ar cru libboost_thread.a *.o
ranlib: file: libboost_thread.a(tss_dll.o) has no symbols
ranlib: file: libboost_thread.a(tss_hooks.o) has no symbols
ranlib: file: libboost_thread.a(tss_null.o) has no symbols
ranlib: file: libboost_thread.a(tss_pe.o) has no symbols
ranlib libboost_thread.a
ranlib: file: libboost_thread.a(tss_dll.o) has no symbols
ranlib: file: libboost_thread.a(tss_hooks.o) has no symbols
ranlib: file: libboost_thread.a(tss_null.o) has no symbols
ranlib: file: libboost_thread.a(tss_pe.o) has no symbols

### In ext/apache2:
g++ -I.. -fPIC -g -DPASSENGER_DEBUG -DDARWIN -
DSIGPROCMASK_SETS_THREAD_MASK -no-cpp-precomp -I/opt/local/include/
apr-1 -I/opt/local/apache2/include -D_REENTRANT -Wall -g -I/usr/local/
include -c mod_passenger.c

### In ext/apache2:
g++ -I.. -fPIC -g -DPASSENGER_DEBUG -DDARWIN -
DSIGPROCMASK_SETS_THREAD_MASK -no-cpp-precomp -I/opt/local/include/
apr-1 -I/opt/local/apache2/include -D_REENTRANT -Wall -g -I/usr/local/
include -c Utils.cpp

### In ext/apache2:
g++ -I.. -fPIC -g -DPASSENGER_DEBUG -DDARWIN -
DSIGPROCMASK_SETS_THREAD_MASK -no-cpp-precomp -I/opt/local/include/
apr-1 -I/opt/local/apache2/include -D_REENTRANT -Wall -g -I/usr/local/
include -c Logging.cpp

### In ext/apache2:
g++ -I.. -fPIC -g -DPASSENGER_DEBUG -DDARWIN -
DSIGPROCMASK_SETS_THREAD_MASK -no-cpp-precomp -I/opt/local/include/
apr-1 -I/opt/local/apache2/include -D_REENTRANT -Wall -g -I/usr/local/
include -c Configuration.cpp

### In ext/apache2:
g++ -I.. -fPIC -g -DPASSENGER_DEBUG -DDARWIN -
DSIGPROCMASK_SETS_THREAD_MASK -no-cpp-precomp -I/opt/local/include/
apr-1 -I/opt/local/apache2/include -D_REENTRANT -Wall -g -I/usr/local/
include -c Hooks.cpp

### In ext/apache2:
g++ -flat_namespace -bundle -undefined dynamic_lookup Utils.o
Logging.o Configuration.o Hooks.o mod_passenger.o -fPIC -o
mod_passenger.so -lstdc++ -lpthread ../boost/src/libboost_thread.a -
L/opt/local/lib -lapr-1

### In ext/passenger:
ruby extconf.rb
creating Makefile

### In ext/passenger:
make
gcc -I. -I/System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/
lib/ruby/1.8/universal-darwin9.0 -I/System/Library/Frameworks/
Ruby.framework/Versions/1.8/usr/lib/ruby/1.8/universal-darwin9.0 -I. -
fno-common -arch ppc -arch i386 -Os -pipe -fno-common -c
native_support.c
cc -arch ppc -arch i386 -pipe -bundle -undefined dynamic_lookup -o
native_support.bundle native_support.o -L"." -L"/System/Library/
Frameworks/Ruby.framework/Versions/1.8/usr/lib" -L. -arch ppc -arch
i386 -lruby -lpthread -ldl -lm


--------------------------------------------
The Apache 2 module was successfully installed.

Please edit your Apache configuration file, and add these lines:

LoadModule passenger_module /Library/Ruby/Gems/1.8/gems/
passenger-1.0.4/ext/apache2/mod_passenger.so
RailsSpawnServer /Library/Ruby/Gems/1.8/gems/passenger-1.0.4/bin/
passenger-spawn-server
RailsRuby /System/Library/Frameworks/Ruby.framework/Versions/1.8/
usr/bin/ruby

After you restart Apache, you are ready to deploy any number of Ruby
on Rails
applications on Apache, without any further Ruby on Rails-specific
configuration!

Press ENTER to continue.


--------------------------------------------
Deploying a Ruby on Rails application: an example

Suppose you have a Ruby on Rails application in /somewhere. Add a
virtual host
to your Apache configuration file, and set its DocumentRoot to
/somewhere/public, like this:

<VirtualHost *:80>
ServerName www.yourhost.com
DocumentRoot /somewhere/public
</VirtualHost>

And that's it! You may also want to check the Users Guide for security
and
optimization tips and other useful information:

/Library/Ruby/Gems/1.8/gems/passenger-1.0.4/doc/Users guide.html

Enjoy Passenger, a product of Phusion (www.phusion.nl) :-)
http://www.modrails.com/
$

Hongli Lai

unread,
May 7, 2008, 3:06:52 PM5/7/08
to phusion-...@googlegroups.com
suzukyu wrote:
> passenger-install-apache2-module was successed. but not boot.

This is a known problem with Passenger 1.0.4 and 64-bit MacOS X. It has
been fixed in version 1.0.5, which was released 20 minutes ago.

The RubyForge gem server hasn't been updated yet. But you can download
the gem via HTTP here:
http://rubyforge.org/frs/?group_id=5873&release_id=21948
--
Phusion | The Computer Science Company

Web: http://www.phusion.nl/
E-mail: in...@phusion.nl
Chamber of commerce no: 08173483 (The Netherlands)

suzukyu

unread,
May 7, 2008, 3:17:58 PM5/7/08
to Phusion Passenger Discussions
Thank you Hongli !!!

> This is a known problem with Passenger 1.0.4 and 64-bit MacOS X. It has
> been fixed in version 1.0.5, which was released 20 minutes ago.

I try a version 1.0.5 now !!

suzukyu

unread,
May 8, 2008, 12:15:45 AM5/8/08
to Phusion Passenger Discussions
I tried a version 1.0.5.
But, a similar symptom appeared and failed in the start of Passenger.
"500 Internal Server Error" occurred.

------Apache error_log------
$ tail /opt/local/apache2/logs/error_log
....
[Thu May 08 12:56:27 2008] [notice] Apache/2.2.8 (Unix) mod_ssl/2.2.8
OpenSSL/0.9.7l DAV/2 PHP/5.2.6 Phusion_Passenger/1.0.5 configured --
resuming normal operations
[2405:Hooks.cpp:400] Processing HTTP request: /retro/
[246:Application.h:264] Application 0x1e28fe0: created.
[246:StandardApplicationPool.h:249] Cleaning idle app /opt/local/
apache2/rails/retrospectiva_dev (PID 2491)
[246:Application.h:274] Application 0x1e28fe0: destroyed.
[2404:Hooks.cpp:400] Processing HTTP request: /retro/
[246:Application.h:264] Application 0x1e28dc0: created.
[246:StandardApplicationPool.h:249] Cleaning idle app /opt/local/
apache2/rails/retrospectiva_dev (PID 2511)
[246:Application.h:274] Application 0x1e28dc0: destroyed.

------Apache access_log------
$ tail /opt/local/apache2/logs/access_log
...
xxx.xxx.xxx.xxx - - [08/May/2008:12:56:48 +0900] "GET /retro/ HTTP/
1.0" 500 60
...
xxx.xxx.xxx.xxx - - [08/May/2008:12:59:59 +0900] "GET /retro/ HTTP/
1.0" 500 60

------passenger module installation log------
$ sudo passenger-install-apache2-module
Welcome to the Passenger Apache 2 module installer, v1.0.5.
cd /Library/Ruby/Gems/1.8/gems/passenger-1.0.5
rake clean apache2
(in /Library/Ruby/Gems/1.8/gems/passenger-1.0.5)
passenger-1.0.5/ext/apache2/mod_passenger.so
RailsSpawnServer /Library/Ruby/Gems/1.8/gems/passenger-1.0.5/bin/
passenger-spawn-server
RailsRuby /System/Library/Frameworks/Ruby.framework/Versions/1.8/
usr/bin/ruby

After you restart Apache, you are ready to deploy any number of Ruby
on Rails
applications on Apache, without any further Ruby on Rails-specific
configuration!

Press ENTER to continue.


--------------------------------------------
Deploying a Ruby on Rails application: an example

Suppose you have a Ruby on Rails application in /somewhere. Add a
virtual host
to your Apache configuration file, and set its DocumentRoot to
/somewhere/public, like this:

<VirtualHost *:80>
ServerName www.yourhost.com
DocumentRoot /somewhere/public
</VirtualHost>

And that's it! You may also want to check the Users Guide for security
and
optimization tips and other useful information:

/Library/Ruby/Gems/1.8/gems/passenger-1.0.5/doc/Users guide.html

Hongli Lai

unread,
May 8, 2008, 3:49:34 AM5/8/08
to phusion-...@googlegroups.com
suzukyu wrote:
> I tried a version 1.0.5.
> But, a similar symptom appeared and failed in the start of Passenger.
> "500 Internal Server Error" occurred.
>
> ------Apache error_log------
> $ tail /opt/local/apache2/logs/error_log
> ....
> [Thu May 08 12:56:27 2008] [notice] Apache/2.2.8 (Unix) mod_ssl/2.2.8
> OpenSSL/0.9.7l DAV/2 PHP/5.2.6 Phusion_Passenger/1.0.5 configured --
> resuming normal operations
> [2405:Hooks.cpp:400] Processing HTTP request: /retro/
> [246:Application.h:264] Application 0x1e28fe0: created.
> [246:StandardApplicationPool.h:249] Cleaning idle app /opt/local/
> apache2/rails/retrospectiva_dev (PID 2491)
> [246:Application.h:274] Application 0x1e28fe0: destroyed.
> [2404:Hooks.cpp:400] Processing HTTP request: /retro/
> [246:Application.h:264] Application 0x1e28dc0: created.
> [246:StandardApplicationPool.h:249] Cleaning idle app /opt/local/
> apache2/rails/retrospectiva_dev (PID 2511)
> [246:Application.h:274] Application 0x1e28dc0: destroyed.

These are just debugging messages. Your log seems to be totally fine
though. Are these the only messages that you see?

And have you already checked your Ruby on Rails log files?

suzukyu

unread,
May 8, 2008, 4:06:06 AM5/8/08
to Phusion Passenger Discussions
Sorry. The check of the rails log was forgotten.
My Apache Setting (httpd.conf)was wrong.
eg:
RAILS_ENV=production -> (httpd.conf) RailsEnv development

Passenger 1.0.5 is perfectly working.

Thank You.
Reply all
Reply to author
Forward
0 new messages