Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Multiple IP adresses: no ASN so no proper balancing #23

Closed
kib opened this issue Aug 3, 2015 · 3 comments
Closed

Multiple IP adresses: no ASN so no proper balancing #23

kib opened this issue Aug 3, 2015 · 3 comments
Labels

Comments

@kib
Copy link
Contributor

kib commented Aug 3, 2015

When connecting from mobile devices mirrorbits 'sees' two external IP's for the device, and is unable to select an ASN. The result is that the client does not receive a download at optimal speed.

For example: http://up.kibje.com/20150803/Screenshot_2015-08-03-17-27-09.png
I have IP's 212.67.184.99 (ASN8608) and 66.249.81.223 (ASN15169)

For mobile the first address almost always corresponds to the location-defining IP of the client. In my case when I am on WLAN I get the proxy of my location, when I am not on WLAN I get the proxy address of my mobile phone provider.
The second IP address is caused by mobile browser optimization services (eg Google / Akamai / Apple) which most phone manufacturers are using on their OS's these days. They can also be caused by webpage filtering software but that is less common.

In my opinion the first address should always be selected if two or more addresses are available.

@etix
Copy link
Owner

etix commented Aug 3, 2015

In the current implementation, the X-Forwarded-For header is expected to contain only one IP address. How were you able to get two?

EDIT: my bad, they're added by proxy servers

@etix etix added the bug label Aug 3, 2015
@etix
Copy link
Owner

etix commented Aug 3, 2015

In my opinion the first address should always be selected if two or more addresses are available.

The first is the "real" user's location but since we need to feed the proxy instead, shouldn't we use the last one? In case of a browser optimization services then it's probably best to use the first, since binary files will probably not go through the proxy.

@kib
Copy link
Contributor Author

kib commented Aug 3, 2015

I'll leave that design choice op to you, but picking either is likely better than none.

@etix etix closed this as completed in c9649e5 Aug 3, 2015
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants