Linux, FreeBSD, Juniper, Cisco / Network security articles and troubleshooting guides

FAQ
It is currently Wed Aug 23, 2017 8:58 am


Internet Protocol, Transport Control Protocol, Network protocols, Routing, Routers, IP aliases, Routes, Ethernet

Author Message
mandrei99
Post  Post subject: FreeBSD + IPERF sending IGMP v2 multicast group join / leave via specific interface  |  Posted: Mon Jul 22, 2013 10:41 am

Joined: Tue Aug 04, 2009 9:16 am
Posts: 245

Offline
 

FreeBSD + IPERF sending IGMP v2 multicast group join / leave via specific interface

FreeBSD + IPERF sending IGMP v2 multicast group join / leave via specific interface

Before I start. The route for the multicast group is obvious default route:
Code:
# route get 239.1.1.1
   route to: 239.1.1.1
destination: default
       mask: default
    gateway: apollo-vl10.ivorde.ro
  interface: vlan10
      flags: <UP,GATEWAY,DONE,STATIC>
recvpipe  sendpipe  ssthresh  rtt,msec    rttvar  hopcount      mtu     expire
       0         0         0         0         0         0      1500         0

Let's say I need to send igmp group report/join out the "vlan120" interface:
Code:
# ifconfig vlan120
vlan120: flags=8843<UP,BROADCAST,RUNNING,SIMPLEX,MULTICAST> metric 0 mtu 1500
        ether 00:07:e9:a5:9b:fa
        inet 10.1.120.2 netmask 0xffffff00 broadcast 10.1.120.255
        media: Ethernet autoselect (1000baseTX <full-duplex>)
        status: active
        vlan: 120 parent interface: em0


1. First add a /32 route for the multicast group via a gateway on the subnet for the specific outgoing interfaces (my case: vlan120 on FreeBSD)
Code:
# route add 239.1.1.1/32 10.1.120.1
add net 239.1.1.1: gateway 10.1.120.1


2. Use Iperf to join a multicast group:
Code:
# iperf -s -B 239.1.1.1 -u         
------------------------------------------------------------
Server listening on UDP port 5001
Binding to local address 239.1.1.1
Joining multicast group  239.1.1.1
Receiving 1470 byte datagrams
UDP buffer size: 40.6 KByte (default)
------------------------------------------------------------

Quote:
-s, --server
run in server mode
-B, --bind <host>
bind to <host>, an interface or multicast address
-u, --udp
use UDP rather than TCP


And the result via tcpdump:
Code:
16:32:53.808311 IP (tos 0x0, ttl 1, id 51941, offset 0, flags [none], proto IGMP (2), length 32, options (RA))
    10.1.120.2 > 239.1.1.1: igmp v2 report 239.1.1.1
16:32:55.360766 IP (tos 0x0, ttl 1, id 5334, offset 0, flags [none], proto IGMP (2), length 32, options (RA))
    10.1.120.2 > 224.0.0.2: igmp leave 239.1.1.1


First packet in above tcpdump is the igmp group report (join) for 239.1.1.1 and the second is the leave packet (when iperf command is interrupted). It is noticeable that multicast packets have a source of the "vlan120" intended outgoing interface.





Top
Display posts from previous:  Sort by  
E-mail friendPrint view

Topics related to - "FreeBSD + IPERF sending IGMP v2 multicast group join / leave via specific interface"
 Topics   Author   Replies   Views   Last post 
There are no new unread posts for this topic. FreeBSD + IPerf send multicast source traffic via specific interface

mandrei99

3

2445

Sat Apr 11, 2015 5:28 am

areeba View the latest post

There are no new unread posts for this topic. FreeBSD list interface multicast group membership

mandrei99

0

1573

Tue Dec 03, 2013 9:02 am

mandrei99 View the latest post

There are no new unread posts for this topic. FreeBSD list the outgoing interface for packets to a specific IP destination

mandrei99

0

759

Mon Jul 22, 2013 10:12 am

mandrei99 View the latest post

There are no new unread posts for this topic. Linux list the outgoing interface for packets to a specific IP destination

mandrei99

0

932

Mon Jul 22, 2013 10:17 am

mandrei99 View the latest post

There are no new unread posts for this topic. "OSPF not enabled on this interface" FreeBSD Quagga ospfd interface status

debuser

1

2450

Thu Apr 01, 2010 5:55 am

debuser View the latest post

There are no new unread posts for this topic. FreeBSD show network interface statistics

mandrei99

0

2161

Wed Sep 25, 2013 9:30 am

mandrei99 View the latest post

There are no new unread posts for this topic. How to accept IPv6 Router Advertisements on interface in FreeBSD

mandrei99

0

1092

Wed Apr 29, 2015 3:54 am

mandrei99 View the latest post

There are no new unread posts for this topic. Linux How to change hardware MAC address of an interface

debuser

1

892

Tue Dec 06, 2011 6:26 am

Zettie49 View the latest post

There are no new unread posts for this topic. KVM: List MAC address table and interface that learned them.

mandrei99

0

1263

Sun Feb 01, 2015 6:26 am

mandrei99 View the latest post

There are no new unread posts for this topic. Linux script for interface network bandwidth monitoring

admin

0

1245

Mon Feb 09, 2015 7:05 pm

admin View the latest post

 

Who is online
Users browsing this forum: No registered users and 0 guests
You can post new topics in this forum
You can reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum
Jump to:  
News News Site map Site map SitemapIndex SitemapIndex RSS Feed RSS Feed Channel list Channel list


Delete all board cookies | The team | All times are UTC - 5 hours [ DST ]



phpBB SEO