[Lxc-users] Unable to set default gw

Hugues huguesmax at gmail.com
Thu Dec 23 22:44:15 UTC 2010


Thanks
Do you have a idea to solve this problem ?
Something low level, like

echo "xxxxx  xxx xxx xxx " > /proc/net/route directly in host server ?

Or to create brigde in contrainer instead of classic interface ?

Hugues.
 

Le 23/12/10 15:28, « Daniel Lezcano » <daniel.lezcano at free.fr> a écrit :

> On 12/16/2010 08:17 PM, Hugues wrote:
>> I¹m going to test lxc on Debian Squeez  kernel 2.6.36.2 and I launch CentOS
>> 5.5
>> 
>> With lxc version 0.72
>> 
>> All works well
>> 
>> My config is
>> 
>> 
>> 
>> lxc.utsname = centos
>> 
>> lxc.tty = 4
>> 
>> lxc.network.type = veth
>> 
>> lxc.network.veth.pair = eth-centos
>> 
>> lxc.network.flags = up
>> 
>> lxc.network.link = br0
>> 
>> lxc.network.name = eth0
>> 
>> lxc.network.mtu = 1500
>> 
>> lxc.network.hwaddr = 00:16:36:2F:8D:DD
>> 
>> lxc.network.ipv4 = 192.168.3.29/24
>> 
>> # Bloquer la possibilité d'effectuer différentes opérations sur le réseau
>> 
>> # configurer les interfaces, modifier les tables de routage
>> 
>> # impossible de mettre net_admin car pas de default route
>> 
>> #lxc.cap.drop = net_admin
>> 
>> lxc.cap.drop = mac_admin
>> 
>> lxc.cap.drop = mac_override
>> 
>> lxc.cap.drop = net_raw
>> 
>> 
>> 
>> 
>> 
>> I would like to limit my CentOS with
>> 
>> lxc.cap.drop = net_admin
>> 
>> but if I active this setting I¹m unable to set default gw ( permission
>> denied ) ­ of course this is what I want for my CentOS machine but I need
>> this setting
>> 
>> how I can solve that ? limit my Centos root user  and have default gw
>> 
>> without default gw , there are no sens ?
>> 
>> I don¹t find lxc.network.default. or some thing like that
>> 
>> I try with lxc-start or lxc-execute but without success
>>    
> 
> Yes, you are right. The default gateway option and more generally the
> routes configuration are not yet implemented.
> 
> 
> 






More information about the lxc-users mailing list