2

I have two websites, say a.com and b.com.

a.com is on a paid hosting service, and b.com is on 000Webhost.

000Webhost crashes sometimes, and my site b.com becomes unreachable.

So is there any way that I can:

  1. create a copy of b.com, in a subfolder of a.com, like a.com/bdotcom
  2. If b.com is unreachable, redirect it to a.com/bdotcom
  3. If possible, keep the url as b.com
dan
  • 15,123
  • 11
  • 44
  • 52
jeff
  • 465
  • 4
  • 12

2 Answers2

2

You would need to have a program checking the status of b.com and once it was unreachable use an API to set a CNAME record for b.com pointed to a.com/bodtcom, though you would need to use b.a.com and have it as a sub-domain.

However a host that is unreachable for me, may still be reached by others. It all depends on what the problem is and where.

In my opinion, I would leave 000Webhost, and move that domain to a more reliable hosting company.

If you have enough money the best solution is to use a load balancer and Scalr on AWS or another cloud service that can monitor your two domains and servers and if a problem comes up it would automatically re-direct traffic.

dan
  • 15,123
  • 11
  • 44
  • 52
Anagio
  • 11,195
  • 1
  • 26
  • 49
1

I think it would require DNS switching.

Check with the domain hosting provider if they can switch it to your backup site as fallback requirement.

Sachin Dhir
  • 307
  • 1
  • 6