You are not logged in.

#1 2023-12-09 05:23:05

vorlket
Member
Registered: 2017-09-30
Posts: 112

[SOLVED] Can ping local network but not internet nor the internet

I have a network like this client -(static) router1 -(dhcp) router2 - the internet.

I have set netctl static network and can ping router1 but can't router2 nor the internet.

I appreciate if you could help me resolving this issue.

I forgot how to write code here (been long since last time I used the forum) but here's the network configuration:

Interface=eno1
Connection=ethernet
IP=static
Address=('192.168.1.2/29')
Gateway='192.168.1.6'

/etc/resolve.conf:
nameserver 8.8.8.8

Last edited by vorlket (2023-12-17 01:30:09)

Offline

#2 2023-12-09 08:33:17

seth
Member
From: Don't DM me only for attention
Registered: 2012-09-03
Posts: 74,325

Re: [SOLVED] Can ping local network but not internet nor the internet

[code][/code] tags

ip a
ip r

Since you can't "ping router2" that's the first obstacle to get out of the way, how do you attempt to do that, what's teh exact result (error message) and and what's that routers IP?
Since it's a dhcp router, you could also try to scan for it.

sudo nmap --script broadcast-dhcp-discover

Online

#3 2023-12-09 09:33:32

vorlket
Member
Registered: 2017-09-30
Posts: 112

Re: [SOLVED] Can ping local network but not internet nor the internet

ip a:
eno1: <BROADCAST, MULTICAST,UP,LOWER_UP> ... UP ...
   ...
   ...
   inet 192.168.1.2/29 brd 192.168.1.7 scope global eno1
   ...

ip r:
default via 192.168.1.6 dev eno1
192.168.1.0/29 dev eno1 proto kernel scopr link src 192.168.1.2

router1 ip: 192.168.1.6 / 192.168.0.2
router 2 ip: 192.168.0.1

nmap --script broadcast-dhcp-discover 192.168.0.2:
Starting Nmap 7.94 ...
Nmap scan report for 192.168.0.2
Host is up ...
Not shown: 999 closed tcp ports (reset)
PORT   STATE   SERVICE
80/tcp   open      http

nmap --script broadcast-dhcp-discover 192.168.0.1:
Starting Nmap 7.94 ...
Note: Host seems down, If it is really up, but blocking our ping probes, try -Pn
Nmap done: 1 IP address (0 hosts up) ...

Last edited by vorlket (2023-12-09 09:39:36)

Offline

#4 2023-12-09 16:01:52

seth
Member
From: Don't DM me only for attention
Registered: 2012-09-03
Posts: 74,325

Re: [SOLVED] Can ping local network but not internet nor the internet

Please don't transcribe random lines, post the entire output.
You can eg. redirect it into a file and usb-walk that to a system w/ interner or possibly use https://wiki.archlinux.org/title/Tethering

The nmap script doesn't make sense w/ a parameter - it scans the reachable segments for a dhcp server.
Since your second call, despite bogus, fails, you probably don't have a route into that segment.
But please post the ping results.

router1 ip: 192.168.1.6 / 192.168.0.2
router 2 ip: 192.168.0.1

I assume that's supposed to say that router1 is your gateway at 192.168.1.6 and itself has a lease 192.168.0.2 on router2?

Can you ping router2 from router1 (it has a http server, so probably some GUI)?
Can you use other clients with this router cascade?
Also post

ip r get 192.168.0.1

How is the routing in router1 configured? Does it act like a bridge or as a router?

Online

#5 2023-12-11 02:34:10

vorlket
Member
Registered: 2017-09-30
Posts: 112

Re: [SOLVED] Can ping local network but not internet nor the internet

Ping from router 1 to router 2:

PING 192.168.0.1 (192.168.0.1): 32 data bytes

40 bytes from 192.168.0.1: icmp_seq=0 ttl=64 Time=0.7 ms

40 bytes from 192.168.0.1: icmp_seq=1 ttl=64 Time=0.6 ms

40 bytes from 192.168.0.1: icmp_seq=2 ttl=64 Time=0.6 ms

40 bytes from 192.168.0.1: icmp_seq=3 ttl=64 Time=0.6 ms

40 bytes from 192.168.0.1: icmp_seq=4 ttl=64 Time=0.6 ms

--- 192.168.0.1 data statistics ---

5 Packets transmitted, 5 Packets received, 0% Packet loss

round-trip min/avg/max = 0.6/0.6/0.7 ms

Can ping from 192.168.1.2 to 192.168.1.6 and 192.168.0.2 but not 192.168.0.1.

ip r get 192.168.0.1:

192.168.0.1 via 192.168.1.6 dev eno1 src 192.168.1.2 uid 0

Router 1 acts as a router. Here's the routing table in router 1:

Destination LAN IP	Subnet Mask	        Gateway	        Interface
192.168.1.0	        255.255.255.248	0.0.0.0	        LAN & Wireless
192.168.0.0	        255.255.255.0	        0.0.0.0	        Internet (WAN)
0.0.0.0	                0.0.0.0	                192.168.0.1	Internet (WAN)

Offline

#6 2023-12-11 08:46:44

seth
Member
From: Don't DM me only for attention
Registered: 2012-09-03
Posts: 74,325

Re: [SOLVED] Can ping local network but not internet nor the internet

Can ping … not 192.168.0.1.

Since you've a route you're just loosing all packages?

seth wrote:

Can you use other clients with this router cascade?

Also what is "router1"? openwrt/dd-wrt?
There's no gateway for the entire 192.168.0.0/24 segment (the realm of router2), why is that?

Online

#7 2023-12-11 09:14:12

vorlket
Member
Registered: 2017-09-30
Posts: 112

Re: [SOLVED] Can ping local network but not internet nor the internet

Yeah none of the packets are replied. The same result with other clients on the 192.168.1.0/29 network.

No openewrt nor dd-wrt - just default firmware for linksys e2000 router.

The routing table got created by default by the router 1. When I tried to put in static route to 192.168.0.0/24 via 192.168.1.6, it says invalid static route...

Perhaps using openwrt or dd-wrt may help.

Offline

#8 2023-12-11 09:20:10

seth
Member
From: Don't DM me only for attention
Registered: 2012-09-03
Posts: 74,325

Re: [SOLVED] Can ping local network but not internet nor the internet

The same result with other clients on the 192.168.1.0/29 network.

The problem is the router and idk how to configure that

The routing table got created by default by the router 1

For what config, though? The router seems to think that it's doing 192.168.0.0/24 - any idea why  that is?

Perhaps using openwrt or dd-wrt may help.

The device seems to support dd-wrt which has many upsides, but please notice that you're likely using warranty when installing a 3rd party firmware.

Online

#9 2023-12-11 10:20:57

vorlket
Member
Registered: 2017-09-30
Posts: 112

Re: [SOLVED] Can ping local network but not internet nor the internet

I have no idea why it set gateway 0.0.0.0 for 192.168.0.0/24. The problem is it doesn't allow me to set static route for that network. I might buy a new router and/or try dd-wrt. Thanks for help.

Offline

#10 2023-12-11 14:08:06

seth
Member
From: Don't DM me only for attention
Registered: 2012-09-03
Posts: 74,325

Re: [SOLVED] Can ping local network but not internet nor the internet

Why do you want to set a static route anywhere?
Just allow router1 to get its IP from the router dhcp and configure it to hand out IPs via dhcp to its clients.
This line here

192.168.0.0	        255.255.255.0	        0.0.0.0	        Internet (WAN)

should prbably not exist.
Do you have a link for an online manual of the router?

Online

#11 2023-12-15 09:34:04

vorlket
Member
Registered: 2017-09-30
Posts: 112

Re: [SOLVED] Can ping local network but not internet nor the internet

I thought static route will simplify things.

Anyway, I removed the static route and set dhcp on router1 and set NAT and RIP then the pings work.

Last edited by vorlket (2023-12-15 10:08:40)

Offline

#12 2023-12-15 14:07:36

seth
Member
From: Don't DM me only for attention
Registered: 2012-09-03
Posts: 74,325

Re: [SOLVED] Can ping local network but not internet nor the internet

\o/
Please always remember to mark resolved threads by editing your initial posts subject - so others will know that there's no task left, but maybe a solution to find.
Thanks.

You might want to record the new conditions of "ip a; ip r", the dhcp scan results and the router configuration (esp. on the 0.0.0.0 gateway for 192.168.0.0)

Online

#13 2023-12-17 01:29:35

vorlket
Member
Registered: 2017-09-30
Posts: 112

Re: [SOLVED] Can ping local network but not internet nor the internet

ip r:
default via 192.168.1.6 dev eno1 proto dhcp src 192.168.1.2 metric 1002
192.168.1.0/29 dev eno1 proto dhcp scope link src 192.168.1.2 metric 1002

Router configuration:

dhcp on router 1 and 2
NAT and RIP configuration

Offline

Board footer

Powered by FluxBB