Question 330
What should an administrator do first when the following occurs: A network daemon is not required but systemd starts it through socket activation after service disable?
Explanation
Correct Answer
The safest fitting response is Disable the unnecessary systemd socket unit as well as the associated service where appropriate. This works because Socket activation can launch a service even if its service unit is otherwise inactive. Validate it by showing The unused listening socket disappears and the service remains unavailable after reboot.
Incorrect Answers
This command or configuration addresses a different case: A fresh server boots with an unapproved web service that nobody uses. Here, Socket activation can launch a service even if its service unit is otherwise inactive, so the targeted action is Disable the unnecessary systemd socket unit as well as the associated service where appropriate.
This command or configuration addresses a different case: A host still exposes Telnet but policy allows only encrypted remote administration. Here, Socket activation can launch a service even if its service unit is otherwise inactive, so the targeted action is Disable the unnecessary systemd socket unit as well as the associated service where appropriate.
Although that change may be valid elsewhere, it responds to A process consumes too much address space and a shell session needs a temporary limit, not to this system state. The relevant fix is Disable the unnecessary systemd socket unit as well as the associated service where appropriate.