Results 1 to 1 of 1
Thread: Routing table simulation
- 01-08-2011, 12:16 AM #1Member
- Join Date
- Jan 2011
- Rep Power
Routing table simulation
To create a distributed simulator of a router program which, when instantiated in several machines, will start communicating with each other to create a routing table at each site.
Your software (which should be called myRouter) will be an independent application under Linux. When it is run, it takes the file name as its argument. So the command line will look like:
java myRouter data.txt
where “data.txt” will have the form e.g.
1. 9989 is the port number which it uses to receive routing data from other routers and receive datagrams from other routers and clients. Please use port numbers from 20001 to 20010 while running the program in Windows.
2. A, B, .. are the names of networks it is connected to (usually two or more).
3. A:22.214.171.124:8989 means this router is connected to A, and there is another router sharing this A which is running at 126.96.36.199:8989.
Routing Table Maintenance
You write only one program (can consist of several classes but only one main method). That same program is run in several PCs concurrently, with arguments as discussed above. They will start communicating with each other, to get a complete routing table at each site. Then they will output the routing table to the standard output. You can use either a distance vector or a link state.
Here is an example output. These are actual outputs after the program is run (tables are in columns defined as Network, hops and route):
A --- r1 --- B --- r2 --- C
r3 - (itl115)
A 0 direct
E 0 direct
B 1 /188.8.131.52
C 2 /184.108.40.206
I already have code for client server communication written in Java and working properly. I now need help with accessing routing table of each router and then appending it with the new entries and displaying it at each terminal with output displayed as above.
This is urgent and would really appreciate if somebody can provide program structure since I dont have much experience working on networking in Java.
- By pavan arepu in forum AWT / SwingReplies: 3Last Post: 04-21-2010, 04:47 PM
- By dnaevolutions in forum Java SoftwareReplies: 0Last Post: 10-05-2008, 01:19 AM
- By JavaBean in forum Java SoftwareReplies: 0Last Post: 11-27-2007, 09:34 PM
- By JavaBean in forum Java SoftwareReplies: 0Last Post: 11-12-2007, 07:01 PM
- By JavaBean in forum Java SoftwareReplies: 0Last Post: 06-23-2007, 07:25 PM