我在 Linux 上运行 rails 版本 3.2.8 和 ruby 版本 1.9.3-p286
user1@company.com [~/rails_apps/myapp]# rails -v
Rails 3.2.8
user1@company.com [~/rails_apps/myapp]# ruby -v
ruby 1.9.3p286 (2012-10-12 revision 37165) [x86_64-linux]
user1@company.com [~/rails_apps/myapp]#
我可以生成迁移,但无法运行它。我不断收到以下错误消息
user1@company.com [~/rails_apps/myapp]# rake db:migrate
/home3/user1/.rvm/rubies/ruby-1.9.3-p286/lib/ruby/1.9.1/yaml.rb:56:in `<top (required)>':
It seems your ruby installation is missing psych (for YAML output).
To eliminate this warning, please install libyaml and reinstall your ruby.
/home3/user1/ruby/gems/gems/json-1.7.5/lib/json/common.rb:67: [BUG] unknown type 0x22 (0xc given)
ruby 1.9.3p286 (2012-10-12 revision 37165) [x86_64-linux]
<snip>
然后是很多调试信息
[NOTE]
You may have encountered a bug in the Ruby interpreter or extension libraries.
Bug reports are welcome.
For details: http://www.ruby-lang.org/bugreport.html
Aborted
user1@company.com [~/rails_apps/myapp]#
我安装了 libyaml
rvm pkg install libyaml
然后重新安装红宝石
rvm reinstall ruby-1.9.3-p286
但这并没有帮助。
为什么我不断收到此错误消息的任何其他想法?
谢谢。