Comments (6)
Neinnnnnnnnn. Not again this foobar.
from icinga-vagrant.
After some digging, it seems that the ip lookup fails, because eth1
is named enp0s8
my environment.
This also affects the other ip addresses.
from icinga-vagrant.
Ok, this affects VirtualBox which uses the "predictable if name schema". Parallels does not for some reason.
[root@icinga2 ~]# ip a
1: lo: <LOOPBACK,UP,LOWER_UP> mtu 65536 qdisc noqueue state UNKNOWN qlen 1
link/loopback 00:00:00:00:00:00 brd 00:00:00:00:00:00
inet 127.0.0.1/8 scope host lo
valid_lft forever preferred_lft forever
inet6 ::1/128 scope host
valid_lft forever preferred_lft forever
2: enp0s3: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc pfifo_fast state UP qlen 1000
link/ether 08:00:27:ed:e3:61 brd ff:ff:ff:ff:ff:ff
inet 10.0.2.15/24 brd 10.0.2.255 scope global dynamic enp0s3
valid_lft 85514sec preferred_lft 85514sec
inet6 fe80::1b76:3522:f94e:cc7e/64 scope link
valid_lft forever preferred_lft forever
3: enp0s8: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc pfifo_fast state UNKNOWN qlen 1000
link/ether 08:00:27:2d:1c:13 brd ff:ff:ff:ff:ff:ff
inet 192.168.33.5/24 brd 192.168.33.255 scope global enp0s8
valid_lft forever preferred_lft forever
inet6 fe80::a00:27ff:fe2d:1c13/64 scope link
valid_lft forever preferred_lft forever
Workaround: Edit .puppet/hieradata/common.yaml and replace eth1
with enp0s8
.
I am still not convinced if enp0s8
always stays the same. There are some guides on the net which allow to disable predictable names and just use eth0/eth1. Still, hiera lookup with a fallback would be better.
from icinga-vagrant.
hashicorp/vagrant#7361 (comment)
elastic/logstash#5467
Note that the bento boxes do not disable predictable network interface names
from icinga-vagrant.
[root@icinga2 ~]# puppet facts
...
"interfaces": "enp0s3,enp0s8,lo",
"ipaddress": "10.0.2.15",
"ipaddress6": "fe80::1b76:3522:f94e:cc7e",
"ipaddress6_enp0s3": "fe80::1b76:3522:f94e:cc7e",
"ipaddress6_enp0s8": "fe80::a00:27ff:fe2d:1c13",
"ipaddress6_lo": "::1",
"ipaddress_enp0s3": "10.0.2.15",
"ipaddress_enp0s8": "192.168.33.5",
"ipaddress_lo": "127.0.0.1",
"mtu_enp0s3": 1500,
"mtu_enp0s8": 1500,
"mtu_lo": 65536,
"netmask": "255.255.255.0",
"netmask6": "ffff:ffff:ffff:ffff::",
"netmask6_enp0s3": "ffff:ffff:ffff:ffff::",
"netmask6_enp0s8": "ffff:ffff:ffff:ffff::",
"netmask6_lo": "ffff:ffff:ffff:ffff:ffff:ffff:ffff:ffff",
"netmask_enp0s3": "255.255.255.0",
"netmask_enp0s8": "255.255.255.0",
"netmask_lo": "255.0.0.0",
"network": "10.0.2.0",
"network6": "fe80::",
"network6_enp0s3": "fe80::",
"network6_enp0s8": "fe80::",
"network6_lo": "::1",
"network_enp0s3": "10.0.2.0",
"network_enp0s8": "192.168.33.0",
"network_lo": "127.0.0.0",
"networking": {
"dhcp": "10.0.2.2",
"domain": "vagrant.demo.icinga.com",
"fqdn": "icinga2.vagrant.demo.icinga.com",
"hostname": "icinga2",
"interfaces": {
"enp0s3": {
"bindings": [
{
"address": "10.0.2.15",
"netmask": "255.255.255.0",
"network": "10.0.2.0"
}
],
"bindings6": [
{
"address": "fe80::1b76:3522:f94e:cc7e",
"netmask": "ffff:ffff:ffff:ffff::",
"network": "fe80::"
}
],
"dhcp": "10.0.2.2",
"ip": "10.0.2.15",
"ip6": "fe80::1b76:3522:f94e:cc7e",
"mac": "08:00:27:ed:e3:61",
"mtu": 1500,
"netmask": "255.255.255.0",
"netmask6": "ffff:ffff:ffff:ffff::",
"network": "10.0.2.0",
"network6": "fe80::"
},
"enp0s8": {
"bindings": [
{
"address": "192.168.33.5",
"netmask": "255.255.255.0",
"network": "192.168.33.0"
}
],
"bindings6": [
{
"address": "fe80::a00:27ff:fe2d:1c13",
"netmask": "ffff:ffff:ffff:ffff::",
"network": "fe80::"
}
],
"ip": "192.168.33.5",
"ip6": "fe80::a00:27ff:fe2d:1c13",
"mac": "08:00:27:2d:1c:13",
"mtu": 1500,
"netmask": "255.255.255.0",
"netmask6": "ffff:ffff:ffff:ffff::",
"network": "192.168.33.0",
"network6": "fe80::"
},
"lo": {
"bindings": [
{
"address": "127.0.0.1",
"netmask": "255.0.0.0",
"network": "127.0.0.0"
}
],
"bindings6": [
{
"address": "::1",
"netmask": "ffff:ffff:ffff:ffff:ffff:ffff:ffff:ffff",
"network": "::1"
}
],
"ip": "127.0.0.1",
"ip6": "::1",
"mtu": 65536,
"netmask": "255.0.0.0",
"netmask6": "ffff:ffff:ffff:ffff:ffff:ffff:ffff:ffff",
"network": "127.0.0.0",
"network6": "::1"
}
},
"ip": "10.0.2.15",
"ip6": "fe80::1b76:3522:f94e:cc7e",
"mac": "08:00:27:ed:e3:61",
"mtu": 1500,
"netmask": "255.255.255.0",
"netmask6": "ffff:ffff:ffff:ffff::",
"network": "10.0.2.0",
"network6": "fe80::",
"primary": "enp0s3"
},
...
from icinga-vagrant.
Ok, fuck it. You cannot reliably determine the secondary interface. Either you attempt to extract that with hiera lookup(), modify hiera to support regexp on key/values. Or you'll go by the route of writing a custom fact which attempts to extract the secondary ip address.
Nothing which works reliably, therefore hieradata gets node specific ip addresses configured like anything else (the distributed boxes already override common.yaml with node specific data). This is how Puppet works, Vagrant is just a bonus on top for the host only bridge.
==> icinga2: Notice: /Stage[main]/Profiles::Icinga::Icingaweb2/Icingaweb2::Module[graphite]/Icingaweb2::Inisection[module-graphite-general]/Concat[/etc/icingaweb2/modules/graphite/config.ini]/File[/etc/icingaweb2/modules/graphite/config.ini]/content: content changed '{md5}960425c353d7d14a88ffab929f9ebb89' to '{md5}6f54e822aca78fded6e6771ad25e8c41'
michi@mbmif ~/coding/icinga/icinga-vagrant/standalone (master *+=) $ vagrant ssh -c 'sudo cat /etc/icingaweb2/modules/graphite/config.ini'
[graphite]
url = "http://192.168.33.5:8003"
[ui]
default_time_range = "5"
default_time_range_unit = "minutes"
disable_no_graphs_found = "0"
Connection to 127.0.0.1 closed.
PR is coming soon.
from icinga-vagrant.
Related Issues (20)
- Use Puppet roles to provide specific scenarios
- Use elastic/puppet-beats to install Elastic beats
- Evaluate Puppet 5 HOT 1
- Elastic: Install Grafana and configure datasource & dashboards
- NFS v3 / UDP is disabled on Centos 7 - icinga-vagrant standalone fails to start HOT 3
- Startup of the distributed environment fails HOT 5
- destroy only works in the vagrant directory HOT 2
- Update to Elastic 6.3
- Graylog Puppet Module support for Elasticsearch >= 6 HOT 3
- Demo with my servers? HOT 2
- Vagrant Up Fails with 'Undefined Local Variable Or Method' HOT 15
- GitLab CI playground
- Prometheus playground
- Graylog 3
- vmware workstation support HOT 1
- Vagrant Box "UP" fails at "puppet" installation
- Installation documentation for windows does not reflect current trees structure
- Standalone "vagrant up" fails due to "icingacli x509 import" returning 255 HOT 3
- vagrant up fails at /bin/yum -d 0 -e 0 -y install mod_ssl in standalone
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from icinga-vagrant.