SUSE Support

Here When You Need Us

"polkit.service" encounter "Permission denied" error when trying to open its authorization rules directories

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

Environment

SUSE Linux Enterprise Server 15 all SP

Situation

The status of the "polkit.service" shows the following "Permission denied" error messages:
# systemctl status polkit.service
...
...... myserver polkitd[31845]: Loading rules from directory /etc/polkit-1/rules.d
...... myserver polkitd[31845]: Error opening rules directory: Error opening directory “/etc/polkit-1/rules.d”: Permission denied (g-file-error-quark, 2)
...... myserver polkitd[31845]: Loading rules from directory /usr/share/polkit-1/rules.d
...... myserver polkitd[31845]: Error opening rules directory: Error opening directory “/usr/share/polkit-1/rules.d”: Permission denied (g-file-error-quark, 2)
Due to this error, some Application services may fail to start if they are managed by the polkit rules.

Resolution

1. Check the "user" and "group" ownership setting for the following 2 polkit authorization rules directories.
     ls -ld /etc/polkit-1/rules.d/
     ls -ld /usr/share/polkit-1/rules.d/


2. The correct "user" and "group" ownership setting for the directories should be "polkitd" and "root" respectively.
   If the ownership setting for the directories are different, make the necessary correction:
     chown polkitd:root /etc/polkit-1/rules.d
     chown polkitd:root /usr/share/polkit-1/rules.d


3. Restart the "polkit.service" with the following commands:
     systemctl restart polkit.service

4. Check the status of the "polkit.service":
     systemctl status polkit.service

   The "Permission denied" errors should not be shown anymore.

Cause

For an unknown reason, the ownership setting for the 2 polkit authorization rules directories are set incorrectly.

Additional Information

The following is an example of the correct ownership setting for the 2 polkit authorization rules directories:
  # ls -ld /etc/polkit-1/rules.d/
  drwx------ 1 polkitd root 76 Jul 31 19:23 /etc/polkit-1/rules.d

  # ls -ld /usr/share/polkit-1/rules.d/
  drwx------ 1 polkitd root 106 Jul 31 19:08 /usr/share/polkit-1/rules.d/
Newer versions of SAP services which are integrated to systemd in SUSE Linux Enterprise Server 15 may be affected by this issue and cannot be started.
Refer to SAP Note 3369963 - Linux: Instance startup fails with 'Interactive authentication required'

 

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:000021187
  • Creation Date: 30-Aug-2023
  • Modified Date:30-Aug-2023
    • SUSE Linux Enterprise Server

< Back to Support Search

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

tick icon

SUSE Support Forums

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

tick icon

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.

tick icon

Open an Incident

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