问题描述
我有一个在我的服务器上运行的 Rails 应用程序.当我转到远程桌面并尝试加载应用程序时,服务器需要 3-4 分钟的时间来响应一个简单的 HTML 页面.但是,当我在服务器上本地加载页面时,页面会在一秒钟内显示出来.我尝试从远程桌面 ping 服务器,并且 ping 在合理的时间内成功完成.
I have a Rails application that I'm running on my server. When I go to a remote desktop and attempt to load the application, the server takes a good 3-4 minutes to respond with a simple HTML page. However, when I load up the page locally on the server, the page shows up in just a second. I tried pinging the server from my remote desktop and the pings are going through successful in a reasonable amount of time.
这一切似乎都是在我安装了 Oracle 的基本客户端和 SQLPLUS 之后开始的.我应该怀疑甲骨文吗?有没有人遇到过类似的情况?
This all seems to have started after I installed Oracle's basic client and SQLPLUS. Should I suspect Oracle? Has anyone experienced anything similar to this?
推荐答案
这里也有同样的问题(即使是一年后).在linux下你必须做以下事情:
Having the same issue here (even a year later). Under linux you have to do the following:
查找文件/usr/lib/ruby/1.9.1/webrick/config.rb 并编辑它.
Look for the file /usr/lib/ruby/1.9.1/webrick/config.rb and edit it.
换行
:DoNotReverseLookup => nil,
与
:DoNotReverseLookup => true,
重新启动 webrick,它会像魅力一样工作:)
Restart webrick and it'll work like a charm :)
这篇关于Webrick 反应很慢.如何加快速度?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持编程学习网!