大网数据广告活动
服务器运维问答

Failed to load resource: net::ERR_CONNECTION_RESET

· 52CE 我爱测

Since I started using an application behind a reverse proxy (Apache2's mod_jk), I've noticed some pages would not load; but do load, without the reverse proxy settings. The error in Google Chrome: Failed to load resource: net::ER…

问题原文

原帖链接 · Mohamed Ennahdi El Idrissi · CC BY-SA 4.0

Since I started using an application behind a reverse proxy (Apache2's mod_jk), I've noticed some pages would not load; but do load, without the reverse proxy settings.

The error in Google Chrome:

Failed to load resource: net::ERR_CONNECTION_RESET.

Simply, a JavaScript file would partially load; ~12KB out of ~50KB.

I thought something was wrong with Apache2, mod_jk, AJP, or Jetty.

I tried using different browsers along with different networks.

Verdict: The error

ERR_CONNECTION_RESET

occurs only when I use networks with a static IP.

I decreased my security level in one router, but in vain.

How to overcome this issue?

Are networks with static IP equipped with higher levels of security?

This is a stalemate because the reverse proxy is mainly destined to take advantage of static IP addresses of our selling points for an increased level of security.

已采纳解答

原帖链接 · Mohamed Ennahdi El Idrissi · CC BY-SA 3.0

I've finally solved the issue.

The breakthrough occured when I followed @john ktejik's directives:

https://stackoverflow.com/questions/4390134/failed-to-load-resource-under-chrome/26742627

I came to realize that the involved resource was encompassed within a .jar file. Therefore, I had to tell Apache2 to explicitely use "SetOutputFilter INFLATE;proxy-html;DEFLATE".

That's when I started to make some progress.

Since The inflate/deflate directive disables some links, I had to make it exclusive for javascript files:

"AddOutputFilterByType DEFLATE application/x-javascript".

Also, I needed an extra tweak which is to activate mod_expires and mod_headers (source).

Finally, I would rather clear cache before testing in different machines.

Clearly, the problem is related to Cache expiration and Static IP, which I can't really understand.

More importantly, the problem is solved (tested on different machines with different browsers with static and dynamic IP)!

摘自公开归档,保留原文语言,版式经整理,外部媒体与邮箱地址已移除。

资料来源与适用范围

资料来源
Server Fault
适用范围
以原帖系统、软件版本与发布日期为准(2016-01-15)
内容语言
中文;命令、路径和错误标识保留技术原文
本地收录日期
2026-11-15
授权说明
CC BY-SA 4.0 / CC BY-SA 3.0

正文与所需资源由本站本地存储。查看来源及更新记录 ↗

请按适用版本和实际日志确认原因;本站没有对每一种系统或设备逐项执行文中的操作。