Comments (2)
I read lines of source code and found out that detailed information for redirection is included in http response header.
The information contains distance between client computer and redirecting computer calculated by longitude/latitude which also calculated by IP address for each computers.
The response header that describes wrong behavior from http://httpredir.debian.org/demo
is as follows:
HTTP/1.1 200 OK
Date: Mon, 03 Oct 2016 05:15:48 GMT
Server: Apache
Cache-Control: no-cache
Pragma: no-cache
Link: <http://giano.com.dist.unige.it/debian/>; rel=duplicate; pri=13948; depth=0, <http://ftp.cz.debian.org/debian/>; rel=duplicate; pri=13968; depth=0, <http://debian.ethz.ch/debian/>; rel=duplicate; pri=14283; depth=0
X-AS: 4713
X-City: Setagaya
X-Closest-Distance: 139.4834
X-Continent: AS
X-Country: JP
X-Distance: 142.8334
X-IP: 61.126.xxx.xxx
X-Match-Type: nearby-continent
X-Population: 8
X-Region: 40
X-Std-Dev: 4.58363229328008
X-Clacks-Overhead: GNU Terry Pratchett
Transfer-Encoding: chunked
Connection: Keep-Alive
When requested the demo page again after tens of minutes, I got correct response from the server as follows:
HTTP/1.1 200 OK
Date: Mon, 03 Oct 2016 05:45:34 GMT
Server: Apache
Cache-Control: no-cache
Pragma: no-cache
Link: <http://debian-mirror.sakura.ne.jp/debian/>; rel=duplicate; pri=10; depth=0
X-AS: 4713
X-City: Setagaya
X-Closest-Distance: 0.0966999999999913
X-Continent: AS
X-Country: JP
X-Distance: 0.0966999999999913
X-IP: 61.126.xxx.xxx
X-Match-Type: country
X-Population: 1
X-Region: 40
X-Std-Dev: 0
X-Clacks-Overhead: GNU Terry Pratchett
Transfer-Encoding: chunked
Connection: Keep-Alive
Comparing X-Closest-Distance in correct/incorrect response header shows the difference.
from http-redirector.
Maybe I've found out root cause of this issue.
There are 2 servers representing httpredir.debian.org
.
appuser@debian-8:~$ nslookup httpredir.debian.org
Server: 10.0.2.3
Address: 10.0.2.3#53
Non-authoritative answer:
Name: httpredir.debian.org
Address: 128.31.0.66
Name: httpredir.debian.org
Address: 5.153.231.35
For the server whose ip is 5.153.231.35
always returns correct mirrors while the server of 128.31.0.66
always return incorrect mirrors.
I looked up those IP addresses in GeoIP and found that the server of 128.31.0.66
is managed by MIT.
IP | Country | Location | Organization | Domain |
---|---|---|---|---|
128.31.0.66 | US | Cambridge, North America | Massachusetts Institute of Technology | mit.edu |
5.153.231.35 | GB | Great Britain, Europe | Bytemark Limited | debian.org |
So I need to tell to the right persons that ./update.sh && ./build-main-db.pl
should be run to update database of mirrors to the latest version.
from http-redirector.
Related Issues (20)
- debian.dc-uoit.net is return a private IPv4 adress HOT 1
- suggestion for better mirror
- restrict to ipv4 lookups only. HOT 1
- http://httpredir.debian.org/debian Not Found HOT 4
- frequent "502 connection closed" errors
- httpredir.debian.org returns IPv4 only domains for an IPv6 only machine HOT 8
- Caching doesn't seem to work with http-redirector HOT 3
- restrict to only certain domains (e.g. *.debian.org) HOT 2
- Redirects are not permanent HOT 2
- Let redirects be short-term cachable HOT 2
- please blacklist mirror.dhakacom.com, it returns every request as 403 Forbidden HOT 1
- Please add support for the new debug archive
- Missing Hungary
- Redirects to mirror with missing packages
- Doesn't understand new ftpsync tracefiles
- Failed to fetch libx11-xcb HOT 4
- flaky 'Remote end closed connection' in docker build HOT 14
- Redirects IPv6 client to hostname which has IPv6, but isn't listening on IPv6
- HTTPS version, i.e. https://httpsredir.debian.org/debian
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from http-redirector.