On Jul 3, 2012, at 10:52 AM, we...@pitt.edu wrote:

> Hi,
> 
> I'm doing the Create Router part in the tutorial. Here are some questions
> I'm confused about.
> 
> The topology is like that:
> h3-eth0 ----- eth1-s1-eth3 ----- eth1-s2-eth2 ----- eth0-h5
> h4-eth0 ----- eth2-s1
> 
> h3 and h4 both gateway is s1, but s1 has two interfaces with different
> MAC. How to add static ARP entry to the host about the s1? Like the
> following?
> h3  arp  -s  10.0.1.1  fa:70:27:95:fd:49
> h4  arp  -s  10.0.1.1  0a:94:cd:59:5a:69
> 
> If so, the mac addr of each interface on the switch changes everytime I
> restart the topology. Is there a way to use fixed mac for switch
> interfaces in the topology script?

MAC addresses reported by Linux for the switch data ports are not particularly 
relevant, since the switch is controlled by OpenFlow and all packets coming in 
(regardless of destination MAC) will be processed under OpenFlow's control.

Even more importantly, you should not try to use the Linux IP stack to "assign" 
an IP address to a switch data port.

You can "assign" any MAC you like to the router by simply picking any MAC you 
like and either installing a static ARP entry or generate ARP replies with that 
MAC.

For the tutorial, I recommend installing a static ARP entry in the hosts for 
the gateway IP address (with any MAC you like) and simply doing routing based 
on destination IP address.

> 
> If not, how to?
> 
> How to use openflow to assign ip to the switch/interface?
> 
> The way to construct an ARP packet is like this?
> arp_reply = arp()
> and then assign values to its attibutes?
> 
> I know the answers to these questions maybe obvious for you, please help me.
> 
> Thank you very much.
> 
> Weiyun
> 
> 
> 
> 
> 
> 

_______________________________________________
openflow-discuss mailing list
openflow-discuss@lists.stanford.edu
https://mailman.stanford.edu/mailman/listinfo/openflow-discuss

Reply via email to