Первоначально я разместил это в Super User, но теперь думаю, что это должно быть здесь ...
Я пытаюсь перенести свое веб-приложение RoR на VPS DreamHost.Я обновил VPS -> Ruby 1.9.2 с 1.8.7 и использую Rails 3.0.1 и gem mysql2 (0.2.6).Я получаю следующую ошибку при попытке запустить mongrel:
/ usr / bin / ruby1.8: ошибка поиска символа: /home/USERNAME/.gems/gems/mysql2-0.2.6/lib/mysql2/mysql2.so: неопределенный символ: rb_intern2
... поэтому я попытался использовать вместо этого gem mysql (2.8.1) и получил следующую ошибку:
неверный тип аргумента Mysql (ожидаемая структура) (TypeError)
0 /home/USERNAME/.gems/gems/activerecord-3.0.1/lib/active_record/connection_adapters/mysql_adapter.rb 600 в real_connect'<br>
1 /home/USERNAME/.gems/gems/activerecord-3.0.1/lib/active_record/connection_adapters/mysql_adapter.rb 600 in
connect '
2 /home/USERNAME/.gems/gems/activerecord-3.0.1/lib/active_record/connection_adapters/mysql_adapter.rb 164 в initialize'<br>
3 /home/USERNAME/.gems/gems/activerecord-3.0.1/lib/active_record/connection_adapters/mysql_adapter.rb 36 in
new'
4 /home/USERNAME/.gems/gems/activerecord-3.0.1/lib/active_record/connection_adapters/mysql_adapter.rb 36 в mysql_connection'<br>
5 /home/USERNAME/.gems/gems/activerecord-3.0.1/lib/active_record/connection_adapters/abstract/connection_pool.rb 230 in
отправить '
6 /home/USERNAME/.gems/gems/activerecord-3.0.1/lib/active_record/connection_adapters/abstract/connection_pool.rb 230 in new_connection'<br>
7 /home/USERNAME/.gems/gems/activerecord-3.0.1/lib/active_record/connection_adapters/abstract/connection_pool.rb 238 in
checkout_new_connection '
8 /home/USERNAME/.gems/gems/activerecord-3.0.1/lib/active_record/connection_adapters / abstract / connection_pool.rb 194 в checkout'<br>
9 /home/USERNAME/.gems/gems/activerecord-3.0.1/lib/active_record/connection_adapters/abstract/connection_pool.rb 190 in
loop '
10 /home/USERNAME/.gems/gems/activerecord-3.0.1/lib/active_record/connection_adapters/abstract/connection_pool.rb 190 в checkout'<br>
11 /usr/lib/ruby/1.8/monitor.rb 242 in
синхронизировать '
12 /home/USERNAME/.gems/gems/activerecord-3.0.1/lib/active_record/connection_adapters/abstract/connection_pool.rb 189 в checkout'<br>
13 /home/USERNAME/.gems/gems/activerecord-3.0.1/lib/active_record/connection_adapters/abstract/connection_pool.rb 96 in
подключении'
14 / home / USERNAME /.gems / gems / activerecord-3.0.1 / lib / active_record / connection_adapters / abstract / connection_pool.rb 318 в retrieve_connection'<br>
15 /home/USERNAME/.gems/gems/activerecord-3.0.1/lib/active_record/connection_adapters/abstract/connection_specification.rb 97 in
retrieve_connection '
16 /home/USERNAME/.gems/gems/activerecord-3.0.1/lib/active_record / connection_adapters / abstract / connection_specification.rb 89 в connection'<br>
17 /home/USERNAME/.gems/gems/activerecord-3.0.1/lib/active_record/associations.rb 1804 in
create_has_and_belongs_to_many_reflection '
18 /home/USERNAME/.gems/gems/activerecord-3.0.1/lib/active_record/associations.rb 1411 в has_and_belongs_to_many'<br>
19 /home/USERNAME/.gems/gems/activerecord-3.0.1/lib/active_record/autosave_association.rb 137 in
1033 * 20 /home/USERNAME/portfoliofinearts.ca/farr/app/models/project.rb 3
21 /home/USERNAME/.gems/gems/activesupport-3.0.1/lib/active_support/dependencies.rb239 в require'<br>
22 /home/USERNAME/.gems/gems/activesupport-3.0.1/lib/active_support/dependencies.rb 239 in
рequire '
23 /home/USERNAME/.gems/gems/activesupport-3.0.1/lib/active_support/dependencies.rb 227 в load_dependency'<br>
24 /home/USERNAME/.gems/gems/activesupport-3.0.1/lib/active_support/dependencies.rb 239 in
require'
25 /home/USERNAME/.gems/gems/activesupport-3.0.1 / lib / active_support / dependencies.rb 346 в require_or_load'<br>
26 /home/USERNAME/.gems/gems/activesupport-3.0.1/lib/active_support/dependencies.rb 300 in
зависимость_on '
27 /home/USERNAME/.gems/gems/activesupport-3.0.1/lib/active_support/dependencies.rb 216 в require_dependency'<br>
28 /home/USERNAME/.gems/gems/railties-3.0.1/lib/rails/engine.rb 138 in
eager_load! '
29 /home/USERNAME/.gems/gems/railties-3.0.1/lib/rails/engine.rb 137 в each'<br>
30 /home/USERNAME/.gems/gems/railties-3.0.1/lib/rails/engine.rb 137 in
eager_load!'
31 / home / USERNAME /.gems / gems / railties-3.0.1 / lib / rails / engine.rb 135 в each'<br>
32 /home/USERNAME/.gems/gems/railties-3.0.1/lib/rails/engine.rb 135 in
eager_load! '
33 /home/USERNAME/.gems/gems/railties-3.0.1/lib/rails/application.rb 108 в eager_load!'<br>
34 /home/USERNAME/.gems/gems/railties-3.0.1/lib/rails/application/finisher.rb 41<br>
35 /home/USERNAME/.gems/gems/railties-3.0.1/lib/rails/initializable.rb 25 in
instance_exec '
36 /home/USERNAME/.gems/gems/railties-3.0.1/lib/rails/initializable.rb 25 в run'<br>
37 /home/USERNAME/.gems/gems/railties-3.0.1/lib/rails/initializable.rb 50 in
run_initializers'
38 / home /ИМЯ ПОЛЬЗОВАТЕЛЯ / .gems / gems / railties-3.0.1 / lib / rails / initializable.rb 49 в each'<br>
39 /home/USERNAME/.gems/gems/railties-3.0.1/lib/rails/initializable.rb 49 in
run_initializers '
40 /home/USERNAME/.gems/gems/railties-3.0.1/lib/rails/application.rb 134 in initialize!'<br>
41 /home/USERNAME/.gems/gems/railties-3.0.1/lib/rails/application.rb 77 in
send '
42 /home/USERNAME/.gems/gems/railties-3.0.1 / lib / rails / application.rb 77 в method_missing'<br>
43 /home/USERNAME/mydomain.com/test_app/config/environment.rb 10<br>
44 /usr/lib/ruby/1.8/rubygems/custom_require.rb 31 in
gem_original_require '
45 /usr/lib/ruby/1.8/rubygems/custom_require.rb 31 в require'<br>
46 config.ru 3<br>
47 /usr/lib/ruby/gems/1.8/gems/rack-1.2.1/lib/rack/builder.rb 46 in
instance_eval'
48 / usr / lib/ruby/gems/1.8/gems/rack-1.2.1/lib/rack/builder.rb 46 в initialize'<br>
49 config.ru 1 in
new '
50 config.ru 1
Я бы предпочелиспользовать mysql2, так что это предпочтительное решение, которое я ищу, но я, безусловно, буду признателен за любую проблему.
Я не сталкиваюсь с такими проблемами в моей среде разработки (то есть windows)