Rails mysql:原因:不安全使用相对rpath

时间:2015-10-04 17:24:46

标签: mysql ruby-on-rails homebrew mysql2

我安装了mysql和rails,升级到最新的OSX版本,现在尝试在我的dev文件夹中运行rails-server时出现此错误。

mt:project1.dev mt$ mysql.server start
Starting MySQL
 SUCCESS!
mt:project1.dev mt$ mysql -v
Welcome to the MySQL monitor.  Commands end with ; or \g.
Your MySQL connection id is 4
Server version: 5.6.26 Homebrew

Copyright (c) 2000, 2015, Oracle and/or its affiliates. All rights reserved.

Oracle is a registered trademark of Oracle Corporation and/or its
affiliates. Other names may be trademarks of their respective
owners.

Reading history-file /Users/mt/.mysql_history
Type 'help;' or '\h' for help. Type '\c' to clear the current input statement.

mysql> Ctrl-C -- exit!
Writing history-file /Users/mt/.mysql_history
Aborted
mt:project1.dev mt$ rails s
/Library/Ruby/Gems/2.0.0/gems/mysql2-0.3.18/lib/mysql2.rb:31:in `require': dlopen(/Library/Ruby/Gems/2.0.0/gems/mysql2-0.3.18/lib/mysql2/mysql2.bundle, 9): Library not loaded: libmysqlclient.18.dylib (LoadError)
  Referenced from: /Library/Ruby/Gems/2.0.0/gems/mysql2-0.3.18/lib/mysql2/mysql2.bundle
  Reason: unsafe use of relative rpath libmysqlclient.18.dylib in /Library/Ruby/Gems/2.0.0/gems/mysql2-0.3.18/lib/mysql2/mysql2.bundle with restricted binary - /Library/Ruby/Gems/2.0.0/gems/mysql2-0.3.18/lib/mysql2/mysql2.bundle
    from /Library/Ruby/Gems/2.0.0/gems/mysql2-0.3.18/lib/mysql2.rb:31:in `<top (required)>'
    from /Library/Ruby/Gems/2.0.0/gems/bundler-1.10.6/lib/bundler/runtime.rb:76:in `require'
    from /Library/Ruby/Gems/2.0.0/gems/bundler-1.10.6/lib/bundler/runtime.rb:76:in `block (2 levels) in require'
    from /Library/Ruby/Gems/2.0.0/gems/bundler-1.10.6/lib/bundler/runtime.rb:72:in `each'
    from /Library/Ruby/Gems/2.0.0/gems/bundler-1.10.6/lib/bundler/runtime.rb:72:in `block in require'
    from /Library/Ruby/Gems/2.0.0/gems/bundler-1.10.6/lib/bundler/runtime.rb:61:in `each'
    from /Library/Ruby/Gems/2.0.0/gems/bundler-1.10.6/lib/bundler/runtime.rb:61:in `require'
    from /Library/Ruby/Gems/2.0.0/gems/bundler-1.10.6/lib/bundler.rb:134:in `require'
    from /Users/mt/Dropbox/01. fm-public/04. Dev/htdocs/project1.dev/config/application.rb:7:in `<top (required)>'
    from /Library/Ruby/Gems/2.0.0/gems/railties-4.0.1/lib/rails/commands.rb:74:in `require'
    from /Library/Ruby/Gems/2.0.0/gems/railties-4.0.1/lib/rails/commands.rb:74:in `block in <top (required)>'
    from /Library/Ruby/Gems/2.0.0/gems/railties-4.0.1/lib/rails/commands.rb:71:in `tap'
    from /Library/Ruby/Gems/2.0.0/gems/railties-4.0.1/lib/rails/commands.rb:71:in `<top (required)>'
    from bin/rails:4:in `require'
    from bin/rails:4:in `<main>'
mt:project1.dev mt$

如您所见,mysql正在运行,我安装了最新版本。但是,由于我不是命令行专家,我真的不理解给出的错误信息以及我现在可以做的事情。

此致 马特

0 个答案:

没有答案