Find the answer to your Linux question:
Results 1 to 4 of 4
Kworkers are going crazy and spoil OpenMp. term-1 top, term-2 cbm1 <- APP using OpenMP to calculate PI, term-3 exec command for debugging For about 5 minuts since APP started, ...
Enjoy an ad free experience by logging in. Not a member yet? Register.
  1. #1
    Just Joined!
    Join Date
    Mar 2012
    Posts
    3

    How could I stop kworkers going crazy?


    Kworkers are going crazy and spoil OpenMp.

    term-1 top,
    term-2 cbm1 <- APP using OpenMP to calculate PI,
    term-3 exec command for debugging

    For about 5 minuts since APP started, kworkers were sane,
    and APP used cpu 198% (dual core).
    Screenshot : "please change 'a' -> 'h' in 'attp' following and browse in the other windows. I'd not posted more than 14 YET. "
    Code:
    attp://a-wada.s30.xrea.com/xxknl/Screenshot-2012-02-22-13-16-08.png
    but, then kworkers woke up and ate cpu 80%+- incessantly
    and APP's went down to 100%+-.
    Code:
    attp://a-wada.s30.xrea.com/xxknl/Screenshot-2012-02-22-13-17-41.png
    attp://a-wada.s30.xrea.com/xxknl/Screenshot-2012-02-22-13-19-05.png
    attp://a-wada.s30.xrea.com/xxknl/Screenshot-2012-02-22-13-35-57.png
    referring to "7. Debugging" in "/usr/src/linux-source-3.0.0/Documentation/workqueue.txt"

    Code:
    a-wada:~/pai$ sudo su -c 'echo workqueue:workqueue_queue_work > /sys/kernel/debug/tracing/set_event'
    [sudo] password for a-wada:
    a-wada:~/pai$ sudo su -c 'cat /sys/kernel/debug/tracing/trace_pipe > out.txt'
    ^C
    a-wada:~/pai$ ll out*
    -rw-r--r-- 1 root root 23032133 2012-02-22 13:30 out.txt
    a-wada:~/pai$ sudo su -c 'cat /proc/THE_OFFENDING_KWORKER/stack > out2.txt'
    cat: /proc/THE_OFFENDING_KWORKER/stack: No such file or directory
    a-wada:~/pai$ ll out*
    -rw-r--r-- 1 root root 23032133 2012-02-22 13:30 out.txt
    -rw-r--r-- 1 root root 0 2012-02-22 13:33 out2.txt
    output of above commands
    Code:
    attp://a-wada.s30.xrea.com/xxknl/out.txt
    source-code of "cbm1" & log when executed normally
    Code:
    attp://a-wada.s30.xrea.com/pailnx64/paicbm.c
    Thanks in Advance.

    ###

    After 8 hours since original post, I'd updated kernel to "3.0.0-16-29 ubuntu" expecting BUG-fix.
    but it had not fixed my problem.
    Code:
    attp://a-wada.s30.xrea.com/xxknl/Screenshot-2012-03-10-00-42-13.png
    kworkers were still going "CRAZY"

    Please HELP
    Last edited by a-wada; 03-10-2012 at 03:17 AM.

  2. #2
    Just Joined!
    Join Date
    Mar 2012
    Posts
    3
    This is a response to my question.

    I could let "kworkers" be sane, by adding
    " acpi=off " to kernel parameters, referring to
    web: please change 'h' <- 'a' in 'attp' of NEXT
    Code:
    attp://morenews.blogspot.com/2011/08/when-kworkers-dont.html
    But it makes "auto poweroff at shutdown" disable, Moreover,

    perfomance of OpenMP Slow down to about 75% (without " acpi=off " 48% ).

    Aren't these "BUGs of KERNEL or LINUX" ?
    Last edited by a-wada; 03-14-2012 at 10:31 AM.

  3. #3
    Just Joined!
    Join Date
    Mar 2012
    Posts
    3
    Excuse me and very sorry everyone.
    Kworkers were discharging their duties, nevertheless I accused them unjustly.

    By my son's suggestion, I sensored the temperature of CPU. After 5 min APP started,
    coretemps went up both to almost 100C (threshold), and woke Kworkers up
    to reduce the load, I think. With " acpi=off ", Kworkers kept being sane but
    the performance had been degraded because of, maybe, high temperature.

    Removing dust from fins of CPU-cooler kept Kworkers sane without " acpi=off "
    and made the performance of OpenMP normal, too.

    Code:
    attp://a-wada.s30.xrea.com/xxknl/Screenshot-2012-03-17-11-28-08.png

  4. $spacer_open
    $spacer_close
  5. #4
    Linux Guru Rubberman's Avatar
    Join Date
    Apr 2009
    Location
    I can be found either 40 miles west of Chicago, in Chicago, or in a galaxy far, far away.
    Posts
    11,655
    I've experienced similar problem with system component (CPU or RAM) overheating. As a result, I monitor these issues continuously now, especially when I am running CPU/RAM-intensive processes. The lm_sensors package (and associated sensors command) help a lot in doing this in a server environment. On my workstation, I use a graphical system monitoring tool to do the same thing.
    Sometimes, real fast is almost as good as real time.
    Just remember, Semper Gumbi - always be flexible!

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •