I found the reason by myself.
Libpcap uses SIOCGIFINDEX ioctl
and according to linux_kernel/net/core/dev_ioctl.c, COLON(':') in interface
name is not supposed to be in a name for macvlan.
Anything after colon is ignored.
Capturing for eth1:2 is same as capturing eth1.
Use eth1_2 instead of eth1:2 t
Hello. Happy new year.
I'm trying to send a pcap file from linux machine A to B(directly
connected).
In machine A, I set up two virtual interfaces.
# ip link add link eth1 eth1:1 address 11:11:11:11:11:11 type macvlan
# ip link set eth1:1 up
# ip link add link eth1 eth1:2 address 22:22:22:2