@ -162,12 +162,16 @@ sub run_jobs
$anvil->data->{job}{short_host_name} = $anvil->Get->short_host_name;
$anvil->data->{job}{node1_short_host_name} = $anvil->data->{hosts}{host_uuid}{$node1_host_uuid}{short_host_name};
$anvil->data->{job}{node2_short_host_name} = $anvil->data->{hosts}{host_uuid}{$node2_host_uuid}{short_host_name};
$anvil->data->{job}{drbd_local_node_id} = $host_uuid eq $node1_host_uuid ? 0 : 1;
$anvil->data->{job}{drbd_peer_node_id} = $host_uuid eq $node1_host_uuid ? 1 : 0;
$anvil->Log->variables({source => $THIS_FILE, line => __LINE__, level => 2, list => {
'job::node1_host_uuid' => $anvil->data->{job}{node1_host_uuid},
'job::node2_host_uuid' => $anvil->data->{job}{node2_host_uuid},
'job::node1_short_host_name' => $anvil->data->{job}{node1_short_host_name},
'job::node2_short_host_name' => $anvil->data->{job}{node2_short_host_name},
'job::short_host_name' => $anvil->data->{job}{short_host_name},
'job::drbd_local_node_id' => $anvil->data->{job}{drbd_local_node_id},
'job::drbd_peer_node_id' => $anvil->data->{job}{drbd_peer_node_id},
}});
# We convert to extents as it ensure clean boundaries and, being based on bytes in both cases, gets
@ -676,7 +680,7 @@ sub startup_resource
});
$anvil->Log->entry({source => $THIS_FILE, line => __LINE__, level => 1, key => "job_0195"});
my $shell_call = $anvil->data->{path}{exe}{drbdsetup}." net-options ".$anvil->data->{job}{server_name}." 1 --set-defaults --_name=".$anvil->data->{job}{peer_short_name}." --protocol=C --fencing=dont-care";
my $shell_call = $anvil->data->{path}{exe}{drbdsetup}." net-options ".$anvil->data->{job}{server_name}." ".$anvil->data->{job}{drbd_peer_node_id}." --set-defaults --_name=".$anvil->data->{job}{peer_short_name}." --protocol=C --fencing=dont-care";
$anvil->Log->variables({source => $THIS_FILE, line => __LINE__, level => 2, list => { shell_call => $shell_call }});
my ($output, $return_code) = $anvil->System->call({shell_call => $shell_call});