Bug 1542400 - Removing task whose target is dnssec-trigger fails to remove dnssec-trigger itself.
Summary: Removing task whose target is dnssec-trigger fails to remove dnssec-trigger i...
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Fedora
Classification: Fedora
Component: dnssec-trigger
Version: 27
Hardware: x86_64
OS: Linux
unspecified
medium
Target Milestone: ---
Assignee: Tomáš Hozza
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2018-02-06 09:47 UTC by ricky.tigg
Modified: 2018-03-06 17:28 UTC (History)
5 users (show)

Fixed In Version: dnssec-trigger-0.15-4.fc27 dnssec-trigger-0.15-4.fc26
Clone Of:
Environment:
Last Closed: 2018-03-06 17:20:53 UTC
Type: Bug
Embargoed:


Attachments (Terms of Use)

Description ricky.tigg 2018-02-06 09:47:39 UTC
Description of problem: Removing task whose target is dnssec-trigger fails to remove dnssec-trigger itself.

Version-Release number of selected component: dnssec-trigger-0.13-5.fc27.x86_64

Actual results:
# dnf remove -y dnssec-trigger
...
Transaction test succeeded.
Running transaction
  Running scriptlet: systemd                                                1/1 
  Preparing        :                                                        1/1 
  Running scriptlet: dnssec-trigger-0.13-5.fc27.x86_64                      1/2 
chattr: Operation not supported while reading flags on /etc/resolv.conf
error: %preun(dnssec-trigger-0.13-5.fc27.x86_64) scriptlet failed, exit status 1
Error in PREUN scriptlet in rpm package dnssec-trigger
Error in PREUN scriptlet in rpm package dnssec-trigger
  Running scriptlet: unbound-1.6.8-1.fc27.x86_64                            2/2 
error: dnssec-trigger-0.13-5.fc27.x86_64: erase failed
  Erasing          : unbound-1.6.8-1.fc27.x86_64                            2/2 
  Running scriptlet: unbound-1.6.8-1.fc27.x86_64                            2/2 
dnssec-trigger-0.13-5.fc27.x86_64 was supposed to be removed but is not!
  Verifying        : dnssec-trigger-0.13-5.fc27.x86_64                      1/2 
  Verifying        : unbound-1.6.8-1.fc27.x86_64                            2/2 

Removed:
  unbound.x86_64 1.6.8-1.fc27                                                   
Failed:
  dnssec-trigger.x86_64 0.13-5.fc27

Expected results: Component to be removable. Permissions related to resolv.conf not to be altered.

Additional info (In terminal):
$ ls -al /etc/resolv.conf
lrwxrwxrwx. 1 root root 35 Feb  6 09:22 /etc/resolv.conf -> /var/run/NetworkManager/resolv.conf

Since component was installed NetworkManager overrides resolv.conf.

Comment 1 ricky.tigg 2018-02-06 10:34:55 UTC
I was not able to propose a fix to the present issue; however I had at last the removing task succeed in an non-academic way.
I had to stop NetworkManager, then as root, manually were removed:
- /etc/resolv.conf ('dnf remove dnssec-trigger' failed yet)
- files and folders related to 'dnssec' ('dnf remove dnssec-trigger' succeed)

Comment 2 Tomáš Hozza 2018-02-19 15:35:35 UTC
The problem happens when you try to remove dnssec-trigger, while it is running or was stopped before the transaction. dnssec-trigger-script is run with --cleanup parameter, which effectively restores /etc/resolv.conf to be a symlink to /var/run/NetworkManager/resolv.conf.

And after that the scriptlet in %preun tries to remove the immutable flag from the file, which ends with error. I think the call to chattr in the scriptlet is redundant and can be removed.

Comment 3 Tomáš Hozza 2018-02-19 16:01:39 UTC
fixed in dnssec-trigger-0.15-4.fc2{6,7,8}

Comment 4 Fedora Update System 2018-02-20 11:12:27 UTC
dnssec-trigger-0.15-4.fc26 has been submitted as an update to Fedora 26. https://bodhi.fedoraproject.org/updates/FEDORA-2018-0003054b16

Comment 5 Fedora Update System 2018-02-20 11:12:40 UTC
dnssec-trigger-0.15-4.fc27 has been submitted as an update to Fedora 27. https://bodhi.fedoraproject.org/updates/FEDORA-2018-3aa6ab3313

Comment 6 Fedora Update System 2018-02-20 17:50:19 UTC
dnssec-trigger-0.15-4.fc26 has been pushed to the Fedora 26 testing repository. If problems still persist, please make note of it in this bug report.
See https://fedoraproject.org/wiki/QA:Updates_Testing for
instructions on how to install test updates.
You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2018-0003054b16

Comment 7 Fedora Update System 2018-02-20 18:19:04 UTC
dnssec-trigger-0.15-4.fc27 has been pushed to the Fedora 27 testing repository. If problems still persist, please make note of it in this bug report.
See https://fedoraproject.org/wiki/QA:Updates_Testing for
instructions on how to install test updates.
You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2018-3aa6ab3313

Comment 8 Fedora Update System 2018-03-06 17:20:53 UTC
dnssec-trigger-0.15-4.fc27 has been pushed to the Fedora 27 stable repository. If problems still persist, please make note of it in this bug report.

Comment 9 Fedora Update System 2018-03-06 17:28:21 UTC
dnssec-trigger-0.15-4.fc26 has been pushed to the Fedora 26 stable repository. If problems still persist, please make note of it in this bug report.


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