New on LowEndTalk? Please Register and read our Community Rules.
All new Registrations are manually reviewed and approved, so a short delay after registration may occur before your account becomes active.
All new Registrations are manually reviewed and approved, so a short delay after registration may occur before your account becomes active.
Geolocation for cheapskates like me
Biggest expense so far has been the Namesilo domain name...
Comments
Might give this a go. Just maybe a lot more servers and lots more traffic.
You're welcome.
Saw it some days ago, will try it out soon :-)
Interesting with the redirects. I used to have something that used the great circle distance (only for large file downloads though, not the entire website), it saves some code but manually tweaking it based on continent probably reduces ping:
Great tutorial, you could complete it with some Cloudflare config screenshots
Thanks. Not much to do in Cloudflare. Add A records. Click to make the clouds grey
A Records:
May want to throw in a 'www' CNAME record pointing to mydomain.com.
Interesting, thanks. That function makes my brain hurt
:O I want to meet kate
Just found this, do you use a cloud host or some random VPS's from diferent providers?
http://www.lowendguide.com/3/monitoring/setup-a-ha-round-robin-blog-on-debian-7-with-cloudflare/
I think this Round-robin DNS approch would only make sense using cheap or free shared hosting, using a master server to sync files and DB, otherwise anyone could just use some Cloud shared host / VPS provider
The "To Do - Part II" from your article is still the most important and that gives sense to overall High Availability Round-robin DNS thing
She's very shy, but I'm hoping to coax her out to meet some people later this summer.
Still lots to do...
Yes, I've seen that. I'm using random VMs from three different providers. Which provides HA from a business perspective
My 'master server' is at home. A bash script sync to the four mirrors. There's no MySQL so the sync is simply rsync.
There are many definitions of "cloud". A "cloud" provider isn't necessarily mirroring your site at four different geographic locations, or providing HA. And if they are, it'll cost much more than the ~ $18/year I'm paying for this
Absolutely agree. I've intentionally not called this High Availability yet, until Part II is sorted. I haven't had time to look at it yet. If anyone has experience using the Cloudflare api, tips are appreciated!
The last time I had to implement something like this, I found that appengine started doing free geolocation for all inbound requests a couple of years ago. It made it ridiculously easy to run a simple frontend, very similar to what's described in this post, but in about 10 lines of code. It didn't use 90% of appengine's features, either, so it's been running under the free quota for about a year.
Some details on how it works can be found here. You just read those request headers and do what you need to do.
I looked at that some time ago. Fact is, I like to try to keep reliance on 3rd-party services to a minimum. That's just me.
As do I, but for geolocation, it's practically impossible to do with zero 3rd party dependencies. Even in the linked article, you're depending on maxmind for the geolocation database. You're not subject to them going down, sure, but you are dependent on them for updates.
That's true. But at the very coarse scale that I'm doing geolocation I don't see database updates as a big issue. For example, geolocating my home dynamic IP returns a half-dozen different results, all of which are incorrect by 200-300 miles. It doesn't matter, that's close enough. And if geolocation fails (say the database doesn't contain info for a particular IP) then the site simply loads from the current mirror. Maybe not ideal, but at least nothing breaks.
I'm not disagreeing at all, it's a fine approach. My use case wasn't the same as yours, and Google was the client, so depending on their service wasn't an issue
I'm not disagreeing with your approach either. And I'll happily change if Google wants to hire me
Can you build it so it goes to the nearest location based on IP location. I have many servers and can't be arsed finding longs and lats
+1 for this.
http://www.lowendtalk.com/discussion/comment/1060464#Comment_1060464
How would that be added. Not got much logic in me today.
Something like:
I've got this scripted and working now. Will let it run and sleep on it for a day/night before posting
Looking for some advice here regarding monitoring and manipulating DNS records....
The basic setup is:
Let's say mirror "three" goes down. We remove the 'A' record
mydomain.com => 192.168.0.3
. No problem.But what to do with the 'A' record
three.mydomain.com => 192.168.0.3
?The choices are:
Option #3 has two issues, both resolvable I think....
But the order needs to be different. The first server_name must always be the actual hostname of the mirror. For example, "two" would have:
Make sense? Any better ideas? Thanks for reading....
Why does it redirect to a different subdomain of each VPS in the first place?
There's no way of manipulating the destination server using PHP and Cloudflare API, and using all servers pointing to the same subdomain? Or in this way you have no control of the round-robin process and the the selection get done randomly by Cloudflare?
The point is, for example I have a website, where most visitors are from a single country, so most traffic would be redirected to the closest server without a balanced distribution?
The lowendguide tutorial used IP's
If I'm understanding it correctly, that gives you HA but not geolocation.
To have geolocation (putting the visitor directly onto the closest mirror) it's necessary to redirect. Or use a DNS service that provides geolocation services for http, which isn't available for free as far as I know.
Ok
I edited my last message I dont know if you noticed my last question
I've never been much concerned about latency, this world isn't that big so would have a need to think about that, for me about HA and distribution of load
For example if I have a VPS in France and other in US West cost and 90% of my traffic is from Japan, my French VPS will barely doing anything and many times distance does not equal to latency
For three.xxx.com just set it to goto a diff server. Remember to have ultra low TTLs 60 is about it.
Rage4 it's free until certain quota. Also prometeus offers DNS which afaik is almost (if not) the same as Rage4, but I am not sure if their panel allows to customize these things.
Also there are these ones:
https://www.zerigo.com/managed-dns (just found it, no idea if their free plan has all the features).
https://nsone.net/pricing/ (I want to try it since long time ago, they put it like a wonderful thing hehe)
http://www.gslb.me/users/ Apparently just two servers on the free plan
I though Rage4 entry level was €1 per month?