Learn how easy it is to sync an existing GitHub or Google Code repo to a SourceForge project! See Demo

Close

#120 coLinux latest snapshot CPU under-utilization

closed
nobody
None
5
2008-01-24
2007-11-01
Ryan Underwood
No

I have installed the latest coLinux snapshot to upgrade my 0.6.4 installation.

Everything went fine, but the coLinux system is quite slow while Windows remains fast. There is no load on the Windows side, and only one running process on the coLinux side, which reads only up to 25% CPU utilization. It's almost as if some throttling is taking place. Unfortunately this slowdown renders a coLinux GUI unusable... even though the system is hardly loaded at all.

Discussion

  • Henry N.
    Henry N.
    2007-11-02

    Logged In: YES
    user_id=579204
    Originator: NO

    What version do you run? Please reffer the build date or the "dmesg|head -n1".
    What Host OS? (Win2000, WinXP, Vista)

    The utilization inside coLinux is not real. CoLinux runs slowly, if Windows dosn't give time to the process.

    Check the processes on windows side with ProcessExplorer (http://www.sysinternals.com, hosted on MS now). Does any coLinux process a highly context switch, or high I/O traffic?

    Run the colinux debugger and check for errors or messages:
    colinux-debug-daemon -d -p -f logfile.xml -s prints=31,misc=31

     
  • Logged In: NO

    What method are you using for displaying the GUI? (colinux framebuffer, X over TCP/IP, X over ssh, NX, VNC, etc)?

    There's not yet any X.org driver written with DRI or shared memory support, since Windows controls the hardware it wouldn't be safe for linux to write directly into video RAM (although it should be possible to allocate some video RAM using DirectX for linux to use -- probably this will become feasible once some of the paravirtualization work is done on video drivers for xen, kvm, etc)

     
  • Ryan Underwood
    Ryan Underwood
    2007-11-02

    Logged In: YES
    user_id=324742
    Originator: YES

    XDMCP login, but video is not the problem. Video drawing was fast before and still is. It's poorly performing even at console.

    There is no change from the previous stable installation where it ran fast. Unfortunately, I've overwritten my previous installation, so I don't know what the previous version was...

    WinXP SP2 host

    I'll post more details in a minute.

     
  • Ryan Underwood
    Ryan Underwood
    2007-11-02

    Logged In: YES
    user_id=324742
    Originator: YES

    I/O usage is between zero and "medium" on the scale (seems like no more than 10MB on the left graph).

    Context switch rate is about 250 per second.

    An empty XML logfile is produced... no errors.

    dmesg |head -n1:
    Linux version 2.6.12-co-0.7.1 (hn@coLinux) (gcc version 3.4.5 (mingw special)) #1 Sat Jul 14 12:13:49 UTC 2007

     
  • Henry N.
    Henry N.
    2007-11-02

    Logged In: YES
    user_id=579204
    Originator: NO

    Ok, have tested the same. Shure the scolling is not fast. But I never see it better.
    You should use the NT console, this is more faster. Or, the best: You use Putty and a SSH login.

    In the idle case my FLTK console has 980 CSwitch Delta (unter Threads in Process Explorer), and goes upt to 1450 while "ls /dev" is printed.
    Interesting: If I stepping down my CPU clock from 1800 MHz to 1200 MHz, then the CSwitch goes down to 1100 wihle "ls /dev" is running.

    Here my times on FLTK console (GUI) with CPU clock 1800 MHz
    # ls /dev | wc
    4832 4832 29049

    # time ls /dev
    ... lots of devices scrolls ...
    real 0m12.753s
    user 0m8.410s
    sys 0m4.340s

    On NT console
    # time ls /dev
    ... all devices ...
    real 0m3.657s
    user 0m2.780s
    sys 0m0.880s

    The same under Putty in a 80x25 screen:
    # time ls /dev
    ...
    real 0m1.028s
    user 0m0.270s
    sys 0m0.050s

     
  • Ryan Underwood
    Ryan Underwood
    2007-11-02

    Logged In: YES
    user_id=324742
    Originator: YES

    Scrolling is not the problem. I can pan a window and it is quite fast.

    It is a general CPU utilization problem. Programs start very slowly and run very slowly. This makes the GUI slow, even though scrolling and panning is fast, the response of the GUI to input events is very slow. Does that make more sense?

     
  • Henry N.
    Henry N.
    2007-11-02

    Logged In: YES
    user_id=579204
    Originator: NO

    In verification with old version 0.6.4 is no big difference:

    FLTK console:
    real 0m13.610s
    user 0m5.190s
    sys 0m8.420s

    NT conole:
    real 0m4.118s
    user 0m1.100s
    sys 0m3.020s

     
  • Henry N.
    Henry N.
    2007-11-02

    Logged In: YES
    user_id=579204
    Originator: NO

    Colinux runs only, if your Windows allows it. That is the "cooperative".

    Perhaps you have an other process on windows side, that eats more of the "idle" time, so coLinux must more break the running?

     
  • Ryan Underwood
    Ryan Underwood
    2007-11-02

    Logged In: YES
    user_id=324742
    Originator: YES

    No, nothing is using CPU on windows side, just as with previous version.

    I guess I have no idea what the problem is.

    I am using a Debian "lenny" distribution and XFCE desktop environment.

    The machine is a P4 3.4GHz with 2GB RAM and SCSI HD.

    It just doesn't make sense that coLinux is always very fast for almost a year now, then I upgrade and it is now very slow.

     
  • Henry N.
    Henry N.
    2007-11-02

    Logged In: YES
    user_id=579204
    Originator: NO

    Pentium P4 with PAE enabled ???

    Perhaps it is side effect from Workarrount for DEP/noexecute bug? This workarrount will clear the page cache on every OS switch. This can be slow down the performance.

    You should give the devel version 0.8.0 from http://www.colinux.org/snapshots/ a try. There the DEP/noexecute workarrount will set only ones per boot.

     
  • Logged In: NO

    Actually, I found the devel version (of August) to be slowest yet of all :-)

    I will try to go to a previous version and find out when the slowdown began.

     
  • Ryan Underwood
    Ryan Underwood
    2007-11-27

    Logged In: YES
    user_id=324742
    Originator: YES

    I noticed if I elevate the process priority using Process Explorer, now coLinux is fast again :-)

    I'm glad that the problem was really simple, but it's sort of strange that this was never required before. Did coLinux previously set its own priority or something similar?

     
  • Henry N.
    Henry N.
    2007-11-27

    Logged In: YES
    user_id=579204
    Originator: NO

    http://colinux.svn.sourceforge.net/viewvc/colinux?view=rev&revision=581
    CoLInux 0.6.4 does nothing on the task priority.
    In difference between 0.6.4 and 0.7.x the process priority for network daemons was increased. colinux-daemon runs unchanged from start. Have main task colinux-daemon problems now?

    Please try: Change the process priority for network daemons back to "normal". Is that better in your case?

    I have never seen such effect. Users ask often for changing priority. It's stays in the feature request #1824341 and will implement in version after 0.7.2

     
  • Ryan Underwood
    Ryan Underwood
    2007-11-27

    Logged In: YES
    user_id=324742
    Originator: YES

    colinux-net-daemon.exe already has priority of "Normal" by default...

     
  • Henry N.
    Henry N.
    2007-11-27

    Logged In: YES
    user_id=579204
    Originator: NO

    We talk about same version?

    Version 0.6.4.x and 0.7.1 all task have priorities 8 (normal).

    Version 0.7.2 has follow priorities:
    colinux-daemon 8 (normal)
    colinux-console-fltk|nt 8 (normal)
    colinux-net-daemon 13 (high)
    colinux-slirp-net-daemon 13 (high)
    colinux-bridged-net-daemon 13 (high)

     
  • Logged In: NO

    Anon says:
    I've used http://www.henrynestler.com/colinux/testing/devel-0.8.0/20070819/devel-coLinux-20070819.exe and it is VERY FAST.

    The CPU utilization of not maxed (but more than 25%).

    If I compile the GCC-4.1 compiler (takes a long time) on WinXP (with Cygwin) _AND_ at the same time compile it with coLinux the coLinux build is 4 or 5 times faster than the WinXP version (with same configure options).

    I use Cygwin's X11 and have many startup programs on WinXP and many daemons on coLinux.

    Despite my efforts to bog my system down coLinux (devel-coLinux-20070819.exe (and prior versions I tried)) is very fast.

     
  • Logged In: NO

    This seems to have cleared up now. Maybe it was a configuration or windows patch temporary problem (?) I'll reopen if I see it again.

     
  • Ryan Underwood
    Ryan Underwood
    2008-01-24

    • status: open --> closed