Public bug reported:

After a few hours of working today I started wondering what was
consuming my battery:

 %CPU %MEM     TIME+ COMMAND      
100,0  0,5 167:06.10 appstreamcli 

"appstreamcli refresh" is running according to ps. I need to kill it in
order to continue sanely so I may not be getting all the necessary
debugging out of it, but here's something.

sudo gdb -p to the process, continue, break and backtrace:
0x00007f14285f9b23 in yaml_parser_parse () from 
/usr/lib/x86_64-linux-gnu/libyaml-0.so.2
(gdb) bt
#0  0x00007f14285f9b23 in yaml_parser_parse () from 
/usr/lib/x86_64-linux-gnu/libyaml-0.so.2
#1  0x00007f1429ea9c4c in as_yamldata_parse_distro_data () from 
/usr/lib/x86_64-linux-gnu/libappstream.so.3
#2  0x00007f1429eab537 in as_metadata_parse_yaml () from 
/usr/lib/x86_64-linux-gnu/libappstream.so.3
#3  0x00007f1429eabc55 in as_metadata_parse_file () from 
/usr/lib/x86_64-linux-gnu/libappstream.so.3
#4  0x00007f1429eaed49 in as_data_pool_update () from 
/usr/lib/x86_64-linux-gnu/libappstream.so.3
#5  0x00007f1429ea4272 in as_cache_builder_refresh () from 
/usr/lib/x86_64-linux-gnu/libappstream.so.3
#6  0x00000000004049de in ascli_refresh_cache ()
#7  0x0000000000403ceb in as_client_run ()
#8  0x00007f1429ad2830 in __libc_start_main (main=0x403490 <main>, argc=2, 
argv=0x7fff509d0768, init=<optimized out>, 
    fini=<optimized out>, rtld_fini=<optimized out>, stack_end=0x7fff509d0758) 
at ../csu/libc-start.c:291
#9  0x0000000000403519 in _start ()

And seems to fluctuate between eg yaml_event_delete, yaml_parser_parse,
but it seems to be stuck in that as_yamldata_parse_distro_data.

Strace does not seem to output anything when attaching, or I'm doing something 
wrong:
$ sudo strace -p 14708
strace: Process 14708 attached
strace: [ Process PID=14708 runs in x32 mode. ]
^Cstrace: Process 14708 detached

I have a snapshot of /var/cache/app-info in store if needed. Nothing
under xapian/ has timestamp newer than 3h ago when the process had
started, and xmls/fwupd.xml is over an hour old too.

** Affects: appstream (Ubuntu)
     Importance: Undecided
         Status: New

-- 
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.
https://bugs.launchpad.net/bugs/1583973

Title:
  appstream refresh stuck at 100% CPU on xenial

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/appstream/+bug/1583973/+subscriptions

-- 
ubuntu-bugs mailing list
ubuntu-bugs@lists.ubuntu.com
https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs

Reply via email to