-
Notifications
You must be signed in to change notification settings - Fork 489
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
extLowerInterface emulation fix #926
extLowerInterface emulation fix #926
Conversation
I don't know what you are trying to achieve with this PR. The purpose of ExtLowerEthernetInterface is to send packets to the host OS device. It cannot be used with TSN priority queueing at the moment. |
Hello @levy, it doesn't allow any packets to be sent to the host os at all, no matter which node you use it with. I tried a regular switch, standardhost, ethernethost... It also gives the same error on all when it receives packets in the simulation, when used in this manner from omnetpp.ini without modifying the ned files. This is because the inout phys gate in extLowerEthernetInterface.ned is declared but it's not connected to anything in the file. I have fixed the writing issue by connecting this. Also, I changed the part it writes to the nic, since it tries to write the whole simulation packet, not excluding the data added by the physical layer. Please correct me if my assumptions are wrong. In my opinion, I believe extLowerEthernetInterface should be it's own node instead of being initialized like this in omnetpp.ini. Because it is connecting to the nic device of the host computer, it is effectively connecting to an external real network, i.e. the cloud. I would actually be happy to open a pull request that implements this, I have also done some work on this as well. Thank you for your time. |
There are examples which use the ExtLowerEthernetInterface module, so it should work as intended. For example, in the examples/emulation/pinger folder you will find a working example, but there are others.
The ExtLowerEthernetInterface module is a network interface and not a network node. The phys gate is defined to be loose that means it can be unconnected internally and it doesn't have to be connected externally either. |
In the pinger example the frame never leaves the node. This issue occurs when a frame is sent from another node to the gate which ExtLowerEthernetInterface is set up. If I understand correctly, the electric signal is not decapsulated correctly to ethernet mac. I used standardhost here, but this occurs with switch too.
https://www.youtube.com/watch?v=-TxcYJhWjFU This is what cml uses, hence I proposed a seperate node for extLowerEthernetInterface. It seems more intiuitive and might be easier to maintain in the future. |
In the pinger example the frame leaves the simulated network node and goes into the host OS veth interface set up in run.sh. I think you misunderstand how emulation should work. An ExtLowerEthernetInterface phys gate should not be connected in the simulation, because as the module's name suggests the lower part of the interface resides in the host OS. The phys gate is there only because the module interface requires this. Please read the relevant chapter in the User's guide and look at the emulation examples/showcases and their documentation on the INET website. |
Oh I see, the gate interacting with the host os is supposed to be internal within the node. It worked when I set it up this way as you stated. However, #847 makes the same mistake I did, if you look at his .ned file. The error is related to that, tsn might not be implemented but his current error is the same as mine. So this worked for me, if anyone else is reading this pr for a solution:
|
Yes, I have already commented on #847 |
Oh, I just saw that. Thank you for your help and patience. I couldn't distinguish well how extLowerInterface was supposed to be used and not connected externally. I didn't realize there was an examples folder when I first started learning about inet and either it wasn't obvious or I missed it on the web ui documentation. The showcases were using apps, so I was having this issue and found this github issue instead. It has been a few months since I have been using inet and I am still very much new. Thanks again. |
close #847