.Xmodmap file makes xorg temporarily reach high cpu usage (90%-100%) after resume or when coming back from tty to X session

Bug #998310 reported by avlas on 2012-05-12
48
This bug affects 9 people
Affects Status Importance Assigned to Milestone
linux (Ubuntu)
Low
Unassigned

Bug Description

Each time when I resume my laptop, my computer nearly freezes for about 5 minutes and Xorg is using 90-100% cpu. This issue disappears and then everything is back to normal.

ProblemType: Bug
DistroRelease: Ubuntu 12.04
Package: xorg 1:7.6+12ubuntu1
ProcVersionSignature: Ubuntu 3.2.0-24.38-generic 3.2.16
Uname: Linux 3.2.0-24-generic x86_64
ApportVersion: 2.0.1-0ubuntu7
Architecture: amd64
Date: Fri May 11 22:57:03 2012
EcryptfsInUse: Yes
InstallationMedia: Kubuntu 11.04 "Natty Narwhal" - Release amd64 (20110427)
ProcEnviron:
 LANGUAGE=ca_ES
 TERM=xterm
 LANG=ca_ES.UTF-8
 SHELL=/bin/bash
SourcePackage: xorg
UpgradeStatus: Upgraded to precise on 2012-03-25 (47 days ago)

avlas (avlas) wrote :
avlas (avlas) wrote :

I attach part of kern.log that may be useful

bugbot (bugbot) on 2012-05-24
tags: added: kubuntu
avlas (avlas) wrote :

This happens to me since I upgraded from oneiric, any clue of how to get rid of this annoying bug?

Bryce Harrington (bryce) wrote :

Generally high X CPU bugs are not due to X itself but rather due to a client program. See http://wiki.ubuntu.com/X/Troubleshooting/HighCPU and try filing a more specific bug report.

Changed in xorg (Ubuntu):
status: New → Invalid
avlas (avlas) wrote :

Thanks for the info...

Playing a bit with it, I realized that the issue is actually related to using a .Xmodmap file. When I remove it from $HOME the issue is gone but it comes back as soon as I create a new .Xmodmap (which is important for me to get catalan characters in a us keyboard).

summary: - xorg temporarily reaches high cpu usage (90%-100%) after resume
+ .Xmodmap file makes xorg temporarily reach high cpu usage (90%-100%)
+ after resume or when coming back from tty to X session
avlas (avlas) wrote :

I modify the title of this bug as well as the status as result of the new evidence...

Changed in xorg (Ubuntu):
status: Invalid → New
Launchpad Janitor (janitor) wrote :

Status changed to 'Confirmed' because the bug affects multiple users.

Changed in xorg (Ubuntu):
status: New → Confirmed
Steffen (fragone) wrote :

I have a related problem on a freshly installed Xubuntu 12.10.
When I type the following commands, everything but the mouse pointer freezes for several minutes.

xmodmap -pke > .Xmodmap
xmodmap ~/.Xmodmap

Sebastian Blask (blask) wrote :

Having a .Xmodmap file in my home directory under Xubuntu 12.10 causes 1 or my CPU cores to use 100% on startup for every login. xfsettingsd uses quite some CPU as well. When I suspend it, X stops using all the CPU and resuming it makes X using all the CPU again. After a few minutes all is back to normal. During this time, None of the keys is usable.

kmic (kmic2006) wrote :

I had the same problem on my Xubuntu 12.04 too, but only for new created accounts, not for my existing one. After some hours of trial and error I've got the one file, which made the difference: It was ~/.cache/sessions/xfce4-session-MYCOMPUTERNAME:0 . So simply saving the desktop session once solved the issue for me.

The hole problem and the solution/workaround is easily to reproduce, at least on my machine with Xubuntu 12.04:
1. Create a new user account with an completly empty home-directory.
2. Copy the .Xmodmap file to that home-directory.
3. Log in. There will be a lot of files automatically created, the .Xmodmap file will be read in and Xorg will run at 100%.
4. Ignore what Xorg is doing and go (under XFCE) to Main menu -> Settings -> Settings -> Session and Startup -> Session -> Save session.
5. Wait until the session is saved, log out, log in and everything is fine. The .Xmodmap is read in, but no Xorg running at 100%.

Notes:
- Maybe you have on an existing account also to disable the xfce4-settings-helper in Main menu -> Settings -> Settings -> Session and Startup -> Application Autostart, but I'm not sure about that.
- When I manually read in the .Xmodmap with the command "xmodmap ~/.Xmodmap", there will still be 100% CPU for about one minute, both in the existing and in the new account. But because I do not need to read it in manually, this is, at least for me, no problem.
- Debian seems to have the same bug, see http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=687112 .

avlas, this bug was reported a while ago and there hasn't been any activity in it recently. We were wondering if this is still an issue? If so, could you please confirm this issue exists with the latest development release of Ubuntu? ISO images are available from http://cdimage.ubuntu.com/daily-live/current/ . If the issue remains, could you please run the following command from a Terminal (Applications->Accessories->Terminal), as it will automatically gather and attach updated debug information to this report:

apport-collect -p linux <replace-with-bug-number>

If reproducible, could you please provide the information following https://wiki.ubuntu.com/DebuggingKernelSuspend ?

If reproducible, could you also please test the latest upstream kernel available (not the daily folder) following https://wiki.ubuntu.com/KernelMainlineBuilds ? It will allow additional upstream developers to examine the issue. Once you've tested the upstream kernel, please comment on which kernel version specifically you tested. If this bug is fixed in the mainline kernel, please add the following tags:
kernel-fixed-upstream
kernel-fixed-upstream-VERSION-NUMBER

where VERSION-NUMBER is the version number of the kernel you tested. For example:
kernel-fixed-upstream-v3.3.13-rc6

This can be done by clicking on the yellow circle with a black pencil icon next to the word Tags located at the bottom of the bug description. As well, please remove the tag:
needs-upstream-testing

If the mainline kernel does not fix this bug, please add the following tags:
kernel-bug-exists-upstream
kernel-bug-exists-upstream-VERSION-NUMBER

As well, please remove the tag:
needs-upstream-testing

Once testing of the upstream kernel is complete, please mark this bug's Status as Confirmed. Please let us know your results. Thank you for your understanding.

affects: xorg (Ubuntu) → linux (Ubuntu)
Changed in linux (Ubuntu):
importance: Undecided → Low
status: Confirmed → Incomplete
peer_gynt (andre--ubuntu) wrote :

I still see this on Mint 16, fresh install. Not sure if this is relevant to this ubuntu tracker, but wanted to mention it.

peer_gynt, thank you for your comment. Unfortunately, reporting bugs about Mint wouldn't be terribly helpful here. However, if this would be reproducible in Ubuntu with your hardware, please feel free file a new report in Ubuntu (not Mint) by executing the following in a terminal:
ubuntu-bug xorg

Please ensure you have xdiagnose installed, and that you click the Yes button for attaching additional debugging information.

For more on this, please see the official Ubuntu documentation:
Ubuntu X.Org Team, Ubuntu Bug Control, and Ubuntu Bug Squad: https://wiki.ubuntu.com/Bugs/BestPractices#X.2BAC8-Reporting.Focus_on_One_Issue
Ubuntu Community: https://help.ubuntu.com/community/ReportingBugs#Bug_reporting_etiquette

When opening up the new report, please feel free to subscribe me to it.

Please note, not filing a new report will delay your problem being addressed as quickly as possible.

Thank you for your understanding.

Krylov Ivan (krylov-r00t) wrote :

I couldn't reproduce this bug in Xubuntu 14.04. Also, there is no /usr/bin/xfce4-settings-helper which caused Xorg to eat 100% CPU.

icyrock.com (icyrock-com) wrote :

May be related to https://bugs.launchpad.net/ubuntu/+source/xfce4-settings/+bug/1395547, using Xubuntu 14.10. The behavior doesn't look completely the same, only similar.

I can confirm this bug for Xubuntu 16.04
Kmoc's workaround does not help.

Please tell me how I can assist with further information.

ITEAS (info-tux-pc) wrote :

I can confirm this bug for Kubuntu 16.04 too. Any workaround?

kayn (pulecp) wrote :

I can confirm this issue on Archlinux. My workaround is to remove ~/.Xmodmap because I don't need it. Make a copy before you remove it.

frank (tristram) wrote :

I can confirm this (1 minute high load) for manually creating and using a .Xmodmap file for my fedora 23 with Xfce 4.12.

simple commands

xmodmap -pke > .Xmodmap
xmodmap .Xmodmap

in home directory produce it

efa (efa) wrote :

confirmed on
Ubuntu 16.04.4
Kernel: 4.4.0-124-generic
xorg: X11R7.7+13ubuntu3 X.Org X Server 1.18.4

Marc Neiger (marc-i) wrote :

still here on
Mint 19.1 xfce
kernel 4.18.0-13-generic

To post a comment you must log in.
This report contains Public information  Edit
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.