Beruflich Dokumente
Kultur Dokumente
net/publication/283967880
CITATIONS READS
0 1,904
1 author:
SEE PROFILE
Some of the authors of this publication are also working on these related projects:
All content following this page was uploaded by Mohamed Elobaid Elshaikh on 17 November 2015.
Mohamed Elshaikh
SCHOOL OF COMPUTER AND COMMUNICATION ENGINEERING,
UNIMAP
Objectives
WAN network design concepts
Routing configuration
Example 1:
Simulation Steps:
Figure 3
In this example we concern about the links and there for we must define the required
gates for each component
Assuming that all connections are Ethernet, Initialize the numer of gates to 2 for each
router and one for each host.
Firstly switch to source mode and under each sub-module add gates section and
initialize the ethg gate to ethg[n] where n is the number of desired gates:
Figure 5.
Having our gates initialized the next step is to connect, however we need a channel to
connect our modules.
Figure 6.
Figure 7
Make sure the gates numbers are exactly the same as in the figure above as we use this
for routers configurations.
Figure 9
The intension of this example is to configure the OSPF router and network IP addressing.
Create a new config.xml file under the same directory to assign IP address for all
interfaces in the network.
Figure 10
Figure 11
Define the area id and its address range (network address can be more than one)
Attach all interfaces connected to the area for each router ad define the external
address rages for all VLANs at each router as:
Figure 12
6- Run the simulation
Create ini file for the network and add the following configuration:
Add a ping application at host A to generate traffic toward host B and vise versa.
The config.xml file must be attached to the configurator and the ASConfig.xml is
assigned to routers.
[General]
network = inet.examples.OSPFLab.OSPF2Routers
**.configurator.config = xmldoc("config.xml")
**.configurator.addStaticRoutes = false
**.configurator.addDefaultRoutes = false
**.ospf.ospfConfig = xmldoc("ASConfig.xml")
**.numPingApps = 1
**.A.pingApp[0].destAddr = "B"
**.B.pingApp[0].destAddr = "A"
**.pingApp[*].sendInterval = 1000ms
**.arp.cacheTimeout = 1s
Figure 13
Figure 14
Example 2
In this example a scenario of OSPF network with 3 routers and 2 areas is shown in figure
2 above.
To create this network follow the steps 1 to 4 in the last example to have your network
and its components connected as in figure 16.
In this example we use Ethernet gate to connect internal network and PPP gates to
connect routers. Make sure you have the correct gate connected in you .ned file
Figure 16
Figure 17
The next step is to configure the OSPF routers. Create a new xml file and name it
(ASConfig2.xml) and add the following code:
Figure 18
Assign both config2.xml and ASConfig2.xml to the configurator and the OSPF routers
[General]
network = inet.examples.OSPFLab.OSPF2Routers
**.configurator.config = xmldoc("config2.xml")
**.configurator.addStaticRoutes = false
**.configurator.addDefaultRoutes = false
**.ospf.ospfConfig = xmldoc("ASConfig2.xml")
**.numPingApps = 1
**.A*.pingApp[0].destAddr = "B1"
**.B*.pingApp[0].destAddr = "A1"
**.pingApp[*].sendInterval = 1000ms
**.arp.cacheTimeout = 1s
Figure 19
Run the simulation and observe results.
Figure 20