Error creating a network card for lxc from command line

lince

Member
Apr 10, 2015
78
3
8
Hello,

I'm getting the following error, is this a bug ? any workaround so I can create a network card from command line ?

root@pve2:~# pct set 124 -net1 name=eth1,bridge=vmbr0,gw=192.168.5.100,ip=192.168.5.124/24,tag=5
Use of uninitialized value in pattern match (m//) at /usr/share/perl5/PVE/LXC/Setup/Debian.pm line 217, <GEN71> line 7.

Thanks.
 
could you please post the output of:
Code:
pveversion -v
 
root@pve2:~# pveversion -v
proxmox-ve: 4.1-26 (running kernel: 4.2.6-1-pve)
pve-manager: 4.1-1 (running version: 4.1-1/2f9650d4)
pve-kernel-4.2.6-1-pve: 4.2.6-26
lvm2: 2.02.116-pve2
corosync-pve: 2.3.5-2
libqb0: 0.17.2-1
pve-cluster: 4.0-29
qemu-server: 4.0-41
pve-firmware: 1.1-7
libpve-common-perl: 4.0-41
libpve-access-control: 4.0-10
libpve-storage-perl: 4.0-38
pve-libspice-server1: 0.12.5-2
vncterm: 1.2-1
pve-qemu-kvm: 2.4-17
pve-container: 1.0-32
pve-firewall: 2.0-14
pve-ha-manager: 1.0-14
ksm-control-daemon: 1.2-1
glusterfs-client: 3.5.2-2+deb8u1
lxc-pve: 1.1.5-5
lxcfs: 0.13-pve1
cgmanager: 0.39-pve1
criu: 1.6.0-1
zfsutils: 0.6.5-pve6~jessie
 
Thanks for your help but I can't update my cluster, if something breaks I don't have time to fix it at the moment and I need it up and running.

In case is useful for you to fix a possible bug I can run some tests if you want.

The problem might be related to a particular container as the command doesn't fail in other containers. Also the command does return an error but the interface is created:


root@pve2:~# pct set 126 -net3 "name=eth3,bridge=vmbr0,ip=192.168.5.126/24,gw=192.168.5.100,tag=5"
root@pve2:~# pct set 126 -net3 "name=eth3,bridge=vmbr0,ip=192.168.5.126/24,gw=192.168.5.100,tag=5"

root@pve2:~# pct config 124
arch: amd64
cpulimit: 1
cpuunits: 1024
hostname: test3
memory: 512
net0: bridge=vmbr0,gw=192.168.1.1,hwaddr=32:33:36:33:63:65,ip=192.168.1.124/32,name=eth0,type=veth
net1: bridge=vmbr0,gw=192.168.5.100,hwaddr=3A:39:36:30:64:32,ip=192.168.5.124/24,name=eth1,tag=5,type=veth
net2: bridge=vmbr0,gw=192.168.6.100,hwaddr=36:34:31:36:37:34,ip=192.168.6.124/24,name=eth2,tag=6,type=veth
ostype: ubuntu
rootfs: nfs-ssd:124/vm-124-disk-2.raw,size=4G
swap: 512

root@pve2:~# pct set 124 -net3 "name=eth3,bridge=vmbr0,ip=192.168.5.126/24,gw=192.168.5.100,tag=5"
Use of uninitialized value in pattern match (m//) at /usr/share/perl5/PVE/LXC/Setup/Debian.pm line 217, <GEN64> line 7.
Use of uninitialized value in pattern match (m//) at /usr/share/perl5/PVE/LXC/Setup/Debian.pm line 217, <GEN64> line 23.

root@pve2:~# pct config 124
arch: amd64
cpulimit: 1
cpuunits: 1024
hostname: test3
memory: 512
net0: bridge=vmbr0,gw=192.168.1.1,hwaddr=32:33:36:33:63:65,ip=192.168.1.124/32,name=eth0,type=veth
net1: bridge=vmbr0,gw=192.168.5.100,hwaddr=3A:39:36:30:64:32,ip=192.168.5.124/24,name=eth1,tag=5,type=veth
net2: bridge=vmbr0,gw=192.168.6.100,hwaddr=36:34:31:36:37:34,ip=192.168.6.124/24,name=eth2,tag=6,type=veth
net3: bridge=vmbr0,gw=192.168.5.100,hwaddr=3A:33:63:36:35:39,ip=192.168.5.126/24,name=eth3,tag=5,type=veth
ostype: ubuntu
rootfs: nfs-ssd:124/vm-124-disk-2.raw,size=4G
swap: 512


root@pve2:~# md5sum /usr/share/perl5/PVE/LXC/Setup/Debian.pm
4fb86ef1633ba27867d98680387d28eb /usr/share/perl5/PVE/LXC/Setup/Debian.pm