Solved

Code Executes Multiple Times

Posted on 2012-04-02
4
749 Views
Last Modified: 2012-06-27
I have compiled code for a simple router program. I am taking a class and I needed to create a program that would simulate routers updating their routing tables. The only real question i have left is i'm not sure if the program should update the routers so often. I have attached all the parts of the program, the exe file and the log file of the output. Can someone take a quick look and let me know if the program should call the update function so many times, as illustrated by the output?

Thanks!

Running one node0/1/2/3.c file will also call the main program prog3.c and the other nodes and initiate the update process between all of the other nodes, also known as routers.
node0.c
node1.c
node2.c
node3.c
prog3.c
RoutingLog.txt
0
Comment
Question by:new435
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
4 Comments
 
LVL 34

Assisted Solution

by:sarabande
sarabande earned 250 total points
ID: 37800293
it is only you who could answer that question. generally, a simulation should be as near as possible to the reality. if in reality you have much less updates it isn't a good simulation at least in that point. note, a simulation is different to a stress test. in the latter you would go the limits but not beyond. if your program is neither a simulation nor a stress test but a unit test you could go beyond the limits and try to produce even worsest scenarios just to proove that your system is stable in every case. such a complete unit test is fine if it has the expected results. if it only finds problems which wouldn't occur in the reality you might loose the right focus and forget to test the normal.

Sara
0
 

Author Comment

by:new435
ID: 37802543
I'm not quite sure how often real routers update themselves, which is why I posed the question.
0
 
LVL 3

Accepted Solution

by:
algorith earned 250 total points
ID: 37803811
I have heard that a poisoned router will be cured in 15 minutes or so on average, but I could not find this number on a quick search.  This article might help http://www.isoc.org/isoc/conferences/ndss/06/proceedings/papers/churn_as_shelter.pdf

Bandwidth limitations might be a good way to decide - i.e. you don't want the router updating so often that it consumes a significant portion of you network's bandwidth.  On the other hand, you do want the bad routing information to be purged as quickly as possible. All of which makes the answer specific to your own situation, which as an assignment is possibly ill-defined.

You could ask the TA...let us know if he can answer...
0
 

Author Comment

by:new435
ID: 37818160
see my program ends up updating > 100 times and im not sure if that is rediculus or not.
0

Featured Post

Technology Partners: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
How do I bind a WPF ComboBox to an ItemSource using XAML? 2 30
c# - Best approach for objects in functions 3 27
Fill Null values 5 36
Selenium and Xpath 4 30
Windows programmers of the C/C++ variety, how many of you realise that since Window 9x Microsoft has been lying to you about what constitutes Unicode (http://en.wikipedia.org/wiki/Unicode)? They will have you believe that Unicode requires you to use…
Container Orchestration platforms empower organizations to scale their apps at an exceptional rate. This is the reason numerous innovation-driven companies are moving apps to an appropriated datacenter wide platform that empowers them to scale at a …
The viewer will learn additional member functions of the vector class. Specifically, the capacity and swap member functions will be introduced.
The viewer will be introduced to the technique of using vectors in C++. The video will cover how to define a vector, store values in the vector and retrieve data from the values stored in the vector.

756 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question