termination command `kill -9 {id}` no longer works (from 2022b to 2024b)
5 次查看(过去 30 天)
显示 更早的评论
My HPC (unix/slurm) used to have matlab 2022b, on which the kill -9 command works well to terminate a job upon completion.
self.call_args = re.sub(r'\s+', ' ', '''"
diary('{0}');
addpath('{1}');
try,
{3},
rc = 0,
catch me,
fprintf('%s: %s\\n', me.identifier, me.message),
rc = 1,
end,
diary off;
fileID = fopen('{2}', 'w');
if rc,
fprintf(fileID, '{2} failed; see log file'),
else,
fprintf(fileID, '{2} run successfully'),
end,
fclose(fileID);
id = feature('getpid');
if ispc,
cmd = sprintf('taskkill /pid %d /f',id),
elseif (ismac || isunix),
cmd = sprintf('kill -9 %d',id),
else,
error('unknown operating system'),
end,
system(cmd);
exit(0);
"'''.format(norm_log, norm_base, self.exec_file, source_exec), flags = re.MULTILINE)
However, since the upgrade to 2024b, the command no longer works and matlab would hang upcome completion of a job.
I'm trying to understand what changed across the two versions.
> Starting from R2024a, all MATLAB installations require MathWorks Service Host.
But matlab’s official release notes don’t mention whether the unix version turned on the feature from 2022b to 2024b. So I'm not sure, so coming here for ideas.
0 个评论
回答(1 个)
另请参阅
类别
在 Help Center 和 File Exchange 中查找有关 Startup and Shutdown 的更多信息
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!