-
Notifications
You must be signed in to change notification settings - Fork 53
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
Use smarter defaults for network interface for elasticsearch #52
Comments
👍 I just fell over that |
Me too. There actually is a default_interface in ohai, maybe this should be used. |
We originally defaulted to eth1 because we were mostly running in cloud environments where eth1 tended to be site-local and not connected to the internet / did not cost for bandwidth, so it seemed safer for cluster communication. We should investigate what the default interface is in ohai when running in popular clouds to see if it defaults to an internet-facing address or something else. |
Ohai parses the output of "route -n", takes the line starting with "0.0.0.0" and get the default_gateway and default_interface from there. So this is definitely an "internet-facing device". case node['custom_ohai_check']['cloud_provider']
when 'rackspace'
default['interface_to_use'] = 'eth1'
default['something_else'] = 'blubb'
when 'google'
<someone else will have to do this and send a pull request>
else
default['interface_to_use'] = node['network']['default_interface']
default['something_else'] = 'blubb'
end https://github.com/chef/ohai/blob/master/lib/ohai/plugins/linux/network.rb#L332-L334 |
There's a suggested approach in #167 :) (my assumption is that eth1 will always be private -- ie "local" in the |
Currently, unless you override, eth1 is used. This causes ES to silently exit if eth1 doesn't exist. We should fall back to eth0.
The text was updated successfully, but these errors were encountered: