[pve-devel] More than 10 interfaces in lxc containers

Stephan Leemburg sleemburg at it-functions.nl
Sun Aug 23 00:16:08 CEST 2020


Sorry, and also in

/usr/share/pve-manager/js/pvemanagerlib.js :

in /usr/share/pve-manager/js/pvemanagerlib.js

change

         for (i = 0; i < 10; i++) {
             if (me.isCreate && !me.dataCache['net'+i.toString()]) {

to

         for (i = 0; i < 31; i++) {
             if (me.isCreate && !me.dataCache['net'+i.toString()]) {

Then it works for me.

It would be great to have an uplift of possible interfaces.

Kind regards,

Stephan

On 22-08-2020 23:41, Stephan Leemburg wrote:
> Hi @dev,
>
> I have read about other people who need more than 10 network 
> interfaces in their lxc containers.
>
> For me, I have that need too for a firewall container.
>
> I think it is not so difficult to raise the 10 upto 32.
>
> Just change
>
> /usr/share/pve-manager/js/pvemanagerlib.js
>
> in Ext.define('PVE.lxc.NetworkView', {
>
> the line
>
> me.down('button[name=addButton]').setDisabled((records.length >= 10));
>
> to
>
> me.down('button[name=addButton]').setDisabled((records.length >= 32));
>
> And in
>
> /usr/share/perl5/PVE/LXC/Config.pm change
>
> my $MAX_LXC_NETWORKS = 10;
>
> to
>
> my $MAX_LXC_NETWORKS = 32;
>
> As far as I can see, that is enough.
>
> Would you please consider raising the limit? Would you like me to send 
> in a patch file or pull request.
>
> Or is the above sufficient.
>
> Thanks and kind regards,
>
> Stephan
>
>
> _______________________________________________
> pve-devel mailing list
> pve-devel at lists.proxmox.com
> https://lists.proxmox.com/cgi-bin/mailman/listinfo/pve-devel
>



More information about the pve-devel mailing list