1

I am observing some strange behavior I cannot explain.

  • I am using chrome Version 110.0.5481.77 (Official Build) (64-bit)

  • I am running nginx/1.22.1 to serve a bundled front end app.

  • When I request my app bundle at IP:443 I receive an incomplete bundle that is not in my public directory and there is an error in the console: net::ERR_INCOMPLETE_CHUNKED_ENCODING 200 (OK).

  • The server's remote address matches my remote address, port 443.

  • The size of the response is 65.5 KB in dev tools.

    Response Header Server: nginx/1.22.0
    
    ETag: W/"SOME ETAG HASH"
    
  • This response is also returned when my NGINX server is NOT RUNNING. So to be clear:

  • Sometimes my NGINX server sends the correct static files. But after some time it no longer sends the correct static files and sends an incomplete bundle.

  • When my NGINX server is not running, this bundle is still sent.

I am puzzled because:

  1. I have not set up my own cache
  2. I am using nginx/1.22.1 NOT nginx/1.22.0 specified by the incorrect bundle
  3. My server may not be up when I receive this response
  4. netstat -nptwc on my host shows:
     tcp 0 0 192.168.1.14:42384 IP:443 TIME_WAIT -
     tcp 0 0 192.168.1.14:49090 IP:443 ESTABLISHED 245476/chrome --typ
    
  5. netstat -nptwc on my host shows no traffic from my host.
  6. I do not see any server traffic on the host when this bundle is returned.

Okay so what is going on here...is my web server's response cached somewhere outside my server???

vidarlo
  • 6,654
  • 2
  • 18
  • 31
Anthony O
  • 111
  • 5

2 Answers2

1

It's possible that the response is being cached somewhere outside of your server, such as in a proxy server or a content delivery network (CDN).

When you access a website through a CDN i.e (CloudFlare), the CDN will cache certain static files, such as images or JavaScript files, on servers that are closer to the user, which can improve the website's performance. It's possible that the incomplete bundle is being served from a CDN cache, which could explain why the response is still being returned even when your NGINX server is not running.

Another possibility is that there is a caching proxy between your browser and your NGINX server. This could be a reverse proxy that is installed on your server, or it could be a separate proxy server that is installed elsewhere on your network or on your ISP's network.

You could try checking your network configuration to see if there are any caching proxies or CDNs that are configured to serve content for your domain. You could also try clearing your browser cache and disabling any caching plugins or extensions that might be causing the issue.

Salim Aljayousi
  • 341
  • 1
  • 3
0

In my case there was a NAT issue at our LAN gateway. Traffic to the public IP was being routed to two servers, one of which we were not aware of.

Anthony O
  • 111
  • 5