1

Ubuntu v. 16 Hosting digitalocean

I customize Sendmail for project(ruby, Sinatra) like in this article. http://www.travisluong.com/ruby-on-rails-sending-email-with-sendmail-on-ubuntu-vps/

I want to reload /etc/hosts

I call /etc/init.d/networking stop, next call /etc/init.d/networking start and get error - Starting networking (via systemctl): networking.serviceJob for networking.service failed because the control process exited with error code. See "systemctl status networking.service" and "journalctl -xe" for details. failed!

etc/host

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

Status networking

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)

I am beginner in administration linux server, please help.

0

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.