Pi-Hole is a DNS server solution for blocking requests to advertising and malvertising domains.
For high availability there's a sync solution called gravity-sync.