2

I have a problem with the Internet connection on my Server. I cannot use Filezilla or Webmin because my systemd-networkd.socket seems to be buggy or something. Can you help me? This is my output:

$ systemctl

systemd-networkd.socket loaded failed failed

$ systemctl status systemd-networkd.socket

Loaded: loaded (/lib/systemd/system/systemd-networkd.socket; enabled; vendor preset: enabled)

Active: failed (Result: service-start-limt-hit)

Also, I get the message:

Jan 20 16:34:21 exampleserver systemd[1]:systemd-networkd.socket: Socket service systemd-networkd.service already active, refusing.

Failed to listen on Network Service Netlink Socket

2 Answers 2

1

On ubuntu 20.04, you can open the application systemd-manager. Then click on the Services button in top bar, a drop-down will open. You will need to select the option 'Sockets'. Left panel will show list of socket services, there you can find the service name as 'systemd-networkd'. Against that service, there must be two green tick marks. If not, then select that service and click on 'enable' button in top bar and then click on 'Start' button (green button) to start the service. This will make the two green ticks against that service in left panel.

enter image description here

0

When i type the command sudo systemctl status systemd-networkd.socket i have an error:

systemd-networkd.socket: Socket service systemd-networkd.service already active, refusing.
systemd[1]: Failed to listen on Network Service Netlink Socket.
Warning: Journal has been rotated since unit was started. Log output is incomplete or unavailable.

We need to find a workaround so as not to use ioctl, ifconfig, route, but choose netlink/rtnetlink for communication between the userspace and the Linux kernel. Netlink allows you to test a large number of kernel subsystems - interfaces, routing, network packet filter.

  • If your are at a dead end and do not know what mistakes there are, then fix first your need to find out: what your are using network-manager or systemd-networkd?

  • Rtnetlink has some difficulty to work with the root directory so, how it is currently being used. It is easier to use for a nearby car, so that your do not stumble on it once again and your have no questions.

  • In Linux 2.2, an interface can have multiple IP addresses; they are alternative device aliases.

  • Rtnetlink consists of the message types in addition to the standards netlink messages RTM_ in return NETLINK_.

For use rtnetlink your need to install:

sudo apt install socket

Used socket with rtnetlink, commands for example:

  • sudo socket -p RTM_GETTCLASS -p network-manager -s | host localhost

output:

localhost has address 127.0.0.1
localhost has IPv6 address ::1
  • sudo socket -p RTM_GETTCLASS -p network-manager -s | host -aCdilrTvVw | /

output:

host 9.11.3-1ubuntu1.15-Ubuntu

Manual:

https://man7.org/linux/man-pages/man7/rtnetlink.7.html

https://man7.org/linux/man-pages/man7/netlink.7.html

rtnetlink, NETLINK_ROUTE - Linux IPv4 routing socket.

RTM_NEWLINK, RTM_DELLINK, RTM_GETLINK - create, delete or get information about specific network interface.
RTM_NEWADDR, RTM_DELADDR, RTM_GETADDR - add, remove or get address information, the IP associated with the interface.
RTM_NEWROUTE, RTM_DELROUTE, RTM_GETROUTE - create, delete, or get information about a network route.
RTM_NEWNEIGH, RTM_DELNEIGH, RTM_GETNEIGH - add, remove or get information about a record, made by a neighboring machine (for example, an ARP entry).
RTM_NEWRULE, RTM_DELRULE, RTM_GETRULE - add, remove or get a rule routing.
RTM_NEWQDISC, RTM_DELQDISC, RTM_GETQDISC - add, remove or get a shipping method package to the queue.
RTM_NEWTCLASS, RTM_DELTCLASS, RTM_GETTCLASS - add, remove or get traffic class. 
RTM_NEWTFILTER, RTM_DELTFILTER, RTM_GETTFILTER - add, remove or get information about a filter traffic.
RTMGRP_LINK - this group receives notifications about changes in network interfaces (interface was removed, added, down, up)
RTMGRP_IPV4_IFADDR - this group receives notifications about changes in IPv4 interface addresses (the address has been added or removed)
RTMGRP_IPV6_IFADDR - this group receives notifications about changes in IPv6 interface addresses (the address has been added or removed)
RTMGRP_IPV4_ROUTE - this group receives notification of changes in the routing table for IPv4 addresses
RTMGRP_IPV6_ROUTE - this group receives notification of changes in the routing table for IPv6 addresses 
NETLINK_ROUTE - receive notifications about changes to the routing table and network interfaces, can also be used to change all the parameters of the above objects.
NETLINK_USERSOCK - reserved for defining custom protocols.
NETLINK_FIREWALL - used to transfer IPv4 packets from the network filter to the user level
NETLINK_INET_DIAG - monitoring inet sockets
NETLINK_NFLOG - network/packet filter ULOG
NETLINK_SELINUX - receive notifications from the Selinux system
NETLINK_NETFILTER - working with the network filter subsystem
NETLINK_KOBJECT_UEVENT - receive kernel messages

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.