小编Bac*_*uty的帖子

使用jemalloc安装ruby时出错

我在ubuntu 12.04.5 LTS上尝试用jemalloc安装ruby.jemalloc已成功安装(https://blog.scalingo.com/2017/05/02/improve-ruby-application-memory-jemalloc.html),但在安装ruby 2.3.4时,它出现了以下错误.

>rvm install 2.3.4 -C --with-jemalloc

Warning, new version of rvm available '1.29.1', you are using older version '1.27.0'.
You can disable this warning with:    echo rvm_autoupdate_flag=0 >> ~/.rvmrc
You can enable  auto-update  with:    echo rvm_autoupdate_flag=2 >> ~/.rvmrc
ruby-2.3.4 - #removing src/ruby-2.3.4..
Checking requirements for ubuntu.
Requirements installation successful.
Installing Ruby from source to: /home/deploy/.rvm/rubies/ruby-2.3.4, this may take a while depending on your cpu(s)...
ruby-2.3.4 - #downloading ruby-2.3.4, this may take a while depending on …
Run Code Online (Sandbox Code Playgroud)

ruby rvm jemalloc

7
推荐指数
2
解决办法
1466
查看次数

rails服务器参数错误

devise_install成功安装设备后,重新启动服务器时,我收到以下错误.请帮我.我已经解决了很多问题而且没有得到正确答复.

错误:

bfmt048@bfmt048-System-Product-Name:~/demo$ rails s
=> Booting WEBrick
=> Rails 4.0.0 application starting in development on  zero.zero.zero.zero:threethousand
=> Run `rails server -h` for more startup options
=> Ctrl-C to shutdown server
Exiting
/home/bfmt048/.rbenv/versions/2.0.0-rc2/lib/ruby/gems/2.0.0/gems/activemodel-4.0.0/lib/active_model/validations/format.rb:46:in `check_options_validity': The provided regular expression is using multiline anchors (^ or $), which may present a security risk. Did you mean to use \A and \z, or forgot to add the :multiline => true option? (ArgumentError)
    from /home/bfmt048/.rbenv/versions/2.0.0-rc2/lib/ruby/gems/2.0.0/gems/activemodel-4.0.0/lib/active_model/validations/format.rb:20:in `check_validity!'
    from /home/bfmt048/.rbenv/versions/2.0.0-rc2/lib/ruby/gems/2.0.0/gems/activemodel-4.0.0/lib/active_model/validator.rb:143:in `initialize'
    from /home/bfmt048/.rbenv/versions/2.0.0-rc2/lib/ruby/gems/2.0.0/gems/activemodel-4.0.0/lib/active_model/validations/with.rb:87:in `new'
    from …
Run Code Online (Sandbox Code Playgroud)

ruby-on-rails devise

5
推荐指数
1
解决办法
2079
查看次数

JRuby + [error] [client xxxx.xx.xxx.xx]脚本头的过早结束:xxxx,referer:

我在生产中使用以下配置

  • Jruby:1.7.13
  • 的Apache2
  • passenger4.0.48

应用程序运行正常.当我尝试上传图像时抛出apache错误

/var/log/apache2/error.log

[error] [client xxxx.xx.xxx.xx] Premature end of script headers: xxxx , referer: 
Run Code Online (Sandbox Code Playgroud)

mongoid-paperclip gem已用于上传文件.甚至,我已经尝试了这里描述的步骤,但无法解决它.

它的开发工作很好.但是在生产上遇到上述问题.

请帮帮我!提前致谢 :)

ruby-on-rails jruby apache2 production-environment

1
推荐指数
1
解决办法
196
查看次数