Skip to content
Snippets Groups Projects
Commit deb50de0 authored by tewk's avatar tewk
Browse files

Fixed bug in src/common/slurm_protocol_pack.c, missing a break statement

modified srun_emu.pl to follow new task launch design
updated port number in testsuite/slurm_unit/slurmd/task_launch-test.c
parent 2064248d
No related branches found
No related tags found
No related merge requests found
......@@ -157,6 +157,7 @@ int pack_msg ( slurm_msg_t const * msg , char ** buffer , uint32_t * buf_len )
break ;
case REQUEST_LAUNCH_TASKS :
pack_launch_tasks_request_msg ( ( launch_tasks_request_msg_t * ) msg->data , ( void ** ) buffer , buf_len ) ;
break ;
case RESPONSE_LAUNCH_TASKS :
pack_launch_tasks_response_msg ( ( launch_tasks_response_msg_t * ) msg->data , ( void ** ) buffer , buf_len ) ;
break ;
......@@ -291,6 +292,7 @@ int unpack_msg ( slurm_msg_t * msg , char ** buffer , uint32_t * buf_len )
case REQUEST_LAUNCH_TASKS :
unpack_launch_tasks_request_msg ( ( launch_tasks_request_msg_t ** ) & ( msg->data ) ,
( void ** ) buffer , buf_len ) ;
break ;
case RESPONSE_LAUNCH_TASKS :
unpack_launch_tasks_response_msg ( ( launch_tasks_response_msg_t ** ) & ( msg->data ) ,
( void ** ) buffer , buf_len ) ;
......
#!/usr/bin/perl
use IO::Socket;
$pid = fork();
if ($pid)
my $sock1 = new IO::Socket::INET (
LocalHost => 'localhost',
LocalPort => '7071',
Proto => 'tcp',
Listen => 1,
Reuse => 1,
);
while ( true )
{
#stdout
my $sock1 = new IO::Socket::INET (
LocalHost => 'localhost',
LocalPort => '7071',
Proto => 'tcp',
Listen => 1,
Reuse => 1,
);
my $new_sock1 = $sock1->accept();
while(<$new_sock1>)
$pid = fork ();
if ($pid)
{
print STDOUT $_;
}
close($sock1);
print "CLOSED STD OUT SOCKET" ;
}
else
{
#stderr
my $sock2 = new IO::Socket::INET (
LocalHost => 'localhost',
LocalPort => '7072',
Proto => 'tcp',
Listen => 1,
Reuse => 1,
);
my $new_sock2 = $sock2->accept();
while(<$new_sock2>)
{
print STDERR $_;
while(<$new_sock1>)
{
print STDOUT $_;
}
close($sock1);
print "CLOSED STD OUT SOCKET" ;
}
close($sock2);
print "CLOSED STD ERR SOCKET" ;
}
......@@ -16,7 +16,7 @@ int main ( int argc , char* argv[] )
gids[1] = 9999 ;
credential . node_list = "TESTING" ;
slurm_set_addr_char ( & slurmd_addr , 7002 , "localhost" ) ;
slurm_set_addr_char ( & slurmd_addr , 7003 , "localhost" ) ;
request_msg . msg_type = REQUEST_LAUNCH_TASKS ;
request_msg . data = & launch_tasks_msg ;
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment