iptables is not picking tap interface packets

tincboy

Renowned Member
Apr 13, 2010
466
5
83
I've used a simple iptables rule to test some idea, but I can see it's not picking any packet on tap interface.
Is that normal?
Code:
root@node01:~# iptables -I FORWARD -i tap101i0
results:
Code:
root@node01:~# iptables -L FORWARD -v -n 
Chain FORWARD (policy ACCEPT 0 packets, 0 bytes)
 pkts bytes target     prot opt in     out     source               destination
    0     0            all  --  tap101i0 *       0.0.0.0/0            0.0.0.0/0
 
I've used a simple iptables rule to test some idea, but I can see it's not picking any packet on tap interface.
Is that normal?
Code:
root@node01:~# iptables -I FORWARD -i tap101i0
results:
Code:
root@node01:~# iptables -L FORWARD -v -n
Chain FORWARD (policy ACCEPT 0 packets, 0 bytes)
pkts bytes target     prot opt in     out     source               destination
    0     0            all  --  tap101i0 *       0.0.0.0/0            0.0.0.0/0
It fixed by using "-m physicaldev --physdev-in tap101i0" instead of -i, and it's because tap is layer 2 not layer 3
 

About

The Proxmox community has been around for many years and offers help and support for Proxmox VE, Proxmox Backup Server, and Proxmox Mail Gateway.
We think our community is one of the best thanks to people like you!

Get your subscription!

The Proxmox team works very hard to make sure you are running the best software and getting stable updates and security enhancements, as well as quick enterprise support. Tens of thousands of happy customers have a Proxmox subscription. Get yours easily in our online shop.

Buy now!