passenger

How to avoid nginx “upstream sent too big header” errors?

会有一股神秘感。 提交于 2019-12-31 08:45:27
问题 I'm running nginx, Phusion Passenger and Rails. I am running up against the following error: upstream sent too big header while reading response header from upstream, client: 87.194.2.18, server: xyz.com, request: "POST /user_session HTTP/1.1", upstream: "passenger://unix:/tmp/passenger.3322/master/helper_server.sock It is occuring on the callback from an authentication call to Facebook Connect. After googling, and trying to change nginx settings including proxy_buffer_size and large_client

How to avoid nginx “upstream sent too big header” errors?

删除回忆录丶 提交于 2019-12-31 08:45:02
问题 I'm running nginx, Phusion Passenger and Rails. I am running up against the following error: upstream sent too big header while reading response header from upstream, client: 87.194.2.18, server: xyz.com, request: "POST /user_session HTTP/1.1", upstream: "passenger://unix:/tmp/passenger.3322/master/helper_server.sock It is occuring on the callback from an authentication call to Facebook Connect. After googling, and trying to change nginx settings including proxy_buffer_size and large_client

User to start Passenger (with Nginx)

可紊 提交于 2019-12-30 04:40:28
问题 I have Nginx with Passenger. In nginx.conf I have line: user pass users; and Nginx process works on 'pass' user, but Passenger* processes work on 'nobody' user. I can run Passenger standalone: sudo passanger start -e production -p 80 --user=pass How can I run Passenger with Nginx with my custom user? 回答1: Put the following into your nginx.conf in the http block: passenger_default_user custom_username; passenger_default_group custom_group; You can find more configuration options here: http:/

Passenger hosted Rails app *painfully* slow, but the server is a beast

怎甘沉沦 提交于 2019-12-29 11:34:10
问题 I have been working to deploy a relatively large Rails app (Rails 2.3.5) and recently doing some load testing we discovered that the throughput for the site is way below the expected level of traffic. We were running on a standard 32bit server, 3GB of RAM with Centos, and we were running Ruby Enterprise Edition (latest build), Passenger (Latest build) and Nginx (Latest build) - when there is only one or two users the site runs fine (as you would expect) however when we try to ramp up the load

ActionView::Template::Error (incompatible character encodings: UTF-8 and ASCII-8BIT)

时间秒杀一切 提交于 2019-12-28 05:52:06
问题 I am using Ruby 1.9.2, Rails 3.0.4/3.0.5 and Phusion Passenger 3.0.3/3.0.4. My templates are written in HAML and I am using the MySQL2 gem. I have a controller action that when passed a parameter that has a special character, like an umlaut, gives me the following error: ActionView::Template::Error (incompatible character encodings: UTF-8 and ASCII-8BIT) The error points to the first line of my HAML template, which has the following code on it: <!DOCTYPE html> My understanding is that this is

ActionView::Template::Error (incompatible character encodings: UTF-8 and ASCII-8BIT)

安稳与你 提交于 2019-12-28 05:52:03
问题 I am using Ruby 1.9.2, Rails 3.0.4/3.0.5 and Phusion Passenger 3.0.3/3.0.4. My templates are written in HAML and I am using the MySQL2 gem. I have a controller action that when passed a parameter that has a special character, like an umlaut, gives me the following error: ActionView::Template::Error (incompatible character encodings: UTF-8 and ASCII-8BIT) The error points to the first line of my HAML template, which has the following code on it: <!DOCTYPE html> My understanding is that this is

cannot load such file — bundler/setup (LoadError)

ⅰ亾dé卋堺 提交于 2019-12-27 12:13:11
问题 I'm setting Rails 4 application with Ruby 2.0, but I'm getting "Web application could not be started" and get this trace: cannot load such file -- bundler/setup (LoadError) /usr/local/lib/ruby/site_ruby/2.0.0/rubygems/core_ext/kernel_require.rb:53:in `require' /usr/local/lib/ruby/site_ruby/2.0.0/rubygems/core_ext/kernel_require.rb:53:in `require' /usr/lib/ruby/gems/1.8/gems/passenger-4.0.19/lib/phusion_passenger/loader_shared_helpers.rb:212:in `run_load_path_setup_code' /usr/lib/ruby/gems/1.8

How to debug requests taking too much time to complete?

◇◆丶佛笑我妖孽 提交于 2019-12-25 07:59:52
问题 XHR requests randomly take too much time to complete. And I fail to find a place where this is happening. If there is one. When I enable profiler around suspicious ruby code blocks, the hold-up is happening elsewhere. I couldn't reproduce it with webrick however. Any ideas? UPD It's a rails application using sequel to connect to postgresql. Here are more details on the issue I'm facing. 回答1: Here's what I did: 1) added the following code to the beginning of /usr/lib/ruby/vendor_ruby/phusion

Rails server return “404 Not Found” after user login

五迷三道 提交于 2019-12-25 07:29:39
问题 Our rails 3.2.12 app is running on ubuntu 12.04 passenger/nginx server. It has been verified that both nginx and passenger are running fine. However after user login, there is 404 Not Found page thrown out. The the page is redirected to session instead of user menu . Here is the production log for a login (the app is running fine with the rails server locally): Started GET "/nbhy" for 73.15.38.185 at 2013-05-04 20:50:55 +0000 Processing by Authentify::SessionsController#new as HTML Rendered

404 Not found error in deploying a Rails app with Apache2 and Passenger

浪尽此生 提交于 2019-12-25 03:27:07
问题 probably a matter of simple adjustment but I have no idea whats going wrong. I want a host to be a server for my rails application, which was deployed using Capistrano 3.2.1. This is a Unix machine running Apache/2.2.15, named eng-perf (corporate internal machine, so no www.address.com syntax at the moment). I followed this guide and the entire installation process went without any trouble. I edited the configuration file so that it looks like this: <VirtualHost *:80> ServerName eng-perf # !!