Take the 2-minute tour ×
Server Fault is a question and answer site for professional system and network administrators. It's 100% free, no registration required.

I have a host that receives broadcast queries on a UDP port. I would like to forward this broadcast traffic to another host from another network. Is it possible to port forwarding broadcast traffic using iptables? I have tried to specify package traffic as broadcast (-m pkttype --pkt-type broadcast), but that didn't work.

If I recive unicast traffic on that port, the forwarding succeeds. I try to forwarding using nat table.(-A POSTROUTING -j DNAT --to-destinatiox x.x.x.x)

share|improve this question

closed as not a real question by Michael Hampton, Scott Pack, Brent Pabst, mdpc, voretaq7 Oct 25 '12 at 18:02

It's difficult to tell what is being asked here. This question is ambiguous, vague, incomplete, overly broad, or rhetorical and cannot be reasonably answered in its current form. For help clarifying this question so that it can be reopened, visit the help center.If this question can be reworded to fit the rules in the help center, please edit the question.

I don't know what you're really after, but I'm pretty sure you do not want to do this. –  Michael Hampton Oct 25 '12 at 15:54
Can you tell us a bit more about what you're trying to accomplish here? Generally you don't want to route broadcast traffic (one of the reasons for subnetting is to restrict broadcast domains - you could certainly write some code to listen for the broadcast requests and forward them along on another interface, but I don't believe there's any built-in facility to do this because it's generally a Bad Idea...) –  voretaq7 Oct 25 '12 at 18:02
I have a host that has a private IP and it comunicates via a NAT. I would like to forward all the broadcast traffic from the public network to this private network. –  Dragos Oct 26 '12 at 6:57