Re: cgroups: cannot write on file memory.oom_control

2014-04-22 Thread Hedi Boufaied
Hi Rami,

Thank you for the advice. Yes, I will try using the event handler.

Best Regards,
Hedi



From:   Rami Rosen roszenr...@gmail.com
To: Hedi Boufaied hedi.boufa...@amadeus.com, 
Cc: kernelnewbies kernelnewbies@kernelnewbies.org
Date:   18/04/2014 22:38
Subject:Re: cgroups: cannot write on file memory.oom_control
Sent by:kernelnewbies-boun...@kernelnewbies.org



Hi Hedi,
Well, you can use disabling oom in conjunction  with event handler. Thus, 
you can free memory by changing memory setting of other cgroups when an 
oom occurs in a specific cgroup, and avoid having an oops in that cgroup.
You can see an example of using event handler in conjunction with 
disabling the oom killer in 
Namespaces and cgroups in linux, in slides 101/102, see:
http://ramirose.wix.com/ramirosen
A shameless plug - I wrote this presentation of 121 slides about 
namespaces and cgroups.
Regards,
Rami Rosen
בתאריך 17 באפר 2014 11:24, Hedi Boufaied hedi.boufa...@amadeus.com 
כתב:
Hi Rami, 

Thanks a lot for your sequence. I followed it and it does work. 
I now see my process paused in sleep state instead of getting killed when 
the cgroup reaches OoO. 

This being said: 
* I do not really understand why the use_hierarchy option needs to be 
disabled in order to allow disabling of the oom killer... 
* I'm not sure that disabling the OoO killer is safe/reliable enough: in 
some of the trials I made, I saw other processes (xterms) not part of the 
OoO cgroup getting completely stuck and I had to reboot my machine... 

Best Regards, 
Hedi 



From:Rami Rosen roszenr...@gmail.com 
To:Hedi Boufaied hedi.boufa...@amadeus.com, 
Cc:kernelnewbies kernelnewbies@kernelnewbies.org 
Date:15/04/2014 15:39 
Subject:Re: cgroups: cannot write on file memory.oom_control 



Hi, Hedi,

This sequence works for me:

echo 0   /sys/fs/cgroup/memory/memory.use_hierarchy

mkdir  /sys/fs/cgroup/memory/0

Then, the following two commands changes the value of oom_kill_disable:

echo 1/sys/fs/cgroup/memory/0/memory.oom_control

echo 0/sys/fs/cgroup/memory/0/memory.oom_control


For more info, please look for the text about enabling/disabling
use_hierarchy in section 6,
http://lxr.free-electrons.com/source/Documentation/cgroups/memory.txt.

Regards,
Rami Rosen
http://ramirose.wix.com/ramirosen



On Mon, Apr 14, 2014 at 12:22 PM, Hedi Boufaied
hedi.boufa...@amadeus.com wrote:
 Hi everyone,

 I am working with cgroups on OpenSuse (over VirtualBox) and I cannot 
disable
 the OOM killer by writing to the file memory.oom_control:

 echo 1  memory.oom_control
 -bash: echo: write error: Invalid argument

 I can change the memory limit and several other settings by writing to 
the
 appropriate files (like memory.limit_in_bytes) but I could never write 
to
 file memory.oom_control although I am root.

 I saw someone posted a similar issue a few days ago but there was no
 reply...

 I have copied below the sequence of command I am using. Any idea what 
could
 be the issue ?

 Thanks in advance for your help!

 Hedi


 

 /sys/fs su - root

 /sys/fs cd cgroup

 /sys/fs/cgroup cgcreate -g memory:/mygroup

 /sys/fs/cgroup cd memory/mygroup

 /sys/fs/cgroup/memory/mygroup echo 32M  memory.limit_in_bytes

 /sys/fs/cgroup/memory/mygroup cat memory.limit_in_bytes
 33554432

 /sys/fs/cgroup/memory/mygroup echo 1  memory.oom_control
 -bash: echo: write error: Invalid argument

 /sys/fs/cgroup/memory/mygroup cat memory.oom_control
 oom_kill_disable 0
 under_oom 0

 ---
 ___
 Kernelnewbies mailing list
 Kernelnewbies@kernelnewbies.org
 http://lists.kernelnewbies.org/mailman/listinfo/kernelnewbies

___
Kernelnewbies mailing list
Kernelnewbies@kernelnewbies.org
http://lists.kernelnewbies.org/mailman/listinfo/kernelnewbies


___
Kernelnewbies mailing list
Kernelnewbies@kernelnewbies.org
http://lists.kernelnewbies.org/mailman/listinfo/kernelnewbies


pft not found for mmtest.

2014-04-22 Thread Raju
Hi all,

May I know from where I can download pft.

As pft is not found in http://mcp/mmtests-mirror/pft/ 
http://mcp/mmtests-mirror/pft//pft-0.12x.tar.gz and 
http://free.linux.hp.com/~lts/Tools/ 
http://free.linux.hp.com/%7Elts/Tools/pft-0.12x.tar.gz


Log while running mmtest
pft-install: Fetching from 
mirrorhttp://mcp/mmtests-mirror/pft//pft-0.12x.tar.gz 
http://mcp/mmtests-mirror/pft//pft-0.12x.tar.gz
pft-install: Fetching from 
internethttp://free.linux.hp.com/~lts/Tools/pft-0.12x.tar.gz 
http://free.linux.hp.com/%7Elts/Tools/pft-0.12x.tar.gz
FATAL pft-install: pft-install: Could not 
downloadhttp://free.linux.hp.com/~lts/Tools/pft-0.12x.tar.gz 
http://free.linux.hp.com/%7Elts/Tools/pft-0.12x.tar.gz
FATAL pft-bench: pft install script returned error
FATAL: pft returned failure, unable to continue
test exit :: pft 255

Regards


___
Kernelnewbies mailing list
Kernelnewbies@kernelnewbies.org
http://lists.kernelnewbies.org/mailman/listinfo/kernelnewbies


Kernel Projects

2014-04-22 Thread Julio Faracco
Hi,

Does anybody know if there is a program to offer small (or big) kernel
projects to students or someone who are interested in?

I'm looking for programs like Google Summer of Code or
http://kernelnewbies.org/KernelProjects

I'm interested to contribute with kernel patches, but I don't know how and
where to start it.

I will be glad if someone give me ideas and/or suggestions.

Thanks!

*--*
*Julio Cesar Faracco*
*University of São Paulo - Brazil*
___
Kernelnewbies mailing list
Kernelnewbies@kernelnewbies.org
http://lists.kernelnewbies.org/mailman/listinfo/kernelnewbies


Re: Kernel Projects

2014-04-22 Thread Peter Senna Tschudin
I would recommend:

http://eudyptula-challenge.org/

On Tue, Apr 22, 2014 at 7:22 PM, Julio Faracco jcfara...@gmail.com wrote:
 Hi,

 Does anybody know if there is a program to offer small (or big) kernel
 projects to students or someone who are interested in?

 I'm looking for programs like Google Summer of Code or
 http://kernelnewbies.org/KernelProjects

 I'm interested to contribute with kernel patches, but I don't know how and
 where to start it.

 I will be glad if someone give me ideas and/or suggestions.

 Thanks!

 --
 Julio Cesar Faracco
 University of São Paulo - Brazil

 ___
 Kernelnewbies mailing list
 Kernelnewbies@kernelnewbies.org
 http://lists.kernelnewbies.org/mailman/listinfo/kernelnewbies




-- 
Peter

___
Kernelnewbies mailing list
Kernelnewbies@kernelnewbies.org
http://lists.kernelnewbies.org/mailman/listinfo/kernelnewbies


Re: Kernel Projects

2014-04-22 Thread Akshay Dixit
Hi Julio,

Have you tried the Eudyptula Challenge?
Its a good place to start from the ground up!

Regards,
Akshay Dixit

On Tue, Apr 22, 2014 at 10:52 PM, Julio Faracco jcfara...@gmail.com wrote:
 Hi,

 Does anybody know if there is a program to offer small (or big) kernel
 projects to students or someone who are interested in?

 I'm looking for programs like Google Summer of Code or
 http://kernelnewbies.org/KernelProjects

 I'm interested to contribute with kernel patches, but I don't know how and
 where to start it.

 I will be glad if someone give me ideas and/or suggestions.

 Thanks!

 --
 Julio Cesar Faracco
 University of São Paulo - Brazil

 ___
 Kernelnewbies mailing list
 Kernelnewbies@kernelnewbies.org
 http://lists.kernelnewbies.org/mailman/listinfo/kernelnewbies


___
Kernelnewbies mailing list
Kernelnewbies@kernelnewbies.org
http://lists.kernelnewbies.org/mailman/listinfo/kernelnewbies


Re: Kernel Projects

2014-04-22 Thread Vitor Braga
I second this, Eudyptula is one of most fun things Ive done in a lot
of time I'm trying to find some time to finish task 16, but the
real world keeps getting in my way :/

On Tue, Apr 22, 2014 at 2:29 PM, Akshay Dixit akshayd...@gmail.com wrote:
 Hi Julio,

 Have you tried the Eudyptula Challenge?
 Its a good place to start from the ground up!

 Regards,
 Akshay Dixit

 On Tue, Apr 22, 2014 at 10:52 PM, Julio Faracco jcfara...@gmail.com wrote:
 Hi,

 Does anybody know if there is a program to offer small (or big) kernel
 projects to students or someone who are interested in?

 I'm looking for programs like Google Summer of Code or
 http://kernelnewbies.org/KernelProjects

 I'm interested to contribute with kernel patches, but I don't know how and
 where to start it.

 I will be glad if someone give me ideas and/or suggestions.

 Thanks!

 --
 Julio Cesar Faracco
 University of São Paulo - Brazil

 ___
 Kernelnewbies mailing list
 Kernelnewbies@kernelnewbies.org
 http://lists.kernelnewbies.org/mailman/listinfo/kernelnewbies


 ___
 Kernelnewbies mailing list
 Kernelnewbies@kernelnewbies.org
 http://lists.kernelnewbies.org/mailman/listinfo/kernelnewbies

___
Kernelnewbies mailing list
Kernelnewbies@kernelnewbies.org
http://lists.kernelnewbies.org/mailman/listinfo/kernelnewbies


Re: Kernel Projects

2014-04-22 Thread aaditya.gavandal...@yahoo.com
I also sent a mail to lit...@eudyptula-challenge.org for joining the challenge 
but didn't received a conformation or a new challenge yet.

___
Kernelnewbies mailing list
Kernelnewbies@kernelnewbies.org
http://lists.kernelnewbies.org/mailman/listinfo/kernelnewbies


Re: Kernel Projects

2014-04-22 Thread Vitor Braga
Give it some time :-) Might take a couple hours to a day between replies.


On Tue, Apr 22, 2014 at 2:55 PM, aaditya.gavandal...@yahoo.com 
aaditya.gavandal...@yahoo.com wrote:

 I also sent a mail to lit...@eudyptula-challenge.org for joining the
 challenge but didn't received a conformation or a new challenge yet.

  --
 * From: * Vitor Braga vitorpybr...@gmail.com;
 * To: * Akshay Dixit akshayd...@gmail.com;
 * Cc: * Julio Faracco jcfara...@gmail.com; 
 Kernelnewbies@kernelnewbies.org;
 * Subject: * Re: Kernel Projects
 * Sent: * Tue, Apr 22, 2014 5:39:06 PM

   I second this, Eudyptula is one of most fun things Ive done in a lot
 of time I'm trying to find some time to finish task 16, but the
 real world keeps getting in my way :/

 On Tue, Apr 22, 2014 at 2:29 PM, Akshay Dixit akshayd...@gmail.com
 wrote:
  Hi Julio,
 
  Have you tried the Eudyptula Challenge?
  Its a good place to start from the ground up!
 
  Regards,
  Akshay Dixit
 
  On Tue, Apr 22, 2014 at 10:52 PM, Julio Faracco jcfara...@gmail.com
 wrote:
  Hi,
 
  Does anybody know if there is a program to offer small (or big) kernel
  projects to students or someone who are interested in?
 
  I'm looking for programs like Google Summer of Code or
  http://kernelnewbies.org/KernelProjects
 
  I'm interested to contribute with kernel patches, but I don't know how
 and
  where to start it.
 
  I will be glad if someone give me ideas and/or suggestions.
 
  Thanks!
 
  --
  Julio Cesar Faracco
  University of São Paulo - Brazil
 
  ___
  Kernelnewbies mailing list
  Kernelnewbies@kernelnewbies.org
  http://lists.kernelnewbies.org/mailman/listinfo/kernelnewbies

 
 
  ___
  Kernelnewbies mailing list
  Kernelnewbies@kernelnewbies.org
  http://lists.kernelnewbies.org/mailman/listinfo/kernelnewbies

 ___
 Kernelnewbies mailing list
 Kernelnewbies@kernelnewbies.org
 http://lists.kernelnewbies.org/mailman/listinfo/kernelnewbies

___
Kernelnewbies mailing list
Kernelnewbies@kernelnewbies.org
http://lists.kernelnewbies.org/mailman/listinfo/kernelnewbies


Re: Kernel Projects

2014-04-22 Thread Greg Freemyer
On Tue, Apr 22, 2014 at 1:22 PM, Julio Faracco jcfara...@gmail.com wrote:
 Hi,

 Does anybody know if there is a program to offer small (or big) kernel
 projects to students or someone who are interested in?

 I'm looking for programs like Google Summer of Code or
 http://kernelnewbies.org/KernelProjects

 I'm interested to contribute with kernel patches, but I don't know how and
 where to start it.

 I will be glad if someone give me ideas and/or suggestions.

 Thanks!

 --
 Julio Cesar Faracco
 University of São Paulo - Brazil

The challenge is probably a great learning experience, but I assume
everyone is doing the same work?

If so, Greg KH has said that code clean-ups to the staging directory
are always accepted.

Just download the kernel source, cd into the staging directory and
start running checkpatch.pl against the various files.  When you find
issues, clean them up and submit a patch.

Greg KH walks through the process here:
https://www.youtube.com/watch?v=LLBrBBImJt4

Greg (not KH)

___
Kernelnewbies mailing list
Kernelnewbies@kernelnewbies.org
http://lists.kernelnewbies.org/mailman/listinfo/kernelnewbies


Re: Kernel Projects

2014-04-22 Thread Greg KH
On Tue, Apr 22, 2014 at 07:15:28PM -0400, Greg Freemyer wrote:
 If so, Greg KH has said that code clean-ups to the staging directory
 are always accepted.

Yes, just start with drivers/staging/*/TODO and go from there.  Help
there is always gladly appreciated.

thanks,

greg (not Freemyer) k-h

___
Kernelnewbies mailing list
Kernelnewbies@kernelnewbies.org
http://lists.kernelnewbies.org/mailman/listinfo/kernelnewbies


a question about __nocache_pa macro

2014-04-22 Thread Chan Kim
Hi,
can someony explain this macro to me? It's in arch/sparc/include/asm/pgtsrmmu.h 
(linux 3.3)
#define __nocache_pa(VADDR) (((unsigned long)VADDR) - SRMMU_NOCACHE_VADDR + 
__pa((unsigned long)srmmu_nocache_pool))
it looks like converting virtual address VADDR to physical address for which no 
cache is used.
so I can see SRMMU_NOCACHE_VADDR is the virtual address start value from which 
no cache is used(in our case it's 0xc800),
and VADDR is relative to this start location (thus the minus).
But why do we add the last srmmu_nocache_pool term? we are adding the offset to 
physical nocache pool address. 
So it seems like it is converting a virtual address to a physcal address 
relative to nocache pool..
Why is it done this way?
Thanks in advance.
Chan
___
Kernelnewbies mailing list
Kernelnewbies@kernelnewbies.org
http://lists.kernelnewbies.org/mailman/listinfo/kernelnewbies