Re: systemd network configuration

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]



On Thu, Jul 26, 2012 at 5:05 AM, David Benfell
<benfell@xxxxxxxxxxxxxxxxx> wrote:
> I have no evidence that it actually runs. If nothing else, I would
> expect a pause, while it works its way through all those "sleep 1"
> statements even if everything succeeds on the first try. And my
> understanding is that none of my network daemons should try to start
> until the network is up (but they do, and many fail). Here is the
> service file:
>
> [Unit]
> Description=My utterly non-standard network setup
> Before=network.target
> Wants=network.target
>
> [Service]
> Type=oneshot
> ExecStart=/etc/rc.local-network
>
> [Install]
> WantedBy=multi-user.target
>
> I have tried placing it in both /etc/systemd/system and
> /etc/systemd/multi-user.target.wants (the latter being where a bunch
> of other service files wound up). But every time, when I boot the
> system and log into the console and try "ip link show", it tells me
> that eth0 is down.

The standard thing is to place it in /etc/systemd/system. However,
this will not start it on next boot. For that you should "systemctl
enable nonstandard-network.service" (which will create a symlink in
multi-user.target.wants). To test it, you can do "systemctl start
nonstandard-network.service". To see get some info about what happened
do (as root) "systemctl status nonstandard-network.service". Notice
that anything your service prints to standard out or syslog ends up in
the journal, and the last bits of it is shown by systemctl status (for
more do "journalctl").

Cheers,

Tom


[Index of Archives]     [Linux Wireless]     [Linux Kernel]     [ATH6KL]     [Linux Bluetooth]     [Linux Netdev]     [Kernel Newbies]     [Share Photos]     [IDE]     [Security]     [Git]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux ATA RAID]     [Samba]     [Device Mapper]
  Powered by Linux