[lxc-devel] LXC-Cgroup memory controller

2010-09-07 Thread jorge espada
Hi Guys I wanna know if it possible to set up a memory controller for each
container..if so..how can I do? any examples?
Thanks

Jorge E. Espada
--
This SF.net Dev2Dev email is sponsored by:

Show off your parallel programming skills.
Enter the Intel(R) Threading Challenge 2010.
http://p.sf.net/sfu/intel-thread-sfd___
Lxc-devel mailing list
Lxc-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/lxc-devel


Re: [lxc-devel] LXC-Cgroup memory controller

2010-09-07 Thread jorge espada
Thank you Daniel, but in order to do this I must have kernel support ,
right?
dev2:~# lxc-checkconfig | grep memory
Cgroup memory controller: disabled
I think I need this property enabled

Thanks in advance

Jorge E. Espada
Phone: +54 9 341 5692435


On Tue, Sep 7, 2010 at 3:00 PM, Daniel Lezcano wrote:

> On 09/07/2010 05:22 PM, jorge espada wrote:
>
>> Hi Guys I wanna know if it possible to set up a memory controller for each
>> container..if so..how can I do? any examples?
>> Thanks
>>
>>
>
> When you start a container, there is a cgroup created automatically where
> all the processes of the container will belong.
>
> In order to modify a cgroup subsystem value use the lxc-cgroup -n 
>  
>
> For example : lxc-cgroup -n foo memory.max_usage_in_bytes 268435456
>
> Or specify it in the configuration file to automatically set it up when the
> container starts.
>
>  lxc.cgroup.memory.max_usage_in_bytes = 268435456
>
>  -- Daniel
>
--
This SF.net Dev2Dev email is sponsored by:

Show off your parallel programming skills.
Enter the Intel(R) Threading Challenge 2010.
http://p.sf.net/sfu/intel-thread-sfd___
Lxc-devel mailing list
Lxc-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/lxc-devel


[lxc-devel] lxc.network.type = macvlan

2010-10-12 Thread jorge espada
Hi, I have a lxc container  running on debian lenny (kernel 2.6.32) with the
following conf:

lxc.network.type = macvlan
lxc.network.flags = up
lxc.network.link = vlan310
lxc.network.name = vlan310
lxc.network.macvlan.mode = vepa
lxc.network.hwaddr = 06:00:0a:1f:00:46
lxc.network.ipv4 = 10.31.0.70/24

# network2
lxc.network.type = macvlan
lxc.network.flags = up
lxc.network.link = vlan400
lxc.network.name = vlan400
lxc.network.macvlan.mode = vepa
lxc.network.hwaddr = 06:00:0a:28:00:46
lxc.network.ipv4 = 10.40.0.70/23


is the macvlan mode vepa supported for that kernel or I need a newer one?

Because I have weird problems with that conf, some times I can ping the
container from another host but some times not...is random

Jorge E. Espada
--
Beautiful is writing same markup. Internet Explorer 9 supports
standards for HTML5, CSS3, SVG 1.1,  ECMAScript5, and DOM L2 & L3.
Spend less time writing and  rewriting code and more time creating great
experiences on the web. Be a part of the beta today.
http://p.sf.net/sfu/beautyoftheweb___
Lxc-devel mailing list
Lxc-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/lxc-devel


Re: [lxc-devel] lxc.network.type = macvlan

2010-10-13 Thread jorge espada
The error was  ICMP "no route to host", but now i change the conf and
instead of vepa I used bridge...after destroy and create the containers with
the new conf, seems to be working as expected for a while, but from time to
time "the container became unresponsive".. no ping (100% packet lost). The
curious thing is, if I login into the host and then to the container
(lxc-console) and ping another container or host the " unresponsive
container " become alive again (ping OK)so I'm a bit lost..

Jorge E. Espada



On Wed, Oct 13, 2010 at 2:17 AM, Daniel Lezcano  wrote:

> On 10/12/2010 10:29 PM, jorge espada wrote:
>
>> Hi, I have a lxc container  running on debian lenny (kernel 2.6.32) with
>> the
>> following conf:
>>
>> lxc.network.type = macvlan
>> lxc.network.flags = up
>> lxc.network.link = vlan310
>> lxc.network.name = vlan310
>> lxc.network.macvlan.mode = vepa
>> lxc.network.hwaddr = 06:00:0a:1f:00:46
>> lxc.network.ipv4 = 10.31.0.70/24
>>
>> # network2
>> lxc.network.type = macvlan
>> lxc.network.flags = up
>> lxc.network.link = vlan400
>> lxc.network.name = vlan400
>> lxc.network.macvlan.mode = vepa
>> lxc.network.hwaddr = 06:00:0a:28:00:46
>> lxc.network.ipv4 = 10.40.0.70/23
>>
>>
>> is the macvlan mode vepa supported for that kernel or I need a newer one?
>>
>
> You need a 2.6.33 kernel version.
>
>
>  Because I have weird problems with that conf, some times I can ping the
>> container from another host but some times not...is random
>>
>
> I am not sure it is related. What happens when you can't ping the host ?
> What is the error ? ICMP "no route to host" ? or just the packet are lost ?
>
--
Beautiful is writing same markup. Internet Explorer 9 supports
standards for HTML5, CSS3, SVG 1.1,  ECMAScript5, and DOM L2 & L3.
Spend less time writing and  rewriting code and more time creating great
experiences on the web. Be a part of the beta today.
http://p.sf.net/sfu/beautyoftheweb___
Lxc-devel mailing list
Lxc-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/lxc-devel


Re: [lxc-devel] lxc.network.type = macvlan

2010-10-13 Thread jorge espada
No, from the host:

Oct 10 06:25:01 srvc15 kernel: imklog 4.4.2, log source = /proc/kmsg
started.
Oct 10 06:25:01 srvc15 rsyslogd: [origin software="rsyslogd"
swVersion="4.4.2" x-pid="2075" x-info="http://www.rsyslog.com";] (re)start
Oct 11 06:25:01 srvc15 rsyslogd: [origin software="rsyslogd"
swVersion="4.4.2" x-pid="2075" x-info="http://www.rsyslog.com";] rsyslogd was
HUPed, type 'restart'.
Oct 11 06:25:01 srvc15 kernel: imklog 4.4.2, log source = /proc/kmsg
started.
Oct 11 06:25:01 srvc15 rsyslogd: [origin software="rsyslogd"
swVersion="4.4.2" x-pid="2075" x-info="http://www.rsyslog.com";] (re)start
Oct 12 06:25:01 srvc15 rsyslogd: [origin software="rsyslogd"
swVersion="4.4.2" x-pid="2075" x-info="http://www.rsyslog.com";] rsyslogd was
HUPed, type 'restart'.
Oct 12 06:25:01 srvc15 kernel: Kernel logging (proc) stopped.
Oct 12 06:25:01 srvc15 kernel: imklog 4.4.2, log source = /proc/kmsg
started.
Oct 12 06:25:01 srvc15 rsyslogd: [origin software="rsyslogd"
swVersion="4.4.2" x-pid="2075" x-info="http://www.rsyslog.com";] (re)start
Oct 13 06:25:01 srvc15 rsyslogd: [origin software="rsyslogd"
swVersion="4.4.2" x-pid="2075" x-info="http://www.rsyslog.com";] rsyslogd was
HUPed, type 'restart'.
Oct 13 06:25:01 srvc15 kernel: Kernel logging (proc) stopped.
Oct 13 06:25:01 srvc15 kernel: imklog 4.4.2, log source = /proc/kmsg
started.
Oct 13 06:25:01 srvc15 rsyslogd: [origin software="rsyslogd"
swVersion="4.4.2" x-pid="2075" x-info="http://www.rsyslog.com";] (re)start

>From the container:
Oct 10 06:25:01 srvc15c0 kernel: imklog 3.18.6, log source = /proc/kmsg
started.
Oct 10 06:25:01 srvc15c0 rsyslogd: [origin software="rsyslogd"
swVersion="3.18.6" x-pid="299" x-info="http://www.rsyslog.com";] restart
Oct 11 06:25:01 srvc15c0 kernel: imklog 3.18.6, log source = /proc/kmsg
started.
Oct 11 06:25:01 srvc15c0 rsyslogd: [origin software="rsyslogd"
swVersion="3.18.6" x-pid="299" x-info="http://www.rsyslog.com";] restart
Oct 12 06:25:01 srvc15c0 kernel: imklog 3.18.6, log source = /proc/kmsg
started.
Oct 12 06:25:01 srvc15c0 rsyslogd: [origin software="rsyslogd"
swVersion="3.18.6" x-pid="299" x-info="http://www.rsyslog.com";] restart
Oct 13 06:25:01 srvc15c0 kernel: imklog 3.18.6, log source = /proc/kmsg
started.
Oct 13 06:25:01 srvc15c0 rsyslogd: [origin software="rsyslogd"
swVersion="3.18.6" x-pid="299" x-info="http://www.rsyslog.com";] restart

That's all :(
Jorge E. Espada



On Wed, Oct 13, 2010 at 9:45 AM, Daniel Lezcano  wrote:

> On 10/13/2010 02:42 PM, jorge espada wrote:
>
>> The error was  ICMP "no route to host", but now i change the conf and
>> instead of vepa I used bridge...after destroy and create the containers
>> with
>> the new conf, seems to be working as expected for a while, but from time
>> to
>> time "the container became unresponsive".. no ping (100% packet lost). The
>> curious thing is, if I login into the host and then to the container
>> (lxc-console) and ping another container or host the " unresponsive
>> container " become alive again (ping OK)so I'm a bit lost..
>>
>
> Is there any trace in /var/log/messages ?
>
--
Beautiful is writing same markup. Internet Explorer 9 supports
standards for HTML5, CSS3, SVG 1.1,  ECMAScript5, and DOM L2 & L3.
Spend less time writing and  rewriting code and more time creating great
experiences on the web. Be a part of the beta today.
http://p.sf.net/sfu/beautyoftheweb___
Lxc-devel mailing list
Lxc-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/lxc-devel


Re: [lxc-devel] lxc.network.type = macvlan

2010-10-14 Thread jorge espada
As extra information  I have configured a bonding in the host(where the
container is running) and the vlans over it:
auto bond0
iface bond0 inet manual
up /sbin/ifconfig bond0 up
down /sbin/ifconfig bond0 down
slaves eth0 eth1
bond_mode balance-xor
bond_miimon 100
bond_updelay 200
bond_downdelay 200

auto vlan310
iface vlan310 inet static
address 10.31.0.151
netmask 255.255.255.0
network 10.31.0.0
broadcast 10.31.0.255
gateway 10.31.0.1
vlan_raw_device bond0


Jorge E. Espada



On Wed, Oct 13, 2010 at 10:06 AM, jorge espada wrote:

> No, from the host:
>
> Oct 10 06:25:01 srvc15 kernel: imklog 4.4.2, log source = /proc/kmsg
> started.
> Oct 10 06:25:01 srvc15 rsyslogd: [origin software="rsyslogd"
> swVersion="4.4.2" x-pid="2075" x-info="http://www.rsyslog.com";] (re)start
> Oct 11 06:25:01 srvc15 rsyslogd: [origin software="rsyslogd"
> swVersion="4.4.2" x-pid="2075" x-info="http://www.rsyslog.com";] rsyslogd
> was HUPed, type 'restart'.
> Oct 11 06:25:01 srvc15 kernel: imklog 4.4.2, log source = /proc/kmsg
> started.
> Oct 11 06:25:01 srvc15 rsyslogd: [origin software="rsyslogd"
> swVersion="4.4.2" x-pid="2075" x-info="http://www.rsyslog.com";] (re)start
> Oct 12 06:25:01 srvc15 rsyslogd: [origin software="rsyslogd"
> swVersion="4.4.2" x-pid="2075" x-info="http://www.rsyslog.com";] rsyslogd
> was HUPed, type 'restart'.
> Oct 12 06:25:01 srvc15 kernel: Kernel logging (proc) stopped.
> Oct 12 06:25:01 srvc15 kernel: imklog 4.4.2, log source = /proc/kmsg
> started.
> Oct 12 06:25:01 srvc15 rsyslogd: [origin software="rsyslogd"
> swVersion="4.4.2" x-pid="2075" x-info="http://www.rsyslog.com";] (re)start
> Oct 13 06:25:01 srvc15 rsyslogd: [origin software="rsyslogd"
> swVersion="4.4.2" x-pid="2075" x-info="http://www.rsyslog.com";] rsyslogd
> was HUPed, type 'restart'.
> Oct 13 06:25:01 srvc15 kernel: Kernel logging (proc) stopped.
> Oct 13 06:25:01 srvc15 kernel: imklog 4.4.2, log source = /proc/kmsg
> started.
> Oct 13 06:25:01 srvc15 rsyslogd: [origin software="rsyslogd"
> swVersion="4.4.2" x-pid="2075" x-info="http://www.rsyslog.com";] (re)start
>
> From the container:
> Oct 10 06:25:01 srvc15c0 kernel: imklog 3.18.6, log source = /proc/kmsg
> started.
> Oct 10 06:25:01 srvc15c0 rsyslogd: [origin software="rsyslogd"
> swVersion="3.18.6" x-pid="299" x-info="http://www.rsyslog.com";] restart
> Oct 11 06:25:01 srvc15c0 kernel: imklog 3.18.6, log source = /proc/kmsg
> started.
> Oct 11 06:25:01 srvc15c0 rsyslogd: [origin software="rsyslogd"
> swVersion="3.18.6" x-pid="299" x-info="http://www.rsyslog.com";] restart
> Oct 12 06:25:01 srvc15c0 kernel: imklog 3.18.6, log source = /proc/kmsg
> started.
> Oct 12 06:25:01 srvc15c0 rsyslogd: [origin software="rsyslogd"
> swVersion="3.18.6" x-pid="299" x-info="http://www.rsyslog.com";] restart
> Oct 13 06:25:01 srvc15c0 kernel: imklog 3.18.6, log source = /proc/kmsg
> started.
> Oct 13 06:25:01 srvc15c0 rsyslogd: [origin software="rsyslogd"
> swVersion="3.18.6" x-pid="299" x-info="http://www.rsyslog.com";] restart
>
> That's all :(
> Jorge E. Espada
>
>
>
>
> On Wed, Oct 13, 2010 at 9:45 AM, Daniel Lezcano wrote:
>
>> On 10/13/2010 02:42 PM, jorge espada wrote:
>>
>>> The error was  ICMP "no route to host", but now i change the conf and
>>> instead of vepa I used bridge...after destroy and create the containers
>>> with
>>> the new conf, seems to be working as expected for a while, but from time
>>> to
>>> time "the container became unresponsive".. no ping (100% packet lost).
>>> The
>>> curious thing is, if I login into the host and then to the container
>>> (lxc-console) and ping another container or host the " unresponsive
>>> container " become alive again (ping OK)so I'm a bit lost..
>>>
>>
>> Is there any trace in /var/log/messages ?
>>
>
>
--
Beautiful is writing same markup. Internet Explorer 9 supports
standards for HTML5, CSS3, SVG 1.1,  ECMAScript5, and DOM L2 & L3.
Spend less time writing and  rewriting code and more time creating great
experiences on the web. Be a part of the beta today.
http://p.sf.net/sfu/beautyoftheweb___
Lxc-devel mailing list
Lxc-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/lxc-devel


Re: [lxc-devel] lxc.network.type = macvlan

2010-10-20 Thread jorge espada
My bad guys, it was a route problem...i have 3 vlans for each container and
also 3 default gw in /etc/network/interfaces (copy and paste :S )...and no
custom route...so...
I modified the conf in /etc/network/interfaces and solved the problem.
Thanks

Jorge E. Espada



On Thu, Oct 14, 2010 at 11:40 AM, jorge espada wrote:

> As extra information  I have configured a bonding in the host(where the
> container is running) and the vlans over it:
> auto bond0
> iface bond0 inet manual
> up /sbin/ifconfig bond0 up
> down /sbin/ifconfig bond0 down
> slaves eth0 eth1
> bond_mode balance-xor
> bond_miimon 100
> bond_updelay 200
> bond_downdelay 200
>
> auto vlan310
> iface vlan310 inet static
> address 10.31.0.151
> netmask 255.255.255.0
> network 10.31.0.0
> broadcast 10.31.0.255
> gateway 10.31.0.1
> vlan_raw_device bond0
>
>
> Jorge E. Espada
>
>
>
>
> On Wed, Oct 13, 2010 at 10:06 AM, jorge espada wrote:
>
>> No, from the host:
>>
>> Oct 10 06:25:01 srvc15 kernel: imklog 4.4.2, log source = /proc/kmsg
>> started.
>> Oct 10 06:25:01 srvc15 rsyslogd: [origin software="rsyslogd"
>> swVersion="4.4.2" x-pid="2075" x-info="http://www.rsyslog.com";] (re)start
>> Oct 11 06:25:01 srvc15 rsyslogd: [origin software="rsyslogd"
>> swVersion="4.4.2" x-pid="2075" x-info="http://www.rsyslog.com";] rsyslogd
>> was HUPed, type 'restart'.
>> Oct 11 06:25:01 srvc15 kernel: imklog 4.4.2, log source = /proc/kmsg
>> started.
>> Oct 11 06:25:01 srvc15 rsyslogd: [origin software="rsyslogd"
>> swVersion="4.4.2" x-pid="2075" x-info="http://www.rsyslog.com";] (re)start
>> Oct 12 06:25:01 srvc15 rsyslogd: [origin software="rsyslogd"
>> swVersion="4.4.2" x-pid="2075" x-info="http://www.rsyslog.com";] rsyslogd
>> was HUPed, type 'restart'.
>> Oct 12 06:25:01 srvc15 kernel: Kernel logging (proc) stopped.
>> Oct 12 06:25:01 srvc15 kernel: imklog 4.4.2, log source = /proc/kmsg
>> started.
>> Oct 12 06:25:01 srvc15 rsyslogd: [origin software="rsyslogd"
>> swVersion="4.4.2" x-pid="2075" x-info="http://www.rsyslog.com";] (re)start
>> Oct 13 06:25:01 srvc15 rsyslogd: [origin software="rsyslogd"
>> swVersion="4.4.2" x-pid="2075" x-info="http://www.rsyslog.com";] rsyslogd
>> was HUPed, type 'restart'.
>> Oct 13 06:25:01 srvc15 kernel: Kernel logging (proc) stopped.
>> Oct 13 06:25:01 srvc15 kernel: imklog 4.4.2, log source = /proc/kmsg
>> started.
>> Oct 13 06:25:01 srvc15 rsyslogd: [origin software="rsyslogd"
>> swVersion="4.4.2" x-pid="2075" x-info="http://www.rsyslog.com";] (re)start
>>
>> From the container:
>> Oct 10 06:25:01 srvc15c0 kernel: imklog 3.18.6, log source = /proc/kmsg
>> started.
>> Oct 10 06:25:01 srvc15c0 rsyslogd: [origin software="rsyslogd"
>> swVersion="3.18.6" x-pid="299" x-info="http://www.rsyslog.com";] restart
>> Oct 11 06:25:01 srvc15c0 kernel: imklog 3.18.6, log source = /proc/kmsg
>> started.
>> Oct 11 06:25:01 srvc15c0 rsyslogd: [origin software="rsyslogd"
>> swVersion="3.18.6" x-pid="299" x-info="http://www.rsyslog.com";] restart
>> Oct 12 06:25:01 srvc15c0 kernel: imklog 3.18.6, log source = /proc/kmsg
>> started.
>> Oct 12 06:25:01 srvc15c0 rsyslogd: [origin software="rsyslogd"
>> swVersion="3.18.6" x-pid="299" x-info="http://www.rsyslog.com";] restart
>> Oct 13 06:25:01 srvc15c0 kernel: imklog 3.18.6, log source = /proc/kmsg
>> started.
>> Oct 13 06:25:01 srvc15c0 rsyslogd: [origin software="rsyslogd"
>> swVersion="3.18.6" x-pid="299" x-info="http://www.rsyslog.com";] restart
>>
>> That's all :(
>> Jorge E. Espada
>>
>>
>>
>>
>> On Wed, Oct 13, 2010 at 9:45 AM, Daniel Lezcano wrote:
>>
>>> On 10/13/2010 02:42 PM, jorge espada wrote:
>>>
>>>> The error was  ICMP "no route to host", but now i change the conf and
>>>> instead of vepa I used bridge...after destroy and create the containers
>>>> with
>>>> the new conf, seems to be working as expected for a while, but from time
>>>> to
>>>> time "the container became unresponsive".. no ping (100% packet lost).
>>>> The
>>>> curious thing is, if I login into the host and then to the container
>>>> (lxc-console) and ping another container or host the " unresponsive
>>>> container " become alive again (ping OK)so I'm a bit lost..
>>>>
>>>
>>> Is there any trace in /var/log/messages ?
>>>
>>
>>
>
--
Download new Adobe(R) Flash(R) Builder(TM) 4
The new Adobe(R) Flex(R) 4 and Flash(R) Builder(TM) 4 (formerly 
Flex(R) Builder(TM)) enable the development of rich applications that run
across multiple browsers and platforms. Download your free trials today!
http://p.sf.net/sfu/adobe-dev2dev___
Lxc-devel mailing list
Lxc-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/lxc-devel