pcscd, sun java, 100% CPU usage

Todd Denniston Todd.Denniston at ssa.crane.navy.mil
Mon Jan 7 18:36:54 UTC 2008


Jeff Krebs wrote, On 01/02/2008 08:52 AM:
> * Tod Merley (todbot88 at gmail.com) wrote:
>> On Jan 1, 2008 9:51 PM, Jeff Krebs <jkrebs at tconl.com> wrote:
>>> Oddest issue with pcsc. I'm getting 100% CPU usage while running pcscd.
>>>
>>> Now to story...
>>>
>>> Finally got my CAC Card setup running and working.  I'm able to do what
>>> I need to do with PKI certificates and such.  Athena reader, Athena
>>> driver.  Started with java-1.7.0-icedtea.  Joy and happiness abounding
>>> except...
>>>
>>> IcedTea just wasn't doing it. CNN video wasn't working.  Odds and ends
>>> borked or not functioning.
>>>
>>> Managed to get all SunJava 1.6.0r3 packages built and installed under
>>> Fedora 8.  Even the jdbc and fonts.  My machine passed the Java.com test
>>> and even updated the java applets (hadn't seen that before).  Java works
>>> wonderful, everything seems to function  very well.  Except...
>>>
>>> Now, after removing IcedTea and installing Sun-Java, my CPU is at 100%.
>>> Top shows pcscd as #1, burning over 91% of the CPU.  This is a P4 1.6
>>> Ghz, and I have 1.2 G of RAM. I can stop pcscd through the "Services"
>>> configuration interface (via /usr/sbin/system-config-services).  The
>>> system CPU usage immediately drops to around 7%.  Much weeping and
>>> gnashing of teeth...
>>>
>>> Now, the question.  What's going on?  Why does Java appear to cause a
>>> race condition in pcscd?  I can certainly disable pcscd when I don't
>>> need it, but when I do need it, will I have to face high CPU usage?
>>>
>>>
>>> Jeff Krebs
>>>
>>>
>> Hi Jeff Krebs!
>>
>> I too do not understand what would make the smart card reader manager
>> go bonkers.  Perhaps Sun's java makes it look for the CAC verification
>> module which perhaps it cannot find?
>>
<SNIP>
>>
>> I have never gone so far into finding the actual problem as these
>> tools can take us.  Hopefully someone who has will chime in.
>>
>> I would love to hear what you do find and how you found it!
>>
>> Good Hunting!
>>
>> Tod
>>
> I did find something after a bit of searching on-line:
> 
> https://bugzilla.redhat.com/show_bug.cgi?id=374291
> 
> I'm not sure that the issue is related to SunJava.  The Fedora pcsc-lite 
> is currently at 1.3.3, and there have been five releases since then, 
> culminating in release 1.4.4.
> 
> On bugzilla, someone mentioned that 1.4.4 took care of the issue; I'll 
> roll my own pcsc-lite RPMs and see if that helps the issue.
> 
> Jeff Krebs
> 

On the system where I experienced it, the problem was that the 
ifd-cyberjack.bundle was being loaded by pcscd even though the reader was a 
CCID reader (SCR331 or GEMplus USB).  once `rpm -e ifd-cyberjack` and `service 
pcscd restart` were ran, all was well with the system.

I think it is like the two options available for syslog ... load just the ONE 
you need/want, not both.  Granted someone made ifd-egate a requirement for 
pcscd, which is just WRONG because pcscd does not need THAT ifd handler. 
pcscd only needs the _appropriate_ one for the hardware you have (I may be in 
a rarefied environment but the current standard for reader hardware seems to 
be ccid).

BTW comment to bug added.
-- 
Todd Denniston
Crane Division, Naval Surface Warfare Center (NSWC Crane)
Harnessing the Power of Technology for the Warfighter




More information about the fedora-list mailing list