- Shell 100%
| README.md | ||
| wan-failover.sh | ||
WanFailOver This repository contains a shell script designed to monitor and manage dual-WAN internet connectivity on a Proxmox host.
Overview The script checks for active internet connectivity through the primary network interface. If the connection drops, it automatically reroutes traffic and updates DNS settings to utilize a secondary backup interface, ensuring minimal downtime.
How It Works Primary Route: By default, the system routes traffic through the primary Proxmox router on vmbr0 using the gateway 192.168.1.1.
Automatic Failover: If the internet becomes unreachable via the primary route, the script updates the routing table to push traffic out through the vmbr1 interface, using the backup gateway at 192.168.30.1.
DNS Resolution: During a failover event, the script modifies the resolv.conf file to use the specific nameserver located on the backup subnet: 192.168.30.19.
Usage (Add execution instructions, cron job scheduling, or required permissions here as you finalize the script).