[Apt-Rpm] Issue with apt-rpm 0.5.15lorg3.2 on Solaris 9 with RPM 4.4.2.3

Brian Schubert schubert at jla.rutgers.edu
Tue Feb 10 10:50:39 PST 2009


Here is a portion of the output of 'truss -f -SSEGV apt-get remove nano':

25910: lwp_schedctl(SC_STATE|SC_PREEMPT, 0, 0xFFBFDB9C) = 0
25910: chdir("/") = 0
25910: getpid() = 25910 [25909]
25910: Incurred fault #6, FLTBOUNDS %pc = 0xFE9D0988
25910: siginfo: SIGSEGV SEGV_MAPERR addr=0x00000000
25910: Received signal #11, SIGSEGV [default]
25910: siginfo: SIGSEGV SEGV_MAPERR addr=0x00000000
25909: sigprocmask(SIG_SETMASK, 0xFE1FA094, 0xFFBFDF28) = 0
25909: sigprocmask(SIG_SETMASK, 0xFFBFDF14, 0x00000000) = 0
25909: mmap(0x00000000, 110592, PROT_READ|PROT_WRITE, 
MAP_PRIVATE|MAP_ANON, -1, 0) = 0xFE0E0000
25909: lwp_park(0x00000000, 0) (sleeping...)

Continued with 'prun':

25909: Received signal #18, SIGCLD, in lwp_park() [caught]
25909: siginfo: SIGCLD CLD_DUMPED pid=25910 status=0x000B
25909: lwp_park(0x00000000, 0) Err#4 EINTR
25909: sigprocmask(SIG_SETMASK, 0xFFBFDB2C, 0x00000000) = 0
25909: getpgid(0) = 25908
25909: waitid(P_PGID, 25908, 0xFFBFD8F0, WEXITED|WTRAPPED|WNOHANG) = 0
25909: getpgid(0) = 25908
25909: waitid(P_PGID, 25908, 0xFFBFD8F0, WEXITED|WTRAPPED|WNOHANG) 
Err#10 ECHILD
25909: sigprocmask(SIG_SETMASK, 0xFE1FA094, 0xFFBFD8E0) = 0
25909: lwp_unpark(1, 1) = 0
25909: setcontext(0xFFBFD8F0)
25909: sigprocmask(SIG_SETMASK, 0xFE1FA094, 0xFFBFDF28) = 0
25909: sigprocmask(SIG_SETMASK, 0xFFBFDF14, 0x00000000) = 0
25909: sigprocmask(SIG_SETMASK, 0xFE1FA094, 0xFFBFDF28) = 0
25909: sigprocmask(SIG_SETMASK, 0xFFBFDF14, 0x00000000) = 0
25909: sigprocmask(SIG_SETMASK, 0xFE1FA094, 0xFFBFDEB8) = 0
25909: sigprocmask(SIG_SETMASK, 0xFFBFDEA4, 0x00000000) = 0
25909: close(-1) Err#9 EBADF
25909: close(-1) Err#9 EBADF
25909: sigprocmask(SIG_SETMASK, 0xFE1FA094, 0xFFBFDEB8) = 0
25909: sigprocmask(SIG_SETMASK, 0xFFBFDEA4, 0x00000000) = 0
25909: sigaction(SIGCLD, 0xFFBFDEA0, 0x00000000) = 0
25909: fstat64(2, 0xFFBFDDC0) = 0
error: 25909: write(2, " e r r o r : ", 7) = 7
%preun(nano-2.1.4-1.sparc64) scriptlet failed, signal 11
25909: write(2, " % p r e u n ( n a n o -".., 57) = 57
25909: close(11) = 0

While the process was stopped, I ran 'pstack' on it, resulting in the 
following stack trace:

fe9d0988 unsetenv (feb5419c, feb54174, feb542a4, feb53fac, d347a, d347f) 
+ 48
feaef474 runScript (d3485, d362a, feb53fac, 1, ffbfe338, d3c3f) + e74
feaefa54 runInstScript (d3c3f, 0, bc4a0, 4, 1, ffbfe404) + 1d4
feaf3064 rpmpsmStage (ba450, 35, 0, ffbfe480, 1c, ff0000) + 2324
feaf0d10 rpmpsmNext (ba450, 35, feb542a4, b6378, 24, 0) + 88
feaf1850 rpmpsmStage (ba450, 2, feab4bcc, fea92714, 1, b1b28) + b10
feaf0d10 rpmpsmNext (ba450, 2, ffbfe77c, 530, 0, 0) + 88
feaf2c60 rpmpsmStage (ba450, 8, b6378, 970e8, b63a8, 0) + 1f20
feb4b788 rpmtsRun (b19c0, 0, 40, 49610, 4961c, a9c) + 2da8
fefee738 _ZN11pkgRPMLibPM7ProcessERSt6vectorIPKcSaIS2_EES5_S5_ (6ea28, 
ffbfe990, ffbfe984, ffbfe978, ffbfe888, 94580) + 3b8
fefef128 _ZN8pkgRPMPM2GoEv (ffbfe984, 1914, ffbfe978, ffbfe99c, 
ffbfe990, 6ea28) + 590
ff028a50 _ZN17pkgPackageManager9DoInstallEP12InstProgress (0, 6cc58, 1, 
d, 0, ff07f5f0) + 30
ff028b6c _ZN17pkgPackageManager9DoInstallEv (6ea28, 0, 0, ffbff11c, 0, 
2000) + 58
00018440 _Z15InstallPackagesR9CacheFilebbb (305c8, 30670, 49318, 0, 
6ea28, 49550) + ad0
0001cf74 _Z9DoInstallR11CommandLine (1, ffbff358, 31908, 312a0, 
ffbff6cc, ffbff6c8) + 17e0
fefb1758 _ZN11CommandLine11DispatchArgEPNS_8DispatchEb (ffbffaf4, 
ffbffa90, 1, 4, 0, ffbff6ec) + 70
000206fc main (3, 69698, ffbffb9c, 497d0, ffbffa70, ffbff7fc) + 5e8
000166dc _start (0, 0, 0, 0, 0, 0) + 5c

Any suggestions based on this information?

-Brian

Brian Schubert wrote:
> Yes, it does work properly with -o RPM::PM="external". Thanks for the 
> suggestion.
>
> I will do some more testing to try and find out what is causing the 
> scriptlet to die when librpm is used.
>
> -Brian
>
> Panu Matilainen wrote:
>> On Wed, 7 Jan 2009, Brian Schubert wrote:
>>
>>> Hello,
>>>
>>> I have managed to get rpm 4.4.2.3 working on Solaris 9 but am unable to
>>> get apt-rpm to work properly with it. Specifically, apt-get gives an
>>> error when ever it encounters a %post, %preun, etc. script.
>>> Additionally, the usage of 'popen' in gpg-check.lua does not appear to
>>> be supported by my setup. Here is an example:
>>>
>>> apt-get install nano
>>> Reading Package Lists... Done
>>> Building Dependency Tree... Done
>>> The following NEW packages will be installed:
>>> nano (2.1.4-1)
>>> 0 upgraded, 1 newly installed, 0 removed and 0 not upgraded.
>>> Need to get 0B/268kB of archives.
>>> After unpacking 781kB of additional disk space will be used.
>>> Checking GPG signatures... Committing changes...######################
>>> [100%]
>>> Preparing... ###########################################
>>> [100%]
>>> 1:nano ###########################################
>>> [100%]
>>> error: %post(nano-2.1.4-1.sparc64) scriptlet failed, signal 11
>>>
>>> W: Error running script: /usr/local/share/apt/scripts/gpg-check.lua:59:
>>> `popen' not supported
>>> W: Some errors occurred while running transaction
>>
>> Hmm, Solaris surely has popen(), so it's not getting built in for 
>> whatever reason, this is what controls it:
>>
>> /*
>> ** by default, posix systems get `popen'
>> */
>> #ifndef USE_POPEN
>> #ifdef _POSIX_C_SOURCE
>> #if _POSIX_C_SOURCE >= 2
>> #define USE_POPEN 1
>> #endif
>> #endif
>> #endif
>>
>>> And here is what happens when I remove the package:
>>>
>>> apt-get remove nano
>>> Reading Package Lists... Done
>>> Building Dependency Tree... Done
>>> The following packages will be REMOVED:
>>> nano (2.1.4-1)
>>> 0 upgraded, 0 newly installed, 1 removed and 0 not upgraded.
>>> Need to get 0B of archives.
>>> After unpacking 781kB disk space will be freed.
>>> Do you want to continue? [Y/n] y
>>> Committing changes...
>>> Preparing... ###########################################
>>> [100%]
>>> error: %preun(nano-2.1.4-1.sparc64) scriptlet failed, signal 11
>>> W: Some errors occurred while running transaction
>>>
>>> I have determined that this is not an rpm issue, since the package
>>> installs/uninstalls without issue when rpm is used directly.
>>>
>>> I also experience the same problem with the 0.5.15lorg3.94a development
>>> release.
>>
>> This is fairly strange, as it's really rpm code which is executing 
>> inside the transaction, apt doesn't directly call anything like 
>> "execute this packages %preun scriptlet" and has been working 
>> reliably for a long time now. Try to get a backtrace of the scriptlet 
>> dying, otherwise it's kinda hopeless guesswork.
>>
>> One possible workaround might be switching to the "external package 
>> manager" mode which actually executes the rpm command instead of 
>> using librpm to do the work, this can be enabled with -o 
>> RPM::PM="external" option to see if it helps. But again, even if it 
>> works, that's just a workaround.
>>
>> - Panu -
>> _______________________________________________
>> Apt-Rpm mailing list
>> Apt-Rpm at lists.laiskiainen.org
>> http://lists.laiskiainen.org/listinfo.cgi/apt-rpm-laiskiainen.org
>
> _______________________________________________
> Apt-Rpm mailing list
> Apt-Rpm at lists.laiskiainen.org
> http://lists.laiskiainen.org/listinfo.cgi/apt-rpm-laiskiainen.org


-- 
Brian Schubert
Student Systems Programmer
OSS/NBCS - OIT Rutgers University



More information about the Apt-Rpm mailing list