(Solved) Wget returned 4 Error on OpenWrt Switch

Hey Community, I set up my second router as a switch, but I can't install new packages or update the package list despite being able to ping websites.

This is my setup:


The only things I did were:

  • changing the IP Adress of my routers to 192.168.0.1 and 192.168.0.2 (this is the router with the Error)
  • deleting the WAN and WAN6 interfaces on the 192.168.0.2 switch
  • deactivating the DHCP Server on my 192.168.0.2 switch

Notes:

  • I put the Lan cable into the LAN Port of the 192.168.0.2 switch
  • I can ping Websites on the my 192.168.0.2 switch (I tried "ping 1.1.1.1")
  • when I connect my computer with the 192.168.02 switch I can access the Internet
  • I read the manual, but it didn't help me (the manual said I have to reconfigure my network and I couldn't figure out what to do)

Go to 192.168.0.2 > interfaces [UPLINKEDINTERFACE]... and put in a DNS/GATEWAY ( which more than likely would be 192.168.0.1 for both )

fyi you "pinged an ipaddress of a website" which does not test DNS.... so you had a gateway presumably... just no dns.... next time ping a name too, as there is a difference....

P.S> Thanks for the diagram.... it really helps....

2 Likes

Thanks, that fixed it :smiley:

For Everyone with the same problem, this is what you have to do:
when you are in the OpenWrt menu: go to Interfaces and then to LAN
for your first router the IPv4 address and the IPv4 gateway must be the same
Screenshot-2019-3-30%20OpenWrt%20-%20Interfaces%20-%20LuCI
for your second router you have to set the ip of your first router as the ip of the IPv4 gateway and the custom DNS server
Screenshot-2019-3-30%20OpenWrt2%20-%20Interfaces%20-%20LuCI
You probably have to reboot both Routers after this (do this if you can't access any sites afterwards) Good Luck!

2 Likes

This topic was automatically closed 10 days after the last reply. New replies are no longer allowed.