So I have just rebooted the PI and changed one of the nameservers to the router IP which is the same as default gateway now. I did have to remove the broadcast IP that was in the config as it refused to connect to the Internet with it in when I first installed it
.252 is a really common IP for class C router/AP interfaces. And potentially not wise to assign a local device. You sure there isnāt a 2nd one LAN side somewhere and suddenly you have an IP clash so routing issue.
The best way to configure DHCP is to assign DNS to the routerās IP.
Do the same if you are using static IP addresses.
The end result is the first DNS lookup will be in the router.
If the router cannot resolve the address, it will ask the remote DNS server that you configured, n.b., 8.8.8.8.
Precisely what fixed my problem. Changed my DHCP range to exclude may static pi address and itās been working fine ever since. Needed a new power supply though (thanks, @obj!).
Right so still having the issue, I have changed the DNS to include 192.168.0.1 on the PI, I have finally found the DHCP Pool settings in my router & changed the end IP to 250. so with the PI being static on 252 im hoping that should be it, as its taken the static range out of the DHCP pool range.
Well 23mins since I rebooted and could access after changing DHCP address pool. And itās back to no local connection via ssh or browser yet its still feeding away. I am really lost now on this.
What did you reboot ? The router or the Raspberry Pi ?
Changing the DHCP scope would require a router reboot to flush the old settings.
It could be continuing feeding via an IPv6 adress maybe ? Or is IPv6 disabled ?
Just a suggestion, shrink the DHCP scope to 150 devices and assign for instance number 200 to the Pi ?
Your settings in the Pi seems to be ok, did you check if IPv6 is still active and getting an DHCP address ?
Maybe that (if IPv6 is active) takes precedence over the IPv4 address ? Just trying to get to the bottom of this with you.
I donāt know if this helps, the feeder stays up and reporting ( stated in the first post) but it canāt be reached on the IPv4 address. Thatās why Iām thinking there might be an IPv6 DHCP lease active ( if IPv6 is activated).
Well over the past 5 days itās been on and off for the local pages working via IP, I honestly donāt know what is going on but I think Iām going to have to just put up with it now, as nothing seams to be sorting it out.
But thanks all for your input and recommendations on trying to correct it.
So I tested something which might be of interest, the WiFi was connected to the 5ghz band so I switched it off on the router and its now back on 2.4ghz and weirdly enough, itās not failed in the last 4 days. So it would seem it was the 5ghz band causing it for some bizarre reason.
5ghz is usually faster, but its range is shorter and it is more subject to interference. If there is a lot of distance (opposite corners of house) or many walls/ducts/etc between your pi and the wifi router, then it is totally plausible that 2.4ghz might be more stable.