Skip to content

Instantly share code, notes, and snippets.

@ChrisLundquist
Created October 16, 2012 09:42
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save ChrisLundquist/3898364 to your computer and use it in GitHub Desktop.
Save ChrisLundquist/3898364 to your computer and use it in GitHub Desktop.
ohai broken ipaddress attribute with missing eth0
ohai network/default_interface
[
"venet0"
]
# ifconfig
lo Link encap:Local Loopback
inet addr:127.0.0.1 Mask:255.0.0.0
inet6 addr: ::1/128 Scope:Host
UP LOOPBACK RUNNING MTU:16436 Metric:1
RX packets:200820 errors:0 dropped:0 overruns:0 frame:0
TX packets:200820 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:0
RX bytes:26350876 (26.3 MB) TX bytes:26350876 (26.3 MB)
venet0 Link encap:UNSPEC HWaddr 00-00-00-00-00-00-00-00-00-00-00-00-00-00-00-00
UP BROADCAST POINTOPOINT RUNNING NOARP MTU:1500 Metric:1
RX packets:148164 errors:0 dropped:0 overruns:0 frame:0
TX packets:52915 errors:0 dropped:2 overruns:0 carrier:0
collisions:0 txqueuelen:0
RX bytes:209215993 (209.2 MB) TX bytes:9759541 (9.7 MB)
venet0:0 Link encap:UNSPEC HWaddr 00-00-00-00-00-00-00-00-00-00-00-00-00-00-00-00
inet addr:208.85.151.98 P-t-P:208.85.151.98 Bcast:0.0.0.0 Mask:255.255.255.255
UP BROADCAST POINTOPOINT RUNNING NOARP MTU:1500 Metric:1
# ip addr show
1: lo: <LOOPBACK,UP,LOWER_UP> mtu 16436 qdisc noqueue state UNKNOWN
link/loopback 00:00:00:00:00:00 brd 00:00:00:00:00:00
inet 127.0.0.1/8 scope host lo
inet6 ::1/128 scope host
valid_lft forever preferred_lft forever
2: venet0: <BROADCAST,POINTOPOINT,NOARP,UP,LOWER_UP> mtu 1500 qdisc noqueue state UNKNOWN
link/void
inet 208.85.151.98/32 scope global venet0:0
# ohai ipaddress
/var/lib/gems/1.9.1/gems/ohai-6.14.0/lib/ohai/system.rb:246:in `attributes_print': I cannot find an attribute named ipaddress! (ArgumentError)
from /var/lib/gems/1.9.1/gems/ohai-6.14.0/lib/ohai/application.rb:101:in `block in run_application'
from /var/lib/gems/1.9.1/gems/ohai-6.14.0/lib/ohai/application.rb:100:in `each'
from /var/lib/gems/1.9.1/gems/ohai-6.14.0/lib/ohai/application.rb:100:in `run_application'
from /var/lib/gems/1.9.1/gems/ohai-6.14.0/lib/ohai/application.rb:75:in `run'
from /var/lib/gems/1.9.1/gems/ohai-6.14.0/bin/ohai:51:in `<top (required)>'
from /usr/local/bin/ohai:19:in `load'
from /usr/local/bin/ohai:19:in `<main>'
# ohai network
[
[
"interfaces",
{
"lo": {
"mtu": "16436",
"flags": [
"LOOPBACK",
"UP",
"LOWER_UP"
],
"encapsulation": "Loopback",
"addresses": {
"127.0.0.1": {
"family": "inet",
"prefixlen": "8",
"netmask": "255.0.0.0",
"scope": "Node"
},
"::1": {
"family": "inet6",
"prefixlen": "128",
"scope": "Node"
}
},
"state": "unknown"
},
"venet0": {
"type": "venet",
"number": "0",
"mtu": "1500",
"flags": [
"BROADCAST",
"NOARP",
"UP",
"LOWER_UP"
],
"state": "unknown",
"routes": [
{
"destination": "default",
"family": "inet",
"scope": "link"
},
{
"destination": "default",
"family": "inet6",
"metric": "1"
}
]
},
"venet0:0": {
"addresses": {
"208.85.151.98": {
"family": "inet",
"prefixlen": "32",
"netmask": "255.255.255.255",
"scope": "Global"
}
}
}
}
],
[
"default_interface",
"venet0"
],
[
"default_gateway",
"0.0.0.0"
],
[
"default_inet6_interface",
"venet0"
],
[
"default_inet6_gateway",
"::"
]
]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment