Hey there:
What I do is query the Database directly for that. I can't help with Java, but I can give you a perl example that maybe you can translate.
$db = SOAP::Lite
-> uri('urn:iControl:Management/DBVariable')
-> readable(1)
-> proxy("https://$sHost/iControl/iControlPortal.cgi");
eval {
$db->transport->http_request->header( 'Authorization' => 'Basic '
. MIME::Base64::encode("$sUID:$sPWD", ''));
};
$soapresponse = $db->query(
SOAP::Data->name ( variables => ["Failover.ForceStandby","Failover.ForceActive"] ),
);
&checkresponse($soapresponse);
@dbva = @{$soapresponse->result};
print "\n";
foreach $dbvar ( @dbva ) {
$varname = $dbvar->{"name"};
$valdata = $dbvar->{"value"};
print "$varname $valdata\n";
}
If you're looking to set them (I always disable redundancy state preference):
Note: F5 recommends the None setting, as it gives you time to investigate why the primary unit failed over, and to assess whether this may happen again. If you select None, you can avoid further failovers if unit1 runs into the same issue multiple times.
$vval1 =
{
name => "Failover.ForceStandby",
value => "disable"
};
$vval2 =
{
name => "Failover.ForceActive",
value => "disable"
};
push @vvaldata,$vval1;
push @vvaldata,$vval2;
$soapresponse = $db->modify(
SOAP::Data->name ( variables => [@vvaldata] ),
);
Hope that this helps.
Chris