Interface/packet mirroring

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



I am trying to mirror the packets that get forwarded from one interface to the another.  One is an eql interface and the other is an ethernet card with a bigger pipe.  The ethernet card is the primary link and I dont even want to touch those packets.  I just want to mirror the packets to the eql interface as many as it can handle and I dont care if packets get lost on the eql interface.  I tried the following on ip_forward_finish() in ip_forward.c (2.4.27), but nothing gets sent on the eql interface.  Can someone point me in the right direction.  Thanks in advanced.
        {
                struct net_device *altdev = dev_get_by_name("eql");
                struct sk_buff *new_skb;
                if(altdev != NULL) {
                        new_skb = skb_copy(skb,GFP_ATOMIC);
                        if(new_skb != NULL) {
                                ((struct rtable*)new_skb->dst)->u.dst.dev = altdev;
                                ip_forward_options(new_skb);
                                ip_send(new_skb);
                                kfree_skb(new_skb);
                        }
                }
        }
        ip_forward_options(skb);
        return (ip_send(skb));


__________________________________________________________________
Switch to Netscape Internet Service.
As low as $9.95 a month -- Sign up today at http://isp.netscape.com/register

Netscape. Just the Net You Need.

New! Netscape Toolbar for Internet Explorer
Search from anywhere on the Web and block those annoying pop-ups.
Download now at http://channels.netscape.com/ns/search/install.jsp
-
: send the line "unsubscribe linux-net" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

[Index of Archives]     [Netdev]     [Ethernet Bridging]     [Linux 802.1Q VLAN]     [Linux Wireless]     [Kernel Newbies]     [Security]     [Linux for Hams]     [Netfilter]     [Git]     [Bugtraq]     [Yosemite News and Information]     [MIPS Linux]     [ARM Linux]     [Linux RAID]     [Linux PCI]     [Linux Admin]     [Samba]

  Powered by Linux