$: /Users/dev/.rvm/gems/ruby-1.9.2-head#rails3/gems/sqlite3-ruby-1.3.1/lib/sqlite3/sqlite3_native.bundle: [BUG] Segmentation fault
ruby 1.8.7 (2009-06-12 patchlevel 174) [universal-darwin10.0]
Abort trap
It's seem that ruby is not the correct version (1.8.7) but :
$: ruby - v
$: ruby 1.9.2dev (2010-07-15 revision 28653) [x86_64-darwin10.4.0]
$: gem list
*** LOCAL GEMS ***
abstract (1.0.0)
actionmailer (3.0.0.beta4, 3.0.0.beta3)
actionpack (3.0.0.beta4, 3.0.0.beta3)
activemodel (3.0.0.beta4, 3.0.0.beta3)
activerecord (3.0.0.beta4, 3.0.0.beta3)
activeresource (3.0.0.beta4, 3.0.0.beta3)
activesupport (3.0.0.beta4, 3.0.0.beta3)
arel (0.4.0, 0.3.3)
builder (2.1.2)
bundler (0.9.26)
erubis (2.6.6)
i18n (0.4.1, 0.3.7)
mail (2.2.5)
memcache-client (1.8.5)
mime-types (1.16)
polyglot (0.3.1)
rack (1.1.0)
rack-mount (0.6.9)
rack-test (0.5.4)
rails (3.0.0.beta4, 3.0.0.beta3)
railties (3.0.0.beta4, 3.0.0.beta3)
rake (0.8.7)
rdoc (2.5.9)
sqlite3-ruby (1.3.1)
text-format (1.0.0)
text-hyphen (1.0.0)
thor (0.13.8)
treetop (1.4.8)
tzinfo (0.3.22)
will_paginate (3.0.pre)
more info :
$: ~ dev$ ruby -v
ruby 1.9.2dev (2010-07-15 revision 28653) [x86_64-darwin10.4.0]
$ :~ dev$ rails -v
/System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ruby/1.8/rubygems.rb:827:in `report_activate_error': Could not find RubyGem rails (>= 0) (Gem::LoadError)
from /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ruby/1.8/rubygems.rb:261:in `activate'
from /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ruby/1.8/rubygems.rb:68:in `gem'
from /usr/bin/rails:18
Any ideas ?
Thanks very much :)
Had the same issue after moving to 1.9.2p0, but restarting the console on Snow Leopard did the trick. Seems rvm might have gotten confused.
Same problem for me on Snow Leopard; even though under rvm 1.9.2#rails3, I can see correct rails version number.
I have to use following command to use rails command:
ruby which rails g scaffold User name:string bio:text
Any solution?
I've finally found the reason. Looks like gem install rails is not managed to install the proper binary for rails in rvm. And rails is still references /usr/bin/rails, which have a #! line point to System ruby.
You can see it with:
head -1 `which rails`
which returns:
#!/System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/bin/ruby
Change that to:
#!/usr/bin/env ruby
will fix the problem. I don't know if this problem affect other executable scripts gem installs, but why gem not install rails to rvm's own bin path is a mystery to me. Anyway, this workaround do the dirty for me.
I Had the same problem when using ree-1.8.7-2011.03. (Ruby enterprise Edition)
I uninstalled the sqlite3 gems then I ran:
gem install sqlite3
and it worked. Note that the sqlite3-ruby gem now recommends to use 'sqlite3' now.
I don't know how this has happened in your case but it looks to me that Rails has tried to run with your system installed Ruby but is loading gems from a 1.9.2 load path. Very odd.
You see the correct Ruby version in your shell (RVM has precedence in the local path) but that's not apparently what Rails is being started with.
Check to see you how you are starting Rails and that you don't have paths or links or aliases messed up between Ruby versions
You might need to run
rvm reload
Same problem after a bunch of updates (rvm to 1.5.2 and ruby to 1.9.2-p180)
Console restart did not work for me, updating to rails 3.0.6 changed the error to a seg error of mysql2 instead of sqlite3, re-installing mysql2 did the trick for me finally.
Regards
Michael
I encountered this exact error in zsh and MacVim, and eventually tracked it back to this RVM issue. The solution was to move the RVM sourcing I had in .zshrc to .zshenv. Worked immediately. Just posting on the off chance someone stumbles across this the way I did.
There is a known issue with zsh, rvm and vim.
The latest solution is to set the shell to sh in your .vimrc
set shell=sh
This blog has all the solutions listed
Related
Here are my local gems :
$ gem list
*** LOCAL GEMS ***
actionmailer (4.0.0, 3.2.14)
actionpack (4.0.0, 3.2.14)
activemodel (4.0.0, 3.2.14)
activerecord (4.0.0, 3.2.14)
activerecord-deprecated_finders (1.0.3)
activeresource (3.2.14)
activesupport (4.0.0, 3.2.14)
arel (4.0.0, 3.0.2)
atomic (1.1.13)
builder (3.1.4, 3.0.4)
bundler (1.3.5)
bundler-unload (1.0.1)
erubis (2.7.0)
hike (1.2.3)
i18n (0.6.5)
journey (1.0.4)
json (1.8.0)
mail (2.5.4)
mime-types (1.24)
minitest (4.7.5)
multi_json (1.7.9)
polyglot (0.3.3)
rack (1.5.2, 1.4.5)
rack-cache (1.2)
rack-ssl (1.3.3)
rack-test (0.6.2)
rails (3.2.14)
railties (4.0.0, 3.2.14)
rake (10.1.0)
rdoc (3.12.2)
rubygems-bundler (1.2.2)
rubygems-update (2.0.7)
rvm (1.11.3.8)
sprockets (2.10.0, 2.2.2)
sprockets-rails (2.0.0)
thor (0.18.1)
thread_safe (0.1.2)
tilt (1.4.1)
treetop (1.4.15)
tzinfo (0.3.37)
But when I type rails -v I get this :
$ rails -v
Rails 4.0.0
$ which rails
/Users/polonium/.rvm/rubies/ruby-2.0.0-p247/bin/rails
How can I specify rvm to use rails version 3.2.14 ?
Thanks in advance
You can create a new rails app with a particular rails version, like this:
rails _3.2.14_ new myApp
How can I specify rvm to use rails version 3.2.14 ?
rvm has nothing to do with rails. rvm is used to manage multiple ruby installations. And each of your ruby installations can be associated with multiple gemsets. For instance, say you have ruby 1.9.3 installed and you created two gemsets for ruby 1.9.3: gemsetA and gemsetB. If you tell rvm to use ruby 1.9.3 with gemsetA, that means:
Your ruby programs will be executed by ruby 1.9.3.
Your ruby programs can require any gem in gemsetA (which then allows your program to use the methods (or classes) defined in gemsetA), but any gems in gemsetB cannot be seen by your ruby program.
Here's a concrete example:
~$ rvm list
rvm rubies
ruby-1.8.7-p370 [ i686 ]
* ruby-1.9.3-p194 [ x86_64 ]
=> ruby-2.0.0-p0 [ x86_64 ]
ruby-2.0.0-p247 [ x86_64 ]
# => - current
# =* - current && default
# * - default
~$ rvm use 1.9.3-p194
Using /Users/7stud/.rvm/gems/ruby-1.9.3-p194
.
~$ rvm gemset list (This lists only the gemsets for the current ruby version)
gemsets for ruby-1.9.3-p194 (found in /Users/7stud/.rvm/gems/ruby-1.9.3-p194)
=> (default)
global
programming
rails3tutorial
rails4
~$ rvm gemset use programming
Using ruby-1.9.3-p194 with gemset programming
After I do that, my ruby programs will be executed by ruby 1.9.3 and any gems in the programming gemset can be required into my ruby program. You can use a shortcut to perform both those commands in one step:
rvm use ruby 1.9.3-p194#programming
You just combine the ruby version and the gemset with an '#' between them.
But when I type rails -v I get this :
$ rails -v
Rails 4.0.0
That's because the current gemset contains the gem for rails 4.0.0. If you want to see $ rails -v output Rails 3.2.14, then you need to tell rvm to switch to a gemset that contains the rails 3.2.14 gem.
However, you can make rvm automatically switch to the proper rails version and gemset for your rails project. In your Gemfile, add a comment after the ruby version:
ruby '2.0.0'
#ruby-gemset=railstutorial4_gems
Then whenever you switch to the directory containing your rails project, rvm will automatically switch the current ruby to ruby 2.0.0 and the current gemset to railstutorial4_gems. If you change directories out of your rails app, rvm will change the current ruby and the current gemset back to what they were.
I'm just a rails beginner, but here are the steps I use to create a new project, which are straight out of the railstutorial book (http://ruby.railstutorial.org/ruby-on-rails-tutorial-book)
1)
.../rails_projects$ rvm use <ruby version here>#<new gemset name here> --create
e.g.
.../rails_projects$ rvm use ruby-1.9.3-p194#myapp_gemset --create
2)
.../rails_projects$ gem install rails --version 3.2.14
Because the current gemset is the myapp gemset, that command installs the rails 3.2.14 gem into the myapp gemset.
3)
.../rails_projects$ rails new myapp
.../rails_projects$ cd myapp
The current gemset is still myapp_gemset.
4)
.../rails_projects/myapp$ rails -v
Rails 3.2.14
In case anyone was wondering what the heck the following two gemsets are all about:
gemsets for ruby-1.9.3-p194 (found in /Users/7stud/.rvm/gems/ruby-1.9.3-p194)
=> (default)
global
rvm creates those two gemsets for every ruby version you install. After you install a ruby version, if you don't create a gemset yourself for that ruby version, and you install a gem, then the gem goes into the (default) gemset. And, if you want all your gemsets to contain a certain gem, you can switch to the global gemset and install the gem there.
Update: -------
To maintain compatibility with other ruby version managers, you can specify the ruby version and gemset name for your project in a different file rather than in the Gemfile:
$ cd ~/rails_projects/myapp
~/rails_projects/myapp$ echo 2.0.0 > .ruby-version
~/rails_projects/myapp$ echo myapp_gemset > .ruby-gemset
You'll still get the same automatic ruby version and gemset switching when you cd into your project's directory. See the rvm docs here.
the path you found /Users/polonium/.rvm/rubies/ruby-2.0.0-p247/bin/rails is not proper path you would found in standard rvm installation while doing proper use of rvm, what you would see should be: /Users/polonium/.rvm/gems/ruby-2.0.0-p247/bin/rails
to get it working properly try this flow:
rvm use 2.0.0
rvm gemset empty
rvm use #rails3 --create
gem install rails -v "~>3.2"
rvm use #rails4 --create
gem install rails -v "~>4"
this way now you can switch between this two rails installations with:
rvm use 2.0.0#rails3
rails -v # rails 3.2...
rvm use 2.0.0#rails4
rails -v # rails 4.0...
you should do: gem install 'rails' -v '3.2.13'
You should use a clean gemset, if you are using rvm, you can try:
rvm gemset create
rvm gemset use
Now you have a clean gemset, it's time to install rails,
gem install rails -v '3.2.13'
and then create a rails app,
rails new app_name
"railties (4.0.0," is the problem you have. I guess it was installed by mistake?
Uninstall that version using, gem uninstall railties, and then picking the option with 4.0.0.
Now the command "rails -v" will return your expected version which is "3.2.14"
Make sure to check the global gemset by first making sure you are in the ruby version you intend to use
$ruby -v
Then switch to the global gemset (the global gemset applys to all of the gemsets so be sure to keep it clean and universal...or global, hence the name)
$rvm gemset use global
After that check the gem list for gems that can affect it like the "railties" gem that Harsha mentioned by typing
$gem list
Sometimes the global gemset can be populated by an accidental gem that will affect all other gemsets. If you find a misplaced gem you can uninstall it simply with
$gem uninstall examplegem
or for a specific version of that gem pass in the -v with the version in quotes
$gem uninstall examplegem -v"3.2.1"
And read 7stud's comment on creating and using RVM for changing between different gemsets.
You could add the version of Rails you want, with:
$ gem install rails --version 3.2.14
And then create an app with that version:
$ rails _3.2.14_ new myapp
Finally, you can check it out the content of the "Gemfile" to corroborate:
...
gem 'rails', '3.2.14'
...
This seems similar to a number of other questions posted, but is actually a different problem and with different (newer) versions (hence, the new question).
On a moderately fresh installation of Ubuntu 10.10 Maverik, I attempted to install Rails using RVM as I have done on other distributions before.
Here are roughly the steps I took:
Installed RVM: bash < <(curl -s https://rvm.beginrescueend.com/install/rvm)
Installed a bunch of dependencies using apt-get (curl, zlib-dev, g++, openssl, apache2-dev, libsqlite3-dev, libreadline5-dev)
Installed Ruby: rvm install 1.9.2; rvm use 1.9.2 --default
Installed Passenger (for use with Apache): rvm gem install passenger
Build the Apache Passenger mod: passenger-install-apache2-module
Note that I actually had an unrelated issue here: it failed a dependency check for openssl. I discovered that just executing ruby -e 'require "openssl"' resulted in an error. So, following the instructions I found at http://www.ruby-forum.com/topic/90083#175543 solved the issue in src/ruby-1.9.2-p290/ext/openssl/ and then the passenger module installation succeeded.
Decided to create a gemset for rails3 as I plan to test 3.1 later: rvm use --create 1.9.2#rails3
Installed rails: rvm gem install rails
That all appeared to go without a hitch (save for a couple warnings from the ri and RDoc generation). However, now if I type rails (after new shell login), I just get:
The program 'rails' is currently not installed. You can install it by typing:
apt-get install rails
However, my PATH is:
/usr/local/rvm/gems/ruby-1.9.2-p290#rails3/bin:/usr/local/rvm/gems/ruby-1.9.2-p290#global/bin:/usr/local/rvm/rubies/ruby-1.9.2-p290/bin:/usr/local/bin:/usr/local/sbin:/usr/sbin:/usr/bin:/sbin:/bin
and rvm info says:
ruby-1.9.2-p290#rails3:
system:
uname: "Linux domU-12-31-39-15-36-1A 2.6.35-24-virtual #42-Ubuntu SMP Thu Dec 2 05:01:52 UTC 2010 i686 GNU/Linux"
bash: "/bin/bash => GNU bash, version 4.1.5(1)-release (i686-pc-linux-gnu)"
zsh: " => not installed"
rvm:
version: "rvm 1.6.32 by Wayne E. Seguin (wayneeseguin#gmail.com) [https://rvm.beginrescueend.com/]"
ruby:
interpreter: "ruby"
version: "1.9.2p290"
date: "2011-07-09"
platform: "i686-linux"
patchlevel: "2011-07-09 revision 32553"
full_version: "ruby 1.9.2p290 (2011-07-09 revision 32553) [i686-linux]"
homes:
gem: "/usr/local/rvm/gems/ruby-1.9.2-p290#rails3"
ruby: "/usr/local/rvm/rubies/ruby-1.9.2-p290"
binaries:
ruby: "/usr/local/rvm/rubies/ruby-1.9.2-p290/bin/ruby"
irb: "/usr/local/rvm/rubies/ruby-1.9.2-p290/bin/irb"
gem: "/usr/local/rvm/rubies/ruby-1.9.2-p290/bin/gem"
rake: "/usr/local/rvm/gems/ruby-1.9.2-p290#global/bin/rake"
environment:
PATH: "/usr/local/rvm/gems/ruby-1.9.2-p290#rails3/bin:/usr/local/rvm/gems/ruby-1.9.2-p290#global/bin:/usr/local/rvm/rubies/ruby-1.9.2-p290/bin:/usr/local/bin:/usr/local/sbin:/usr/sbin:/usr/bin:/sbin:/bin"
GEM_HOME: "/usr/local/rvm/gems/ruby-1.9.2-p290#rails3"
GEM_PATH: "/usr/local/rvm/gems/ruby-1.9.2-p290#rails3:/usr/local/rvm/gems/ruby-1.9.2-p290#global"
MY_RUBY_HOME: "/usr/local/rvm/rubies/ruby-1.9.2-p290"
IRBRC: "/usr/local/rvm/rubies/ruby-1.9.2-p290/.irbrc"
RUBYOPT: ""
gemset: "rails3"
So, my question for some Rails/Ruby/Ubuntu Gurus is: what is going on here? If I just need to add something to my PATH to allow bash to find rails, I can't figure out what.
The result of executing find /usr/local/rvm -name rails is:
/usr/local/rvm/src/rvm/scripts/extras/rails
/usr/local/rvm/scripts/extras/rails
/usr/local/rvm/gems/ruby-1.9.2-p290/gems/passenger-3.0.7/test/ruby/shared/rails
/usr/local/rvm/gems/ruby-1.9.2-p290/gems/passenger-3.0.7/test/stub/rails_apps/3.0/empty/script/rails
/usr/local/rvm/gems/ruby-1.9.2-p290/gems/rails-3.0.9/bin/rails
/usr/local/rvm/gems/ruby-1.9.2-p290/gems/activerecord-3.0.9/lib/rails
/usr/local/rvm/gems/ruby-1.9.2-p290/gems/railties-3.0.9/lib/rails
/usr/local/rvm/gems/ruby-1.9.2-p290/gems/railties-3.0.9/lib/rails/generators/rails
/usr/local/rvm/gems/ruby-1.9.2-p290/gems/railties-3.0.9/lib/rails/generators/rails/app/templates/script/rails
/usr/local/rvm/gems/ruby-1.9.2-p290/gems/actionmailer-3.0.9/lib/rails
/usr/local/rvm/gems/ruby-1.9.2-p290/bin/rails
/usr/local/rvm/gems/ruby-1.9.2-p290/doc/activerecord-3.0.9/rdoc/lib/rails
/usr/local/rvm/gems/ruby-1.9.2-p290/doc/actionmailer-3.0.9/rdoc/lib/rails
But attempting to directly execute /usr/local/rvm/gems/ruby-1.9.2-p290/bin/rails just gives:
/usr/local/rvm/rubies/ruby-1.9.2-p290/lib/ruby/site_ruby/1.9.1/rubygems/dependency.rb:247:in `to_specs': Could not find rails (>= 0) amongst [rake-0.8.7] (Gem::LoadError)
from /usr/local/rvm/rubies/ruby-1.9.2-p290/lib/ruby/site_ruby/1.9.1/rubygems/dependency.rb:256:in `to_spec'
from /usr/local/rvm/rubies/ruby-1.9.2-p290/lib/ruby/site_ruby/1.9.1/rubygems.rb:1195:in `gem'
from /usr/local/rvm/gems/ruby-1.9.2-p290/bin/rails:18:in `<main>'
(and I have no idea if that is even a reasonable thing to try)
Just in case I've not provided enough information :) - rvm gem list gives:
*** LOCAL GEMS ***
abstract (1.0.0)
actionmailer (3.0.9)
actionpack (3.0.9)
activemodel (3.0.9)
activerecord (3.0.9)
activeresource (3.0.9)
activesupport (3.0.9)
arel (2.0.10)
builder (2.1.2)
bundler (1.0.15)
daemon_controller (0.2.6)
erubis (2.6.6)
fastthread (1.0.7)
i18n (0.5.0)
mail (2.2.19)
mime-types (1.16)
passenger (3.0.7)
polyglot (0.3.2)
rack (1.3.2, 1.2.3)
rack-mount (0.6.14)
rack-test (0.5.7)
rails (3.0.9)
railties (3.0.9)
rake (0.8.7 ruby)
rdoc (3.9.1)
sqlite3 (1.3.4)
sqlite3-ruby (1.3.3)
thor (0.14.6)
treetop (1.4.10)
tzinfo (0.3.29)
Any help or pointers greatly appreciated. Meanwhile I'll continue to bang my head on it.
use gem install rails instead of rvm gem install rails
Running RoR under Cygwin, I have installed sqlite3 and sqlite3-ruby gems but they aren't being found. In development.log I get:
Status: 500 Internal Server Error
RubyGem version error: sqlite3(1.3.3 not >= 0)
And if I try rake db:migrate I get:
$ rake db:migrate
(in /home/projects/sample)
rake aborted!
RubyGem version error: sqlite3(1.3.3 not >= 0)
I have installed the gems:
$ gem list
*** LOCAL GEMS ***
actionmailer (2.3.4)
actionpack (2.3.4)
activerecord (2.3.4)
activeresource (2.3.4)
activesupport (2.3.4)
bundler (1.0.10)
cgi_multipart_eof_fix (2.5.0)
daemons (1.1.0)
envy (0.0.1)
fastthread (1.0.1 i386-mswin32)
gem_plugin (0.2.3)
mongrel (1.1.5 x86-mswin32-60)
mysql (2.8.1 x86-mswin32)
rack (1.2.1, 1.0.0)
rails (2.3.4)
rake (0.8.7)
rdoc (3.5.3)
rubysspi (1.3.1)
sqlite3 (1.3.3 x86-mswin32-60)
I have tried installing and uninstalling the sqlite3-ruby.gem too but that doesn't help.
Sqlite3 works fine by itself:
$ sqlite3
SQLite version 3.7.3
Enter ".help" for instructions
Enter SQL statements terminated with a ";"
sqlite>
I have a feeling your are making use of sqllite3-ruby gems for Windows,
Do note, you would have to use OS/environment specific ruby gems for them to work for you, if I am correct to the best of my knowledge. In your case Cygwin seems to be a Linux type environment, thus why don't you try to install gems suiting the Linux environment and check if this does the trick for you..
Also, Have you installed the sqlite3 DB and configured your rails_app_name/config/database.yml file. You need to in this file specify details like username, password etc.
I make use of MySQL DB and related gems. You seem to have that installed too.. if sqlite3 DB doesn't work for you just give a try with MySQL DB. You need to installed this DB also and again fill in the required details to configure your DB with the rails app in your database.yml.
Hope this helps!
Good Luck!
I ended up downloading the SQLite3 headers (sqlite3.h and sqlite3ext.h) and placing them in the directory then
$ gem install sqlite3-ruby-1.2.3-mswin32.gem -- --curdir
You need the first empty -- option qualifiers to signify that the second set is for the specific .gem file, not the gem command.
I installed RoR on ubuntu 10, using all kinds so method i could find on internet, either "sudo apt-get" or "sudo gem install", by running 'gem list', i can see they are all the latest version:
*** LOCAL GEMS ***
actionmailer (2.3.8)
actionpack (2.3.8)
activerecord (2.3.8)
activeresource (2.3.8)
activesupport (2.3.8)
fastthread (1.0.7)
mysql (2.8.1)
passenger (2.2.15)
rack (1.1.0)
rails (2.3.8)
rake (0.8.7)
rubygems-update (1.3.7)
but when i created a ror application by running 'rails samplecode', then run 'script/about', it always showed:
About your application's environment
Ruby version 1.8.7 (x86_64-linux)
RubyGems version 1.3.5
Rails version 2.2.3
Active Record version 2.2.3
Action Pack version 2.2.3
Active Resource version 2.2.3
Action Mailer version 2.2.3
Active Support version 2.2.3
Edge Rails revision unknown
Application root /home/kc/Projects/samplecode
Environment development
Database adapter mysql
why these 2 settings are different? how can i force the application to use the local gems (latest version)? Thanks.
Ubuntu (aptitude/apt-get) installs gems in /var/lib/gems/1.8. When you run gem install manually, you're likely installing them in /usr/lib/ruby/gems/1.8.
Run "gem env" and look at what the gem path(s) is/are.
If you set the GEM_HOME environment variable (GEM_HOME=/usr/lib/ruby/gems/1.8), you can have you application look there.
Alternately, you can install the gems you want (including rails) in your application's vendor directory by putting config.gem lines in environment.rb and running rake gems:unpack:dependencies.
Uninstall the apt-get version of Rails:
sudo apt-get remove rails
And then install Rails again using gem:
sudo gem install rails
I am trying to deploy a jruby on rails application.
Right now I am running mongrel + Apache2 using reverse proxy from mod_proxy. However, because mongrel_jcluster does not work for the latest versions of jruby, I am only able to run one mongrel server, and cant take advantage of load balancing from apache2.
Is there any way other way to create a mongrel cluster? I'd really prefer mongrel cluster + apache2 to a java servlet type system.
I've tried jetty using the instructions here: http://jetty-rails.rubyforge.org/
but I get the following error when starting up the jetty server, even though I've checked my activerecord-jdbcmysql-adapter gem version under jruby and its there and version 0.9.7
DEPRECATION WARNING: require "activesupport" is deprecated and will be removed in Rails 3. Use require "active_support" instead. (called from /home/andrew/.gem/jruby/1.8/gems/activesupport-2.3.8/lib/activesupport.rb:2)
2010-07-20 17:00:46.820::INFO: Logging to STDERR via org.mortbay.log.StdErrLog
Starting server 3000
2010-07-20 17:00:47.134::INFO: jetty-6.1.14
2010-07-20 17:01:03.511:/:INFO: Info: using runtime pool timeout of 30 seconds
2010-07-20 17:01:03.511:/:INFO: Info: received min runtimes = 1
2010-07-20 17:01:03.511:/:INFO: Info: received max runtimes = 5
Loading parser from serialized file lib/stanford-parser/englishPCFG.ser.gz ... done [4.6 sec].
2010-07-20 17:01:14.341:/:WARN: Error: unable to initialize application
org.jruby.rack.RackInitializationException: Please install the jdbcmysql adapter: `gem install activerecord-jdbcmysql-adapter` (no such file to load -- active_record/connection_adapters/jdbcmysql_adapter)
any suggestions would be appreciated, thanks!
EDIT: I don't know if this makes a difference, but I am able to tell that before it crashes, jetty_rails successfully loads a global variable declared in the environment.rb
EDIT: here is my full gem list from jruby -S gem list --local
*** LOCAL GEMS ***
actionmailer (2.3.8)
actionpack (2.3.8)
activerecord (2.3.8)
activerecord-jdbc-adapter (0.9.7)
activerecord-jdbcmysql-adapter (0.9.7)
activeresource (2.3.8)
activesupport (2.3.8)
builder (2.1.2)
gem_plugin (0.2.3)
jdbc-mysql (5.0.4)
jetty-rails (0.8.1)
jruby-jars (1.5.1)
jruby-openssl (0.7)
jruby-rack (1.0.1)
mizuno (0.3.6)
mongrel (1.1.5)
rack (1.1.0)
rails (2.3.8)
rake (0.8.7)
rubyzip (0.9.4)
sources (0.0.1)
warbler (1.1.0)
Maybe you're switching between multiple ruby interpreters (via RVM or manually). Make sure
that you have 2.3.8 gems for rails and it's dependencies by running "gem list" using Jruby.
If you don't have the gems under Jruby, run "gem install -v=2.3.8 rails".
You could pack the rails gems inside the project tree by running "rake rails:freeze:gems".
The only possible answer that I know is that you have two ruby interpreters on the system, and the one being picked up by the jetty environment is missing gems. Does ruby -v give you a different answer than jruby -v?
That being said, is there a reason why you don't want to use warble and deploy a war to Jetty or Tomcat? I find that works well.