LinuxQuestions.org
Share your knowledge at the LQ Wiki.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Slackware
User Name
Password
Slackware This Forum is for the discussion of Slackware Linux.

Notices


Reply
  Search this Thread
Old 11-21-2010, 12:38 PM   #16
Ian John Locke II
Member
 
Registered: Mar 2008
Location: /dev/null
Distribution: Slackware, Android, Slackware64
Posts: 130

Rep: Reputation: 17

Quote:
Originally Posted by BrZ View Post
@Linux and Ian,

When firing up the thing, I got:


'cgroup path is (null)'? <-- ok?

Would you mind sharing your configs for libcgroup and kernel (cgroup)? =]
To be fair, I haven't tried out the fix, I was just saying you can always source your rc file. Sorry.
 
Old 11-21-2010, 07:23 PM   #17
BrZ
Member
 
Registered: Apr 2009
Distribution: Slackware
Posts: 543

Rep: Reputation: 121Reputation: 121
No problem. Libcg is a clever tool, but totally overkill for my desktop =]

The patch applied without error and, until now, no problems. 'cat /proc/sys/kernel sched_autogroup_enabled' return '1'.

Using the 'mount' and '.bash.rc' method, 'ps O cgroup' gave:
Quote:
# ps O cgroup
PID TTY STAT TIME COMMAND
19933 tty3 R<s+ 1:18 /usr/bin/X :0 -nolisten tcp -br -auth /root/.serverau
1504 tty2 Ss+ 0:00 /sbin/agetty 38400 tty2 linux
22415 pts/3 S+ 0:00 /usr/lib64/gcc/x86_64-slackware-linux/4.5.1/../../../
22429 pts/3 S+ 0:00 /usr/lib64/gcc/x86_64-slackware-linux/4.5.1/../../../
22445 pts/3 S+ 0:00 /usr/lib64/gcc/x86_64-slackware-linux/4.5.1/../../../
22461 pts/3 S+ 0:00 /usr/lib64/gcc/x86_64-slackware-linux/4.5.1/../../../
22361 pts/3 S+ 0:00 /usr/lib64/gcc/x86_64-slackware-linux/4.5.1/../../../
21950 pts/3 S+ 0:00 /usr/lib64/gcc/x86_64-slackware-linux/4.5.1/../../../
12575 tty1 Ss 0:00 -bash
20352 pts/0 Ss 0:00 bash
21671 pts/3 Ss 0:00 bash
22317 pts/4 Ss+ 0:00 bash
22460 pts/3 R+ 0:00 /usr/libexec/gcc/x86_64-slackware-linux/4.5.1/cc1 -qu
22444 pts/3 R+ 0:00 /usr/libexec/gcc/x86_64-slackware-linux/4.5.1/cc1 -qu
22428 pts/3 R+ 0:00 /usr/libexec/gcc/x86_64-slackware-linux/4.5.1/cc1 -qu
22414 pts/3 R+ 0:00 /usr/libexec/gcc/x86_64-slackware-linux/4.5.1/cc1 -qu
22360 pts/3 R+ 0:00 /usr/libexec/gcc/x86_64-slackware-linux/4.5.1/cc1 -qu
21948 pts/3 R+ 0:02 /usr/libexec/gcc/x86_64-slackware-linux/4.5.1/cc1 -qu
22412 pts/3 S+ 0:00 gcc -Wp,-MD,arch/x86/mm/.fault.o.d -nostdinc -isystem
22459 pts/3 S+ 0:00 gcc -Wp,-MD,arch/x86/kernel/.irqinit.o.d -nostdinc -i
21941 pts/3 S+ 0:00 gcc -Wp,-MD,kernel/.sched.o.d -nostdinc -isystem /usr
22359 pts/3 S+ 0:00 gcc -Wp,-MD,fs/.read_write.o.d -nostdinc -isystem /us
22427 pts/3 S+ 0:00 gcc -Wp,-MD,arch/x86/kernel/.i8259.o.d -nostdinc -isy
22443 pts/3 S+ 0:00 gcc -Wp,-MD,mm/.oom_kill.o.d -nostdinc -isystem /usr/
21909 pts/3 S+ 0:00 make -f scripts/Makefile.build obj=arch/x86
22174 pts/3 S+ 0:00 make -f scripts/Makefile.build obj=arch/x86/mm
21939 pts/3 S+ 0:00 make -f scripts/Makefile.build obj=mm
21920 pts/3 S+ 0:00 make -f scripts/Makefile.build obj=kernel
22205 pts/3 S+ 0:00 make -f scripts/Makefile.build obj=fs
21922 pts/3 S+ 0:00 make -f scripts/Makefile.build obj=arch/x86/kernel
21684 pts/3 S+ 0:00 make -j7 bzImage
22465 pts/3 R+ 0:00 objdump -M x86-64 -hdr arch/x86/kernel/setup.o
22462 pts/3 S+ 0:00 perl /usr/src-2/linux-2.6.36/scripts/recordmcount.pl
22466 pts/0 R+ 0:00 ps O cgroup
22374 pts/3 S+ 0:00 /bin/sh -c set -e; ? echo ' CC arch/x86/kerne
22410 pts/3 S+ 0:00 /bin/sh -c set -e; ? echo ' CC arch/x86/mm/fa
22442 pts/3 S+ 0:00 /bin/sh -c set -e; ? echo ' CC mm/oom_kill.o'
22458 pts/3 S+ 0:00 /bin/sh -c set -e; ? echo ' CC arch/x86/kerne
21930 pts/3 S+ 0:00 /bin/sh -c set -e; ? echo ' CC kernel/sched.o
22352 pts/3 S+ 0:00 /bin/sh -c set -e; ? echo ' CC fs/read_write.
22426 pts/3 S+ 0:00 /bin/sh -c set -e; ? echo ' CC arch/x86/kerne
19916 tty1 S+ 0:00 /bin/sh /usr/bin/startx
19915 tty1 S+ 0:00 /bin/bash /bin/x
19932 tty1 S+ 0:00 xinit /root/.xinitrc -- /usr/bin/X :0 -nolisten tcp -
Is this it?

Thanks.

Edit: With the patch(es) it just... flow =]
Sorry for bugging...

Last edited by BrZ; 11-22-2010 at 04:06 PM.
 
Old 11-23-2010, 02:11 AM   #18
ponce
LQ Guru
 
Registered: Aug 2004
Location: Pisa, Italy
Distribution: Slackware
Posts: 7,109

Rep: Reputation: 4179Reputation: 4179Reputation: 4179Reputation: 4179Reputation: 4179Reputation: 4179Reputation: 4179Reputation: 4179Reputation: 4179Reputation: 4179Reputation: 4179
Quote:
Originally Posted by AlvaroG View Post
In the slashdot discussion on the subject it was mentioned several times that this will only work for applications started from a tty, or a single bash session. This means, as Con Kolivas wrote, that the "normal" GUI apps started from the desktop (e.g. via krunner or the kde menu) will not see a difference (as all of them will be grouped together), and that in any case the window manager may be modified to do something similar to what the scripts do.
this is slightly changed: the last version of the patch works per session

http://lkml.org/lkml/2010/11/20/91

can confirm that kde 4.5.3 (I've that installed on 64-current) looks much more smooth and fluid with autogroup on: trying it with zen-stable git that includes latest patch.

Last edited by ponce; 11-23-2010 at 02:54 AM.
 
Old 11-28-2010, 05:21 AM   #19
H_TeXMeX_H
LQ Guru
 
Registered: Oct 2005
Location: $RANDOM
Distribution: slackware64
Posts: 12,928
Blog Entries: 2

Rep: Reputation: 1301Reputation: 1301Reputation: 1301Reputation: 1301Reputation: 1301Reputation: 1301Reputation: 1301Reputation: 1301Reputation: 1301Reputation: 1301
I think this patch is BS. It seems to be experimental, nobody can clearly explain how it works or what it is good for, and yet everyone praises it as a miracle. A bunch of BS. I have tried it and the alternative and there's no difference. It's probably because everyone is using CFQ, which causes lags and stuttering and this is a workaround.

This is all IMO, of course.
 
Old 11-28-2010, 06:57 AM   #20
GazL
LQ Veteran
 
Registered: May 2008
Posts: 6,904

Rep: Reputation: 5025Reputation: 5025Reputation: 5025Reputation: 5025Reputation: 5025Reputation: 5025Reputation: 5025Reputation: 5025Reputation: 5025Reputation: 5025Reputation: 5025
H_Tex, I'm with you on this one. Problem is there's a whole lot of bloggers and journalists for that matter out there parroting the "Miracle patch makes linux run faster" headline, who don't really understand what they're talking about.

Blindly grouping processes into cgroups based on session id is going to cause as many problems as it solves. All I see happening is that instead as running things that you don't want to impact your system with "nice <program>", you'll end up using "setsid <program>" to break things that you do want to get a fair share out of the current session.

Last edited by GazL; 11-28-2010 at 07:09 AM.
 
Old 11-28-2010, 07:01 AM   #21
sycamorex
LQ Veteran
 
Registered: Nov 2005
Location: London
Distribution: Slackware64-current
Posts: 5,836
Blog Entries: 1

Rep: Reputation: 1251Reputation: 1251Reputation: 1251Reputation: 1251Reputation: 1251Reputation: 1251Reputation: 1251Reputation: 1251Reputation: 1251
Glad you have tried the patch. I was about to do it as well as due to the hype in the media I had quite high expectations. Sorry to hear it that at the moment it's the case of much ado about nothing. Clearly we're not there yet...
 
Old 11-28-2010, 07:02 AM   #22
H_TeXMeX_H
LQ Guru
 
Registered: Oct 2005
Location: $RANDOM
Distribution: slackware64
Posts: 12,928
Blog Entries: 2

Rep: Reputation: 1301Reputation: 1301Reputation: 1301Reputation: 1301Reputation: 1301Reputation: 1301Reputation: 1301Reputation: 1301Reputation: 1301Reputation: 1301
Yeah, I think using 'nice' properly will be a much better solution than this. This is just a crazy hack.

P.S.

You should try it, but know that it's not as miraculous as they say. I mean, I didn't notice any difference. Don't take my word for it, your system is setup differently, it may actually work, who knows.

Last edited by H_TeXMeX_H; 11-28-2010 at 07:04 AM.
 
Old 11-29-2010, 06:58 AM   #23
Linux.tar.gz
Senior Member
 
Registered: Dec 2003
Location: Paris
Distribution: Slackware forever.
Posts: 2,534

Original Poster
Rep: Reputation: 100Reputation: 100
Tried it and it IS miraculous.
To see that, you have to overload your desktop.
But as we never use a make -j64, it's not really useful.
Anyway, this is a good thing.
 
Old 11-29-2010, 07:08 AM   #24
H_TeXMeX_H
LQ Guru
 
Registered: Oct 2005
Location: $RANDOM
Distribution: slackware64
Posts: 12,928
Blog Entries: 2

Rep: Reputation: 1301Reputation: 1301Reputation: 1301Reputation: 1301Reputation: 1301Reputation: 1301Reputation: 1301Reputation: 1301Reputation: 1301Reputation: 1301
Quote:
Originally Posted by Linux.tar.gz View Post
Tried it and it IS miraculous.
To see that, you have to overload your desktop.
But as we never use a make -j64, it's not really useful.
Anyway, this is a good thing.
Ok, so it would only make a difference if I were to use make -j64 ? You have any benchmarks, for example make -j64 versus make -j4 or -j5 for a quad core ?
 
Old 11-29-2010, 08:39 AM   #25
TobiSGD
Moderator
 
Registered: Dec 2009
Location: Germany
Distribution: Whatever fits the task best
Posts: 17,148
Blog Entries: 2

Rep: Reputation: 4886Reputation: 4886Reputation: 4886Reputation: 4886Reputation: 4886Reputation: 4886Reputation: 4886Reputation: 4886Reputation: 4886Reputation: 4886Reputation: 4886
Quote:
Originally Posted by H_TeXMeX_H View Post
Ok, so it would only make a difference if I were to use make -j64 ? You have any benchmarks, for example make -j64 versus make -j4 or -j5 for a quad core ?
Shouldn't it compile slower with the patch? I thought this patch is for more responsiveness, not for actually accelerating things. I mean, if your desktop is more responsive during a make -j64, it has to get more of the CPU than without the patch/alternative solution. So the compile-time must be longer. Or didn't I get the point?
 
Old 11-29-2010, 09:09 AM   #26
GazL
LQ Veteran
 
Registered: May 2008
Posts: 6,904

Rep: Reputation: 5025Reputation: 5025Reputation: 5025Reputation: 5025Reputation: 5025Reputation: 5025Reputation: 5025Reputation: 5025Reputation: 5025Reputation: 5025Reputation: 5025
Quote:
Originally Posted by TobiSGD View Post
Shouldn't it compile slower with the patch? I thought this patch is for more responsiveness, not for actually accelerating things. I mean, if your desktop is more responsive during a make -j64, it has to get more of the CPU than without the patch/alternative solution. So the compile-time must be longer. Or didn't I get the point?
Actually, it doesn't have to get more time, it has to get the same amount of time, just in smaller, more frequent chunks.

glxgears is a good example for demonstating this when run on a non-accelerated Xserver such as nouveau, fbdev,nv or vesa. The nature of glxgears is that it will try and use as much cpu as it can get, but because 3d is not accelerated the Xserver process will need to do the grunt work using mesa.

try this:

open a terminal and run 'top' so you can see what's happening.

then open a second terminal and run
(It'll attempt to start 20 copies of glxgears)
Code:
for (( i=0 ; i < 20 ; i++ ))
do
   glxgears >/dev/null 2>&1 &
done
Try moving some of the windows so you can see them all (on my system it doesn't even manage to start them all). Responsiveness is terrible and you'll notice that not all the gears are spinning at once. The reason for this is that the XServer process will be competing with each of the 20 glxgears for cputime as they are all the same priority.

Clear them up with "pkill glxgears" and then try the same thing but this time we'll nice them
Code:
for (( i=0 ; i < 20 ; i++ ))
do
   nice -n 19 glxgears >/dev/null 2>&1 &
done
Not only will all the gears be spinning at once, your desktop will remain responsive.

This demonstrates why I think this new patch is not all that miraculous. Simply running these tasks at a lower priority is enough, and unlike automated cgroups it won't have any unanticipated side effects by unintentional groupings.

If you want to automate this stuff why not just add a " renice -n 19 $$ "to your .bashrc. As far as I can see, that would pretty much have the same practical effect as the kernel patch would on a "make -j 64"
 
1 members found this post helpful.
Old 11-29-2010, 09:17 AM   #27
H_TeXMeX_H
LQ Guru
 
Registered: Oct 2005
Location: $RANDOM
Distribution: slackware64
Posts: 12,928
Blog Entries: 2

Rep: Reputation: 1301Reputation: 1301Reputation: 1301Reputation: 1301Reputation: 1301Reputation: 1301Reputation: 1301Reputation: 1301Reputation: 1301Reputation: 1301
Well, if it isn't about performance then what good is it (why not use nice) ? My desktop is very responsive as is. I can be running 'make -j4' in the background and be browsing the web at the same time without issue or lag and WITHOUT this patch. I think this may be about more than just cpu scheduling, it may also have to do with HDD I/O scheduling. I used to have some terrible lagging when using CFQ.
 
Old 11-29-2010, 09:40 AM   #28
ponce
LQ Guru
 
Registered: Aug 2004
Location: Pisa, Italy
Distribution: Slackware
Posts: 7,109

Rep: Reputation: 4179Reputation: 4179Reputation: 4179Reputation: 4179Reputation: 4179Reputation: 4179Reputation: 4179Reputation: 4179Reputation: 4179Reputation: 4179Reputation: 4179
FYI, in 2.6.36-zen1, you can choose between CFS (patched for autogroups or not, best behaviour with CFQ here) or latest BFS (best behaviour with BFQ here, the combination I'm using), plus aufs, squashfs+lzma and a boatload of the same -zen stuff (you can even raise the CONFIG_HZ, I tried 2000 and works fine here).
And they include interesting patches that try to fix the I/O load problem.

if you're into measuring latency with different kernels, the best tool out there is probably Con's kernbench (benchmarks must run in init 1).

Last edited by ponce; 11-30-2010 at 01:21 PM. Reason: best, not better ;P
 
1 members found this post helpful.
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
LXer: The ~200 Line Linux Kernel Patch That Does Wonders LXer Syndicated Linux News 0 11-16-2010 03:51 PM
LXer: The ~200 Line Linux Kernel Patch That Does Wonders LXer Syndicated Linux News 0 11-16-2010 12:00 PM
CPU consumption - %usr and %sys ?? gomes1333 Linux - General 6 04-03-2010 05:13 AM
why a process ( written in c++) taking 200% cpu usage? sasd Linux - Games 2 03-24-2010 12:24 AM
missing file??? /proc/sys/kernel/sysrq bad_gui Linux - General 4 08-18-2006 10:37 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Slackware

All times are GMT -5. The time now is 09:34 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration