Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!


Need help - Newbie questions about VPS
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.

Need help - Newbie questions about VPS

GanesanGanesan Member
edited December 2017 in Help

Hi everyone. Long time lurker posting for the first time here.

I have been using shared hosting to host my WP blogs for the past years. I have tried more than 10 providers but I am not satisfied with the speed and uptime performance over time. Sometimes, it would take at least 1 minute to upload 1 plugin and then another 1-2 minutes to activate that plugin. As for downtime, the longest one I had was more than 72 hours. The second longest downtime, which was by another provider, was slightly under 24 hours.

I want to learn how to use VPS to host my blogs, so I got myself 3 VPS (2 KVM and 1 OpenVZ) here during BF and have been trying them out using tutorials from DO and a few other online sources. I feel overwhelmed (and confused) by all the tutorials (some are good; some are outdated) and fragmented information online and I have some questions to be clarified.

Here's what I want to do with these VPS.

  • VPS #1 (UK location) will be used to host 10 blogs.
  • VPS #2 (US location with DDoS-filtered IP address) will be used to host another 9 blogs.
  • VPS #3 (AU location) will be used to host another 7 blogs.

Questions about DNS and DDoS protection

1) If I were to get a DDoS-protected DNS for VPS #2, would my websites on that VPS have better DDoS protection since it has both DDoS-filtered IP address and DDoS-protected DNS?

2) If I use a hosted DNS service that allows me to create vanity nameservers with the IP address from VPS #1, can I use these vanity nameservers for the IP addresses of VPS #2 and VPS #3?
I understand that I can just update the nameservers within the domain registrars' DNS settings. My concern is regarding the IP addresses. Would using the vanity nameservers of VPS #1 affect the latency of VPS #3? Would there be any lag for my readers in the Asia-Pacific region?

3) In relation to question #2, since VPS #1 does not have a DDoS-filtered IP address, would using its vanity nameservers for VPS #2 negate its DDoS-protection ability?

Questions about failover

4) Is it possible to use the same domain name on 2 or more VPS from different providers and locations, and then get hosted DNS with failover monitoring to create some sort of failover mechanism?

5) I read in DO and Ubuntu Wiki that you can set up high availability with haproxy and keepalived. The terms "floating IP" and "virtual IP" were used in their guides respectively. What is this floating/virtual IP address? Where can I find or get it if I'm not using DO or similar cloud providers?

6) What is your recommendation on creating a high availability environment for WP websites?

I look forward to seeing your expert opinions on these issues. Thank you in advance.

Comments

  • tl;dr. Im summoning @WSS.

  • qtwrkqtwrk Member
    edited December 2017

    1) If I were to get a DDoS-protected DNS for VPS #2, would my websites on that VPS have better DDoS protection since it has both DDoS-filtered IP address and DDoS-protected DNS?

    the sites on VPS #2 will have better DDoS protection

    2) If I use a hosted DNS service that allows me to create vanity nameservers with the IP address from VPS #1, can I use these vanity nameservers for the IP addresses of VPS #2 and VPS #3? I understand that I can just update the nameservers within the domain registrars' DNS settings. My concern is regarding the IP addresses. Would using the vanity nameservers of VPS #1 affect the latency of VPS #3? Would there be any lag for my readers in the Asia-Pacific region?

    from my personal experience , yes , it will affect speed on solving DNS , I have my site DNS on Cloudflare , which has bad connection to China , my visitor reports they sometimes have error like "DNS can't be solved" , I assume it's because of CF bad connection to China.

    on that regard , I would suggest a DNS service with anycast , if you don't have Chinese visitors , Cloudflare would be quite good for it.

    3) In relation to question #2, since VPS #1 does not have a DDoS-filtered IP address, would using its vanity nameservers for VPS #2 negate its DDoS-protection ability?

    I am not fully understand your question.
    but this is case , if your VPS #1 is down by attack , then the domain can't be solved?

    Questions about failover

    4) Is it possible to use the same domain name on 2 or more VPS from different providers and locations, and then get hosted DNS with failover monitoring to create some sort of failover mechanism?

    yes , you can solve to different IP on same domain , usually by geolocation , and IP will solve to closest server.

    for example , if I have server in US and EU , I can setup something like EU visitor will be directed to EU server, and US visitor will be redirected to US server for optimal speed.
    but this comes with a lot of more stuff to working , like real time sync between 2 server in order to have same data at same time.

    5) I read in DO and Ubuntu Wiki that you can set up high availability with haproxy and keepalived. The terms "floating IP" and "virtual IP" were used in their guides respectively. What is this floating/virtual IP address? Where can I find or get it if I'm not using DO or similar cloud providers?

    floating IP is a static public IP , for example in my case , I have a alibaba cloud , there is a product called "elastic IP" , same thing as "floating IP" just with different name ,
    what I can do is , I can bind or unbind this IP to different server in order to maintain the SAME public IP.

    for virtual IP , you can see this

    on simple term , it's like main server and backup server has same IP, but main server will occupy this IP until it is down, then backup server will automatically get this IP , in order to keep service up and running

    6) What is your recommendation on creating a high availability environment for WP websites?

    instead of setting up HA for your own , I'd suggest you use Cloudflare's load balancing

    hope this answers you some of your questions :)

    Thanked by 1Ganesan
  • Thank you for your input, @qtwrk. I appreciate it very much.

    @qtwrk said:

    3) In relation to question #2, since VPS #1 does not have a DDoS-filtered IP address, would using its vanity nameservers for VPS #2 negate its DDoS-protection ability?

    I am not fully understand your question.
    but this is case , if your VPS #1 is down by attack , then the domain can't be solved?

    Sorry for not being clear. Let me rephrase that:
    If I were to use the vanity nameservers (no DDoS protection) that were created with VPS #1's IP address (no DDoS protection too) for all blogs on the 3 VPS, would the blogs hosted on VPS #2 (has DDoS-filtered IP address) still be online if VPS #2 is under DDoS attack?

    for example , if I have server in US and EU , I can setup something like EU visitor will be directed to EU server, and US visitor will be redirected to US server for optimal speed.
    but this comes with a lot of more stuff to working , like real time sync between 2 server in order to have same data at same time.

    What software/scripts do you recommend to sync the 2 servers? I'll look it up and learn how to use it.

    floating IP is a static public IP , for example in my case , I have a alibaba cloud , there is a product called "elastic IP" , same thing as "floating IP" just with different name ,
    what I can do is , I can bind or unbind this IP to different server in order to maintain the SAME public IP.

    for virtual IP , you can see this

    on simple term , it's like main server and backup server has same IP, but main server will occupy this IP until it is down, then backup server will automatically get this IP , in order to keep service up and running

    The 3 VPS I bought came with 1 IPv4 each. In my case, where can I get this floating/virtual IP? If I get just 1 more IPv4 from one of the providers, can this IPv4 be treated as a floating/virtual IP?

    instead of setting up HA for your own , I'd suggest you use Cloudflare's load balancing

    Thank you for referring me to that article. I'll look into using CF's load balancing after I am more familiar with VPS setup.

  • ewrekewrek Member
    edited December 2017

    @creep said:
    tl;dr. Im summoning @WSS.

  • @Ganesan said:
    Sorry for not being clear. Let me rephrase that:
    If I were to use the vanity nameservers (no DDoS protection) that were created with VPS #1's IP address (no DDoS protection too) for all blogs on the 3 VPS, would the blogs hosted on VPS #2 (has DDoS-filtered IP address) still be online if VPS #2 is under DDoS attack?

    that depends on type of attacker , if DNS server was targeted and knocked off , the all the domain will not be solved , so make your domain inaccessible

    if attack was targeting VPS 2 IP directly , then it should be OK for VPS #1
    but I am not sure what happens if HTTP Flood takes place.

    I don't know anything about attack , I don't get attacked often , so I don't really know much about this

    but I always place my DNS on major provider , like Cloudflare , to have faster resolving.

    What software/scripts do you recommend to sync the 2 servers? I'll look it up and learn how to use it.

    I don't really have HA needed , so I am not sure if this is gonna work out or not , but in theory it should.

    in my case , I have 2 databases on master-master replication , you can try master-master or cluster.

    for files system , I was thinking somethign like RSYNC , you could try something like NFS is network suits you fine.

    from what I observed , databases replication is almost instant , maybe 1 second delay , but I don't really need HA , so I gave it a try and let it go. cluster should suit you better if you have a lot of visitors simultaneously , if not it could probably mess up database.

    about files , I don't know , my sites files don't change often , so I didn't perform more extensive test.

    The 3 VPS I bought came with 1 IPv4 each. In my case, where can I get this floating/virtual IP? If I get just 1 more IPv4 from one of the providers, can this IPv4 be treated as a floating/virtual IP?

    like I said , I don't really need HA , so I don't really know about this stuff , try google "HAproxy + keepalived"

    it should give you some hint.

    if I am understand it correctly.

    it uses virtual router , creating a virtual IP , and bind this VIP to master server , and if master server went down , it jumps to secondary server, I don't really understand how it is accomplished.

    all articles about keepalived I read is on same provider within private network , I am not sure if it works out on public network.

    good luck

    Thanked by 1Ganesan
  • mfsmfs Banned, Member

    Ganesan said: failover

    You may want to give a peep at this recent thread too

    Thanked by 1Ganesan
  • Thank you again for your sharing your opinion, @qtwrk.

    Thank you for pointing me to that thread, @mfs. I saw the comments there and also the other related LET thread there.

Sign In or Register to comment.