OPNsense Forum

Archive => 22.7 Legacy Series => Topic started by: chuliu on January 21, 2023, 01:11:04 PM

Title: [solved] dual wan and pi-hole on opnsense
Post by: chuliu on January 21, 2023, 01:11:04 PM
Hi, I am new to opnsense and software router as a whole.  I just received the intel celeron N5105 hardware with 4 network ports a few days ago with pfsense installed.  For some reason, pfsense wouldn't work well for my xbox series x giving me a double nat error.  I decided to switch to opnsense. 

Now, here is my setup:  N5105 cpu with 4 netowrk ports, dual ftth from different isps with the same speed, pi-hole with unbound on rasphberry pi, one lan with ip addresses 192.168.86.1/24 

I followed this (https://docs.opnsense.org/manual/how-tos/multiwan.html) and set up my opnsense with dual wan and set the dns servers to google and cloudflare respectively.  I didn't set the dns to my pi-hole becuase if I set it up in system->settings->general by filling up my pi-hole ip and specifying the gateways and saved it, it will give me an error saying "You can not assign a gateway to DNS server "192.168.86.150" which is on a directly connected network." 

My goal is to be able to set up pi-hole as dns server for the network for blocking youtube from my kids.  I don't mind if I cannot use unbound for dns resolver.  If I can, that is even better.  How can I set it up with the opnsense limiting me from setting up dns with an ip in the lan subnet.  Thanks. 
Title: Re: dual wan and pi-hole on opnsense
Post by: lilsense on January 21, 2023, 06:16:08 PM
pihole address goes in the DHCP settings for your subnet.
Title: Re: [solved] dual wan and pi-hole on opnsense
Post by: chuliu on January 22, 2023, 03:48:56 AM
Never thought it was as easy as that!
Thanks.