我们的开发网络服务器已开始向浏览器提供页面中相同文件的“连接重置”错误,但前提是我们使用内部网络进行请求。如果我从家里连接,那么请求就可以得到很好的满足。
apache 日志显示 GET 服务正常,状态为 200,但图像/css 文件/js 不会在浏览器中加载,即使路径被复制到地址栏也是如此。页面中的其他文件加载良好 - 并且始终是失败的相同文件。外部没有任何问题。
也许重要的是,所有无法加载的文件都是 4kb。将注释块中的随机代码添加到文件中以更改其文件大小,并且它们将正确加载。取出该内容块,文件将无法再次加载。二进制文件(图像)的情况类似。 4kb 的文件不会加载,在 Fireworks 中打开该文件,然后保存该文件,它将在内部正常加载 - 文件大小可达 16kb。不过,在此之前的文件没有任何问题 - 它们预览/打开良好,可以看到图像或可以读取文本,没有损坏 - 如果请求来自另一个互联网连接,则可以正常服务。
我尝试将网站移至另一台 Mac - 从我们的网络内部出现同样的问题,从外部再次正常。我在 MAMP 服务器上下载了安装的较新版本,并复制了 htdocs 内容 - 同样的问题。
我已经清除了缓存、摆弄了 MTU 设置、更换了路由器以及许多其他操作,但均无济于事。我非常确定它与 Mac 文件系统相关联,因为在其他计算机上进行测试时,文件本身是唯一的共同因素。
环境是 iMac、Mac OS x 10.6 Snow Leopard、MAMP 2.0 以及 MAMP 1.9。
该页面基于 PHP,提供带有链接 javascript/css/图像的 HTML。
Our development webserver has started giving 'connection reset' errors to browsers for the same files in pages but only if we use the internal network to request from. If I connect from home then the requests are served fine.
The apache logs show that the GET was served fine with a 200 status but the image / css files / js wont load in a browser, even if the path is copied to the address bar. other files in the page load fine - and its always the same files that fail. Externally there are no problems.
Perhaps of importance is that all of the files that fail to load are 4kb. Adding random code in comment blocks to the files to alter their filesize and they will load correctly. Take that block of content out and the file fails to load again. Its a similar story with binary files ( images ). Files of 4kb are not loaded, Opening the file in say, fireworks and then savine that file and it will load fine internally - the filesize goes up to 16kb. There is nothing wrong with the files before this though - they preview / open fine, images can be seen or text can be read, there is no corruption - they are served OK if the request comes from another internet connection.
I tried moving the websites to another mac - the same issue from inside our network and fine from outside again. I downloaded an installed a newer version on the MAMP server and copied the htdocs contents in - same problem.
I have cleared caches, fiddled with MTU settings, replaced routers and a host of other things to no avail. Im pretty sure that it is linked to the Mac filesystem as the files themselves are the only common factor when tested on other computers.
The environment is an iMac, Mac OS x 10.6 Snow Leopard, MAMP 2.0 as well as MAMP 1.9.
The page is PHP based serving HTML with linked javascript / css / images.
发布评论
评论(1)
看起来这个错误与apache、软件或计算机无关——肯定是第一个路由器出现了故障,第二个路由器也出现了同样的故障。我们现在安装了一台全新的 Netgear 路由器,此后再也没有出现过任何问题。
如果一开始就能找出路由器到底出了什么问题就好了,但这并不重要——它又可以工作了!
It would seem that the error had nothing to do with apache or software or the computer - there must have been a fault with the first router followed a fluke identical fault on the second. We have now installed a brand new Netgear router and have not had a single issue since.
Would have been nice to have figured out what was actually wrong with the router in the first place but that doesn't matter - its working again!