-
Notifications
You must be signed in to change notification settings - Fork 59
Add Traceroute Visualization Feature for Mini-Internet #50
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: master
Are you sure you want to change the base?
Add Traceroute Visualization Feature for Mini-Internet #50
Conversation
|
Thank you, will have a look at it in the coming days. |
|
@FuhrmannMartin did not forget about this PR, hope to have time over the coming long weekend. |
buehlert
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Some high-level observations:
- Using the code in its current form, I was not able to get it to run
- The traceroute page on the webserver loads nicely but running any traceroute cmd just leads to an empty response, i.e., just a small gray box without any content (under "Show raw output"). Would be good to show some error message instead.
- If I understand it correctly, you run the traceroute cmd via
docker execfrom within the webserver container. However, at the moment, the webserver container has no access to the host docker socket and can therefore not execute thedocker execcmd. Did it work for you? - One fix would be to add something like
-v /var/run/docker.sock:/var/run/docker.sockto thedocker runcmd that starts the webserver (e.g., in website_setup.sh). However, it could be risky to give the webserver these capabilities. Assuming a student would be able to somehow run an arbitrary docker cmd on the server, they could crash the entire mini-Internet.
- To test a bit more, I added the "fix" from the previous point. Now I was able to run traceroute cmds and they were displayed as expected.
- At the moment, you run the traceroute cmds between routers and not between hosts. In general, we always advise to run traceroutes from the host containers. The explanation is a bit difficult but basically you can end up in the following situation:
- Given that the IP subnet, used on an interface that conntects two ASes (normally something like 179.X.Y.Z/24), is not distributed into OSPF (a setup that also happens in the real Internet), routers/hosts that are not directly connected to this interface will not be able to reach the 179.X.Y.Z address. Assuming you start a traceroute on a router that has at least one external connection, it could happen that it selects the source IP address for the traceroute as the 179.X.Y.Z one (often the source IP is chosen randomly). As a result, traceroute packets will normally be able to reach the destination but the corresponding ICMP replies (once the TTL reaches zero) will be sent towards the 179.X.Y.Z address. As this address is normally not reachable, you will see a lot of
*traceroute hops. I was able to observe this behavior with your tool. - Perhaps it would be better to start the traceroutes from a host instead (with this setup it is impossible to use a 179.X.Y.Z address as source IP).
- Given that the IP subnet, used on an interface that conntects two ASes (normally something like 179.X.Y.Z/24), is not distributed into OSPF (a setup that also happens in the real Internet), routers/hosts that are not directly connected to this interface will not be able to reach the 179.X.Y.Z address. Assuming you start a traceroute on a router that has at least one external connection, it could happen that it selects the source IP address for the traceroute as the 179.X.Y.Z one (often the source IP is chosen randomly). As a result, traceroute packets will normally be able to reach the destination but the corresponding ICMP replies (once the TTL reaches zero) will be sent towards the 179.X.Y.Z address. As this address is normally not reachable, you will see a lot of
- I did not yet test if a policy validation is correctly displayed on the webserver. I wonder if it would need a dedicated entry in the "Legend" box that is shown at the bottom of the page.
Would be good if you could improve these points.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is this change needed? Normally, we do not want to define the specific host IP address that should be used between two ASes that belong to student groups (hence e.g., an entry such as 179.3.4.0/24). In the lecture, we normally ask the students to discuss with their neighboring ASes to figure out which IPs they should use (similar to peering discussions in the real Internet).
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
In my opinion it is needed, yes.
The default setup in the master branch has all inter-AS connections already configured as defined in the aslevel_links_students text-file.
While developing the traceroute feature I was using the auto-configuration function to configure the student's ASes. Only after fixing this lines the inter AS-routing was working correctly for me.
3 LUGA Peer 4 LUGA Peer 179.3.4.0/24
4 LUGA Peer 3 LUGA Peer 179.3.4.0/24
Before the change both sides were assigned the same IP address as can be seen above, which was causing the problem I guess.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Will look into that, thanks
|
@FuhrmannMartin finally, I had some time for a more detailed look. Sorry for the delays. A lot is going on at the moment. See review above for feedback. |
|
@buehlert thank you for your review!
I will come back to you once I find the time for implementation. |
|
@FuhrmannMartin some immediate reactions:
Thanks again for all your contributions. |
(cherry picked from commit 5a9624a)
|
Hello Tobias, I just pushed the changes based on your feedback. Aside from the minor points we discussed earlier, traceroutes now originate from and target the hosts connected to the selected routers. Two additional notes:
Best regards, |
|
Thank you, will have a look |
As discussed with Tobias Bühler via email, I’m submitting this pull request to contribute the new traceroute visualization feature to the Mini-Internet project.
A description of the implementation is available at:
platform/docker_images/webserver/docs/
I’m happy to adjust or refine anything if needed and look forward to your feedback!