Bug 2852 - zypper assertion fail
Summary: zypper assertion fail
Status: VERIFIED WORKSFORME
Alias: None
Product: OE-Core
Classification: Build System, Metadata & Runtime
Component: core (show other bugs)
Version: 1.3
Hardware: x86 arm
: High normal
Target Milestone: 1.3 M4
Assignee: Robert Yang
QA Contact:
URL:
Whiteboard:
Depends on:
Blocks:
 
Reported: 2012-07-30 03:37 UTC by veera
Modified: 2012-09-24 08:38 UTC (History)
11 users (show)

See Also:
OS type for building Yocto: ---
Type of Regression: ---
Verified:
Documentation change: ---


Attachments
zypper error is attached (248.48 KB, image/png)
2012-07-30 03:37 UTC, veera
no flags Details

Note You need to log in before you can comment on or make changes to this bug.
Description veera 2012-07-30 03:37:32 UTC
Created attachment 664 [details]
zypper error is attached

build              : http://autobuilder.yoctoproject.org/pub/nightly/20120725-3/
Test case ID       : TC-2682 , TC-2683 , TC-2684
Target platform    : qemuarm
Image Profile   : sato-sdk
Procedure      :  
		1. runqemu qemuxarm zImage-qemuarm.bin core-image-sato-sdk-qemuarm-20120725214148.rootfs.ext3
                  2. once system comes up properly  
                  3. Execute "zypper search avahi"
                  Error "zypper: dbconfig.c:493: db3New: Assertion `dbOpts != ((void *)0) && *dbOpts != '\0'' failed.Aborted"
Expected Output : zypper repo should work properly
Observed output :Error "zypper: dbconfig.c:493: db3New: Assertion `dbOpts != ((void *)0) && *dbOpts != '\0'' failed.Aborted"
Comment 1 Yi Zhao 2012-07-30 06:39:28 UTC
Hi Veera,

We didn't encounter this issue in the same image:
##########
root@qemuarm:~# zypper search avahi
Loading repository data...
Reading installed packages...

S | Name               | Summary                                                                | Type   
--+--------------------+------------------------------------------------------------------------+--------
i | avahi              | Avahi IPv4LL network address configuration daemon                      | package
i | avahi-daemon       | Avahi IPv4LL network address configuration daemon                      | package
i | avahi-dev          | Avahi IPv4LL network address configuration daemon - Development files  | package
i | avahi-locale-en-gb | Avahi IPv4LL network address configuration daemon - en_GB translations | package
i | libavahi-client3   | Avahi IPv4LL network address configuration daemon                      | package
i | libavahi-common3   | Avahi IPv4LL network address configuration daemon                      | package
i | libavahi-core7     | Avahi IPv4LL network address configuration daemon                      | package
i | libavahi-glib1     | Avahi IPv4LL network address configuration daemon                      | package
i | libavahi-gobject0  | Avahi IPv4LL network address configuration daemon                      | package
root@qemuarm:~# 
root@qemuarm:~# 
######
Comment 3 Yi Zhao 2012-07-30 08:18:39 UTC
Hi Veera,

My kernel and image are download from the same link.
Here is the md5 checksum of kernel:
#########
$ md5sum zImage-qemuarm.bin 
da2df9914f5bb11e4fa04cd600019569  zImage-qemuarm.bin
#########

For the ext3 image, the checksum is unavailable because once you boot up the image the checksum will be changed. So I use the rootfs tarball via nfs to test it again.
#########
$ md5sum core-image-sato-sdk-qemuarm-20120725214148.rootfs.tar.bz2 
a428fef3bbbbe3b68f3786756912902f  core-image-sato-sdk-qemuarm-20120725214148.rootfs.tar.bz2
$ runqemu-extract-sdk core-image-sato-sdk-qemuarm-20120725214148.rootfs.tar.bz2 rootfs/
$ runqemu nfs zImage-qemuarm.bin rootfs/
#########

There is no this issue.

My test env:
##########
Ubuntu 12.04 LTS x86_64
Linux zhaoyi-ubuntu 3.2.0-27-generic #43-Ubuntu SMP Fri Jul 6 14:25:57 UTC 2012 x86_64 x86_64 x86_64 GNU/Linux
##########

Does this issue happen every time when you run this command ?

I will download the image from http://autobuilder.yoctoproject.org/pub/nightly/20120725-3/machines/qemu/qemuarm/core-image-sato-sdk-qemuarm-20120725214148.rootfs.ext3 again and test it.
Comment 4 veera 2012-07-30 08:50:59 UTC
Hi Yi zhao ,

       yes we are able to reproduce every time.
Comment 5 veera 2012-07-30 08:54:13 UTC
Hi Yi zhao ,

       yes we are able to reproduce every time.

      i am using below command to run qemu

      runqemu qemuxarm zImage-qemuarm.bin core-image-sato-sdk-qemuarm-20120725214148.rootfs.ext3


      i observed that you are using "runqemu nfs"

      my md5sum is mathcing with ur md5sum.

      i am using open suse as a host
      openSUSE 12.1 (i586)
      VERSION = 12.1
      CODENAME = Asparagus


Thanks & Regards
Veera Brahmam
Comment 6 Yi Zhao 2012-07-30 11:26:51 UTC
(In reply to comment #5)
> Hi Yi zhao ,
> 
>        yes we are able to reproduce every time.
> 
>       i am using below command to run qemu
> 
>       runqemu qemuxarm zImage-qemuarm.bin
> core-image-sato-sdk-qemuarm-20120725214148.rootfs.ext3
> 
> 
>       i observed that you are using "runqemu nfs"
> 
>       my md5sum is mathcing with ur md5sum.
> 
>       i am using open suse as a host
>       openSUSE 12.1 (i586)
>       VERSION = 12.1
>       CODENAME = Asparagus

Hi Veera,
I re-download the ext3 image and test it on openSuse 12.1 x86. There is no this issue. Did you run any command before you searched package? It looks like the db file corruption.

Thanks,
Yi
 
> 
> 
> Thanks & Regards
> Veera Brahmam
Comment 7 veera 2012-07-31 04:34:31 UTC
Hi Yi ,

even know also i tryed i am getting same error .
i able to use same repo for other qemu platforms .
please check 

root@qemuarm:~# zypper search avahi
zypper: dbconfig.c:493: db3New: Assertion `dbOpts != ((void *)0) && *dbOpts != '\0'' failed.
Aborted
root@qemuarm:~#

Thanks
veera
Comment 8 Robert Yang 2012-07-31 06:04:49 UTC
I think that this is caused by using the sstate-cache across different distributions, please see 2753.
Comment 9 Richard Purdie 2012-08-02 14:42:29 UTC
This cannot be a sstate bug as you're using the same image files and there is no sstate involved. The difference could be the repository you're connecting to? Please investiagte this further and find out why this works in some cases but not in others. Are you using the same repository to test teh query against?
Comment 10 veera 2012-08-03 06:57:16 UTC
in this build we are able to reproduce .

But latest Release http://autobuilder.yoctoproject.org/pub/nightly/20120801-1/  this issue is not able to reproduce.
please take a call.

Thanks
veera
Comment 11 Yi Zhao 2012-08-03 07:43:02 UTC
(In reply to comment #10)
> in this build we are able to reproduce .
> 
> But latest Release
> http://autobuilder.yoctoproject.org/pub/nightly/20120801-1/  this issue is
> not able to reproduce.
> please take a call.
> 
> Thanks
> veera

Hi veera, 

Which repository do you use ? 

Thanks,
Yi
Comment 12 veera 2012-08-03 09:40:53 UTC
Hi Yi,
    
      I followed https://wiki.yoctoproject.org/wiki/Zypper_Repository_Setup steps & Created my own zypper repo.

Thanks 
veera
Comment 13 Saul Wold 2012-08-12 10:47:05 UTC
This is still and issue with a couple of the M3 builds that needs to be resolved, it;s not just zypper, but also rpmresolve, so it's a library issue.
Comment 14 Richard Purdie 2012-08-16 15:18:30 UTC
You can see errors from rpm like this when it can't find certain files it needs, for example its macros file. Could you attach strace logs for the failing zypper command so we can see if something like this is the problem.
Comment 15 Yi Zhao 2012-09-03 08:30:18 UTC
I rebuilt the image with same commit in my side, but can not reproduce this issue. I found if I removed the file /usr/lib/rpm/macros , this issue would happen:
##########
root@qemuarm:~# mv /usr/lib/rpm/macros /usr/lib/rpm/macros.bak
root@qemuarm:~# zypper search avahi
zypper: dbconfig.c:493: db3New: Assertion `dbOpts != ((void *)0) && *dbOpts != '\0'' failed.
Aborted
root@qemuarm:~# 
##########

Veera, would you please check the /usr/lib/rpm/macros in your image ?
Comment 16 veera 2012-09-05 13:19:14 UTC
Today i tested agaian with http://autobuilder.yoctoproject.org/pub/nightly/20120725-3/ build   , but i am not able to reproduce the issue

but if i do : mv /usr/lib/rpm/macros /usr/lib/rpm/macros.bak
i am able to reproduce.


md5sum 
553b34abc93295b04dec6fd630eeb9e2  core-image-sato-sdk-qemuarm-20120725214148.rootfs.ext3

da2df9914f5bb11e4fa04cd600019569  zImage-qemuarm.bin

Regards
Veera
Comment 17 Robert Yang 2012-09-05 15:17:53 UTC
(In reply to comment #16)
> Today i tested agaian with
> http://autobuilder.yoctoproject.org/pub/nightly/20120725-3/ build   , but i
> am not able to reproduce the issue
> 
> but if i do : mv /usr/lib/rpm/macros /usr/lib/rpm/macros.bak
> i am able to reproduce.
> 

Yes, the *dbOpts' value is from /usr/lib/rpm/macros, so you can reproduce the error after remove the file, but the problem is that how this file can be disappeared in a normal build.

> 
> md5sum 
> 553b34abc93295b04dec6fd630eeb9e2 
> core-image-sato-sdk-qemuarm-20120725214148.rootfs.ext3
> 
> da2df9914f5bb11e4fa04cd600019569  zImage-qemuarm.bin
> 
> Regards
> Veera
Comment 18 Saul Wold 2012-09-11 14:10:22 UTC
Seems there was a missing file, possibly a bad build.  If the problem re-appears please reopen this bug or a new one.
Comment 19 Andreea Brandusa Proca 2012-09-24 08:38:54 UTC
Verified in commit: e5c3513ca8abb21eb5e9b8c19d1b9199b14ae07c.