[pve-devel] [PATCH manager] fix #871: netstat: include veth devices

Stefan Priebe - Profihost AG s.priebe at profihost.ag
Wed Jan 20 10:53:34 CET 2016


Am 20.01.2016 um 10:26 schrieb Wolfgang Bumiller:
> Just a quick follow-up question: Is this not supposed to include
> data blocked by the firewall?

Yes but that's the way it works. If you rent a server somewhere you
still have to pay traffic which is blocked by YOUR iptables / Firewall
rules. The data was / is already transfered. Same for me and our
upstream carriers.

Stefan

> 
>> On January 19, 2016 at 11:47 AM Stefan Priebe - Profihost AG <s.priebe at profihost.ag> wrote:
>>
>>
>> ah thx! Never used LXC - Qemu only user.
>>
>> Am 19.01.2016 um 11:34 schrieb Wolfgang Bumiller:
>>>
>>>> On January 19, 2016 at 10:21 AM Stefan Priebe - Profihost AG <s.priebe at profihost.ag> wrote:
>>>>
>>>>
>>>> Am 19.01.2016 um 09:45 schrieb Wolfgang Bumiller:
>>>>> Include container's veth devices in /nodes/{node}/netstat
>>>>> ---
>>>>>
>>>>>  @Stefan Priebe:
>>>>>  As the implementation came from you with commit 72eb5b9f and I don't
>>>>>  see other references to this netstat function in the code I'd like
>>>>>  to ask if you agree with this change?
>>>>
>>>> ACK. Just to know - is veth still in use? I thought OpenVZ is dropped.
>>>
>>> veth != venet, veth is the standard linux two-port virtual ethernet link
>>> and used with LXC containers with the same naming scheme
>>> 'veth${vmid}i${netid}'
>>>
>>>> Stefan
>>>>
>>>>>
>>>>>  PVE/API2/Nodes.pm | 2 +-
>>>>>  1 file changed, 1 insertion(+), 1 deletion(-)
>>>>>
>>>>> diff --git a/PVE/API2/Nodes.pm b/PVE/API2/Nodes.pm
>>>>> index 311d874..b48478d 100644
>>>>> --- a/PVE/API2/Nodes.pm
>>>>> +++ b/PVE/API2/Nodes.pm
>>>>> @@ -290,7 +290,7 @@ __PACKAGE__->register_method({
>>>>>  
>>>>>  	my $netdev = PVE::ProcFSTools::read_proc_net_dev();
>>>>>  	foreach my $dev (keys %$netdev) {
>>>>> -		next if $dev !~ m/^tap([1-9]\d*)i(\d+)$/;
>>>>> +		next if $dev !~ m/^(?:tap|veth)([1-9]\d*)i(\d+)$/;
>>>>>  	        my $vmid = $1;
>>>>>  	        my $netid = $2;
>>>>>  
>>>>>
>>>>
>>>
>>
> 



More information about the pve-devel mailing list