Bug 29158

Summary: tor package's uninstall script has error (easy to fix, solution in report).
Product: Mageia Reporter: PC LX <mageia>
Component: RPM PackagesAssignee: Jani Välimaa <jani.valimaa>
Status: RESOLVED OLD QA Contact:
Severity: minor    
Priority: Normal CC: herman.viaene, jani.valimaa
Version: 7   
Target Milestone: ---   
Hardware: All   
OS: Linux   
Whiteboard:
Source RPM: tor-0.3.5.15-1.mga7.src.rpm CVE:
Status comment:
Bug Depends on: 29136    
Bug Blocks:    

Description PC LX 2021-06-20 11:47:47 CEST
Description of problem:

When uninstalling the tor package the following error messages are displayed.

$ urpme tor
removing tor-0.3.5.15-1.mga7.x86_64
rm: cannot remove '/var/lib/tor/keys': Is a directory
error: %preun(tor-0.3.5.15-1.mga7.x86_64) scriptlet failed, exit status 1
ERROR: 'script' failed for tor-0.3.5.15-1.mga7.x86_64
error: tor-0.3.5.15-1.mga7.x86_64: erase failed

The error is caused by the following line in the uninstall script:
        rm -f /var/lib/tor/*

It needs the "-R" option to remove directories, like this:
        rm -Rf /var/lib/tor



Version-Release number of selected component (if applicable):

tor-0.3.5.15-1.mga7.x86_64



How reproducible:

Always.



Steps to Reproduce:
1. Install tor (urpmi tor);
2. Start tor service (systemctl start tor.service);
3. Stop tor service (systemctl stop tor.service);
4. Uninstall tor (urpme tor);
Comment 1 Lewis Smith 2021-06-20 20:50:13 CEST
Thank you for this helpful report.

'tor' has no fixed maintainer, so assigning this bug globally.

Assignee: bugsquad => pkg-bugs

Jani Välimaa 2021-06-21 12:49:55 CEST

Blocks: (none) => 29136

Comment 2 Jani Välimaa 2021-06-21 13:11:02 CEST
Should be fixed with:
tor-0.3.5.15-1.1.mga7
tor-0.3.5.15-1.1.mga8

Assignee: pkg-bugs => qa-bugs
Whiteboard: (none) => MGA8TOO
CC: (none) => jani.valimaa

Comment 3 Herman Viaene 2021-06-21 13:45:24 CEST
OK as tested on bug 29136.

CC: (none) => herman.viaene
Whiteboard: MGA8TOO => MGA8TOO MGA7-64-OK

David Walser 2021-06-21 21:07:40 CEST

Assignee: qa-bugs => jani.valimaa
Whiteboard: MGA8TOO MGA7-64-OK => (none)

Aurelien Oudelet 2021-06-28 21:55:22 CEST

Blocks: 29136 => (none)
Depends on: (none) => 29136

Comment 4 Aurelien Oudelet 2021-07-06 13:17:55 CEST
Mageia 7 is EOL since July 1st 2021.
There will not have any further bugfix for this release.

You are encouraged to upgrade to Mageia 8 as soon as possible.

@reporter, if this bug still apply with Mageia 8, please let us know it.

@packager, if you work on the Mageia 7 version of your package, please check the Mageia 8 package if issue is also present. In this case, please fix the Mageia 8 version instead.

This bug report will be closed OLD if there is no further notice within 1st September 2021.
Comment 5 Herman Viaene 2021-07-06 14:06:52 CEST
I've tested a tor version lately, but it's gone now from the updates list, so I cann't check anymore whether I tested for M7 or M8 or both. Anyway, I didn't see that issue.
Comment 6 Marja Van Waes 2021-09-07 14:11:29 CEST
Hi bug reporter and hi assignee and others involved,

Please reopen this bug report if it is still valid for Mageia 8 or 9(cauldron), and change "Version:" in the upper left of this report accordingly.

This report is being closed as OLD because it was filed against Mageia 7, for which  support ended on June 30th 2021.

Thanks,
Marja

Status: NEW => RESOLVED
Resolution: (none) => OLD