Forums

Skip to content

Advanced search
  • Quick links
    • Unanswered topics
    • Active topics
    • Search
  • FAQ
  • Login
  • Register
  • Board index Assistance Desktop Environments
  • Search

gam_server (app-admin/gamin) eats CPU

Problems with GUI applications? Questions about X, KDE, Gnome, Fluxbox, etc.? Come on in. NOTE: For multimedia, go up one forum
Post Reply
Advanced search
14 posts • Page 1 of 1
Author
Message
xororand
Tux's lil' helper
Tux's lil' helper
Posts: 119
Joined: Thu Jul 22, 2004 10:38 am

gam_server (app-admin/gamin) eats CPU

  • Quote

Post by xororand » Sat May 27, 2006 11:55 pm

I've recently noticed that a process called gam_server - started by kded - eats about 20-30% when using my system normally, for example compiling something. Apparently app-admin/gamin is a replacement for the FAM File Alteration Monitor and makes use of the inotify feature in 2.6 kernels. It's said to be quite fast due to that.
Though I've activated inotify it still eats CPU.
Do you have any suggestions how to prevent this? Unmerging doesn't work as gnome-base/gnome-vfs-2.14.1 depends on ganim. At least emerge gives me this error when trying to emerge gnome-vfs with gamin masked: http://phpfi.com/120254
Top
xororand
Tux's lil' helper
Tux's lil' helper
Posts: 119
Joined: Thu Jul 22, 2004 10:38 am

  • Quote

Post by xororand » Sun May 28, 2006 12:30 am

Solved. You have to tell gamin to use the INOTIFY kernel feature with this line in /etc/gamin/gaminrc:
notify /*

More information on: http://www.gnome.org/~veillard/gamin/config.html
Top
suredeath
Tux's lil' helper
Tux's lil' helper
User avatar
Posts: 101
Joined: Tue Aug 15, 2006 10:30 am
Location: Easterwood, N.Br., The Netherlands
Contact:
Contact suredeath
Website

gam_server cpu load high

  • Quote

Post by suredeath » Sat Oct 21, 2006 9:01 am

Since last world update gam_server is typically topping the proces list in top using 7 to 8 % cpu constantly, 24/7. I never before noticed any activity of gamin at all. Nowhere on my box I can find a gaminrc file of any sorts. In another thread I read gam_server was constantly adding stuff to error logs, so I tried running df a few times to see whether somewhere disk space was rapidly being consumed. Nothing. I just have no clue where this sudden behaviour came from and how to end it. Killing the process won't help, it just respawns after a few moments. I have NOT changed anything to my kernel configuration either. I have not been able to tie the activity to some specific other app running on my system.

My system configuration (in detail) at http://www.xs4all.nl/~sjoerdw/users/sch ... ms/gentoo/ if that's any help. Thanks in advance.
Top
CRV§ADER//KY
Guru
Guru
User avatar
Posts: 405
Joined: Mon Aug 30, 2004 6:47 pm
Location: Torino
Contact:
Contact CRV§ADER//KY
Website

  • Quote

Post by CRV§ADER//KY » Mon Oct 30, 2006 2:20 am

same problem. I let my XFCE 4.3.9 run for several hours alone, then I came back and, WTF, 60% CPU consumption by gam_server on my athlon 2000+ 8O
Kyrie, Ignis Divine, Eleison ~ Elfen Lied
Top
friedmud
Apprentice
Apprentice
User avatar
Posts: 258
Joined: Thu Apr 18, 2002 8:49 pm
Location: Austin, TX USA

  • Quote

Post by friedmud » Thu Nov 16, 2006 1:22 am

Same problem here.... any resolution?

Friedmud
Top
CRV§ADER//KY
Guru
Guru
User avatar
Posts: 405
Joined: Mon Aug 30, 2004 6:47 pm
Location: Torino
Contact:
Contact CRV§ADER//KY
Website

  • Quote

Post by CRV§ADER//KY » Thu Nov 16, 2006 8:59 am

I tried putting this in /etc/gamin/gaminrc:

Code: Select all

notify /*
fsset ext2 kernel
fsset ext3 kernel
fsset reisefs kernel
fsset vfat kernel
fsset fat kernel
fsset fat32 kernel
fsset ntfs kernel
fsset tmpfs kernel
So far, I haven't had any more CPU consumptions... but since they're quite random, I'm still waiting before I say the solution actually works.
Kyrie, Ignis Divine, Eleison ~ Elfen Lied
Top
antares2001
Guru
Guru
User avatar
Posts: 339
Joined: Tue Mar 02, 2004 3:37 pm
Location: Germany

  • Quote

Post by antares2001 » Sun Nov 19, 2006 12:45 pm

What is gamin exactly good for so I cannot live without it any more (I mean it is version 0.1.7 !!!!!)? Can I do without it, is there any replacement? Or can my system run also without gamin (also I see it is a dependency of kdelibs)?
* Toshiba SM30X Notebook, Pentium-M 725 CPU, ATI Radeon 9700, 512MB RAM, 80GB
* Pentium D 820 2,8 GHz (EM64T), Geforce6, 200GB + 40GB ATA, 250GB SATA2, WinFastTV 2000XP, 1,5GB RAM
Gentoo Linux 2006.1
Top
suredeath
Tux's lil' helper
Tux's lil' helper
User avatar
Posts: 101
Joined: Tue Aug 15, 2006 10:30 am
Location: Easterwood, N.Br., The Netherlands
Contact:
Contact suredeath
Website

  • Quote

Post by suredeath » Sun Nov 19, 2006 3:14 pm

CRV§ADER//KY wrote:I tried putting this in /etc/gamin/gaminrc:

Code: Select all

notify /*
fsset ext2 kernel
fsset ext3 kernel
fsset reisefs kernel
fsset vfat kernel
fsset fat kernel
fsset fat32 kernel
fsset ntfs kernel
fsset tmpfs kernel
So far, I haven't had any more CPU consumptions... but since they're quite random, I'm still waiting before I say the solution actually works.
I followed your example, and unfortunately I can say the dude's back, I'm upgrading my kde and suddenly gam_server reraised its ugly head. On my box always the same percentage cpu (abt 6 to 7) after a while. As others have wondered, where did this mofu come from and why do we need it? Never saw it, until about a month and a half ago. I read some pages on it, and still it is unclear to me what it is exactly good for. Then again, I am thick as wood of course.
Top
friedmud
Apprentice
Apprentice
User avatar
Posts: 258
Joined: Thu Apr 18, 2002 8:49 pm
Location: Austin, TX USA

  • Quote

Post by friedmud » Sun Nov 19, 2006 5:51 pm

I am pretty sure that gam_server is related to KDE auto-refreshing the file-system.

Have you ever noticed that KDE is johnny on the spot when it comes to showing you new files in a folder? For instance, you can have a fold open and then populate it with some script in the background and as soon as files appear KDE knows about them and displays them. Another instance is when you have a file open.... like a PDF in KPDF and then you update that PDF.... and KPDF knows about it and reloads the PDF (this scenario is my life right now... while I'm writing my thesis in Latex using Kile).

Like I say... I'm pretty sure that gam_server is there to tell KDE when files and folders are updated.

I believe the problem manifests itself in ~/.xsession_errors. If you open that up you will see:

Code: Select all

nd from FAM server connection
invalid length 24902
invalid length 24902
invalid length 24902
invalid length 24902
end from FAM server connection
invalid length 24902
invalid length 24902
invalid length 24902
invalid length 24902
end from FAM server connection
invalid length 24902
It looks like maybe the newest KDE isn't playing well with gam_server. They are probably yelling back and forth to eachother and this is causing some of the CPU usage we're all seeing.

I'm actually having the opposite problem though.... my KPDF is intermittently _not_ wanting to update when the PDF updates now.... it's _highly_ annoying... and I think it's tied to this whole gam_server issue.

If anyone out there knows how to _actually_ fix this problem (and not by telling gam_server to ignore a crapload of your files... because I actually do need gam_server to work)... please chime in!

Friedmud
Top
CRV§ADER//KY
Guru
Guru
User avatar
Posts: 405
Joined: Mon Aug 30, 2004 6:47 pm
Location: Torino
Contact:
Contact CRV§ADER//KY
Website

  • Quote

Post by CRV§ADER//KY » Sun Nov 19, 2006 8:37 pm

suredeath wrote:As others have wondered, where did this mofu come from and why do we need it? Never saw it, until about a month and a half ago. I read some pages on it, and still it is unclear to me what it is exactly good for. Then again, I am thick as wood of course.
gamin is a file alteration monitor. Applications can use it to listen for modifications to files or to the content of a directory. it's ABI compatible with FAM but, unlike fam, it doesn't do polling, but instead it supports the kernel inotify interface that doesn't have the overhead typical of polling (except bugs like this one).

If the CPU consumption problem is too annyoing for you, unmerge it and emerge fam. note that, unlike gamin, fam requires a daemon to run; otherwise your application won't know when a file or directory changes.
Kyrie, Ignis Divine, Eleison ~ Elfen Lied
Top
Shamus397
Apprentice
Apprentice
User avatar
Posts: 218
Joined: Sun Apr 03, 2005 2:01 pm
Location: Ur-th

  • Quote

Post by Shamus397 » Thu Jul 05, 2007 3:39 am

gamin 0.1.8 supposedly fixes the CPU hogging bug as so I would suggest trying that if you're experiencing this problem. As seen in this bug.

I had to log out of X, then

Code: Select all

su killall gam_server
before starting X up again. Now gam_server is behaving as it should. 8)
Top
DeathAndTaxes
Tux's lil' helper
Tux's lil' helper
Posts: 124
Joined: Thu Mar 27, 2003 12:02 am

  • Quote

Post by DeathAndTaxes » Fri Aug 03, 2007 4:43 pm

Shamus397 wrote:gamin 0.1.8 supposedly fixes the CPU hogging bug as so I would suggest trying that if you're experiencing this problem. As seen in this bug.

I had to log out of X, then

Code: Select all

su killall gam_server
before starting X up again. Now gam_server is behaving as it should. 8)
gam_server seems to still misbehave on nfs shares. I've tried disabling gam_server entirely (none /*) in /etc/gamin/gaminrc and in ~/.gaminrc, but it still pegs the cpu periodically (an unpredictably) on some nfs shares.

mv gam_server gam_server.movedbecauseitsbroken ; killall nautilus was the only viable workaround I have found.
Top
Tanj
Tux's lil' helper
Tux's lil' helper
User avatar
Posts: 79
Joined: Thu Oct 17, 2002 2:24 am
Location: London Ontario Canada

  • Quote

Post by Tanj » Mon Dec 17, 2007 10:30 pm

I just noticed this process on my work server today. Didn't know what it was for or where it came from. When I got home from work I checked my gentoo box and there is no trace of it anywhere. My home box is more up to date then the server is so I don't understand why the server has it but my home box doesn't.

I use fluxbox for my window manager and I don't think I have kde or gnome installed. I do have some kde apps though so maybe it got pulled in with one of them. It isn't from what I can notice using any resources so i'm not too concerned about it now. I will keep an eye on it for a few weeks.
Please don't make ignorant statements. It hurts my brain.
Top
asroka
n00b
n00b
User avatar
Posts: 19
Joined: Fri Nov 01, 2002 10:18 pm
Location: Los Angeles, CA USA

  • Quote

Post by asroka » Fri Jul 25, 2008 4:26 am

I just noticed this problem on both of my laptops (MacBook Pro running 2.6.25-mactel amd64, my work machine, and Dell Latitude D610 running 2.6.26-gentoo x86.) gam_server process running in the background pegs the processor. More of a pain on the older machine for obvious reasons. I couldn't find any good reason for this. I use xfce 4.4.2, but I do have a couple Gnome and/or KDE apps installed.

Code: Select all

equery depends gamin
produces:

Code: Select all

[ Searching for packages depending on gamin... ]
dev-libs/glib-2.16.3-r1 (fam? virtual/fam)
gnome-base/gnome-vfs-2.20.1-r1 (virtual/fam)
www-servers/lighttpd-1.4.19-r2 (fam? virtual/fam)
xfce-base/thunar-0.9.0-r2 (virtual/fam)
Sooo...

Code: Select all

emerge --unmerge gamin
emerge -av fam
rc-config start famd
rc-update add famd default
and add "fam" useflag to /etc/make.conf

don't forget to run a revdep-rebuild so that apps linked against gamin will be rebuilt against fam.

The interesting thing here is that gamin is *supposed* to outperform fam and is thus recommended. Reality seems to contradict this. Plus fam supposedly does some stuff that gamin doesn't do (If I cared about those things I might know what they were ;-)
Top
Post Reply

14 posts • Page 1 of 1

Return to “Desktop Environments”

Jump to
  • Assistance
  • ↳   News & Announcements
  • ↳   Frequently Asked Questions
  • ↳   Installing Gentoo
  • ↳   Multimedia
  • ↳   Desktop Environments
  • ↳   Networking & Security
  • ↳   Kernel & Hardware
  • ↳   Portage & Programming
  • ↳   Gamers & Players
  • ↳   Other Things Gentoo
  • ↳   Unsupported Software
  • Discussion & Documentation
  • ↳   Documentation, Tips & Tricks
  • ↳   Gentoo Chat
  • ↳   Gentoo Forums Feedback
  • ↳   Duplicate Threads
  • International Gentoo Users
  • ↳   中文 (Chinese)
  • ↳   Dutch
  • ↳   Finnish
  • ↳   French
  • ↳   Deutsches Forum (German)
  • ↳   Diskussionsforum
  • ↳   Deutsche Dokumentation
  • ↳   Greek
  • ↳   Forum italiano (Italian)
  • ↳   Forum di discussione italiano
  • ↳   Risorse italiane (documentazione e tools)
  • ↳   Polskie forum (Polish)
  • ↳   Instalacja i sprzęt
  • ↳   Polish OTW
  • ↳   Portuguese
  • ↳   Documentação, Ferramentas e Dicas
  • ↳   Russian
  • ↳   Scandinavian
  • ↳   Spanish
  • ↳   Other Languages
  • Architectures & Platforms
  • ↳   Gentoo on ARM
  • ↳   Gentoo on PPC
  • ↳   Gentoo on Sparc
  • ↳   Gentoo on Alternative Architectures
  • ↳   Gentoo on AMD64
  • ↳   Gentoo for Mac OS X (Portage for Mac OS X)
  • Board index
  • All times are UTC
  • Delete cookies

© 2001–2026 Gentoo Foundation, Inc.

Powered by phpBB® Forum Software © phpBB Limited

Privacy Policy

 

 

magic