-
Notifications
You must be signed in to change notification settings - Fork 68
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
Allow user to specify which broadcast IP to use for meshage #1458
Conversation
In some cases, cluster compute nodes have multiple interfaces and networks they can communicate with each other over, and one may be desirable over another for meshage comms. By default, minimega uses `255.255.255.255` as the broadcast address, and when multiple interfaces are present, the one acting as the default route is the one used. This commit adds a new command line option, `-broadcast`, for users to specify which broadcast IP to use for the mesh. It defaults to `255.255.255.255`, so this commit should be backwards compatible.
@aherna anymore thoughts on this? It doesn't break normal, default behavior (i.e., it's backwards compatible) so I'm hoping you will be amenable to merging it in. |
@activeshadow Havent tested the with latest changes. Is this urgent or can it wait til new year? |
@aherna it can most definitely wait. |
Hi @aherna just wanted to ping you on this again. |
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.
LGTM
func meshageStart(host, namespace string, degree, msaTimeout uint, broadcastIP string, port int) error { | ||
bip := net.ParseIP(broadcastIP) | ||
if bip == nil { | ||
return fmt.Errorf("invalid broadcast IP %s for meshage", broadcastIP) |
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.
Would it be more appropriate to state that the broadcastIP is an invalid IP as its invalid because it failed to parse vs its not the right IP for meshage? @activeshadow
f_base = flag.String("base", BASE_PATH, "base path for minimega data") | ||
f_degree = flag.Uint("degree", 0, "meshage starting degree") | ||
f_msaTimeout = flag.Uint("msa", 10, "meshage MSA timeout") | ||
f_broadcastIP = flag.String("broadcast", "255.255.255.255", "meshage broadcast address to use") |
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.
Whats the use case here? A user can dial by specific IP or hostname to reach another Minimega instance and create a mesh. ie mesh dial
In some cases, cluster compute nodes have multiple interfaces and
networks they can communicate with each other over, and one may be
desirable over another for meshage comms. By default, minimega uses
255.255.255.255
as the broadcast address, and when multiple interfacesare present, the one acting as the default route is the one used.
This commit adds a new command line option,
-broadcast
, for users tospecify which broadcast IP to use for the mesh. It defaults to
255.255.255.255
, so this commit should be backwards compatible.