Bug 1645415 - authselect fails to replace authconfig
Summary: authselect fails to replace authconfig
Keywords:
Status: CLOSED NOTABUG
Alias: None
Product: Fedora
Classification: Fedora
Component: authselect
Version: 29
Hardware: Unspecified
OS: Unspecified
unspecified
unspecified
Target Milestone: ---
Assignee: Pavel Březina
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2018-11-02 07:56 UTC by Nikos Mavrogiannopoulos
Modified: 2018-11-26 11:28 UTC (History)
2 users (show)

Fixed In Version:
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Environment:
Last Closed: 2018-11-23 16:44:12 UTC
Type: Bug
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Red Hat Bugzilla 1577250 0 unspecified CLOSED systemd-libs modifies /etc/nsswitch.conf in scriptlets which conflicts with authselect on Fedora 28 2021-02-22 00:41:40 UTC

Internal Links: 1577250

Description Nikos Mavrogiannopoulos 2018-11-02 07:56:36 UTC
Description of problem:

The standard way to configure sssd with kerberos was:
```
authconfig --enablesssdauth --enablesssd --enablemkhomedir --update
```

The equivalent of authselect is:
```
authselect select sssd  with-mkhomedir
```

However it fails for two reasons:
1. oddjob-mkhomedir is not installed (should have been a Recommends of authselect)

2. It prints errors about /etc/nsswitch.conf not being a symbolic link
```
[error] [/etc/nsswitch.conf] is not a symbolic link!
[error] [/etc/nsswitch.conf] was not created by authselect!
Current configuration is not valid. It was probably modified outside authselect.
```

Comment 1 Pavel Březina 2018-11-02 09:40:06 UTC
This is not a regression but expected behavior.

1) About "[error] [/etc/nsswitch.conf] is not a symbolic link!"

This is expected as authselect will never touch configuration that was not generated by authselect. If you read the error further, you will know what to do:

[root /home/pbrezina]# authselect select sssd with-mkhomedir
[error] [/etc/nsswitch.conf] is not a symbolic link!
[error] [/etc/nsswitch.conf] was not created by authselect!
[error] Unexpected changes to the configuration were detected.
[error] Refusing to activate profile unless those changes are removed or overwrite is requested.

Some unexpected changes to the configuration were detected.
Use --force parameter if you want to overwrite these changes.

2) About "oddjob-mkhomedir is not installed (should have been a Recommends of authselect)"

Authselect is really a generic tool and as such it can not require any package needed by profiles -- customers does not want to have winbind installed if they are using sssd profile etc. But the spec file uses the weak dependency suggests to say what packages may be interesting to have:
Suggests: sssd
Suggests: samba-winbind
Suggests: fprintd-pam
Suggests: oddjob-mkhomedir

[pbrezina ~]$ sudo authselect select sssd  with-mkhomedir
Profile "sssd" was selected.
The following nsswitch maps are overwritten by the profile:
- passwd
- group
- netgroup
- automount
- services

Make sure that SSSD service is configured and enabled. See SSSD documentation for more information.
 
- with-mkhomedir is selected, make sure oddjobd service is enabled
  - systemctl enable oddjobd.service
  - systemctl start oddjobd.service

This part we can improve to also tell the administrator to install pam_oddjob_mkhomedir module is installed.


Note You need to log in before you can comment on or make changes to this bug.