FS#44061 - [xjadeo] Invalid .INSTALL script : cannot install / remove it

Attached to Project: Community Packages
Opened by Benjamin Robin (benjarobin) - Thursday, 05 March 2015, 22:02 GMT
Last edited by Jelle van der Waa (jelly) - Monday, 28 March 2016, 08:38 GMT
Task Type Bug Report
Category Packages
Status Closed
Assigned To speps (archspeps)
Architecture All
Severity High
Priority Normal
Reported Version
Due in Version Undecided
Due Date Undecided
Percent Complete 100%
Votes 0
Private No

Details

Description:

When try to install xjadeo, pacman hang... After killing pacman, when trying to remove it, pacman hang again...

Additional info:
* package version(s)
xjadeo 0.8.0-2

Steps to reproduce:

The .INSTALL script contains :

post_install() {
update-desktop-database -q
}

post_install() {
post_install
}

post_remove() {
post_install
}

pacman run : /usr/bin/bash -c ". /tmp/alpm_Su7kI7/.INSTALL; post_remove 0.8.0-2"
The following command line hang, moreover ps or htop no longer works...

But if you run this script with zsh, zsh is nice with use :
> post_install:1: maximum nested function level reached

The only way to fix it, it to run this :
pacman -R --noscriptlet xjadeo
Then : update-desktop-database
This task depends upon

Closed by  Jelle van der Waa (jelly)
Monday, 28 March 2016, 08:38 GMT
Reason for closing:  Fixed
Additional comments about closing:  Fixed in 0.8.5-3.
Comment by Doug Newgard (Scimmia) - Thursday, 05 March 2015, 22:08 GMT
This recursive function has been there since the package was first added to the repos on 2013-07-01. I wonder if anyone actually uses this package.
Comment by Benjamin Robin (benjarobin) - Thursday, 05 March 2015, 22:14 GMT
I think there is a new critical bug inside bash (kernel also ?)... Why I cannot longer use ps or htop ? This is just a recursive function, there is no fork bomb here... I don't understand everything here...
Comment by Benjamin Robin (benjarobin) - Thursday, 05 March 2015, 23:16 GMT
The problem was not reported because bash was crashing with this error :
[1] 28976 bus error (core dumped) /usr/bin/bash...

I did try with an old version (1 year old) of bash, and the result is the same.

Bash no longer crashes with the kernel linux-3.18.6-1. I have no idea if this is a good thing, but now if you run this script, the kernel is in a bad state, htop and ps are no longer working properly. I have no idea why, but top still works.
The bug in the kernel was introduced between 3.18.5-1 ("working") and 3.18.6-1 (htop and ps hang)

It's starting to be late here (France), I don't know if I will be able to investigate this weekend. Anyway, I will create, if not already exist, a bug report upstream.
Comment by Benjamin Robin (benjarobin) - Friday, 06 March 2015, 22:36 GMT
For information the kernel bug is reported here : https://bugzilla.kernel.org/show_bug.cgi?id=94441
The author of the problematic commit is Linus himself.
Linus respond to the bug report quickly and said :
"3.18.6 was missing a critical commit ("x86: mm: move mmap_sem unlock from mm_fault_error() to caller").
But 3.18.7 should be fine."
Comment by Benjamin Robin (benjarobin) - Wednesday, 18 March 2015, 20:19 GMT
Up ?
Comment by smmilut (smmilut) - Saturday, 12 March 2016, 20:39 GMT
Installing this package today for the first time (was just curious about the package, and unaware of the bug), and i reproduce this. Except i don't see anything wrong with htop.

With :
xjadeo 0.8.5-2
pacman 5.0.1-2
bash 4.3.042-4
linux 4.4.5-1 on x86_64

Installing or removing xjadeo hangs for 2 seconds, and pacman outputs :
error: command terminated by signal 11: Segmentation fault

In dmesg, i get sometimes :
bash[1148]: segfault at 7ffce749bff8 ip 0000000000428a32 sp 00007ffce749c000 error 6 in bash[400000+bd000]

and sometimes :
bash[1712]: segfault at 7ffc849b7ff0 ip 00007fad71ff6b69 sp 00007ffc849b7fe0 error 6 in libc-2.23.so[7fad71f80000+198000]

But the error being in "bash" or "libc-2.23.so" doesn't seem to be related to whether i'm installing or removing.

This said, the packaged software seems to run fine anyway.
In addition, the desktop entry seems to be correctly added and removed to the database (anyway it appears and disappears correctly from the menu i get from /etc/xdg/menus/arch-applications.menu)

I don't have a problem with this bug, just wanted to share the info i have.
I don't know what more information to provide.

Loading...