From: Martin Jansa <martin.jansa@gmail.com>
To: Richard Purdie <richard.purdie@linuxfoundation.org>
Cc: openembedded-commits@lists.openembedded.org,
openembedded-core@lists.openembedded.org
Subject: Re: [oe-commits] Jonathan Liu : fontcache.bbclass: prepend to PACKAGEFUNCS instead of appending
Date: Mon, 23 Mar 2015 23:21:13 +0100 [thread overview]
Message-ID: <20150323222113.GD3904@jama> (raw)
In-Reply-To: <20150321145504.GG4738@jama>
[-- Attachment #1: Type: text/plain, Size: 5477 bytes --]
On Sat, Mar 21, 2015 at 03:55:04PM +0100, Martin Jansa wrote:
> On Sat, Mar 21, 2015 at 09:29:07AM +0000, Richard Purdie wrote:
> > On Sat, 2015-03-21 at 03:11 +0100, Martin Jansa wrote:
> > > On Mon, Mar 16, 2015 at 05:42:36PM +0000, git@git.openembedded.org wrote:
> > > > Module: openembedded-core.git
> > > > Branch: master
> > > > Commit: f0e3db4eaacc32423934ce09b91bc619dc5dbd21
> > > > URL: http://git.openembedded.org/?p=openembedded-core.git&a=commit;h=f0e3db4eaacc32423934ce09b91bc619dc5dbd21
> > > >
> > > > Author: Jonathan Liu <net147@gmail.com>
> > > > Date: Mon Mar 9 12:13:56 2015 +1100
> > > >
> > > > fontcache.bbclass: prepend to PACKAGEFUNCS instead of appending
> > > >
> > > > Appending to PACKAGEFUNCS results in the font packages missing the
> > > > postinst/postrm scripts and the fontconfig cache not being generated
> > > > in /var/cache/fontconfig when creating images or installing font
> > > > packages. This is because the package data has already been emitted
> > > > by emit_pkgdata in PACKAGEFUNCS. Prepend to PACKAGEFUNCS to ensure
> > > > add_fontcache_postinsts is executed before emit_pkgdata.
> > >
> > > It's not caused by this change, but fixing this issue revealed that
> > > fc-cache doesn't really work here.
> > >
> > > Every time the intercept_scripts/update_font_cache executes qemu it gets
> > > "stuck" eating a lot of cpu and memory until it dies. Is anyone alse
> > > seeing this behavior?
> > >
> > > WARNING: The postinstall intercept hook 'update_font_cache' failed (exit code: 137)! See log for details!
> > > WARNING: The postinstalls for the following packages will be postponed for first boot: liberation-fonts
> > > ERROR: The following packages could not be configured offline and rootfs is read-only: ['liberation-fonts']
> > > ERROR: Function failed: do_rootfs
> > >
> > > bitbake 32618 98.8 67.1 11031512 10983420 pts/3 R+ 03:00 4:53
> > > qemu-i386 -r 2.6.32 -L /OE/rootfs -E uD_LIBRARY_PATH=/OE/rootfs//usr/lib:/OE/rootfs//lib /OE/rootfs/usr/bin/fc-cache --sysroot=/OE/rootfs
> >
> > There are a couple of bugs in the bugzilla around this. One seemed to be
> > related to circular symlinks in udev's ptest package which was
> > supposedly fixed. The other claims to have been resolved by upgrading
> > fontconfig to a version which doesn't have issues with circular paths.
> >
> > There is general confusion about how to reproduce the issue and what the
> > real problem is though.
> >
> > Does your system have any recursive directory structures?
>
> I've tried to build a bit smaller image after sending the report and in
> that do_rootfs it finished successfully. I'll try to re-execute this to
> see if I get consistent results.
>
> The bigger image has only few more packages in it, so if this is the
> case and smaller always works while bigger always fails I should be able
> to quickly find out which package/file is causing this.
>
> I'll check the circular symlinks, I know there are some ptest packages
> in the bigger one.
In my case it's reproducible by adding udev-ptest to image, more specifically
having these 2 directories in rootfs:
usr/lib/udev/ptest/test/sys/devices
usr/lib/udev/ptest/test/sys/bus
deleting them and re-triggering the qemu works.
I can also confirm that it's not just lack of memory on the build machine.
It triggers OOM killer after using 64GB as well as on machine with just 8GB.
fc-bug/rootfs-broken$ time ../../../../sysroots/x86_64-linux/usr/bin/qemu-i386 -r 2.6.32 -L . -E LD_LIBRARY_PATH=usr/lib:lib usr/bin/fc-cache --sysroot=.
... OOM killer in an hour or 2 ... (this time I didn't get a log, because it killed almost everything else except qemu-i386 :)
fc-bug/rootfs-broken$ cd ..
fc-bug$ cp -ra rootfs-broken rootfs-broken-without-udev-ptest-bus-devices
fc-bug$ cd rootfs-broken-without-udev-ptest-bus-devices
fc-bug/rootfs-broken-without-udev-ptest-bus-devices$ rm -rf usr/lib/udev/ptest/test/sys/devices/ usr/lib/udev/ptest/test/sys/bus/
fc-bug/rootfs-broken-without-udev-ptest-bus-devices$ time ../../../../sysroots/x86_64-linux/usr/bin/qemu-i386 -r 2.6.32 -L . -E LD_LIBRARY_PATH=usr/lib:lib usr/bin/fc-cache --sysroot=.
real 0m30.424s
user 0m29.714s
sys 0m0.548s
Comparing strace shows the broken one to cycle a lot in directories like this:
< getdents(51, /* 8 entries */, 32768) = 248
< openat(AT_FDCWD, "//home/jenkins/anaconda/build-starfish-dizzy/build/BUILD/work/qemux86-starfish-linux/fc-bug/rootfs-broken/./usr/lib/udev/ptest/test/sys/dev/block/8:1/subsystem/loop2/bdi/subsystem/0:16/subsystem/0:16/subsystem/0:16/subsystem/0:16/subsystem/0:16/subsystem/0:16/subsystem/0:16/subsystem/0:16/subsystem/0:16/subsystem/0:16/subsystem/0:16/subsystem/0:16/subsystem/0:16/subsystem/0:16/subsystem/0:16/subsystem/0:16/subsystem/8:16/subsystem/8:0/power", O_RDONLY|O_NONBLOCK|O_DIRECTORY|O_CLOEXEC) = 52
This issue forced me to finally set ulimit in my builds so that I can kill the
right process a bit sooner (instead of waiting for it to eat e.g. 128GB)
I'll try to create smaller reproducer and check newer fontconfig.
>
> Thanks
>
> > I'd like to get to the bottom of the issue and fix it once and for all
> > but we likely need more info.
> >
> > Cheers,
> >
> > Richard
> >
>
> --
> Martin 'JaMa' Jansa jabber: Martin.Jansa@gmail.com
--
Martin 'JaMa' Jansa jabber: Martin.Jansa@gmail.com
[-- Attachment #2: Digital signature --]
[-- Type: application/pgp-signature, Size: 188 bytes --]
next prev parent reply other threads:[~2015-03-23 22:21 UTC|newest]
Thread overview: 24+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <20150316174236.48B8050234@opal.openembedded.org>
2015-03-21 2:11 ` [oe-commits] Jonathan Liu : fontcache.bbclass: prepend to PACKAGEFUNCS instead of appending Martin Jansa
2015-03-21 9:29 ` Richard Purdie
2015-03-21 14:55 ` Martin Jansa
2015-03-23 22:21 ` Martin Jansa [this message]
2015-03-25 12:11 ` Burton, Ross
2015-03-25 16:12 ` Martin Jansa
2015-03-25 16:18 ` Burton, Ross
2015-03-25 22:14 ` Martin Jansa
2015-03-26 21:39 ` Burton, Ross
2015-03-29 0:28 ` Martin Jansa
2015-03-29 1:27 ` [PATCH] fontcache: allow to pass different fontconfig cache dir Martin Jansa
2015-03-30 10:47 ` Burton, Ross
2015-03-30 17:27 ` Martin Jansa
2015-04-07 11:21 ` [PATCHv2] " Martin Jansa
2015-04-09 10:12 ` Richard Purdie
2015-04-09 11:35 ` Martin Jansa
2015-04-20 10:16 ` Martin Jansa
2015-03-30 10:09 ` [oe-commits] Jonathan Liu : fontcache.bbclass: prepend to PACKAGEFUNCS instead of appending Burton, Ross
2015-03-30 16:41 ` Khem Raj
2015-03-30 16:43 ` Burton, Ross
2015-03-30 16:47 ` Khem Raj
2015-03-30 18:46 ` Martin Jansa
2015-03-30 18:49 ` Khem Raj
2015-03-30 20:07 ` Martin Jansa
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20150323222113.GD3904@jama \
--to=martin.jansa@gmail.com \
--cc=openembedded-commits@lists.openembedded.org \
--cc=openembedded-core@lists.openembedded.org \
--cc=richard.purdie@linuxfoundation.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox