SUSE Support

Here When You Need Us

systemd service unit incorrectly reported as masked

This document (7022685) is provided subject to the disclaimer at the end of this document.

Environment

SUSE Linux Enterprise Server 12 Service Pack 1 (SLES 12 SP1)
SUSE Linux Enterprise Server 12 Service Pack 2 (SLES 12 SP2)
SUSE Linux Enterprise Server 12 Service Pack 3 (SLES 12 SP3)

Situation

Checking the status of a service shows it is masked.

Running systemctl unmask <unit file> doesn't change the status.


Resolution

The systemd unit file is empty.  Replace it in /usr/lib/systemd/system by reinstalling the package in which the unit file was contained.

Reload the systemd configuration file with systemctl daemon-reload after the unit file is replaced.

Cause


Additional Information

Masking a systemd unit is used to prevent the unit from starting.

When a mask is set on a unit, a symbolic link with the name of that unit is created in the /etc/systemd/system directory which points to /dev/null

Systemd unit files in /etc/systemd/system override vendor-supplied unit files in /usr/lib/systemd/system, so attempting to start a masked unit will do nothing.

Disclaimer

This Support Knowledgebase provides a valuable tool for SUSE customers and parties interested in our products and solutions to acquire information, ideas and learn from one another. Materials are provided for informational, personal or non-commercial use within your organization and are presented "AS IS" WITHOUT WARRANTY OF ANY KIND.

  • Document ID:7022685
  • Creation Date: 23-Feb-2018
  • Modified Date:03-Mar-2020
    • SUSE Linux Enterprise Server

< Back to Support Search

For questions or concerns with the SUSE Knowledgebase please contact: tidfeedback[at]suse.com

SUSE Support Forums

Get your questions answered by experienced Sys Ops or interact with other SUSE community experts.

Support Resources

Learn how to get the most from the technical support you receive with your SUSE Subscription, Premium Support, Academic Program, or Partner Program.

Open an Incident

Open an incident with SUSE Technical Support, manage your subscriptions, download patches, or manage user access.