Premature end of script headers: media ( Issue related to :rails app deployment+passenger+ubuntu+apache)

百般思念 提交于 2019-12-07 13:33:51

问题


i just setup a linode server and deploy my rails 3 app on it.its up and running.The problem is that some images are not showing up in the production.locally they are perfectly working.i double checked the log file(production.log) but nothing found.then i check server error.log file that says.

[Sat Dec 29 22:54:14 2012] [error] [client 182.177.228.157] Premature end of script headers: media, referer: http://50.116.57.152/app?v=11&o=33

Check out http://50.116.57.152/app?v=11&o=33  for live demo.

Thanking in advance.


回答1:


i figured it out.ImageMagick gem was not installed on my linode server and i used dragonfly for images that's why error was coming i just installed it and bingooooo every thing is now working perfectly...........So guys be aware if you are facing the seme problem double check all the required gems installed.

Secondly, if you have installed ruby 1.9.3p360 remember it has bugs due to that request rendering does not complete. So the solution is down the ruby version from p360 to let say p327 and if you are using passenger as a web server then reinstall it. Copy 3 lines that passenger gives after installation in you apache2.cong file. restart server and this error should not occur again. thanks.



来源:https://stackoverflow.com/questions/14086883/premature-end-of-script-headers-media-issue-related-to-rails-app-deployment

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!