/etc/init.d/networking start - 控制进程因错误代码退出。请参阅“systemctl status networking.service”

/etc/init.d/networking start - 控制进程因错误代码退出。请参阅“systemctl status networking.service”

Ubuntu v. 16 托管 digitalocean

我按照本文所述为项目(ruby、Sinatra)定制了 Sendmail。http://www.travisluong.com/ruby-on-rails-sending-email-with-sendmail-on-ubuntu-vps/

我想重新加载 /etc/hosts

我调用 /etc/init.d/networking stop,下次调用 /etc/init.d/networking start并收到错误 -启动网络(通过 systemctl):networking.servicenetworking.service 的作业失败,因为控制进程退出并显示错误代码。有关详细信息,请参阅“systemctl status networking.service”和“journalctl -xe”。失败!

等/主机

127.0.0.1 localhost MY-WEB-SERVER

# The following lines are desirable for IPv6 capable hosts
::1 ip6-localhost ip6-loopback
fe00::0 ip6-localnet
ff00::0 ip6-mcastprefix
ff02::1 ip6-allnodes
ff02::2 ip6-allrouters
ff02::3 ip6-allhosts

状态联网

systemctl status networking.service
● networking.service - Raise network interfaces
   Loaded: loaded (/lib/systemd/system/networking.service; enabled; vendor preset: enabled)
  Drop-In: /run/systemd/generator/networking.service.d
           └─50-insserv.conf-$network.conf
   Active: failed (Result: exit-code) since Mon 2016-12-19 11:39:44 UTC; 25min ago
     Docs: man:interfaces(5)
  Process: 2587 ExecStop=/sbin/ifdown -a --read-environment (code=exited, status=0/SUCCESS)
  Process: 10746 ExecStart=/sbin/ifup -a --read-environment (code=exited, status=1/FAILURE)
  Process: 10741 ExecStartPre=/bin/sh -c [ "$CONFIGURE_INTERFACES" != "no" ] && [ -n "$(ifquery --read-environment --list --exclude=lo)" ] && ud
 Main PID: 10746 (code=exited, status=1/FAILURE)

sudo journalctl-xe

Unit networking.service has begun starting up.
Dec 19 12:49:18 sudoku-spielen ifup[13363]: run-parts: failed to exec /etc/network/if-up.d/00-iptables: Exec format error
Dec 19 12:49:18 sudoku-spielen ifup[13363]: run-parts: /etc/network/if-up.d/00-iptables exited with return code 1
Dec 19 12:49:18 sudoku-spielen ifup[13363]: Failed to bring up lo.
Dec 19 12:49:18 sudoku-spielen ifup[13363]: RTNETLINK answers: File exists
Dec 19 12:49:18 sudoku-spielen ifup[13363]: Failed to bring up eth0.
Dec 19 12:49:18 sudoku-spielen ifup[13363]: RTNETLINK answers: File exists
Dec 19 12:49:18 sudoku-spielen ifup[13363]: Failed to bring up eth0:1.
Dec 19 12:49:18 sudoku-spielen ifup[13363]: run-parts: failed to exec /etc/network/if-up.d/00-iptables: Exec format error
Dec 19 12:49:18 sudoku-spielen ifup[13363]: run-parts: /etc/network/if-up.d/00-iptables exited with return code 1
Dec 19 12:49:18 sudoku-spielen ifup[13363]: /sbin/ifup: post-up script failed.
Dec 19 12:49:18 sudoku-spielen systemd[1]: networking.service: Main process exited, code=exited, status=1/FAILURE
Dec 19 12:49:18 sudoku-spielen systemd[1]: Failed to start Raise network interfaces.
-- Subject: Unit networking.service has failed
-- Defined-By: systemd
-- Support: http://lists.freedesktop.org/mailman/listinfo/systemd-devel
-- 
-- Unit networking.service has failed.
-- 
-- The result is failed.
Dec 19 12:49:18 sudoku-spielen systemd[1]: networking.service: Unit entered failed state.
Dec 19 12:49:18 sudoku-spielen systemd[1]: networking.service: Failed with result 'exit-code'.
Dec 19 12:49:18 sudoku-spielen sudo[13344]: pam_unix(sudo:session): session closed for user root
Dec 19 12:49:25 sudoku-spielen sudo[13424]:   deploy : TTY=pts/0 ; PWD=/home/deploy ; USER=root ; COMMAND=/bin/journalctl -xe
Dec 19 12:49:25 sudoku-spielen sudo[13424]: pam_unix(sudo:session): session opened for user root by deploy(uid=0)

我是 Linux 服务器管理的新手,请帮忙。

相关内容