Author Topic: Network is unreachable  (Read 6413 times)

nontrivial

  • Zen Warrior
  • ***
  • Posts: 173
  • Karma: +14/-0
    • View Profile
Network is unreachable
« on: June 18, 2012, 02:40:53 am »
I have a new install of Zentyal 2.3. I have three network interfaces:
 * eth0 -> Internal wired network, static, 192.168.1.1
 * eth1 -> Internal wireless network, static, 192.168.2.1
 * eth2 -> External connected to cable modem, static, IP 98.174.187.147,SM 255.255.255.240, GW 98.174.187.145

I am attempting to replace a stock Ubuntu 10.04 install that has worked flawlessly for two years that I am very comfortable configuring by hand. I was hoping Zentyal would make my life easier, but so far not so much. The install went fine, and standing on a ladder holding the keyboard in my hand, I can log into my Zentyal box, do the initial configuration, ifconfig looks good, resolve internet addresses, and ping various places. It all looks good, so I go to one of the wired Ubuntu workstations to tweak the box via the web administration, and that's when unhappiness ensues.

The first problem is DHCP isn't working, and therefore I have no internet to view the online docs. I jacked with the settings for an hour or so (standing on a ladder) with no luck before giving up and defining a static IP on the workstation. I can probably figure out the DHCP problem, eventually, but there is a bigger problem that has me REALLY stumped. I was able to slogin to the box and was then able to resolve IP addresses, but I couldn't ping anything except the Zentyal box. I get "connect: Network is unreachable". So I spent another couple hours jacking with settings before giving up and bypassing the router and using my emergency Lynkys box until I have another few hours trying to get basic networking on a linux box working.

It's almost as if the box isn't forwarding packets from the internal network to the external network, ie iptables doesn't have IP_FORWARD set or something, but I am REALLY reaching the limits of my linux administration knowledge here, and I have no idea what most of the settings in Zentyal do, or how they interact. I even tried turning off the firewall (that gave me a warm fuzzy) and that didn't help. When I run route -n, the table looks REALLY odd to me:
0.0.0.0         98.174.187.145  0.0.0.0         UG    100    0        0 eth2
98.174.187.144  0.0.0.0         255.255.255.240 U     0      0        0 eth2
192.168.1.0     0.0.0.0         255.255.255.0   U     0      0        0 eth0
192.168.2.0     0.0.0.0         255.255.255.0   U     0      0        0 eth1
192.168.122.0   0.0.0.0         255.255.255.0   U     0      0        0 virbr0

Now, ignoring whatever the hell "virbr0" is, I have no idea what the "98.174.187.144" line is doing there, the default gateway line looks porked, and I have never see the default gateway listed FIRST before. Seeing as how DHCP did not come turned on by default, I can only guess what else I have to set up as well. I will try again tomorrow, but my best guess for the DHCP issue is that, despite the fact that the configuration page seems to indicate all is well, after reading the docs I probably still need to define a range of IP addresses to serve (after figuring out what a network object is and setting one up, of course). As for the routing issue I am REALLY guessing. My best guess is, even though the route command seems to indicate that there are routes for the internal networks, that I still need to add static routes in the Zentyal config. I still think I am going to be boned with the default gateway, so I am probably going to spend some quality time with the route command adjusting the routing table. Again, I am reaching the limit of my linux administration knowledge, and any help would be appreciated.

Escorpiom

  • Zen Hero
  • *****
  • Posts: 897
  • Karma: +25/-1
    • View Profile
Re: Network is unreachable
« Reply #1 on: June 18, 2012, 05:00:13 am »
We could get this solved sooner if you had included some important information, so now I have to go into "assume" mode.

Assuming your provider gave you a static IP address. Then yes, you will have to set that IP and the default gateway in Zentyal.
And no, no need to dig, just log into the admin interface (from the Zentyal box or another system in your network) and set the
default gateway for eth2 in Network > Gateways. It may be 98.174.187.1 but you better ask your provider.

If your provider is doing DHCP, then the default gateway will be configured automatically.

When the default gateway is configured correctly, you can get out to Internet.
DHCP is working fine, but you have to make sure that you define an available range. Reading the documentation can help you.

Cheers.
« Last Edit: June 18, 2012, 05:02:28 am by Escorpiom »
Marcus' Rule:
Blanks & capitals = avoid it and you'll avoid problems...

robb

  • Guest
Re: Network is unreachable
« Reply #2 on: June 18, 2012, 08:08:09 am »
DId you enable the modules you installed?

To get internet access from the LAN it is MANDATORY to mark (in your case) eth2 as external. If it is marked as internal packets to the internet will not be forwarded.
« Last Edit: June 18, 2012, 08:10:01 am by robb »

nontrivial

  • Zen Warrior
  • ***
  • Posts: 173
  • Karma: +14/-0
    • View Profile
Re: Network is unreachable
« Reply #3 on: June 18, 2012, 05:36:52 pm »
Whoops, sorry, I thought that it was obvious from my post that I had/needed a static connection. The reason why I was trying not to consult the docs was because it is very difficult to connect a mouse, keyboard, and monitor where my router is is mounted. Rather than have extremely important information in a separate place, why not have that information available from the administration tool? The help that IS there is on the order of "This is the Foozwah button. When you press the foozwah button, foozwah happens!", which isn't extremely useful. I think it would also be very helpful to enable the DHCP module (with sane, usable defaults) like the other critical modules when it is installed.

Anyway, after A) actually enabling the DHCP module and B) defining a range of IP addresses to serve, I can now put away my ladder an remotely administrate my router. I have no idea how the routing table is actually working, but it does appear to be working. Thank you for your help.

christian

  • Guest
Re: Network is unreachable
« Reply #4 on: June 18, 2012, 06:02:04 pm »
I wonder why people only look at "route" to get an idea of Zentyal routing features  ::)  Keep in mind to look at iptable too  ;) and most the time, once choice is made to use GUI (i.e. Zentyal here) rather than CLI, do not use CLI if there is no need and if you have very detailed understanding of what is configured and where. This might just confuse you further.

nontrivial

  • Zen Warrior
  • ***
  • Posts: 173
  • Karma: +14/-0
    • View Profile
Re: Network is unreachable
« Reply #5 on: June 19, 2012, 01:06:55 am »
Whoops, I spoke too soon about the routing, and I am back to using my linksys router again. I applied the updates and now it isn't working again. I rebooted several times, reinstalled twice, and it just doesn't work. After a reinstall routing works briefly, and then it doesn't. My internal networks are eth0 (192.168.1.0) and eth1 (192.168.2.0). Again, I have a ******EXTERNAL STATIC****** interface eth2, IP address is 98.174.187.147, netmask is 255.255.255.240, and gateway is 98.174.187.145. Again, Ubuntu 10.04 worked flawlessly and I am just about out of patience with Zentyal, and downloading the Ubuntu 12.04 server image even though I would prefer not to return to that tedium. There does not appear to be a default gateway defined, but supposedly that doesn't matter with Zentyal. Command outputs are attached. I have to use the -n option because, since routing isn't working, I can't get to a name server. Any help would be GREATLY appreciated, and pleae let me know if anybody has any ideas on how to fix this. I really haven't been able to evaluate Zentyal without basic routing working.

nontrivial

  • Zen Warrior
  • ***
  • Posts: 173
  • Karma: +14/-0
    • View Profile
Re: Network is unreachable
« Reply #6 on: June 19, 2012, 10:18:06 pm »
I posted this in another thread, but figured for completeness I should also post here. After adding a default gateway by hand ("route add default gw 98.174.187.145 eth2"), network routing started working as expected. The kicker is, that temporary solution seems to have permanently fixed the problem. After several configuration changes and reboots I have not had another routing issue. It doesn't exactly give me a warm fuzzy, though, which is why I disagree with christian. It's all well and good to have a magic black box to solve your problems right up until the magic stops working, and then you are completely boned. Which is why I prefer to understand how something I depend on for my livelihood works. But I have moved on to other issues now, at least unless or until network routing becomes an issue again.

The good news is that, other than some errors I tend to run into (dutifully reported to the big cloud in the sky), I am really starting to like Zentyal.

doncamilo

  • Zen Warrior
  • ***
  • Posts: 158
  • Karma: +27/-0
    • View Profile
Re: Network is unreachable
« Reply #7 on: August 22, 2019, 02:47:46 pm »
 :)

Hi!

This is a really old topic. Open a new one if you need help.

Cheers!