我尝试在我的ubuntu服务器上部署我的rails 4应用程序,如果我运行rake db:migrate命令我收到此错误
rake aborted!
ArgumentError: invalid byte sequence in UTF-8
我的环境:
Rails 4.1.6 ruby 2.1.2p95(2014-05-08修订版45877)[x86_64-linux]
这里的痕迹
/usr/local/rvm/gems/ruby-2.1.4/gems/rake-10.3.2/lib/rake/file_list.rb:395:in `glob'
/usr/local/rvm/gems/ruby-2.1.4/gems/rake-10.3.2/lib/rake/file_list.rb:395:in `glob'
/usr/local/rvm/gems/ruby-2.1.4/gems/rake-10.3.2/lib/rake/application.rb:258:in `block in have_rakefile'
/usr/local/rvm/gems/ruby-2.1.4/gems/rake-10.3.2/lib/rake/application.rb:256:in `each'
/usr/local/rvm/gems/ruby-2.1.4/gems/rake-10.3.2/lib/rake/application.rb:256:in `have_rakefile'
/usr/local/rvm/gems/ruby-2.1.4/gems/rake-10.3.2/lib/rake/application.rb:657:in `find_rakefile_location'
/usr/local/rvm/gems/ruby-2.1.4/gems/rake-10.3.2/lib/rake/application.rb:673:in `raw_load_rakefile'
/usr/local/rvm/gems/ruby-2.1.4/gems/rake-10.3.2/lib/rake/application.rb:94:in `block in load_rakefile'
/usr/local/rvm/gems/ruby-2.1.4/gems/rake-10.3.2/lib/rake/application.rb:176:in `standard_exception_handling'
/usr/local/rvm/gems/ruby-2.1.4/gems/rake-10.3.2/lib/rake/application.rb:93:in `load_rakefile'
/usr/local/rvm/gems/ruby-2.1.4/gems/rake-10.3.2/lib/rake/application.rb:77:in `block in run'
/usr/local/rvm/gems/ruby-2.1.4/gems/rake-10.3.2/lib/rake/application.rb:176:in `standard_exception_handling'
/usr/local/rvm/gems/ruby-2.1.4/gems/rake-10.3.2/lib/rake/application.rb:75:in `run'
/root/.rbenv/versions/2.1.2/bin/rake:33:in `<main>'
有什么想法吗?
在我的本地机器上一切正常......
答案 0 :(得分:0)
出于好奇,这里使用的数据存储是什么?是否有可能只是破坏数据库并偶然重新开始?如果是这样,你可以用:
rake db:drop db:create db:migrate