Packagekitd keeps writing to logs, uses disk, ram and CPU

[emanu@desktop ~]$ dnf repolist

[emanu@desktop ~]$ pkcon repo-list

Recupero dei repository [=========================]
Completato [=========================]
Disabilitato updates-testing Fedora 34 - x86_64 - Test Updates
Disabilitato updates-testing-debuginfo Fedora 34 - x86_64 - Test Updates Debug
Disabilitato updates-testing-source Fedora 34 - Test Updates Source
Disabilitato updates Fedora 34 - x86_64 - Updates
Disabilitato updates-debuginfo Fedora 34 - x86_64 - Updates - Debug
Disabilitato updates-source Fedora 34 - Updates Source
Disabilitato fedora Fedora 34 - x86_64
Disabilitato fedora-debuginfo Fedora 34 - x86_64 - Debug
Disabilitato fedora-source Fedora 34 - Source
Disabilitato rpmfusion-free-updates-testing RPM Fusion for Fedora 34 - Free - Test Updates
Disabilitato rpmfusion-free-updates-testing-debuginfo RPM Fusion for Fedora 34 - Free - Test Updates Debug
Disabilitato rpmfusion-free-updates-testing-source RPM Fusion for Fedora 34 - Free - Test Updates Source
Disabilitato rpmfusion-nonfree-updates-testing RPM Fusion for Fedora 34 - Nonfree - Test Updates
Disabilitato rpmfusion-nonfree-updates-testing-debuginfo RPM Fusion for Fedora 34 - Nonfree - Test Updates Debug
Disabilitato rpmfusion-nonfree-updates-testing-source RPM Fusion for Fedora 34 - Nonfree - Test Updates Source
Disabilitato updates-testing-modular Fedora Modular 34 - x86_64 - Test Updates
Disabilitato updates-testing-modular-debuginfo Fedora Modular 34 - x86_64 - Test Updates Debug
Disabilitato updates-testing-modular-source Fedora Modular 34 - Test Updates Source
Disabilitato fedora-modular Fedora Modular 34 - x86_64
Disabilitato fedora-modular-debuginfo Fedora Modular 34 - x86_64 - Debug
Disabilitato fedora-modular-source Fedora Modular 34 - Source
Disabilitato updates-modular Fedora Modular 34 - x86_64 - Updates
Disabilitato updates-modular-debuginfo Fedora Modular 34 - x86_64 - Updates - Debug
Disabilitato updates-modular-source Fedora Modular 34 - Updates Source
Disabilitato copr:copr.fedorainfracloud.org:kwizart:fedy Copr repo for fedy owned by kwizart
Disabilitato brave-browser-rpm-release.s3.brave.com_x86_64_ created by dnf config-manager from https://brave-browser-rpm-release.s3.brave.com/x86_64/
Disabilitato fedora-cisco-openh264 Fedora 34 openh264 (From Cisco) - x86_64
Disabilitato fedora-cisco-openh264-debuginfo Fedora 34 openh264 (From Cisco) - x86_64 - Debug
Disabilitato google-earth-pro google-earth-pro
Disabilitato MEGAsync MEGAsync
Disabilitato opera Opera packages
Disabilitato rpmfusion-free RPM Fusion for Fedora 34 - Free
Disabilitato rpmfusion-free-debuginfo RPM Fusion for Fedora 34 - Free - Debug
Disabilitato rpmfusion-free-source RPM Fusion for Fedora 34 - Free - Source
Disabilitato rpmfusion-free-tainted RPM Fusion for Fedora 34 - Free tainted
Disabilitato rpmfusion-free-tainted-debuginfo RPM Fusion for Fedora 34 - Free tainted - Debug
Disabilitato rpmfusion-free-tainted-source RPM Fusion for Fedora 34 - Free tainted - Source
Disabilitato rpmfusion-free-updates RPM Fusion for Fedora 34 - Free - Updates
Disabilitato rpmfusion-free-updates-debuginfo RPM Fusion for Fedora 34 - Free - Updates Debug
Disabilitato rpmfusion-free-updates-source RPM Fusion for Fedora 34 - Free - Updates Source
Disabilitato rpmfusion-nonfree RPM Fusion for Fedora 34 - Nonfree
Disabilitato rpmfusion-nonfree-debuginfo RPM Fusion for Fedora 34 - Nonfree - Debug
Disabilitato rpmfusion-nonfree-source RPM Fusion for Fedora 34 - Nonfree - Source
Disabilitato rpmfusion-nonfree-updates RPM Fusion for Fedora 34 - Nonfree - Updates
Disabilitato rpmfusion-nonfree-updates-debuginfo RPM Fusion for Fedora 34 - Nonfree - Updates Debug
Disabilitato rpmfusion-nonfree-updates-source RPM Fusion for Fedora 34 - Nonfree - Updates Source

As you can see, nothing changes.

I don’t know if it will be useful, but I started packagekit in “verbose” mode.
Documentation: PackageKit - Reporting Bugs

https://paste.centos.org/view/32466de9

I repeated it again, found these logs, I hope they add some more information:

0	get-updates	/2171_caacaded	state[finished] exclusive[1] background[0]
1	get-updates	/2172_aebbbbbe	state[finished] exclusive[1] background[0]
2	get-updates	/2173_edcbbabe	state[finished] exclusive[1] background[0]
3	get-updates	/2174_ddbddbcd	state[finished] exclusive[1] background[0]
4	get-updates	/2175_eabdbcad	state[finished] exclusive[1] background[0]
5	unknown	/2176_debebbda	state[new] exclusive[0] background[0]

18:39:59	PackageKit	1 have an unknown role (CreateTransaction then nothing?)
18:39:59	PackageKit	State:
0	get-updates	/2171_caacaded	state[finished] exclusive[1] background[0]
1	get-updates	/2172_aebbbbbe	state[finished] exclusive[1] background[0]
2	get-updates	/2173_edcbbabe	state[finished] exclusive[1] background[0]
3	get-updates	/2174_ddbddbcd	state[finished] exclusive[1] background[0]
4	get-updates	/2175_eabdbcad	state[finished] exclusive[1] background[0]
5	unknown	/2176_debebbda	state[new] exclusive[0] background[0]

18:39:59	PackageKit	1 have not been committed and may be pending auth
18:39:59	PackageKit	transaction /2171_caacaded completed, removing
18:39:59	PackageKit	emitting destroy /2171_caacaded
18:39:59	PackageKit	SetHints method called: locale=C, background=false, interactive=true, cache-age=4294967295
18:39:59	PackageKit	cache-age changed to 4294967295
18:39:59	PackageKit	GetUpdates method called
18:39:59	PackageKit	transaction now ready
18:39:59	PackageKit	changing transaction to exclusive mode
18:39:59	PackageKit	5 transactions in list, 1 committed but not finished
18:39:59	PackageKit	transaction now running
18:39:59	PackageKit	install uid now 1000
18:39:59	PackageKit	install cmdline now PackageKit: get-updates
18:39:59	PackageKit	setting role for /2176_debebbda to get-updates
18:39:59	PackageKit-DNF	using cached sack DnfSack::release_ver[34]::filelists|remote
18:39:59	PackageKit	backend was running for 51 ms
18:39:59	PackageKit	emitting finished 'success', 51
18:39:59	PackageKit	transaction now finished
18:39:59	PackageKit	5 transactions in list, 0 committed but not finished

No. I don’t know. In a VM I enabled the repositories you have. I’ve installed and removed packages, performed updates and so on, but when the operations are concluded, the log stays silent: I’m unable to reproduce all this flood.

I don’t remember. Did you already try to perform this command?
pkcon repair

Or/and

sudo systemctl stop packagekit.service && sudo rm -rf /var/cache/PackageKit/* && sudo systemctl start packagekit.service

then

pkcon refresh -v

If nothing changes, I would file a new bug highlighting that the log is flooded even if all the repositories are disabled.


Unfortunately it doesn’t solve

Not related to Fedora 1820931 – PackageKit get-updates being called every second, but interesting.
It says "PackageKit does not schedule it’s own transactions. Something must be calling into PackageKit in a loop […] You need to find the process that’s calling PackageKit. Maybe top or ps would help?

1 Like

Unfortunately I can’t find it, but when I enable the “verbose”, it seems that packagekit is called by DNF:

lug 06 15:11:35 desktop packagekitd[1418]: 15:11:35 PackageKit trying to open database ‘/var/lib/PackageKit/transactions.db’
lug 06 15:11:35 desktop packagekitd[1418]: 15:11:35 PackageKit-DNF using cached sack DnfSack::release_ver[34]::filelists|remote

Thanks for your help.

Sorry if I suggest random things.
Could you try to kill gnome-software and see if the issue is still here?
killall gnome-software

Unfortunately it doesn’t solve, I tried it.

1 Like

Ok. Let’s try to isolate the issue.
Since this continuous get-updates seems triggered by user id 1000 (your user), could you try to create a new user, log off and log in with such brand new user?

1 Like

Ok, changing user, the problem doesn’t seem to arise.
So at this point is there any user configuration calling packagekitd? which could be?

Mmh. Maybe some GNOME extension? Some user’s systemd timer? Some program that automatically start when the user log in?

I’ll have to look better. But a software shouldn’t start that way without knowing who starts it.
I exclude extensions because I have the same extensions in the other user. I’ve already removed dnfdragora, and it’s not him.
I’ll research what causes this very annoying problem and let you know if I have any news.
Thanks Alessio!

Maybe it is not an extension. But, have you enabled all the same extensions as well for the new user?

Eeeh. Who knows :slight_smile:

You could file an issue directly to PackageKit developers. Maybe asking (or searching in the issues) if there is a way to know who invoke it and maybe if it is possible to implement it in future releases.

Uh uh. In a previous screenshot I’ve seen that you use Byobu? Is it?
Maybe the issue is the following one?

4 Likes

Great Alessio!
He was just byobu! When I open byobu I have a flood of packagekit logs which stops as soon as I close it.

2 Likes

Great.
Have you searched if there is already a bug report, a solution or a workaround, related to that bad behavior? (Apart closing byobu :sweat_smile:)

1 Like

The workaround will be to not enable the updates notification bit in byobu. (I’ve been using byobu for years now and never used it, which is why I wasn’t seeing a similar flood).

So, in a byobu session, byobu-config and then toggle the updates notification off.

It really is a very weird way of polling for updates. Here’s the bug report against byobu: Bug #1828115 ""updates_available” feature floods PackageKit with... : Bugs : byobu

@emanuc If you can file an issue against the Fedora package, maybe the maintainer can modify this until upstream fixes it?

https://docs.fedoraproject.org/en-US/quick-docs/howto-file-a-bug/

File a new bug in the “byobu” component of the “Fedora” product

You will be able to login to bugzilla using your Fedora account.

2 Likes

I reported it, hopefully right: https://bugzilla.redhat.com/show_bug.cgi?id=1980327

2 Likes

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.