Scheduled Maintenance: We are aware of an issue with Google, AOL, and Yahoo services as email providers which are blocking new registrations. We are trying to fix the issue and we have several internal and external support tickets in process to resolve the issue. Please see: viewtopic.php?t=158230

 

 

 

[Solved] Failed to start raise network interfaces

Linux Kernel, Network, and Services configuration.
Post Reply
Message
Author
Lamios
Posts: 37
Joined: 2017-12-09 23:26

[Solved] Failed to start raise network interfaces

#1 Post by Lamios »

Hello,

when I start Debian I get an error message saying the following:

Code: Select all

[Failed] Failed to start Raise network interfaces.
See 'systemctl status networking.service' for details.
systemctl status networking.service gives me the following:

Code: Select all

● networking.service - Raise network interfaces
   Loaded: loaded (/lib/systemd/system/networking.service; enabled; vendor preset: en
   Active: failed (Result: exit-code) since Sat 2017-12-09 12:49:24 GMT; 11h ago
     Docs: man:interfaces(5)
 Main PID: 2043 (code=exited, status=1/FAILURE)
lines 1-5/5 (END)
ifconfig -a lists the following devices:
- enp0s25
- lo
- vpn0
- wlp2s0

The network had been configured automatically with DHCP during the installation...

I am still able to connect to the internet, also if I sometimes have to reboot, because I get the massage that the connection had been deactivated.

The system (Debian 9 with KDE) is newly installed and the problem existed from beginning. The results from google and forum searches did not fit to my error message (at least as far as I can asses it as a Linux beginner).

Thank you for your help!
Lamios

P.S.: I hope the post is complete for the beginning. I am not sure in the moment, which additional output is going to be needed.
Last edited by Lamios on 2017-12-11 15:48, edited 1 time in total.

User avatar
Head_on_a_Stick
Posts: 14114
Joined: 2014-06-01 17:46
Location: London, England
Has thanked: 81 times
Been thanked: 133 times

Re: Failed to start raise network interfaces

#2 Post by Head_on_a_Stick »

Hello :)
Lamios wrote:

Code: Select all

 Main PID: 2043 (code=exited, status=1/FAILURE)
lines 1-5/5 (END)
We can check those lines with:

Code: Select all

systemctl cat networking.service
The journal contents will probably tell us more:

Code: Select all

# journalctl -u networking.service
deadbang

p.H
Global Moderator
Global Moderator
Posts: 3049
Joined: 2017-09-17 07:12
Has thanked: 5 times
Been thanked: 132 times

Re: Failed to start raise network interfaces

#3 Post by p.H »

Also please post the contents of /etc/network/interfaces which is the configuration file of the networking service.

Lamios
Posts: 37
Joined: 2017-12-09 23:26

Re: Failed to start raise network interfaces

#4 Post by Lamios »

Thank you for the very fast reply!

systemctl cat networking.service:

Code: Select all

# /lib/systemd/system/networking.service
[Unit]
Description=Raise network interfaces
Documentation=man:interfaces(5)
DefaultDependencies=no
Wants=network.target
After=local-fs.target network-pre.target apparmor.service systemd-sysctl.service syst
Before=network.target shutdown.target network-online.target
Conflicts=shutdown.target

[Install]
WantedBy=multi-user.target
WantedBy=network-online.target

[Service]
Type=oneshot
EnvironmentFile=-/etc/default/networking
ExecStartPre=-/bin/sh -c '[ "$CONFIGURE_INTERFACES" != "no" ] && [ -n "$(ifquery --re
ExecStart=/sbin/ifup -a --read-environment
ExecStop=/sbin/ifdown -a --read-environment --exclude=lo
RemainAfterExit=true
TimeoutStartSec=5min
lines 1-22/22 (END)
journalctl -u networking.service:

Code: Select all

-- Logs begin at Sun 2017-12-10 12:00:15 GMT, end at Sun 2017-12-10 12:07:46 GMT. --
Dec 10 12:00:16 PP systemd[1]: Starting Raise network interfaces...
Dec 10 12:00:16 PP ifup[334]: /etc/network/if-pre-up.d/firewall_renamed: 2: /etc/netw
Dec 10 12:00:16 PP ifup[334]: run-parts: /etc/network/if-pre-up.d/firewall_renamed ex
Dec 10 12:00:16 PP ifup[334]: ifup: pre-up script failed
Dec 10 12:00:16 PP systemd[1]: networking.service: Main process exited, code=exited, 
Dec 10 12:00:16 PP systemd[1]: Failed to start Raise network interfaces.
Dec 10 12:00:16 PP systemd[1]: networking.service: Unit entered failed state.
Dec 10 12:00:16 PP systemd[1]: networking.service: Failed with result 'exit-code'.
Dec 10 12:00:17 PP systemd[1]: Starting Raise network interfaces...
Dec 10 12:00:17 PP ifup[594]: /etc/network/if-pre-up.d/firewall_renamed: 2: /etc/netw
Dec 10 12:00:17 PP ifup[594]: run-parts: /etc/network/if-pre-up.d/firewall_renamed ex
Dec 10 12:00:17 PP ifup[594]: ifup: pre-up script failed
Dec 10 12:00:17 PP systemd[1]: networking.service: Main process exited, code=exited, 
Dec 10 12:00:17 PP systemd[1]: Failed to start Raise network interfaces.
Dec 10 12:00:17 PP systemd[1]: networking.service: Unit entered failed state.
Dec 10 12:00:17 PP systemd[1]: networking.service: Failed with result 'exit-code'.
lines 1-17/17 (END)
The loopback network interface contain the following:

Code: Select all

auto lo
iface lo inet loopback
I think I probably see the error in 'journalctl -u networking.service'. I tried to setup a firewall with iptables but than thought it might be easier to use a firewall tool (at least for the beginning). To prevent an interference between the firewall tool and the existing iptables rules I renamed '/etc/iptables.firewall.rules', '/etc/network/if-pre-up.d/firewall' and '/etc/network/if-pre-up.d/firewall.save' with the addition "_renamed". Is it possible that the .save had not been created by me earlier and is now causing the problem? Or is it because all these files are only renamed and not deleted?

p.H
Global Moderator
Global Moderator
Posts: 3049
Joined: 2017-09-17 07:12
Has thanked: 5 times
Been thanked: 132 times

Re: Failed to start raise network interfaces

#5 Post by p.H »

The lines you posted are truncated.

Scripts in /etc/network/if-*.d/ are run by run-parts. By default run-parts executes all scripts with names containing only letters, digits, underscore and hyphen [A-Za-z0-9_-]. So /etc/network/if-pre-up.d/firewall is executed, but /etc/network/if-pre-up.d/firewall.save is not because its name contains a dot, not in the allowed character list.

Renaming /etc/network/if-pre-up.d/firewall by adding _renamed does not disable its execution by run-parts because all characters of the suffix are allowed. However if an instruction in the script uses an other file such as /etc/iptables.firewall.rules and you renamed that file without updating the script, then an error may arise. Check in /etc/network/if-pre-up.d/firewall_renamed.

Also note that just renaming the script and not disabling it does not prevent interference with another firewall script.

User avatar
Head_on_a_Stick
Posts: 14114
Joined: 2014-06-01 17:46
Location: London, England
Has thanked: 81 times
Been thanked: 133 times

Re: Failed to start raise network interfaces

#6 Post by Head_on_a_Stick »

p.H wrote:The lines you posted are truncated.
Sorry, my fault! :oops:

@OP:

Code: Select all

# journalctl -u networking.service --no-pager
deadbang

Lamios
Posts: 37
Joined: 2017-12-09 23:26

Re: Failed to start raise network interfaces

#7 Post by Lamios »

'journalctl -u networking.service --no-pager' geave me the following output:

Code: Select all

-- Logs begin at Sun 2017-12-10 22:41:52 GMT, end at Sun 2017-12-10 22:46:26 GMT. --
Dec 10 22:41:53 PP systemd[1]: Starting Raise network interfaces...
Dec 10 22:41:53 PP ifup[313]: /etc/network/if-pre-up.d/firewall_renamed: 2: /etc/network/if-pre-up.d/firewall_renamed: cannot open /etc/iptables.firewall.rules: No such file
Dec 10 22:41:53 PP ifup[313]: run-parts: /etc/network/if-pre-up.d/firewall_renamed exited with return code 2
Dec 10 22:41:53 PP ifup[313]: ifup: pre-up script failed
Dec 10 22:41:53 PP systemd[1]: networking.service: Main process exited, code=exited, status=1/FAILURE
Dec 10 22:41:53 PP systemd[1]: Failed to start Raise network interfaces.
Dec 10 22:41:53 PP systemd[1]: networking.service: Unit entered failed state.
Dec 10 22:41:53 PP systemd[1]: networking.service: Failed with result 'exit-code'.
Dec 10 22:42:18 PP systemd[1]: Starting Raise network interfaces...
Dec 10 22:42:18 PP ifup[1530]: /etc/network/if-pre-up.d/firewall_renamed: 2: /etc/network/if-pre-up.d/firewall_renamed: cannot open /etc/iptables.firewall.rules: No such file
Dec 10 22:42:18 PP ifup[1530]: run-parts: /etc/network/if-pre-up.d/firewall_renamed exited with return code 2
Dec 10 22:42:18 PP systemd[1]: networking.service: Main process exited, code=exited, status=1/FAILURE
Dec 10 22:42:18 PP ifup[1530]: ifup: pre-up script failed
Dec 10 22:42:18 PP systemd[1]: Failed to start Raise network interfaces.
Dec 10 22:42:18 PP systemd[1]: networking.service: Unit entered failed state.
Dec 10 22:42:18 PP systemd[1]: networking.service: Failed with result 'exit-code'.
I did not update the script in '/etc/network/if-pre-up.d/', thus that should be the reason. How can I disable the script?
In '/etc/network/if-pre-up.d/' is also file called firewall.save (or now firewall_renamed.save), which I assumed the system created it to run the firewall rules I created. Is that true or is it there for any other reason?

p.H
Global Moderator
Global Moderator
Posts: 3049
Joined: 2017-09-17 07:12
Has thanked: 5 times
Been thanked: 132 times

Re: Failed to start raise network interfaces

#8 Post by p.H »

Lamios wrote:How can I disable the script?
(Re)move it, or rename it with a period (".") in the new name so that run-parts ignores it.
Lamios wrote:In '/etc/network/if-pre-up.d/' is also file called firewall.save (or now firewall_renamed.save), which I assumed the system created it to run the firewall rules I created. Is that true or is it there for any other reason?
"The system" does not create such files on its own. Maybe your text editor did as a backup when you modified the original "firewall" file ?
Anyway its filename contains a period, thus is ignored by run-parts and not executed.

Lamios
Posts: 37
Joined: 2017-12-09 23:26

Re: Failed to start raise network interfaces

#9 Post by Lamios »

Cool, works again in the correct way :)
Thank you for your help!

Lamios
Posts: 37
Joined: 2017-12-09 23:26

Re: Failed to start raise network interfaces

#10 Post by Lamios »

How can I mark the topic as solved? :D

User avatar
GarryRicketson
Posts: 5644
Joined: 2015-01-20 22:16
Location: Durango, Mexico

Re: Failed to start raise network interfaces

#11 Post by GarryRicketson »

You edit the subject line on your first post

Lamios
Posts: 37
Joined: 2017-12-09 23:26

Re: [Solved] Failed to start raise network interfaces

#12 Post by Lamios »

Thanks.

Post Reply