ohai 0.6.12 → 0.6.14.rc.1
Sign up to get free protection for your applications and to get access to all the features.
- data/lib/ohai/config.rb +13 -0
- data/lib/ohai/mixin/command.rb +9 -1
- data/lib/ohai/plugins/darwin/network.rb +5 -4
- data/lib/ohai/plugins/darwin/platform.rb +4 -2
- data/lib/ohai/plugins/ec2.rb +1 -1
- data/lib/ohai/plugins/eucalyptus.rb +1 -1
- data/lib/ohai/plugins/java.rb +8 -1
- data/lib/ohai/plugins/linux/network.rb +143 -47
- data/lib/ohai/plugins/linux/platform.rb +13 -13
- data/lib/ohai/plugins/linux/virtualization.rb +8 -12
- data/lib/ohai/plugins/network.rb +10 -4
- data/lib/ohai/plugins/os.rb +3 -3
- data/lib/ohai/plugins/rackspace.rb +1 -1
- data/lib/ohai/plugins/solaris2/platform.rb +7 -1
- data/lib/ohai/plugins/windows/network.rb +24 -32
- data/lib/ohai/plugins/windows/uptime.rb +23 -0
- data/lib/ohai/system.rb +26 -1
- data/lib/ohai/version.rb +1 -1
- data/spec/ohai/plugins/darwin/network_spec.rb +851 -0
- data/spec/ohai/plugins/darwin/platform_spec.rb +33 -1
- data/spec/ohai/plugins/ec2_spec.rb +32 -0
- data/spec/ohai/plugins/eucalyptus_spec.rb +32 -0
- data/spec/ohai/plugins/linux/network_spec.rb +597 -100
- data/spec/ohai/plugins/linux/platform_spec.rb +73 -53
- data/spec/ohai/plugins/linux/virtualization_spec.rb +11 -10
- data/spec/ohai/plugins/os_spec.rb +11 -0
- data/spec/ohai/plugins/platform_spec.rb +3 -3
- data/spec/ohai/plugins/rackspace_spec.rb +80 -49
- data/spec/ohai/plugins/solaris2/platform_spec.rb +77 -0
- metadata +53 -5
data/lib/ohai/plugins/os.rb
CHANGED
@@ -35,9 +35,9 @@ when /freebsd(.+)$/
|
|
35
35
|
os "freebsd"
|
36
36
|
when /openbsd(.+)$/
|
37
37
|
os "openbsd"
|
38
|
-
when /netbsd(
|
38
|
+
when /netbsd(.*)$/
|
39
39
|
os "netbsd"
|
40
|
-
when /solaris2
|
40
|
+
when /solaris2/
|
41
41
|
os "solaris2"
|
42
42
|
when /mswin|mingw32|windows/
|
43
43
|
# After long discussion in IRC the "powers that be" have come to a concensus
|
@@ -47,7 +47,7 @@ when /mswin|mingw32|windows/
|
|
47
47
|
# subsystems.
|
48
48
|
os "windows"
|
49
49
|
else
|
50
|
-
|
50
|
+
os ::RbConfig::CONFIG['host_os']
|
51
51
|
end
|
52
52
|
|
53
53
|
os_version kernel[:release]
|
@@ -48,7 +48,7 @@ end
|
|
48
48
|
# true:: If the rackspace cloud can be identified
|
49
49
|
# false:: Otherwise
|
50
50
|
def looks_like_rackspace?
|
51
|
-
has_rackspace_mac? || has_rackspace_kernel?
|
51
|
+
hint?('rackspace') || has_rackspace_mac? || has_rackspace_kernel?
|
52
52
|
end
|
53
53
|
|
54
54
|
# Names rackspace ip address
|
@@ -39,6 +39,9 @@ end
|
|
39
39
|
File.open("/etc/release") do |file|
|
40
40
|
while line = file.gets
|
41
41
|
case line
|
42
|
+
when /^\s*(OmniOS).*r(\d+).*$/
|
43
|
+
platform "omnios"
|
44
|
+
platform_version $2
|
42
45
|
when /^\s*(OpenIndiana).*oi_(\d+).*$/
|
43
46
|
platform "openindiana"
|
44
47
|
platform_version $2
|
@@ -51,6 +54,9 @@ File.open("/etc/release") do |file|
|
|
51
54
|
platform "solaris2"
|
52
55
|
when /^\s*(NexentaCore)\s.*$/
|
53
56
|
platform "nexentacore"
|
57
|
+
when /^\s*(SmartOS)\s(\d{8}T\d{6}Z)\s.*$/
|
58
|
+
platform "smartos"
|
59
|
+
platform_version $2
|
54
60
|
end
|
55
61
|
end
|
56
|
-
end
|
62
|
+
end
|
@@ -25,47 +25,33 @@ def encaps_lookup(encap)
|
|
25
25
|
encap
|
26
26
|
end
|
27
27
|
|
28
|
-
def derive_bcast(ipaddr, ipmask, zero_bcast = false)
|
29
|
-
begin
|
30
|
-
ipaddr_int = ipaddr.split(".").collect{ |x| x.to_i}.pack("C4").unpack("N").first
|
31
|
-
ipmask_int = ipmask.split(".").collect{ |x| x.to_i}.pack("C4").unpack("N").first
|
32
|
-
if zero_bcast
|
33
|
-
bcast_int = ipaddr_int & ipmask_int
|
34
|
-
else
|
35
|
-
bcast_int = ipaddr_int | 2 ** 32 - ipmask_int - 1
|
36
|
-
end
|
37
|
-
bcast = [bcast_int].pack("N").unpack("C4").join(".")
|
38
|
-
return bcast
|
39
|
-
rescue
|
40
|
-
return nil
|
41
|
-
end
|
42
|
-
end
|
43
|
-
|
44
28
|
iface = Mash.new
|
45
29
|
iface_config = Mash.new
|
46
30
|
iface_instance = Mash.new
|
47
31
|
|
32
|
+
# http://msdn.microsoft.com/en-us/library/windows/desktop/aa394217%28v=vs.85%29.aspx
|
48
33
|
adapters = WMI::Win32_NetworkAdapterConfiguration.find(:all)
|
49
34
|
adapters.each do |adapter|
|
50
35
|
i = adapter.Index
|
51
36
|
iface_config[i] = Mash.new
|
52
37
|
adapter.properties_.each do |p|
|
53
|
-
iface_config[i][p.name.wmi_underscore.to_sym] = adapter.
|
38
|
+
iface_config[i][p.name.wmi_underscore.to_sym] = adapter.invoke(p.name)
|
54
39
|
end
|
55
40
|
end
|
56
41
|
|
42
|
+
# http://msdn.microsoft.com/en-us/library/windows/desktop/aa394216(v=vs.85).aspx
|
57
43
|
adapters = WMI::Win32_NetworkAdapter.find(:all)
|
58
44
|
adapters.each do |adapter|
|
59
45
|
i = adapter.Index
|
60
46
|
iface_instance[i] = Mash.new
|
61
47
|
adapter.properties_.each do |p|
|
62
|
-
iface_instance[i][p.name.wmi_underscore.to_sym] = adapter.
|
48
|
+
iface_instance[i][p.name.wmi_underscore.to_sym] = adapter.invoke(p.name)
|
63
49
|
end
|
64
50
|
end
|
65
51
|
|
66
52
|
iface_instance.keys.each do |i|
|
67
|
-
if iface_config[i][:ip_enabled] and iface_instance[i][:net_connection_id]
|
68
|
-
cint = sprintf("0x%x", iface_instance[i][:interface_index]).downcase
|
53
|
+
if iface_config[i][:ip_enabled] and iface_instance[i][:net_connection_id]
|
54
|
+
cint = sprintf("0x%x", iface_instance[i][:interface_index] ? iface_instance[i][:interface_index] : iface_instance[i][:index] ).downcase
|
69
55
|
iface[cint] = Mash.new
|
70
56
|
iface[cint][:configuration] = iface_config[i]
|
71
57
|
iface[cint][:instance] = iface_instance[i]
|
@@ -73,18 +59,24 @@ iface_instance.keys.each do |i|
|
|
73
59
|
iface[cint][:counters] = Mash.new
|
74
60
|
iface[cint][:addresses] = Mash.new
|
75
61
|
iface[cint][:configuration][:ip_address].each_index do |i|
|
76
|
-
|
77
|
-
|
78
|
-
|
79
|
-
|
80
|
-
|
81
|
-
|
82
|
-
|
83
|
-
|
84
|
-
|
85
|
-
|
86
|
-
|
87
|
-
|
62
|
+
ip = iface[cint][:configuration][:ip_address][i]
|
63
|
+
_ip = IPAddress("#{ip}/#{iface[cint][:configuration][:ip_subnet][i]}")
|
64
|
+
iface[cint][:addresses][ip] = Mash.new(
|
65
|
+
:prefixlen => _ip.prefix
|
66
|
+
)
|
67
|
+
if _ip.ipv6?
|
68
|
+
# inet6 address
|
69
|
+
iface[cint][:addresses][ip][:family] = "inet6"
|
70
|
+
iface[cint][:addresses][ip][:scope] = "Link" if ip =~ /^fe80/i
|
71
|
+
else
|
72
|
+
# should be an inet4 address
|
73
|
+
iface[cint][:addresses][ip][:netmask] = _ip.netmask.to_s
|
74
|
+
if iface[cint][:configuration][:ip_use_zero_broadcast]
|
75
|
+
iface[cint][:addresses][ip][:broadcast] = _ip.network.to_s
|
76
|
+
else
|
77
|
+
iface[cint][:addresses][ip][:broadcast] = _ip.broadcast.to_s
|
78
|
+
end
|
79
|
+
iface[cint][:addresses][ip][:family] = "inet"
|
88
80
|
end
|
89
81
|
end
|
90
82
|
# Apparently you can have more than one mac_address? Odd.
|
@@ -0,0 +1,23 @@
|
|
1
|
+
#
|
2
|
+
# Author:: Paul Mooring (paul@opscode.com)
|
3
|
+
# Copyright:: Copyright (c) 2012 Opscode, Inc.
|
4
|
+
# License:: Apache License, Version 2.0
|
5
|
+
#
|
6
|
+
# Licensed under the Apache License, Version 2.0 (the "License");
|
7
|
+
# you may not use this file except in compliance with the License.
|
8
|
+
# You may obtain a copy of the License at
|
9
|
+
#
|
10
|
+
# http://www.apache.org/licenses/LICENSE-2.0
|
11
|
+
#
|
12
|
+
# Unless required by applicable law or agreed to in writing, software
|
13
|
+
# distributed under the License is distributed on an "AS IS" BASIS,
|
14
|
+
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
15
|
+
# See the License for the specific language governing permissions and
|
16
|
+
# limitations under the License.
|
17
|
+
#
|
18
|
+
require 'ruby-wmi'
|
19
|
+
|
20
|
+
provides "uptime", "uptime_seconds"
|
21
|
+
|
22
|
+
uptime_seconds ::WMI::Win32_PerfFormattedData_PerfOS_System.find(:first).SystemUpTime.to_i
|
23
|
+
uptime self._seconds_to_human(uptime_seconds)
|
data/lib/ohai/system.rb
CHANGED
@@ -26,7 +26,7 @@ require 'yajl'
|
|
26
26
|
|
27
27
|
module Ohai
|
28
28
|
class System
|
29
|
-
attr_accessor :data, :seen_plugins
|
29
|
+
attr_accessor :data, :seen_plugins, :hints
|
30
30
|
|
31
31
|
include Ohai::Mixin::FromFile
|
32
32
|
include Ohai::Mixin::Command
|
@@ -36,6 +36,7 @@ module Ohai
|
|
36
36
|
@seen_plugins = Hash.new
|
37
37
|
@providers = Mash.new
|
38
38
|
@plugin_path = ""
|
39
|
+
@hints = Hash.new
|
39
40
|
end
|
40
41
|
|
41
42
|
def [](key)
|
@@ -101,6 +102,27 @@ module Ohai
|
|
101
102
|
def get_attribute(name)
|
102
103
|
@data[name]
|
103
104
|
end
|
105
|
+
|
106
|
+
def hint?(name)
|
107
|
+
@json_parser ||= Yajl::Parser.new
|
108
|
+
|
109
|
+
return @hints[name] if @hints[name]
|
110
|
+
|
111
|
+
Ohai::Config[:hints_path].each do |path|
|
112
|
+
filename = File.join(path, "#{name}.json")
|
113
|
+
if File.exist?(filename)
|
114
|
+
begin
|
115
|
+
hash = @json_parser.parse(File.read(filename))
|
116
|
+
@hints[name] = hash || Hash.new # hint should exist because the file did, even if it didn't contain anything
|
117
|
+
rescue Yajl::ParseError => e
|
118
|
+
Ohai::Log.error("Could not parse hint file at #{filename}: #{e.message}")
|
119
|
+
end
|
120
|
+
end
|
121
|
+
end
|
122
|
+
|
123
|
+
@hints[name]
|
124
|
+
end
|
125
|
+
|
104
126
|
|
105
127
|
def all_plugins
|
106
128
|
require_plugin('os')
|
@@ -159,6 +181,9 @@ module Ohai
|
|
159
181
|
|
160
182
|
refreshments = collect_providers(h)
|
161
183
|
Ohai::Log.debug("Refreshing plugins: #{refreshments.join(", ")}")
|
184
|
+
|
185
|
+
# remove the hints cache
|
186
|
+
@hints = Hash.new
|
162
187
|
|
163
188
|
refreshments.each do |r|
|
164
189
|
@seen_plugins.delete(r) if @seen_plugins.has_key?(r)
|
data/lib/ohai/version.rb
CHANGED
@@ -0,0 +1,851 @@
|
|
1
|
+
#
|
2
|
+
# Author:: Alan Harper <alan@aussiegeek.net>
|
3
|
+
# Copyright:: Copyright (c) 2012 Opscode, Inc.
|
4
|
+
# License:: Apache License, Version 2.0
|
5
|
+
#
|
6
|
+
# Licensed under the Apache License, Version 2.0 (the "License");
|
7
|
+
# you may not use this file except in compliance with the License.
|
8
|
+
# You may obtain a copy of the License at
|
9
|
+
#
|
10
|
+
# http://www.apache.org/licenses/LICENSE-2.0
|
11
|
+
#
|
12
|
+
# Unless required by applicable law or agreed to in writing, software
|
13
|
+
# distributed under the License is distributed on an "AS IS" BASIS,
|
14
|
+
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
15
|
+
# See the License for the specific language governing permissions and
|
16
|
+
# limitations under the License.
|
17
|
+
#
|
18
|
+
|
19
|
+
require File.expand_path(File.dirname(__FILE__) + '/../../../spec_helper.rb')
|
20
|
+
|
21
|
+
describe Ohai::System, "Darwin Network Plugin" do
|
22
|
+
before do
|
23
|
+
darwin_ifconfig = <<-DARWIN_IFCONFIG
|
24
|
+
lo0: flags=8049<UP,LOOPBACK,RUNNING,MULTICAST> mtu 16384
|
25
|
+
options=3<RXCSUM,TXCSUM>
|
26
|
+
inet6 fe80::1%lo0 prefixlen 64 scopeid 0x1
|
27
|
+
inet 127.0.0.1 netmask 0xff000000
|
28
|
+
inet6 ::1 prefixlen 128
|
29
|
+
inet6 fd54:185f:37df:cad2:ba8d:12ff:fe3a:32de prefixlen 128
|
30
|
+
gif0: flags=8010<POINTOPOINT,MULTICAST> mtu 1280
|
31
|
+
stf0: flags=0<> mtu 1280
|
32
|
+
en1: flags=8863<UP,BROADCAST,SMART,RUNNING,SIMPLEX,MULTICAST> mtu 1500
|
33
|
+
ether b8:8d:12:3a:32:de
|
34
|
+
inet6 fe80::ba8d:12ff:fe3a:32de%en1 prefixlen 64 scopeid 0x4
|
35
|
+
inet 10.20.10.144 netmask 0xffffff00 broadcast 10.20.10.255
|
36
|
+
inet6 2001:44b8:4186:1100:ba8d:12ff:fe3a:32de prefixlen 64 autoconf
|
37
|
+
inet6 2001:44b8:4186:1100:7dba:7a60:97a:e14a prefixlen 64 autoconf temporary
|
38
|
+
media: autoselect
|
39
|
+
status: active
|
40
|
+
p2p0: flags=8843<UP,BROADCAST,RUNNING,SIMPLEX,MULTICAST> mtu 2304
|
41
|
+
ether 0a:8d:12:3a:32:de
|
42
|
+
media: autoselect
|
43
|
+
status: inactive
|
44
|
+
en0: flags=8863<UP,BROADCAST,SMART,RUNNING,SIMPLEX,MULTICAST> mtu 1500
|
45
|
+
options=2b<RXCSUM,TXCSUM,VLAN_HWTAGGING,TSO4>
|
46
|
+
ether 3c:07:54:4e:0e:35
|
47
|
+
media: autoselect (none)
|
48
|
+
status: inactive
|
49
|
+
fw0: flags=8822<BROADCAST,SMART,SIMPLEX,MULTICAST> mtu 4078
|
50
|
+
lladdr a4:b1:97:ff:fe:b9:3a:d4
|
51
|
+
media: autoselect <full-duplex>
|
52
|
+
status: inactive
|
53
|
+
utun0: flags=8051<UP,POINTOPOINT,RUNNING,MULTICAST> mtu 1380
|
54
|
+
inet6 fe80::ba8d:12ff:fe3a:32de%utun0 prefixlen 64 scopeid 0x8
|
55
|
+
inet6 fd00:6587:52d7:c87:ba8d:12ff:fe3a:32de prefixlen 64
|
56
|
+
DARWIN_IFCONFIG
|
57
|
+
|
58
|
+
darwin_arp = <<-DARWIN_ARP
|
59
|
+
? (10.20.10.1) at 0:4:ed:de:41:bf on en1 ifscope [ethernet]
|
60
|
+
? (10.20.10.2) at 0:1e:c9:55:7e:ee on en1 ifscope [ethernet]
|
61
|
+
? (10.20.10.6) at 34:15:9e:18:a1:20 on en1 ifscope [ethernet]
|
62
|
+
? (10.20.10.57) at cc:8:e0:e0:8a:2 on en1 ifscope [ethernet]
|
63
|
+
? (10.20.10.61) at 28:37:37:12:5:77 on en1 ifscope [ethernet]
|
64
|
+
? (10.20.10.73) at e0:f8:47:8:86:2 on en1 ifscope [ethernet]
|
65
|
+
? (10.20.10.130) at 68:a8:6d:da:2b:24 on en1 ifscope [ethernet]
|
66
|
+
? (10.20.10.138) at 8:0:37:8c:d2:23 on en1 ifscope [ethernet]
|
67
|
+
? (10.20.10.141) at b8:8d:12:28:c5:90 on en1 ifscope [ethernet]
|
68
|
+
? (10.20.10.166) at 0:1b:63:a0:1:3a on en1 ifscope [ethernet]
|
69
|
+
? (10.20.10.174) at 98:d6:bb:bd:37:ad on en1 ifscope [ethernet]
|
70
|
+
? (10.20.10.178) at 24:ab:81:2d:a3:c5 on en1 ifscope [ethernet]
|
71
|
+
? (10.20.10.181) at 78:a3:e4:e4:16:32 on en1 ifscope [ethernet]
|
72
|
+
? (10.20.10.185) at 0:26:8:9a:e8:a3 on en1 ifscope [ethernet]
|
73
|
+
? (10.20.10.200) at b8:8d:12:55:7f:7f on en1 ifscope [ethernet]
|
74
|
+
? (10.20.10.255) at ff:ff:ff:ff:ff:ff on en1 ifscope [ethernet]
|
75
|
+
DARWIN_ARP
|
76
|
+
|
77
|
+
darwin_route = <<-DARWIN_ROUTE
|
78
|
+
route to: default
|
79
|
+
destination: default
|
80
|
+
mask: default
|
81
|
+
gateway: 10.20.10.1
|
82
|
+
interface: en1
|
83
|
+
flags: <UP,GATEWAY,DONE,STATIC,PRCLONING>
|
84
|
+
recvpipe sendpipe ssthresh rtt,msec rttvar hopcount mtu expire
|
85
|
+
0 0 0 0 0 0 1500 0
|
86
|
+
DARWIN_ROUTE
|
87
|
+
|
88
|
+
darwin_netstat = <<-DARWIN_NETSTAT
|
89
|
+
Name Mtu Network Address Ipkts Ierrs Ibytes Opkts Oerrs Obytes Coll Drop
|
90
|
+
lo0 16384 <Link#1> 174982 0 25774844 174982 0 25774844 0
|
91
|
+
lo0 16384 fe80::1%lo0 fe80:1::1 174982 - 25774844 174982 - 25774844 - -
|
92
|
+
lo0 16384 127 127.0.0.1 174982 - 25774844 174982 - 25774844 - -
|
93
|
+
lo0 16384 ::1/128 ::1 174982 - 25774844 174982 - 25774844 - -
|
94
|
+
lo0 16384 fd54:185f:3 fd54:185f:37df:ca 174982 - 25774844 174982 - 25774844 - -
|
95
|
+
gif0* 1280 <Link#2> 0 0 0 0 0 0 0
|
96
|
+
stf0* 1280 <Link#3> 0 0 0 0 0 0 0
|
97
|
+
en1 1500 <Link#4> b8:8d:12:3a:32:de 5921903 0 2530556736 14314573 0 18228234970 0
|
98
|
+
en1 1500 fe80::ba8d: fe80:4::ba8d:12ff 5921903 - 2530556736 14314573 - 18228234970 - -
|
99
|
+
en1 1500 10.20.10/24 10.20.10.144 5921903 - 2530556736 14314573 - 18228234970 - -
|
100
|
+
en1 1500 2001:44b8:4 2001:44b8:4186:11 5921903 - 2530556736 14314573 - 18228234970 - -
|
101
|
+
en1 1500 2001:44b8:4 2001:44b8:4186:11 5921903 - 2530556736 14314573 - 18228234970 - -
|
102
|
+
p2p0 2304 <Link#5> 0a:8d:12:3a:32:de 0 0 0 0 0 0 0
|
103
|
+
en0 1500 <Link#6> 3c:07:54:4e:0e:35 0 0 0 0 0 2394 0
|
104
|
+
fw0* 4078 <Link#7> a4:b1:97:ff:fe:b9:3a:d4 0 0 0 0 0 1038 0
|
105
|
+
utun0 1380 <Link#8> 5 0 324 13 0 740 0
|
106
|
+
utun0 1380 fe80::ba8d: fe80:8::ba8d:12ff 5 - 324 13 - 740 - -
|
107
|
+
utun0 1380 fd00:6587:5 fd00:6587:52d7:c8 5 - 324 13 - 740 - -
|
108
|
+
DARWIN_NETSTAT
|
109
|
+
|
110
|
+
darwin_sysctl = <<-DARWIN_SYSCTL
|
111
|
+
net.local.stream.sendspace: 8192
|
112
|
+
net.local.stream.recvspace: 8192
|
113
|
+
net.local.stream.tracemdns: 0
|
114
|
+
net.local.dgram.maxdgram: 2048
|
115
|
+
net.local.dgram.recvspace: 4096
|
116
|
+
net.local.inflight: 0
|
117
|
+
net.inet.ip.portrange.lowfirst: 1023
|
118
|
+
net.inet.ip.portrange.lowlast: 600
|
119
|
+
net.inet.ip.portrange.first: 49152
|
120
|
+
net.inet.ip.portrange.last: 65535
|
121
|
+
net.inet.ip.portrange.hifirst: 49152
|
122
|
+
net.inet.ip.portrange.hilast: 65535
|
123
|
+
net.inet.ip.forwarding: 1
|
124
|
+
net.inet.ip.redirect: 1
|
125
|
+
net.inet.ip.ttl: 64
|
126
|
+
net.inet.ip.rtexpire: 12
|
127
|
+
net.inet.ip.rtminexpire: 10
|
128
|
+
net.inet.ip.rtmaxcache: 128
|
129
|
+
net.inet.ip.sourceroute: 0
|
130
|
+
net.inet.ip.intr_queue_maxlen: 50
|
131
|
+
net.inet.ip.intr_queue_drops: 0
|
132
|
+
net.inet.ip.accept_sourceroute: 0
|
133
|
+
net.inet.ip.keepfaith: 0
|
134
|
+
net.inet.ip.gifttl: 30
|
135
|
+
net.inet.ip.subnets_are_local: 0
|
136
|
+
net.inet.ip.mcast.maxgrpsrc: 512
|
137
|
+
net.inet.ip.mcast.maxsocksrc: 128
|
138
|
+
net.inet.ip.mcast.loop: 1
|
139
|
+
net.inet.ip.check_route_selfref: 1
|
140
|
+
net.inet.ip.use_route_genid: 1
|
141
|
+
net.inet.ip.dummynet.hash_size: 64
|
142
|
+
net.inet.ip.dummynet.curr_time: 0
|
143
|
+
net.inet.ip.dummynet.ready_heap: 0
|
144
|
+
net.inet.ip.dummynet.extract_heap: 0
|
145
|
+
net.inet.ip.dummynet.searches: 0
|
146
|
+
net.inet.ip.dummynet.search_steps: 0
|
147
|
+
net.inet.ip.dummynet.expire: 1
|
148
|
+
net.inet.ip.dummynet.max_chain_len: 16
|
149
|
+
net.inet.ip.dummynet.red_lookup_depth: 256
|
150
|
+
net.inet.ip.dummynet.red_avg_pkt_size: 512
|
151
|
+
net.inet.ip.dummynet.red_max_pkt_size: 1500
|
152
|
+
net.inet.ip.dummynet.debug: 0
|
153
|
+
net.inet.ip.fw.enable: 1
|
154
|
+
net.inet.ip.fw.autoinc_step: 100
|
155
|
+
net.inet.ip.fw.one_pass: 0
|
156
|
+
net.inet.ip.fw.debug: 0
|
157
|
+
net.inet.ip.fw.verbose: 0
|
158
|
+
net.inet.ip.fw.verbose_limit: 0
|
159
|
+
net.inet.ip.fw.dyn_buckets: 256
|
160
|
+
net.inet.ip.fw.curr_dyn_buckets: 256
|
161
|
+
net.inet.ip.fw.dyn_count: 0
|
162
|
+
net.inet.ip.fw.dyn_max: 4096
|
163
|
+
net.inet.ip.fw.static_count: 2
|
164
|
+
net.inet.ip.fw.dyn_ack_lifetime: 300
|
165
|
+
net.inet.ip.fw.dyn_syn_lifetime: 20
|
166
|
+
net.inet.ip.fw.dyn_fin_lifetime: 1
|
167
|
+
net.inet.ip.fw.dyn_rst_lifetime: 1
|
168
|
+
net.inet.ip.fw.dyn_udp_lifetime: 10
|
169
|
+
net.inet.ip.fw.dyn_short_lifetime: 5
|
170
|
+
net.inet.ip.fw.dyn_keepalive: 1
|
171
|
+
net.inet.ip.maxfragpackets: 1536
|
172
|
+
net.inet.ip.maxfragsperpacket: 128
|
173
|
+
net.inet.ip.maxfrags: 3072
|
174
|
+
net.inet.ip.scopedroute: 1
|
175
|
+
net.inet.ip.check_interface: 0
|
176
|
+
net.inet.ip.linklocal.in.allowbadttl: 1
|
177
|
+
net.inet.ip.random_id: 1
|
178
|
+
net.inet.ip.maxchainsent: 0
|
179
|
+
net.inet.ip.select_srcif_debug: 0
|
180
|
+
net.inet.icmp.maskrepl: 0
|
181
|
+
net.inet.icmp.icmplim: 250
|
182
|
+
net.inet.icmp.timestamp: 0
|
183
|
+
net.inet.icmp.drop_redirect: 0
|
184
|
+
net.inet.icmp.log_redirect: 0
|
185
|
+
net.inet.icmp.bmcastecho: 1
|
186
|
+
net.inet.igmp.recvifkludge: 1
|
187
|
+
net.inet.igmp.sendra: 1
|
188
|
+
net.inet.igmp.sendlocal: 1
|
189
|
+
net.inet.igmp.v1enable: 1
|
190
|
+
net.inet.igmp.v2enable: 1
|
191
|
+
net.inet.igmp.legacysupp: 0
|
192
|
+
net.inet.igmp.default_version: 3
|
193
|
+
net.inet.igmp.gsrdelay: 10
|
194
|
+
net.inet.igmp.debug: 0
|
195
|
+
net.inet.tcp.rfc1323: 1
|
196
|
+
net.inet.tcp.rfc1644: 0
|
197
|
+
net.inet.tcp.mssdflt: 512
|
198
|
+
net.inet.tcp.keepidle: 7200000
|
199
|
+
net.inet.tcp.keepintvl: 75000
|
200
|
+
net.inet.tcp.sendspace: 65536
|
201
|
+
net.inet.tcp.recvspace: 65536
|
202
|
+
net.inet.tcp.keepinit: 75000
|
203
|
+
net.inet.tcp.v6mssdflt: 1024
|
204
|
+
net.inet.tcp.log_in_vain: 0
|
205
|
+
net.inet.tcp.blackhole: 0
|
206
|
+
net.inet.tcp.delayed_ack: 3
|
207
|
+
net.inet.tcp.tcp_lq_overflow: 1
|
208
|
+
net.inet.tcp.recvbg: 0
|
209
|
+
net.inet.tcp.drop_synfin: 1
|
210
|
+
net.inet.tcp.reass.maxsegments: 3072
|
211
|
+
net.inet.tcp.reass.cursegments: 0
|
212
|
+
net.inet.tcp.reass.overflows: 0
|
213
|
+
net.inet.tcp.slowlink_wsize: 8192
|
214
|
+
net.inet.tcp.maxseg_unacked: 8
|
215
|
+
net.inet.tcp.rfc3465: 1
|
216
|
+
net.inet.tcp.rfc3465_lim2: 1
|
217
|
+
net.inet.tcp.rtt_samples_per_slot: 20
|
218
|
+
net.inet.tcp.recv_allowed_iaj: 5
|
219
|
+
net.inet.tcp.acc_iaj_high_thresh: 100
|
220
|
+
net.inet.tcp.rexmt_thresh: 2
|
221
|
+
net.inet.tcp.path_mtu_discovery: 1
|
222
|
+
net.inet.tcp.slowstart_flightsize: 1
|
223
|
+
net.inet.tcp.local_slowstart_flightsize: 8
|
224
|
+
net.inet.tcp.tso: 1
|
225
|
+
net.inet.tcp.ecn_initiate_out: 0
|
226
|
+
net.inet.tcp.ecn_negotiate_in: 0
|
227
|
+
net.inet.tcp.packetchain: 50
|
228
|
+
net.inet.tcp.socket_unlocked_on_output: 1
|
229
|
+
net.inet.tcp.rfc3390: 1
|
230
|
+
net.inet.tcp.min_iaj_win: 4
|
231
|
+
net.inet.tcp.acc_iaj_react_limit: 200
|
232
|
+
net.inet.tcp.sack: 1
|
233
|
+
net.inet.tcp.sack_maxholes: 128
|
234
|
+
net.inet.tcp.sack_globalmaxholes: 65536
|
235
|
+
net.inet.tcp.sack_globalholes: 0
|
236
|
+
net.inet.tcp.minmss: 216
|
237
|
+
net.inet.tcp.minmssoverload: 0
|
238
|
+
net.inet.tcp.do_tcpdrain: 0
|
239
|
+
net.inet.tcp.pcbcount: 86
|
240
|
+
net.inet.tcp.icmp_may_rst: 1
|
241
|
+
net.inet.tcp.strict_rfc1948: 0
|
242
|
+
net.inet.tcp.isn_reseed_interval: 0
|
243
|
+
net.inet.tcp.background_io_enabled: 1
|
244
|
+
net.inet.tcp.rtt_min: 100
|
245
|
+
net.inet.tcp.rexmt_slop: 200
|
246
|
+
net.inet.tcp.randomize_ports: 0
|
247
|
+
net.inet.tcp.newreno_sockets: 81
|
248
|
+
net.inet.tcp.background_sockets: -1
|
249
|
+
net.inet.tcp.tcbhashsize: 4096
|
250
|
+
net.inet.tcp.background_io_trigger: 5
|
251
|
+
net.inet.tcp.msl: 15000
|
252
|
+
net.inet.tcp.max_persist_timeout: 0
|
253
|
+
net.inet.tcp.always_keepalive: 0
|
254
|
+
net.inet.tcp.timer_fastmode_idlemax: 20
|
255
|
+
net.inet.tcp.broken_peer_syn_rxmit_thres: 7
|
256
|
+
net.inet.tcp.tcp_timer_advanced: 5
|
257
|
+
net.inet.tcp.tcp_resched_timerlist: 12209
|
258
|
+
net.inet.tcp.pmtud_blackhole_detection: 1
|
259
|
+
net.inet.tcp.pmtud_blackhole_mss: 1200
|
260
|
+
net.inet.tcp.timer_fastquantum: 100
|
261
|
+
net.inet.tcp.timer_slowquantum: 500
|
262
|
+
net.inet.tcp.win_scale_factor: 3
|
263
|
+
net.inet.tcp.in_sw_cksum: 5658081
|
264
|
+
net.inet.tcp.in_sw_cksum_bytes: 2198681467
|
265
|
+
net.inet.tcp.out_sw_cksum: 14166053
|
266
|
+
net.inet.tcp.out_sw_cksum_bytes: 17732561863
|
267
|
+
net.inet.tcp.sockthreshold: 64
|
268
|
+
net.inet.tcp.bg_target_qdelay: 100
|
269
|
+
net.inet.tcp.bg_allowed_increase: 2
|
270
|
+
net.inet.tcp.bg_tether_shift: 1
|
271
|
+
net.inet.tcp.bg_ss_fltsz: 2
|
272
|
+
net.inet.udp.checksum: 1
|
273
|
+
net.inet.udp.maxdgram: 9216
|
274
|
+
net.inet.udp.recvspace: 42080
|
275
|
+
net.inet.udp.in_sw_cksum: 19639
|
276
|
+
net.inet.udp.in_sw_cksum_bytes: 3928092
|
277
|
+
net.inet.udp.out_sw_cksum: 17436
|
278
|
+
net.inet.udp.out_sw_cksum_bytes: 2495444
|
279
|
+
net.inet.udp.log_in_vain: 0
|
280
|
+
net.inet.udp.blackhole: 0
|
281
|
+
net.inet.udp.pcbcount: 72
|
282
|
+
net.inet.udp.randomize_ports: 1
|
283
|
+
net.inet.ipsec.def_policy: 1
|
284
|
+
net.inet.ipsec.esp_trans_deflev: 1
|
285
|
+
net.inet.ipsec.esp_net_deflev: 1
|
286
|
+
net.inet.ipsec.ah_trans_deflev: 1
|
287
|
+
net.inet.ipsec.ah_net_deflev: 1
|
288
|
+
net.inet.ipsec.ah_cleartos: 1
|
289
|
+
net.inet.ipsec.ah_offsetmask: 0
|
290
|
+
net.inet.ipsec.dfbit: 0
|
291
|
+
net.inet.ipsec.ecn: 0
|
292
|
+
net.inet.ipsec.debug: 0
|
293
|
+
net.inet.ipsec.esp_randpad: -1
|
294
|
+
net.inet.ipsec.bypass: 0
|
295
|
+
net.inet.ipsec.esp_port: 4500
|
296
|
+
net.inet.raw.maxdgram: 8192
|
297
|
+
net.inet.raw.recvspace: 8192
|
298
|
+
net.link.generic.system.ifcount: 10
|
299
|
+
net.link.generic.system.dlil_verbose: 0
|
300
|
+
net.link.generic.system.multi_threaded_input: 1
|
301
|
+
net.link.generic.system.dlil_input_sanity_check: 0
|
302
|
+
net.link.ether.inet.prune_intvl: 300
|
303
|
+
net.link.ether.inet.max_age: 1200
|
304
|
+
net.link.ether.inet.host_down_time: 20
|
305
|
+
net.link.ether.inet.apple_hwcksum_tx: 1
|
306
|
+
net.link.ether.inet.apple_hwcksum_rx: 1
|
307
|
+
net.link.ether.inet.arp_llreach_base: 30
|
308
|
+
net.link.ether.inet.maxtries: 5
|
309
|
+
net.link.ether.inet.useloopback: 1
|
310
|
+
net.link.ether.inet.proxyall: 0
|
311
|
+
net.link.ether.inet.sendllconflict: 0
|
312
|
+
net.link.ether.inet.log_arp_warnings: 0
|
313
|
+
net.link.ether.inet.keep_announcements: 1
|
314
|
+
net.link.ether.inet.send_conflicting_probes: 1
|
315
|
+
net.link.bridge.log_stp: 0
|
316
|
+
net.link.bridge.debug: 0
|
317
|
+
net.key.debug: 0
|
318
|
+
net.key.spi_trycnt: 1000
|
319
|
+
net.key.spi_minval: 256
|
320
|
+
net.key.spi_maxval: 268435455
|
321
|
+
net.key.int_random: 60
|
322
|
+
net.key.larval_lifetime: 30
|
323
|
+
net.key.blockacq_count: 10
|
324
|
+
net.key.blockacq_lifetime: 20
|
325
|
+
net.key.esp_keymin: 256
|
326
|
+
net.key.esp_auth: 0
|
327
|
+
net.key.ah_keymin: 128
|
328
|
+
net.key.prefered_oldsa: 0
|
329
|
+
net.key.natt_keepalive_interval: 20
|
330
|
+
net.inet6.ip6.forwarding: 0
|
331
|
+
net.inet6.ip6.redirect: 1
|
332
|
+
net.inet6.ip6.hlim: 64
|
333
|
+
net.inet6.ip6.maxfragpackets: 1536
|
334
|
+
net.inet6.ip6.accept_rtadv: 0
|
335
|
+
net.inet6.ip6.keepfaith: 0
|
336
|
+
net.inet6.ip6.log_interval: 5
|
337
|
+
net.inet6.ip6.hdrnestlimit: 15
|
338
|
+
net.inet6.ip6.dad_count: 1
|
339
|
+
net.inet6.ip6.auto_flowlabel: 1
|
340
|
+
net.inet6.ip6.defmcasthlim: 1
|
341
|
+
net.inet6.ip6.gifhlim: 0
|
342
|
+
net.inet6.ip6.kame_version: 2009/apple-darwin
|
343
|
+
net.inet6.ip6.use_deprecated: 1
|
344
|
+
net.inet6.ip6.rr_prune: 5
|
345
|
+
net.inet6.ip6.v6only: 0
|
346
|
+
net.inet6.ip6.rtexpire: 3600
|
347
|
+
net.inet6.ip6.rtminexpire: 10
|
348
|
+
net.inet6.ip6.rtmaxcache: 128
|
349
|
+
net.inet6.ip6.use_tempaddr: 1
|
350
|
+
net.inet6.ip6.temppltime: 86400
|
351
|
+
net.inet6.ip6.tempvltime: 604800
|
352
|
+
net.inet6.ip6.auto_linklocal: 1
|
353
|
+
net.inet6.ip6.prefer_tempaddr: 1
|
354
|
+
net.inet6.ip6.use_defaultzone: 0
|
355
|
+
net.inet6.ip6.maxfrags: 12288
|
356
|
+
net.inet6.ip6.mcast_pmtu: 0
|
357
|
+
net.inet6.ip6.neighborgcthresh: 1024
|
358
|
+
net.inet6.ip6.maxifprefixes: 16
|
359
|
+
net.inet6.ip6.maxifdefrouters: 16
|
360
|
+
net.inet6.ip6.maxdynroutes: 1024
|
361
|
+
net.inet6.ip6.fw.enable: 1
|
362
|
+
net.inet6.ip6.fw.debug: 0
|
363
|
+
net.inet6.ip6.fw.verbose: 0
|
364
|
+
net.inet6.ip6.fw.verbose_limit: 0
|
365
|
+
net.inet6.ip6.scopedroute: 1
|
366
|
+
net.inet6.ip6.select_srcif_debug: 0
|
367
|
+
net.inet6.ip6.mcast.maxgrpsrc: 512
|
368
|
+
net.inet6.ip6.mcast.maxsocksrc: 128
|
369
|
+
net.inet6.ip6.mcast.loop: 1
|
370
|
+
net.inet6.ip6.only_allow_rfc4193_prefixes: 0
|
371
|
+
net.inet6.ipsec6.def_policy: 1
|
372
|
+
net.inet6.ipsec6.esp_trans_deflev: 1
|
373
|
+
net.inet6.ipsec6.esp_net_deflev: 1
|
374
|
+
net.inet6.ipsec6.ah_trans_deflev: 1
|
375
|
+
net.inet6.ipsec6.ah_net_deflev: 1
|
376
|
+
net.inet6.ipsec6.ecn: 0
|
377
|
+
net.inet6.ipsec6.debug: 0
|
378
|
+
net.inet6.ipsec6.esp_randpad: -1
|
379
|
+
net.inet6.icmp6.rediraccept: 1
|
380
|
+
net.inet6.icmp6.redirtimeout: 600
|
381
|
+
net.inet6.icmp6.nd6_prune: 1
|
382
|
+
net.inet6.icmp6.nd6_delay: 5
|
383
|
+
net.inet6.icmp6.nd6_umaxtries: 3
|
384
|
+
net.inet6.icmp6.nd6_mmaxtries: 3
|
385
|
+
net.inet6.icmp6.nd6_useloopback: 1
|
386
|
+
net.inet6.icmp6.nodeinfo: 3
|
387
|
+
net.inet6.icmp6.errppslimit: 500
|
388
|
+
net.inet6.icmp6.nd6_maxnudhint: 0
|
389
|
+
net.inet6.icmp6.nd6_debug: 0
|
390
|
+
net.inet6.icmp6.nd6_accept_6to4: 1
|
391
|
+
net.inet6.icmp6.nd6_onlink_ns_rfc4861: 0
|
392
|
+
net.inet6.icmp6.nd6_llreach_base: 30
|
393
|
+
net.inet6.mld.gsrdelay: 10
|
394
|
+
net.inet6.mld.v1enable: 1
|
395
|
+
net.inet6.mld.use_allow: 1
|
396
|
+
net.inet6.mld.debug: 0
|
397
|
+
net.idle.route.expire_timeout: 30
|
398
|
+
net.idle.route.drain_interval: 10
|
399
|
+
net.statistics: 1
|
400
|
+
net.alf.loglevel: 55
|
401
|
+
net.alf.perm: 0
|
402
|
+
net.alf.defaultaction: 1
|
403
|
+
net.alf.mqcount: 0
|
404
|
+
net.smb.fs.version: 107000
|
405
|
+
net.smb.fs.loglevel: 0
|
406
|
+
net.smb.fs.kern_ntlmssp: 0
|
407
|
+
net.smb.fs.kern_deprecatePreXPServers: 1
|
408
|
+
net.smb.fs.kern_deadtimer: 60
|
409
|
+
net.smb.fs.kern_hard_deadtimer: 600
|
410
|
+
net.smb.fs.kern_soft_deadtimer: 30
|
411
|
+
net.smb.fs.tcpsndbuf: 261120
|
412
|
+
net.smb.fs.tcprcvbuf: 261120
|
413
|
+
DARWIN_SYSCTL
|
414
|
+
|
415
|
+
@ohai = Ohai::System.new
|
416
|
+
@ohai.stub!(:require_plugin).and_return(true)
|
417
|
+
|
418
|
+
@stdin_ifconfig = StringIO.new
|
419
|
+
@stdin_arp = StringIO.new
|
420
|
+
@stdin_sysctl = StringIO.new
|
421
|
+
@stdin_netstat = StringIO.new
|
422
|
+
|
423
|
+
@ifconfig_lines = darwin_ifconfig.split("\n")
|
424
|
+
@arp_lines = darwin_arp.split("\n")
|
425
|
+
@netstat_lines = darwin_netstat.split("\n")
|
426
|
+
@sysctl_lines = darwin_sysctl.split("\n")
|
427
|
+
|
428
|
+
@ohai.stub(:from).with("route -n get default").and_return(darwin_route)
|
429
|
+
@ohai.stub(:popen4).with("netstat -i -d -l -b -n")
|
430
|
+
end
|
431
|
+
|
432
|
+
describe "gathering IP layer address info" do
|
433
|
+
before do
|
434
|
+
@ohai.stub!(:popen4).with("arp -an").and_yield(nil, @stdin_arp, @arp_lines, nil)
|
435
|
+
@ohai.stub!(:popen4).with("ifconfig -a").and_yield(nil, @stdin_ifconfig, @ifconfig_lines, nil)
|
436
|
+
@ohai.stub(:popen4).with("netstat -i -d -l -b -n").and_yield(nil, @stdin_netstat, @netstat_lines, nil)
|
437
|
+
@ohai.stub(:popen4).with("sysctl net").and_yield(nil, @stdin_sysctl, @sysctl_lines, nil)
|
438
|
+
@ohai._require_plugin("network")
|
439
|
+
@ohai._require_plugin("darwin::network")
|
440
|
+
end
|
441
|
+
|
442
|
+
it "completes the run" do
|
443
|
+
@ohai['network'].should_not be_nil
|
444
|
+
end
|
445
|
+
|
446
|
+
it "detects the interfaces" do
|
447
|
+
@ohai['network']['interfaces'].keys.sort.should == ["en0", "en1", "fw0", "gif0", "lo0", "p2p0", "stf0", "utun0"]
|
448
|
+
end
|
449
|
+
|
450
|
+
it "detects the ipv4 addresses of the ethernet interface" do
|
451
|
+
@ohai['network']['interfaces']['en1']['addresses'].keys.should include('10.20.10.144')
|
452
|
+
@ohai['network']['interfaces']['en1']['addresses']['10.20.10.144']['netmask'].should == '255.255.255.0'
|
453
|
+
@ohai['network']['interfaces']['en1']['addresses']['10.20.10.144']['broadcast'].should == '10.20.10.255'
|
454
|
+
@ohai['network']['interfaces']['en1']['addresses']['10.20.10.144']['family'].should == 'inet'
|
455
|
+
end
|
456
|
+
|
457
|
+
it "detects the ipv6 addresses of the ethernet interface" do
|
458
|
+
@ohai['network']['interfaces']['en1']['addresses'].keys.should include('fe80::ba8d:12ff:fe3a:32de')
|
459
|
+
@ohai['network']['interfaces']['en1']['addresses']['fe80::ba8d:12ff:fe3a:32de']['scope'].should == 'Link'
|
460
|
+
@ohai['network']['interfaces']['en1']['addresses']['fe80::ba8d:12ff:fe3a:32de']['prefixlen'].should == '64'
|
461
|
+
@ohai['network']['interfaces']['en1']['addresses']['fe80::ba8d:12ff:fe3a:32de']['family'].should == 'inet6'
|
462
|
+
|
463
|
+
@ohai['network']['interfaces']['en1']['addresses'].keys.should include('2001:44b8:4186:1100:ba8d:12ff:fe3a:32de')
|
464
|
+
@ohai['network']['interfaces']['en1']['addresses']['2001:44b8:4186:1100:ba8d:12ff:fe3a:32de']['scope'].should == 'Global'
|
465
|
+
@ohai['network']['interfaces']['en1']['addresses']['2001:44b8:4186:1100:ba8d:12ff:fe3a:32de']['prefixlen'].should == '64'
|
466
|
+
@ohai['network']['interfaces']['en1']['addresses']['2001:44b8:4186:1100:ba8d:12ff:fe3a:32de']['family'].should == 'inet6'
|
467
|
+
end
|
468
|
+
|
469
|
+
it "detects the mac addresses of the ethernet interface" do
|
470
|
+
@ohai['network']['interfaces']['en1']['addresses'].keys.should include('b8:8d:12:3a:32:de')
|
471
|
+
@ohai['network']['interfaces']['en1']['addresses']['b8:8d:12:3a:32:de']['family'].should == 'lladdr'
|
472
|
+
end
|
473
|
+
|
474
|
+
it "detects the encapsulation type of the ethernet interface" do
|
475
|
+
@ohai['network']['interfaces']['en1']['encapsulation'].should == 'Ethernet'
|
476
|
+
end
|
477
|
+
|
478
|
+
it "detects the flags of the ethernet interface" do
|
479
|
+
@ohai['network']['interfaces']['en1']['flags'].sort.should == ["BROADCAST", "MULTICAST", "RUNNING", "SIMPLEX", "SMART", "UP"]
|
480
|
+
end
|
481
|
+
|
482
|
+
|
483
|
+
it "detects the mtu of the ethernet interface" do
|
484
|
+
@ohai['network']['interfaces']['en1']['mtu'].should == "1500"
|
485
|
+
end
|
486
|
+
|
487
|
+
it "detects the ipv4 addresses of the loopback interface" do
|
488
|
+
@ohai['network']['interfaces']['lo0']['addresses'].keys.should include('127.0.0.1')
|
489
|
+
@ohai['network']['interfaces']['lo0']['addresses']['127.0.0.1']['netmask'].should == '255.0.0.0'
|
490
|
+
@ohai['network']['interfaces']['lo0']['addresses']['127.0.0.1']['family'].should == 'inet'
|
491
|
+
end
|
492
|
+
|
493
|
+
it "detects the ipv6 addresses of the loopback interface" do
|
494
|
+
@ohai['network']['interfaces']['lo0']['addresses'].keys.should include('::1')
|
495
|
+
@ohai['network']['interfaces']['lo0']['addresses']['::1']['scope'].should == 'Node'
|
496
|
+
@ohai['network']['interfaces']['lo0']['addresses']['::1']['prefixlen'].should == '128'
|
497
|
+
@ohai['network']['interfaces']['lo0']['addresses']['::1']['family'].should == 'inet6'
|
498
|
+
end
|
499
|
+
|
500
|
+
it "detects the encapsulation type of the loopback interface" do
|
501
|
+
@ohai['network']['interfaces']['lo0']['encapsulation'].should == 'Loopback'
|
502
|
+
end
|
503
|
+
|
504
|
+
it "detects the flags of the ethernet interface" do
|
505
|
+
@ohai['network']['interfaces']['lo0']['flags'].sort.should == ["LOOPBACK", "MULTICAST", "RUNNING", "UP"]
|
506
|
+
end
|
507
|
+
|
508
|
+
it "detects the mtu of the loopback interface" do
|
509
|
+
@ohai['network']['interfaces']['lo0']['mtu'].should == "16384"
|
510
|
+
end
|
511
|
+
|
512
|
+
it "detects the arp entries" do
|
513
|
+
@ohai['network']['interfaces']['en1']['arp']['10.20.10.1'].should == '0:4:ed:de:41:bf'
|
514
|
+
end
|
515
|
+
|
516
|
+
it "detects the ethernet counters" do
|
517
|
+
@ohai['counters']['network']['interfaces']['en1']['tx']['bytes'].should == "18228234970"
|
518
|
+
@ohai['counters']['network']['interfaces']['en1']['tx']['packets'].should == "14314573"
|
519
|
+
@ohai['counters']['network']['interfaces']['en1']['tx']['collisions'].should == "0"
|
520
|
+
@ohai['counters']['network']['interfaces']['en1']['tx']['errors'].should == "0"
|
521
|
+
@ohai['counters']['network']['interfaces']['en1']['tx']['carrier'].should == 0
|
522
|
+
@ohai['counters']['network']['interfaces']['en1']['tx']['drop'].should == 0
|
523
|
+
|
524
|
+
@ohai['counters']['network']['interfaces']['en1']['rx']['bytes'].should == "2530556736"
|
525
|
+
@ohai['counters']['network']['interfaces']['en1']['rx']['packets'].should == "5921903"
|
526
|
+
@ohai['counters']['network']['interfaces']['en1']['rx']['errors'].should == "0"
|
527
|
+
@ohai['counters']['network']['interfaces']['en1']['rx']['overrun'].should == 0
|
528
|
+
@ohai['counters']['network']['interfaces']['en1']['rx']['drop'].should == 0
|
529
|
+
end
|
530
|
+
|
531
|
+
it "detects the loopback counters" do
|
532
|
+
@ohai['counters']['network']['interfaces']['lo0']['tx']['bytes'].should == "25774844"
|
533
|
+
@ohai['counters']['network']['interfaces']['lo0']['tx']['packets'].should == "174982"
|
534
|
+
@ohai['counters']['network']['interfaces']['lo0']['tx']['collisions'].should == "0"
|
535
|
+
@ohai['counters']['network']['interfaces']['lo0']['tx']['errors'].should == "0"
|
536
|
+
@ohai['counters']['network']['interfaces']['lo0']['tx']['carrier'].should == 0
|
537
|
+
@ohai['counters']['network']['interfaces']['lo0']['tx']['drop'].should == 0
|
538
|
+
|
539
|
+
@ohai['counters']['network']['interfaces']['lo0']['rx']['bytes'].should == "25774844"
|
540
|
+
@ohai['counters']['network']['interfaces']['lo0']['rx']['packets'].should == "174982"
|
541
|
+
@ohai['counters']['network']['interfaces']['lo0']['rx']['errors'].should == "0"
|
542
|
+
@ohai['counters']['network']['interfaces']['lo0']['rx']['overrun'].should == 0
|
543
|
+
@ohai['counters']['network']['interfaces']['lo0']['rx']['drop'].should == 0
|
544
|
+
end
|
545
|
+
|
546
|
+
it "finds the default interface by asking which iface has the default route" do
|
547
|
+
@ohai['network'][:default_interface].should == 'en1'
|
548
|
+
end
|
549
|
+
|
550
|
+
it "finds the default interface by asking which iface has the default route" do
|
551
|
+
@ohai['network'][:default_gateway].should == '10.20.10.1'
|
552
|
+
end
|
553
|
+
|
554
|
+
it "should detect network settings" do
|
555
|
+
@ohai['network']['settings']['net.local.stream.sendspace'].should == '8192'
|
556
|
+
@ohai["network"]["settings"]['net.local.stream.recvspace'].should == '8192'
|
557
|
+
@ohai["network"]["settings"]['net.local.stream.tracemdns'].should == '0'
|
558
|
+
@ohai["network"]["settings"]['net.local.dgram.maxdgram'].should == '2048'
|
559
|
+
@ohai["network"]["settings"]['net.local.dgram.recvspace'].should == '4096'
|
560
|
+
@ohai["network"]["settings"]['net.local.inflight'].should == '0'
|
561
|
+
@ohai["network"]["settings"]['net.inet.ip.portrange.lowfirst'].should == '1023'
|
562
|
+
@ohai["network"]["settings"]['net.inet.ip.portrange.lowlast'].should == '600'
|
563
|
+
@ohai["network"]["settings"]['net.inet.ip.portrange.first'].should == '49152'
|
564
|
+
@ohai["network"]["settings"]['net.inet.ip.portrange.last'].should == '65535'
|
565
|
+
@ohai["network"]["settings"]['net.inet.ip.portrange.hifirst'].should == '49152'
|
566
|
+
@ohai["network"]["settings"]['net.inet.ip.portrange.hilast'].should == '65535'
|
567
|
+
@ohai["network"]["settings"]['net.inet.ip.forwarding'].should == '1'
|
568
|
+
@ohai["network"]["settings"]['net.inet.ip.redirect'].should == '1'
|
569
|
+
@ohai["network"]["settings"]['net.inet.ip.ttl'].should == '64'
|
570
|
+
@ohai["network"]["settings"]['net.inet.ip.rtexpire'].should == '12'
|
571
|
+
@ohai["network"]["settings"]['net.inet.ip.rtminexpire'].should == '10'
|
572
|
+
@ohai["network"]["settings"]['net.inet.ip.rtmaxcache'].should == '128'
|
573
|
+
@ohai["network"]["settings"]['net.inet.ip.sourceroute'].should == '0'
|
574
|
+
@ohai["network"]["settings"]['net.inet.ip.intr_queue_maxlen'].should == '50'
|
575
|
+
@ohai["network"]["settings"]['net.inet.ip.intr_queue_drops'].should == '0'
|
576
|
+
@ohai["network"]["settings"]['net.inet.ip.accept_sourceroute'].should == '0'
|
577
|
+
@ohai["network"]["settings"]['net.inet.ip.keepfaith'].should == '0'
|
578
|
+
@ohai["network"]["settings"]['net.inet.ip.gifttl'].should == '30'
|
579
|
+
@ohai["network"]["settings"]['net.inet.ip.subnets_are_local'].should == '0'
|
580
|
+
@ohai["network"]["settings"]['net.inet.ip.mcast.maxgrpsrc'].should == '512'
|
581
|
+
@ohai["network"]["settings"]['net.inet.ip.mcast.maxsocksrc'].should == '128'
|
582
|
+
@ohai["network"]["settings"]['net.inet.ip.mcast.loop'].should == '1'
|
583
|
+
@ohai["network"]["settings"]['net.inet.ip.check_route_selfref'].should == '1'
|
584
|
+
@ohai["network"]["settings"]['net.inet.ip.use_route_genid'].should == '1'
|
585
|
+
@ohai["network"]["settings"]['net.inet.ip.dummynet.hash_size'].should == '64'
|
586
|
+
@ohai["network"]["settings"]['net.inet.ip.dummynet.curr_time'].should == '0'
|
587
|
+
@ohai["network"]["settings"]['net.inet.ip.dummynet.ready_heap'].should == '0'
|
588
|
+
@ohai["network"]["settings"]['net.inet.ip.dummynet.extract_heap'].should == '0'
|
589
|
+
@ohai["network"]["settings"]['net.inet.ip.dummynet.searches'].should == '0'
|
590
|
+
@ohai["network"]["settings"]['net.inet.ip.dummynet.search_steps'].should == '0'
|
591
|
+
@ohai["network"]["settings"]['net.inet.ip.dummynet.expire'].should == '1'
|
592
|
+
@ohai["network"]["settings"]['net.inet.ip.dummynet.max_chain_len'].should == '16'
|
593
|
+
@ohai["network"]["settings"]['net.inet.ip.dummynet.red_lookup_depth'].should == '256'
|
594
|
+
@ohai["network"]["settings"]['net.inet.ip.dummynet.red_avg_pkt_size'].should == '512'
|
595
|
+
@ohai["network"]["settings"]['net.inet.ip.dummynet.red_max_pkt_size'].should == '1500'
|
596
|
+
@ohai["network"]["settings"]['net.inet.ip.dummynet.debug'].should == '0'
|
597
|
+
@ohai["network"]["settings"]['net.inet.ip.fw.enable'].should == '1'
|
598
|
+
@ohai["network"]["settings"]['net.inet.ip.fw.autoinc_step'].should == '100'
|
599
|
+
@ohai["network"]["settings"]['net.inet.ip.fw.one_pass'].should == '0'
|
600
|
+
@ohai["network"]["settings"]['net.inet.ip.fw.debug'].should == '0'
|
601
|
+
@ohai["network"]["settings"]['net.inet.ip.fw.verbose'].should == '0'
|
602
|
+
@ohai["network"]["settings"]['net.inet.ip.fw.verbose_limit'].should == '0'
|
603
|
+
@ohai["network"]["settings"]['net.inet.ip.fw.dyn_buckets'].should == '256'
|
604
|
+
@ohai["network"]["settings"]['net.inet.ip.fw.curr_dyn_buckets'].should == '256'
|
605
|
+
@ohai["network"]["settings"]['net.inet.ip.fw.dyn_count'].should == '0'
|
606
|
+
@ohai["network"]["settings"]['net.inet.ip.fw.dyn_max'].should == '4096'
|
607
|
+
@ohai["network"]["settings"]['net.inet.ip.fw.static_count'].should == '2'
|
608
|
+
@ohai["network"]["settings"]['net.inet.ip.fw.dyn_ack_lifetime'].should == '300'
|
609
|
+
@ohai["network"]["settings"]['net.inet.ip.fw.dyn_syn_lifetime'].should == '20'
|
610
|
+
@ohai["network"]["settings"]['net.inet.ip.fw.dyn_fin_lifetime'].should == '1'
|
611
|
+
@ohai["network"]["settings"]['net.inet.ip.fw.dyn_rst_lifetime'].should == '1'
|
612
|
+
@ohai["network"]["settings"]['net.inet.ip.fw.dyn_udp_lifetime'].should == '10'
|
613
|
+
@ohai["network"]["settings"]['net.inet.ip.fw.dyn_short_lifetime'].should == '5'
|
614
|
+
@ohai["network"]["settings"]['net.inet.ip.fw.dyn_keepalive'].should == '1'
|
615
|
+
@ohai["network"]["settings"]['net.inet.ip.maxfragpackets'].should == '1536'
|
616
|
+
@ohai["network"]["settings"]['net.inet.ip.maxfragsperpacket'].should == '128'
|
617
|
+
@ohai["network"]["settings"]['net.inet.ip.maxfrags'].should == '3072'
|
618
|
+
@ohai["network"]["settings"]['net.inet.ip.scopedroute'].should == '1'
|
619
|
+
@ohai["network"]["settings"]['net.inet.ip.check_interface'].should == '0'
|
620
|
+
@ohai["network"]["settings"]['net.inet.ip.linklocal.in.allowbadttl'].should == '1'
|
621
|
+
@ohai["network"]["settings"]['net.inet.ip.random_id'].should == '1'
|
622
|
+
@ohai["network"]["settings"]['net.inet.ip.maxchainsent'].should == '0'
|
623
|
+
@ohai["network"]["settings"]['net.inet.ip.select_srcif_debug'].should == '0'
|
624
|
+
@ohai["network"]["settings"]['net.inet.icmp.maskrepl'].should == '0'
|
625
|
+
@ohai["network"]["settings"]['net.inet.icmp.icmplim'].should == '250'
|
626
|
+
@ohai["network"]["settings"]['net.inet.icmp.timestamp'].should == '0'
|
627
|
+
@ohai["network"]["settings"]['net.inet.icmp.drop_redirect'].should == '0'
|
628
|
+
@ohai["network"]["settings"]['net.inet.icmp.log_redirect'].should == '0'
|
629
|
+
@ohai["network"]["settings"]['net.inet.icmp.bmcastecho'].should == '1'
|
630
|
+
@ohai["network"]["settings"]['net.inet.igmp.recvifkludge'].should == '1'
|
631
|
+
@ohai["network"]["settings"]['net.inet.igmp.sendra'].should == '1'
|
632
|
+
@ohai["network"]["settings"]['net.inet.igmp.sendlocal'].should == '1'
|
633
|
+
@ohai["network"]["settings"]['net.inet.igmp.v1enable'].should == '1'
|
634
|
+
@ohai["network"]["settings"]['net.inet.igmp.v2enable'].should == '1'
|
635
|
+
@ohai["network"]["settings"]['net.inet.igmp.legacysupp'].should == '0'
|
636
|
+
@ohai["network"]["settings"]['net.inet.igmp.default_version'].should == '3'
|
637
|
+
@ohai["network"]["settings"]['net.inet.igmp.gsrdelay'].should == '10'
|
638
|
+
@ohai["network"]["settings"]['net.inet.igmp.debug'].should == '0'
|
639
|
+
@ohai["network"]["settings"]['net.inet.tcp.rfc1323'].should == '1'
|
640
|
+
@ohai["network"]["settings"]['net.inet.tcp.rfc1644'].should == '0'
|
641
|
+
@ohai["network"]["settings"]['net.inet.tcp.mssdflt'].should == '512'
|
642
|
+
@ohai["network"]["settings"]['net.inet.tcp.keepidle'].should == '7200000'
|
643
|
+
@ohai["network"]["settings"]['net.inet.tcp.keepintvl'].should == '75000'
|
644
|
+
@ohai["network"]["settings"]['net.inet.tcp.sendspace'].should == '65536'
|
645
|
+
@ohai["network"]["settings"]['net.inet.tcp.recvspace'].should == '65536'
|
646
|
+
@ohai["network"]["settings"]['net.inet.tcp.keepinit'].should == '75000'
|
647
|
+
@ohai["network"]["settings"]['net.inet.tcp.v6mssdflt'].should == '1024'
|
648
|
+
@ohai["network"]["settings"]['net.inet.tcp.log_in_vain'].should == '0'
|
649
|
+
@ohai["network"]["settings"]['net.inet.tcp.blackhole'].should == '0'
|
650
|
+
@ohai["network"]["settings"]['net.inet.tcp.delayed_ack'].should == '3'
|
651
|
+
@ohai["network"]["settings"]['net.inet.tcp.tcp_lq_overflow'].should == '1'
|
652
|
+
@ohai["network"]["settings"]['net.inet.tcp.recvbg'].should == '0'
|
653
|
+
@ohai["network"]["settings"]['net.inet.tcp.drop_synfin'].should == '1'
|
654
|
+
@ohai["network"]["settings"]['net.inet.tcp.reass.maxsegments'].should == '3072'
|
655
|
+
@ohai["network"]["settings"]['net.inet.tcp.reass.cursegments'].should == '0'
|
656
|
+
@ohai["network"]["settings"]['net.inet.tcp.reass.overflows'].should == '0'
|
657
|
+
@ohai["network"]["settings"]['net.inet.tcp.slowlink_wsize'].should == '8192'
|
658
|
+
@ohai["network"]["settings"]['net.inet.tcp.maxseg_unacked'].should == '8'
|
659
|
+
@ohai["network"]["settings"]['net.inet.tcp.rfc3465'].should == '1'
|
660
|
+
@ohai["network"]["settings"]['net.inet.tcp.rfc3465_lim2'].should == '1'
|
661
|
+
@ohai["network"]["settings"]['net.inet.tcp.rtt_samples_per_slot'].should == '20'
|
662
|
+
@ohai["network"]["settings"]['net.inet.tcp.recv_allowed_iaj'].should == '5'
|
663
|
+
@ohai["network"]["settings"]['net.inet.tcp.acc_iaj_high_thresh'].should == '100'
|
664
|
+
@ohai["network"]["settings"]['net.inet.tcp.rexmt_thresh'].should == '2'
|
665
|
+
@ohai["network"]["settings"]['net.inet.tcp.path_mtu_discovery'].should == '1'
|
666
|
+
@ohai["network"]["settings"]['net.inet.tcp.slowstart_flightsize'].should == '1'
|
667
|
+
@ohai["network"]["settings"]['net.inet.tcp.local_slowstart_flightsize'].should == '8'
|
668
|
+
@ohai["network"]["settings"]['net.inet.tcp.tso'].should == '1'
|
669
|
+
@ohai["network"]["settings"]['net.inet.tcp.ecn_initiate_out'].should == '0'
|
670
|
+
@ohai["network"]["settings"]['net.inet.tcp.ecn_negotiate_in'].should == '0'
|
671
|
+
@ohai["network"]["settings"]['net.inet.tcp.packetchain'].should == '50'
|
672
|
+
@ohai["network"]["settings"]['net.inet.tcp.socket_unlocked_on_output'].should == '1'
|
673
|
+
@ohai["network"]["settings"]['net.inet.tcp.rfc3390'].should == '1'
|
674
|
+
@ohai["network"]["settings"]['net.inet.tcp.min_iaj_win'].should == '4'
|
675
|
+
@ohai["network"]["settings"]['net.inet.tcp.acc_iaj_react_limit'].should == '200'
|
676
|
+
@ohai["network"]["settings"]['net.inet.tcp.sack'].should == '1'
|
677
|
+
@ohai["network"]["settings"]['net.inet.tcp.sack_maxholes'].should == '128'
|
678
|
+
@ohai["network"]["settings"]['net.inet.tcp.sack_globalmaxholes'].should == '65536'
|
679
|
+
@ohai["network"]["settings"]['net.inet.tcp.sack_globalholes'].should == '0'
|
680
|
+
@ohai["network"]["settings"]['net.inet.tcp.minmss'].should == '216'
|
681
|
+
@ohai["network"]["settings"]['net.inet.tcp.minmssoverload'].should == '0'
|
682
|
+
@ohai["network"]["settings"]['net.inet.tcp.do_tcpdrain'].should == '0'
|
683
|
+
@ohai["network"]["settings"]['net.inet.tcp.pcbcount'].should == '86'
|
684
|
+
@ohai["network"]["settings"]['net.inet.tcp.icmp_may_rst'].should == '1'
|
685
|
+
@ohai["network"]["settings"]['net.inet.tcp.strict_rfc1948'].should == '0'
|
686
|
+
@ohai["network"]["settings"]['net.inet.tcp.isn_reseed_interval'].should == '0'
|
687
|
+
@ohai["network"]["settings"]['net.inet.tcp.background_io_enabled'].should == '1'
|
688
|
+
@ohai["network"]["settings"]['net.inet.tcp.rtt_min'].should == '100'
|
689
|
+
@ohai["network"]["settings"]['net.inet.tcp.rexmt_slop'].should == '200'
|
690
|
+
@ohai["network"]["settings"]['net.inet.tcp.randomize_ports'].should == '0'
|
691
|
+
@ohai["network"]["settings"]['net.inet.tcp.newreno_sockets'].should == '81'
|
692
|
+
@ohai["network"]["settings"]['net.inet.tcp.background_sockets'].should == '-1'
|
693
|
+
@ohai["network"]["settings"]['net.inet.tcp.tcbhashsize'].should == '4096'
|
694
|
+
@ohai["network"]["settings"]['net.inet.tcp.background_io_trigger'].should == '5'
|
695
|
+
@ohai["network"]["settings"]['net.inet.tcp.msl'].should == '15000'
|
696
|
+
@ohai["network"]["settings"]['net.inet.tcp.max_persist_timeout'].should == '0'
|
697
|
+
@ohai["network"]["settings"]['net.inet.tcp.always_keepalive'].should == '0'
|
698
|
+
@ohai["network"]["settings"]['net.inet.tcp.timer_fastmode_idlemax'].should == '20'
|
699
|
+
@ohai["network"]["settings"]['net.inet.tcp.broken_peer_syn_rxmit_thres'].should == '7'
|
700
|
+
@ohai["network"]["settings"]['net.inet.tcp.tcp_timer_advanced'].should == '5'
|
701
|
+
@ohai["network"]["settings"]['net.inet.tcp.tcp_resched_timerlist'].should == '12209'
|
702
|
+
@ohai["network"]["settings"]['net.inet.tcp.pmtud_blackhole_detection'].should == '1'
|
703
|
+
@ohai["network"]["settings"]['net.inet.tcp.pmtud_blackhole_mss'].should == '1200'
|
704
|
+
@ohai["network"]["settings"]['net.inet.tcp.timer_fastquantum'].should == '100'
|
705
|
+
@ohai["network"]["settings"]['net.inet.tcp.timer_slowquantum'].should == '500'
|
706
|
+
@ohai["network"]["settings"]['net.inet.tcp.win_scale_factor'].should == '3'
|
707
|
+
@ohai["network"]["settings"]['net.inet.tcp.sockthreshold'].should == '64'
|
708
|
+
@ohai["network"]["settings"]['net.inet.tcp.bg_target_qdelay'].should == '100'
|
709
|
+
@ohai["network"]["settings"]['net.inet.tcp.bg_allowed_increase'].should == '2'
|
710
|
+
@ohai["network"]["settings"]['net.inet.tcp.bg_tether_shift'].should == '1'
|
711
|
+
@ohai["network"]["settings"]['net.inet.tcp.bg_ss_fltsz'].should == '2'
|
712
|
+
@ohai["network"]["settings"]['net.inet.udp.checksum'].should == '1'
|
713
|
+
@ohai["network"]["settings"]['net.inet.udp.maxdgram'].should == '9216'
|
714
|
+
@ohai["network"]["settings"]['net.inet.udp.recvspace'].should == '42080'
|
715
|
+
@ohai["network"]["settings"]['net.inet.udp.log_in_vain'].should == '0'
|
716
|
+
@ohai["network"]["settings"]['net.inet.udp.blackhole'].should == '0'
|
717
|
+
@ohai["network"]["settings"]['net.inet.udp.pcbcount'].should == '72'
|
718
|
+
@ohai["network"]["settings"]['net.inet.udp.randomize_ports'].should == '1'
|
719
|
+
@ohai["network"]["settings"]['net.inet.ipsec.def_policy'].should == '1'
|
720
|
+
@ohai["network"]["settings"]['net.inet.ipsec.esp_trans_deflev'].should == '1'
|
721
|
+
@ohai["network"]["settings"]['net.inet.ipsec.esp_net_deflev'].should == '1'
|
722
|
+
@ohai["network"]["settings"]['net.inet.ipsec.ah_trans_deflev'].should == '1'
|
723
|
+
@ohai["network"]["settings"]['net.inet.ipsec.ah_net_deflev'].should == '1'
|
724
|
+
@ohai["network"]["settings"]['net.inet.ipsec.ah_cleartos'].should == '1'
|
725
|
+
@ohai["network"]["settings"]['net.inet.ipsec.ah_offsetmask'].should == '0'
|
726
|
+
@ohai["network"]["settings"]['net.inet.ipsec.dfbit'].should == '0'
|
727
|
+
@ohai["network"]["settings"]['net.inet.ipsec.ecn'].should == '0'
|
728
|
+
@ohai["network"]["settings"]['net.inet.ipsec.debug'].should == '0'
|
729
|
+
@ohai["network"]["settings"]['net.inet.ipsec.esp_randpad'].should == '-1'
|
730
|
+
@ohai["network"]["settings"]['net.inet.ipsec.bypass'].should == '0'
|
731
|
+
@ohai["network"]["settings"]['net.inet.ipsec.esp_port'].should == '4500'
|
732
|
+
@ohai["network"]["settings"]['net.inet.raw.maxdgram'].should == '8192'
|
733
|
+
@ohai["network"]["settings"]['net.inet.raw.recvspace'].should == '8192'
|
734
|
+
@ohai["network"]["settings"]['net.link.generic.system.ifcount'].should == '10'
|
735
|
+
@ohai["network"]["settings"]['net.link.generic.system.dlil_verbose'].should == '0'
|
736
|
+
@ohai["network"]["settings"]['net.link.generic.system.multi_threaded_input'].should == '1'
|
737
|
+
@ohai["network"]["settings"]['net.link.generic.system.dlil_input_sanity_check'].should == '0'
|
738
|
+
@ohai["network"]["settings"]['net.link.ether.inet.prune_intvl'].should == '300'
|
739
|
+
@ohai["network"]["settings"]['net.link.ether.inet.max_age'].should == '1200'
|
740
|
+
@ohai["network"]["settings"]['net.link.ether.inet.host_down_time'].should == '20'
|
741
|
+
@ohai["network"]["settings"]['net.link.ether.inet.apple_hwcksum_tx'].should == '1'
|
742
|
+
@ohai["network"]["settings"]['net.link.ether.inet.apple_hwcksum_rx'].should == '1'
|
743
|
+
@ohai["network"]["settings"]['net.link.ether.inet.arp_llreach_base'].should == '30'
|
744
|
+
@ohai["network"]["settings"]['net.link.ether.inet.maxtries'].should == '5'
|
745
|
+
@ohai["network"]["settings"]['net.link.ether.inet.useloopback'].should == '1'
|
746
|
+
@ohai["network"]["settings"]['net.link.ether.inet.proxyall'].should == '0'
|
747
|
+
@ohai["network"]["settings"]['net.link.ether.inet.sendllconflict'].should == '0'
|
748
|
+
@ohai["network"]["settings"]['net.link.ether.inet.log_arp_warnings'].should == '0'
|
749
|
+
@ohai["network"]["settings"]['net.link.ether.inet.keep_announcements'].should == '1'
|
750
|
+
@ohai["network"]["settings"]['net.link.ether.inet.send_conflicting_probes'].should == '1'
|
751
|
+
@ohai["network"]["settings"]['net.link.bridge.log_stp'].should == '0'
|
752
|
+
@ohai["network"]["settings"]['net.link.bridge.debug'].should == '0'
|
753
|
+
@ohai["network"]["settings"]['net.key.debug'].should == '0'
|
754
|
+
@ohai["network"]["settings"]['net.key.spi_trycnt'].should == '1000'
|
755
|
+
@ohai["network"]["settings"]['net.key.spi_minval'].should == '256'
|
756
|
+
@ohai["network"]["settings"]['net.key.spi_maxval'].should == '268435455'
|
757
|
+
@ohai["network"]["settings"]['net.key.int_random'].should == '60'
|
758
|
+
@ohai["network"]["settings"]['net.key.larval_lifetime'].should == '30'
|
759
|
+
@ohai["network"]["settings"]['net.key.blockacq_count'].should == '10'
|
760
|
+
@ohai["network"]["settings"]['net.key.blockacq_lifetime'].should == '20'
|
761
|
+
@ohai["network"]["settings"]['net.key.esp_keymin'].should == '256'
|
762
|
+
@ohai["network"]["settings"]['net.key.esp_auth'].should == '0'
|
763
|
+
@ohai["network"]["settings"]['net.key.ah_keymin'].should == '128'
|
764
|
+
@ohai["network"]["settings"]['net.key.prefered_oldsa'].should == '0'
|
765
|
+
@ohai["network"]["settings"]['net.key.natt_keepalive_interval'].should == '20'
|
766
|
+
@ohai["network"]["settings"]['net.inet6.ip6.forwarding'].should == '0'
|
767
|
+
@ohai["network"]["settings"]['net.inet6.ip6.redirect'].should == '1'
|
768
|
+
@ohai["network"]["settings"]['net.inet6.ip6.hlim'].should == '64'
|
769
|
+
@ohai["network"]["settings"]['net.inet6.ip6.maxfragpackets'].should == '1536'
|
770
|
+
@ohai["network"]["settings"]['net.inet6.ip6.accept_rtadv'].should == '0'
|
771
|
+
@ohai["network"]["settings"]['net.inet6.ip6.keepfaith'].should == '0'
|
772
|
+
@ohai["network"]["settings"]['net.inet6.ip6.log_interval'].should == '5'
|
773
|
+
@ohai["network"]["settings"]['net.inet6.ip6.hdrnestlimit'].should == '15'
|
774
|
+
@ohai["network"]["settings"]['net.inet6.ip6.dad_count'].should == '1'
|
775
|
+
@ohai["network"]["settings"]['net.inet6.ip6.auto_flowlabel'].should == '1'
|
776
|
+
@ohai["network"]["settings"]['net.inet6.ip6.defmcasthlim'].should == '1'
|
777
|
+
@ohai["network"]["settings"]['net.inet6.ip6.gifhlim'].should == '0'
|
778
|
+
@ohai["network"]["settings"]['net.inet6.ip6.kame_version'].should == '2009/apple-darwin'
|
779
|
+
@ohai["network"]["settings"]['net.inet6.ip6.use_deprecated'].should == '1'
|
780
|
+
@ohai["network"]["settings"]['net.inet6.ip6.rr_prune'].should == '5'
|
781
|
+
@ohai["network"]["settings"]['net.inet6.ip6.v6only'].should == '0'
|
782
|
+
@ohai["network"]["settings"]['net.inet6.ip6.rtexpire'].should == '3600'
|
783
|
+
@ohai["network"]["settings"]['net.inet6.ip6.rtminexpire'].should == '10'
|
784
|
+
@ohai["network"]["settings"]['net.inet6.ip6.rtmaxcache'].should == '128'
|
785
|
+
@ohai["network"]["settings"]['net.inet6.ip6.use_tempaddr'].should == '1'
|
786
|
+
@ohai["network"]["settings"]['net.inet6.ip6.temppltime'].should == '86400'
|
787
|
+
@ohai["network"]["settings"]['net.inet6.ip6.tempvltime'].should == '604800'
|
788
|
+
@ohai["network"]["settings"]['net.inet6.ip6.auto_linklocal'].should == '1'
|
789
|
+
@ohai["network"]["settings"]['net.inet6.ip6.prefer_tempaddr'].should == '1'
|
790
|
+
@ohai["network"]["settings"]['net.inet6.ip6.use_defaultzone'].should == '0'
|
791
|
+
@ohai["network"]["settings"]['net.inet6.ip6.maxfrags'].should == '12288'
|
792
|
+
@ohai["network"]["settings"]['net.inet6.ip6.mcast_pmtu'].should == '0'
|
793
|
+
@ohai["network"]["settings"]['net.inet6.ip6.neighborgcthresh'].should == '1024'
|
794
|
+
@ohai["network"]["settings"]['net.inet6.ip6.maxifprefixes'].should == '16'
|
795
|
+
@ohai["network"]["settings"]['net.inet6.ip6.maxifdefrouters'].should == '16'
|
796
|
+
@ohai["network"]["settings"]['net.inet6.ip6.maxdynroutes'].should == '1024'
|
797
|
+
@ohai["network"]["settings"]['net.inet6.ip6.fw.enable'].should == '1'
|
798
|
+
@ohai["network"]["settings"]['net.inet6.ip6.fw.debug'].should == '0'
|
799
|
+
@ohai["network"]["settings"]['net.inet6.ip6.fw.verbose'].should == '0'
|
800
|
+
@ohai["network"]["settings"]['net.inet6.ip6.fw.verbose_limit'].should == '0'
|
801
|
+
@ohai["network"]["settings"]['net.inet6.ip6.scopedroute'].should == '1'
|
802
|
+
@ohai["network"]["settings"]['net.inet6.ip6.select_srcif_debug'].should == '0'
|
803
|
+
@ohai["network"]["settings"]['net.inet6.ip6.mcast.maxgrpsrc'].should == '512'
|
804
|
+
@ohai["network"]["settings"]['net.inet6.ip6.mcast.maxsocksrc'].should == '128'
|
805
|
+
@ohai["network"]["settings"]['net.inet6.ip6.mcast.loop'].should == '1'
|
806
|
+
@ohai["network"]["settings"]['net.inet6.ip6.only_allow_rfc4193_prefixes'].should == '0'
|
807
|
+
@ohai["network"]["settings"]['net.inet6.ipsec6.def_policy'].should == '1'
|
808
|
+
@ohai["network"]["settings"]['net.inet6.ipsec6.esp_trans_deflev'].should == '1'
|
809
|
+
@ohai["network"]["settings"]['net.inet6.ipsec6.esp_net_deflev'].should == '1'
|
810
|
+
@ohai["network"]["settings"]['net.inet6.ipsec6.ah_trans_deflev'].should == '1'
|
811
|
+
@ohai["network"]["settings"]['net.inet6.ipsec6.ah_net_deflev'].should == '1'
|
812
|
+
@ohai["network"]["settings"]['net.inet6.ipsec6.ecn'].should == '0'
|
813
|
+
@ohai["network"]["settings"]['net.inet6.ipsec6.debug'].should == '0'
|
814
|
+
@ohai["network"]["settings"]['net.inet6.ipsec6.esp_randpad'].should == '-1'
|
815
|
+
@ohai["network"]["settings"]['net.inet6.icmp6.rediraccept'].should == '1'
|
816
|
+
@ohai["network"]["settings"]['net.inet6.icmp6.redirtimeout'].should == '600'
|
817
|
+
@ohai["network"]["settings"]['net.inet6.icmp6.nd6_prune'].should == '1'
|
818
|
+
@ohai["network"]["settings"]['net.inet6.icmp6.nd6_delay'].should == '5'
|
819
|
+
@ohai["network"]["settings"]['net.inet6.icmp6.nd6_umaxtries'].should == '3'
|
820
|
+
@ohai["network"]["settings"]['net.inet6.icmp6.nd6_mmaxtries'].should == '3'
|
821
|
+
@ohai["network"]["settings"]['net.inet6.icmp6.nd6_useloopback'].should == '1'
|
822
|
+
@ohai["network"]["settings"]['net.inet6.icmp6.nodeinfo'].should == '3'
|
823
|
+
@ohai["network"]["settings"]['net.inet6.icmp6.errppslimit'].should == '500'
|
824
|
+
@ohai["network"]["settings"]['net.inet6.icmp6.nd6_maxnudhint'].should == '0'
|
825
|
+
@ohai["network"]["settings"]['net.inet6.icmp6.nd6_debug'].should == '0'
|
826
|
+
@ohai["network"]["settings"]['net.inet6.icmp6.nd6_accept_6to4'].should == '1'
|
827
|
+
@ohai["network"]["settings"]['net.inet6.icmp6.nd6_onlink_ns_rfc4861'].should == '0'
|
828
|
+
@ohai["network"]["settings"]['net.inet6.icmp6.nd6_llreach_base'].should == '30'
|
829
|
+
@ohai["network"]["settings"]['net.inet6.mld.gsrdelay'].should == '10'
|
830
|
+
@ohai["network"]["settings"]['net.inet6.mld.v1enable'].should == '1'
|
831
|
+
@ohai["network"]["settings"]['net.inet6.mld.use_allow'].should == '1'
|
832
|
+
@ohai["network"]["settings"]['net.inet6.mld.debug'].should == '0'
|
833
|
+
@ohai["network"]["settings"]['net.idle.route.expire_timeout'].should == '30'
|
834
|
+
@ohai["network"]["settings"]['net.idle.route.drain_interval'].should == '10'
|
835
|
+
@ohai["network"]["settings"]['net.statistics'].should == '1'
|
836
|
+
@ohai["network"]["settings"]['net.alf.loglevel'].should == '55'
|
837
|
+
@ohai["network"]["settings"]['net.alf.perm'].should == '0'
|
838
|
+
@ohai["network"]["settings"]['net.alf.defaultaction'].should == '1'
|
839
|
+
@ohai["network"]["settings"]['net.alf.mqcount'].should == '0'
|
840
|
+
@ohai["network"]["settings"]['net.smb.fs.version'].should == '107000'
|
841
|
+
@ohai["network"]["settings"]['net.smb.fs.loglevel'].should == '0'
|
842
|
+
@ohai["network"]["settings"]['net.smb.fs.kern_ntlmssp'].should == '0'
|
843
|
+
@ohai["network"]["settings"]['net.smb.fs.kern_deprecatePreXPServers'].should == '1'
|
844
|
+
@ohai["network"]["settings"]['net.smb.fs.kern_deadtimer'].should == '60'
|
845
|
+
@ohai["network"]["settings"]['net.smb.fs.kern_hard_deadtimer'].should == '600'
|
846
|
+
@ohai["network"]["settings"]['net.smb.fs.kern_soft_deadtimer'].should == '30'
|
847
|
+
@ohai["network"]["settings"]['net.smb.fs.tcpsndbuf'].should == '261120'
|
848
|
+
@ohai["network"]["settings"]['net.smb.fs.tcprcvbuf'].should == '261120'
|
849
|
+
end
|
850
|
+
end
|
851
|
+
end
|