Problems setting uo a modem/router server.

Issues related to configuring your network
Post Reply
wp.rauchholz
Posts: 132
Joined: 2016/11/20 11:58:45

Problems setting uo a modem/router server.

Post by wp.rauchholz » 2021/01/18 18:38:19

Trying to setup me box as modem/router with iptables and network-scripts
The server has two NICs: LAN=enp3s0 / WAN = ep5s0/ppp0
Package forwarding is set: net.ipv4.ip_forward = 1
Firewall is up and running:
…..
###############################################################
### OUTBOUND Rule: Allow ALL packets out the external device
iptables -A OUTPUT -o $EXT_DEV -j ACCEPT
iptables -A FORWARD -i $INT_DEV -o $EXT_DEV -j ACCEPT

###############################################################
### MASQUERADING: All packets from the internal network will appear as if they had originated from the firewall.
iptables -t nat -A POSTROUTING -o $EXT_DEV -s $INT_NET -j MASQUERADE
…..
I ran pppoe-setup top configure interface to my ISP.

DNS server from my ISP are set correctly:
more /etc/resolv.conf
# MADE-BY-RP-PPPOE
nameserver 80.58.61.250
nameserver 80.58.61.254

When booting the computer the network start fails.
Systemctl status network gives me:

Active: failed

...Bringing up interface enp3s0: [ OK ]
...Bringing up interface enp5s0: [ OK ]
...Bringing up interface ppp0: ERROR : [/etc/sysconfig/network-scripts/ifup-eth] Device ppp0 does not seem to be present, delaying initialization.
...home.wo-lar.com network[945]: [FAILED]
… home.wo-lar.com systemd[1]: network.service: Control process exited, code=exited status=1


When on CLI I can start ppp0 manually with pppoe-start and after that the network with systemctl start network. I have access to internet and can run dig, dnf install. All working.
This is what I find in varlog/messages:
pppd[5666]: pppd 2.4.7 started by wp.rauchholz, uid 0
pppd[5666]: Using interface ppp0
pppd[5666]: Connect: ppp0 <--> /dev/pts/1
systemd-udevd[5668]: link_config: autonegotiation is unset or enabled, the speed and duplex are not writable.
pppoe[5667]: PPP session is 1063 (0x427)
pppd[5666]: CHAP authentication succeeded
pppd[5666]: CHAP authentication succeeded
kernel: PPP BSD Compression module registered
pppd[5666]: local IP address 88.1.251.17
pppd[5666]: remote IP address 192.168.144.1
home systemd[5561]: Starting Mark boot as successful...
home systemd[5561]: grub-boot-success.service: Succeeded.
systemd[5561]: Started Mark boot as successful.
systemd[1]: Starting LSB: Bring up/down networking...
home network[5725]: Bringing up loopback interface: [ OK ]
home network[5725]: Bringing up interface enp3s0: [ OK ]
home network[5725]: Bringing up interface enp5s0: [ OK ]
home network[5725]: Bringing up interface ppp0: [ OK ]
home network[5725]: RTNETLINK answers: File exists


I also have no access from the LAN to internet.
From my laptop I tried this:
(1)traceroute google.com
google.com: Name or service not known
Cannot handle "host" cmdline arg `google.com' on position 1 (argc 1)
(2) traceroute 8.8.8.8
traceroute to 8.8.8.8 (8.8.8.8), 30 hops max, 60 byte packets

Why does Centos does not start ppp0 at startup and claims ppp0 is not present?
What am I missing to get internet access from my LAN?

Thanks a lot for your help.

User avatar
jlehtone
Posts: 3335
Joined: 2007/12/11 08:17:33
Location: Finland

Re: Problems setting uo a modem/router server.

Post by jlehtone » 2021/01/19 15:05:55

I have no experience with "modems".

Although more about NM, it seems that there is "ModemManager" (pppd?) that is creating the "ppp0" in the first place:
https://superuser.com/questions/1043141 ... ager-nmcli

RHEL docs seem less verbose:
https://access.redhat.com/documentation ... t_settings

Post Reply

Return to “CentOS 7 - Networking Support”