Hi, without settin gup WAN i cant connect to Internet. After Pi, i have Xiaomi AX3600 in AP Mode for the WiFi extention. Can you tell me how do i comeover with this Problem ?
you need to draw out how your network is laid out so we better understand what you are doing.
When i used pihole i just installed ubuntu server on my pi and ran pi-hole that way. you dont need it as a router.
However if you are using the pi to pass your lan to a wifi ap then you will need to reconfigure how everything works.
Hi, Pihole was something different. There we used to just hang it on to the ISP Router through USB Device and a single LAN cable, the rest is done by Pi through some routing as far as i understood.
Here in Pi4 we have 2 LAN(2nd one through USB 3.0 to Gigabit Adapter which acting as WAN, through which i could use one more Router which i can use it in AP-Mode for better WiFi coverage). that was working by default very well till the last few updates. I really dont know what is wrong from the last few updates of Rpi4 or is it just me playing with the packages for Adblocking... i am going crazy now by not getting the Adblock eventough i am trying to install only these 2 Packages on Pi4( Crowdsec and Adguardhome) for Adblocking. i am unable to get it working as it should be...
Its very sad on my part to see thee things failing after investing so much Time for it...
ok let me try explain this better.
Your ISP router. Your telcom one?
Tick the Obtain DNS server address automatically.
or set the dns to 1.1.1.1 and 1.0.0.1 That is Cloudflare DNS. That will set your WAN side of the network properly.
Having looked up more info your ISP router will NOT let you change its DHCP DNS address. Irritating and stupid but its their device. So we will disable their DHCP and you will use AGH DHCP instead.
This is why you have been having trouble.
Log in to your pi and go to your WAN settings for the pi.
Make sure it has a static address not DHCP.
General settings :
IP address : 192.168.2.2
IP netmask : 255.255.255.0
IP gateway : 192.168.2.1 < your isp router
Firewall Settings :
Create / Assign firewall-zone : Change from WAN to LAN
Now goto your LAN settings page and re-enable your DHCP server.
Anything downstream of that will use AGH and your blocklists.
You will proberbly need to manually edit your adguardhome.yaml file to change from 192.168.2.100 to 192.168.2.2
Now back to your telcom router.
turn DHCP off here.
So your isp router now acts as gateway. and your pi will give out DHCP and adblock.
Also remove crowdsec. your pi is behind your isp router and thus not exposed to the internet. no reason to have crowdsec on it.
Hi, thanks for the detailed explanation. I changed the wan to static but the lan is not allowing me to change it to dhcp. What can i do ? Is it because it is set to 192.168.2.2 ? Should i change the ip address of lan to something else like 192.168.1.1 ?
Your Lan doesnt need to be DHCP. it has to be fixed to hand out DHCP. Flip it back to 192.168.1.1 like you had it before. Its not ideal but will work.
Ok, now i have done as you said. I have cloudflare dns in isp router. Set wan static 192.168.2.2. Lan also static but 192.168.1.1
So pls tell me which ip address should i use for AGH ???
it should be running on your pi with 192.168.2.2 you may need to change the yaml file so it loads and binds to the correct interface/ip.
But i dont have internet connection with your settings... It says no internet connection
turn your isp dhcp back on for now so you can trouble shoot. plug into your isp router so u can get to both it and the pi and get AGH working on 192.168.2.2. once you have that working look to connect from the other side of the pi and check it works.
Which dhcp interface should i choose in AGH ? br lan with 192.168.1.1 or eth1 with 192.168.2.2 ?
that depends on how you are running your network. is everything behind the pi with a 192.168.1.x address? or are you running things off the 192.168.2.x subnet as well? You never properly explained your network.
I think this WAN is having 192.168.2.2.... and also AGH. I dont have Internet . I am using mobile network and posting you this...
Please tell me should all the devices be in one series of ip address ? I mean isp router, pi and wan addresses must be in 192.168.1... range ?
I can reconfigure them and try if it works.
Previously i didnt have to bother about all these ip address assignment or changing them, it used to work out of the box. Now only its troubling me to work as it should and not blocking ads...
that is not true i use it as my firewall and i only use about 110 mb of memory
try loading up lots of filter lists (like big 2million block lists) and you will find out it will fall over.