-
Notifications
You must be signed in to change notification settings - Fork 27
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
add loopback veth code #77
base: master
Are you sure you want to change the base?
Conversation
@networkop i have updated the 2node.yaml, but not sure if we have any validity checking for links existing on the pod or not |
log.Infof("MY VETH STRUCT: %+v", spew.Sdump(myVeth)) | ||
log.Infof("PEER STRUCT: %+v", spew.Sdump(peerVeth)) | ||
return err | ||
} |
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.
Do we need a "continue" statement after successful. veth creation ?
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.
fixed this too
tests/2node.yml
Outdated
@@ -14,6 +14,10 @@ items: | |||
local_ip: 12.12.12.1/24 | |||
peer_intf: eth1 | |||
peer_ip: 12.12.12.2/24 | |||
- uid: 2 |
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.
I think uid:2
is already used, try making it 3 to avoid confusion.
As for the testing, try giving both ends of the link an IP address. I'm assuming ping -I <sourceIntf> <destIP>
should force the traffic down the veth pair. Might be worth checking with tcpdump.
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.
fixed the uid, though the veth is created fine, having same subnet on two interfaces would not work properly without moving the interfaces into separate netns.
143: eth3@eth2: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc noqueue state UP
link/ether ba:7e:81:44:27:86 brd ff:ff:ff:ff:ff:ff
inet 13.13.13.2/24 brd 13.13.13.255 scope global eth3
valid_lft forever preferred_lft forever
144: eth2@eth3: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc noqueue state UP
link/ether 52:fd:54:06:4e:50 brd ff:ff:ff:ff:ff:ff
inet 13.13.13.1/24 brd 13.13.13.255 scope global eth2
valid_lft forever preferred_lft forever
reminder to self to test and merge this @networkop |
@kingshukdev @manomugdha @networkop
Please review, this one is not tested in my lab yet..