Commit b0db7bbb authored by Mike Hibler's avatar Mike Hibler

Attempt to compensate for nodes whose WhOL interface is trying to auto

negotiate:

# Divide the nodes up into used and unused based on the status of
# their WhOL experimental interface:
#
# enabled=yes     port in use
# enabled=no      not used
#
# If a port is "in use" we assume it has talked to the switch and
# no speed/duplex changes are needed.
#
# If the port is unused, we assume that the port will try to auto
# negotiate with the switch when enabled.  In this case we set
# auto-negotiation on the switch to maximize the chance that we will
# sucessfully communicate with the card.
parent da99a847
......@@ -147,6 +147,37 @@ sub whacksome($@) {
}
}
#
# Divide the nodes up into used and unused based on the status of
# their WhOL experimental interface:
#
# enabled=yes port in use
# enabled=no not used
#
# If a port is "in use" we assume it has talked to the switch and
# no speed/duplex changes are needed.
#
# If the port is unused, we assume that the port will try to auto
# negotiate with the switch when enabled. In this case we set
# auto-negotiation on the switch to maximize the chance that we will
# sucessfully communicate with the card.
#
my $autoneg = "";
for my $key (keys(%portinfo)) {
if ($portinfo{$key}{status} &&
$portinfo{$key}{status} =~ /enabled=no/) {
$autoneg .= "$key ";
}
}
if ($autoneg ne "") {
print STDERR "Setting autonegotiate on ports: $autoneg\n"
if ($debug);
if (system("$SNMPIT -a $portstr")) {
warn "WhOL: could not set autoconfig for $portstr\n";
$failed++;
}
}
#
# Put all ports in the WhOL VLAN, snmpit will enable them.
#
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment