[systemd-devel] howto systemd restart one network device

J Decker d3ck0r at gmail.com
Wed Mar 2 00:23:23 UTC 2016


yes restart repeatedly does the same thing and doesn't work....



On Tue, Mar 1, 2016 at 10:49 AM, Kai Krakow <hurikhan77 at gmail.com> wrote:
> Am Mon, 29 Feb 2016 22:59:17 -0800
> schrieb J Decker <d3ck0r at gmail.com>:
>
>> well that was the search....
>>
>> after everything is up how do I restart a single device so it will
>> work in the meantime...
>
> I usually do "systemctl restart systemd-networkd" which probably
> restarts all devices. This worked for me all the time.
>
> Maybe something like:
>
> $ systemctl restart sys-subsystem-net-devices-enp5s0.device
>                                               ^^^^^^
>                                         put your device here
>
> Found by "systemctl | fgrep enp"
>
> However, "systemctl show ..." indicates it doesn't support doing that.
>


 fgrep he   // he is in 'ethernet' but he-tunnel is the .netdev I want to start
[code]
  sys-devices-pci0000:00-0000:00:19.0-net-eno1.device
                     loaded active plugged   Ethernet Connection
I217-LM
  sys-subsystem-net-devices-eno1.device
                     loaded active plugged   Ethernet Connection
I217-LM
  httpd.service
                     loaded active running   Apache Web Server
  kmod-static-nodes.service
                     loaded active exited    Create list of required
static device nodes for the current kernel
  systemd-fsck at dev-disk-by\x2duuid-50a189be\x2d1ec4\x2d4efc\x2db575\x2d7396e7923413.service
loaded active exited    File System Check on
/dev/disk/by-uuid/50a189be-1ec4-4efc-b575-7396e7923413
  systemd-fsck at dev-disk-by\x2duuid-d55e3257\x2d76bb\x2d49a5\x2da9ff\x2d076b0559369e.service
loaded active exited    File System Check on
/dev/disk/by-uuid/d55e3257-76bb-49a5-a9ff-076b0559369e
  systemd-fsck at dev-disk-by\x2duuid-fec23492\x2d4be8\x2d4c03\x2d9349\x2d9ee06ab2c5ff.service
loaded active exited    File System Check on
/dev/disk/by-uuid/fec23492-4be8-4c03-9349-9ee06ab2c5ff
  man-db.timer
                     loaded active waiting   Daily man-db cache update
LOAD   = Reflects whether the unit definition was properly loaded.
ACTIVE = The high-level unit activation state, i.e. generalization of SUB.
SUB    = The low-level unit activation state, values depend on unit type.

[/code]


and just blindly trying it...

systemctl restart sys-subsystem-net-devices-he-tunnel.netdev
Failed to restart sys-subsystem-net-devices-he-tunnel.netdev.service:
Unit sys-subsystem-net-devices-he-tunnel.netdev.service not found.



> --
> Regards,
> Kai
>
> Replies to list-only preferred.
>
> _______________________________________________
> systemd-devel mailing list
> systemd-devel at lists.freedesktop.org
> https://lists.freedesktop.org/mailman/listinfo/systemd-devel


More information about the systemd-devel mailing list