Changes related to master windows and remote slaves unix

time-shift
Marco Ratto 2011-05-04 10:34:03 +02:00
parent 3d80322303
commit bf580acb4a
5 changed files with 6 additions and 6 deletions

View File

@ -29,7 +29,7 @@ function dirlist = dynareParallelDir(filename,PRCDir,Parallel)
dirlist=[];
for indPC=1:length(Parallel),
if ~ispc, %isunix || (~matlab_ver_less_than('7.4') && ismac),
if ~ispc || strcmpi('unix',Parallel(indPC).OperatingSystem), %isunix || (~matlab_ver_less_than('7.4') && ismac),
if Parallel(indPC).Local==0,
if exist('OCTAVE_VERSION') % Patch for peculiar behaviour of ssh-ls under Linux.
% It is necessary to capture the ls warning message.

View File

@ -34,14 +34,14 @@ function dynareParallelGetFiles(NamFileInput,PRCDir,Parallel)
if ischar(NamFileInput),
for j=1:size(NamFileInput,1),
NamFile(j,:)={['.',filesep],deblank(NamFileInput(j,:))};
NamFile(j,:)={'',deblank(NamFileInput(j,:))};
end
NamFileInput = NamFile;
end
for indPC=1:length(Parallel),
if Parallel(indPC).Local==0,
if ~ispc, %isunix || (~matlab_ver_less_than('7.4') && ismac),
if ~ispc || strcmpi('unix',Parallel(indPC).OperatingSystem), %isunix || (~matlab_ver_less_than('7.4') && ismac),
for jfil=1:size(NamFileInput,1),
% if ~isempty(dynareParallelDir(NamFileInput{jfil,2},[PRCDir,filesep,NamFileInput{jfil,1}],Parallel(indPC))),

View File

@ -36,7 +36,7 @@ end
for indPC=1:length(Parallel)
if Parallel(indPC).Local==0,
if ~ispc, %isunix || (~matlab_ver_less_than('7.4') && ismac),
if ~ispc || strcmpi('unix',Parallel(indPC).OperatingSystem), %isunix || (~matlab_ver_less_than('7.4') && ismac),
[NonServeS NonServeD]=system(['ssh ',Parallel(indPC).UserName,'@',Parallel(indPC).ComputerName,' mkdir -p ',Parallel(indPC).RemoteDirectory,'/',PRCDir]);
else
[NonServeS NonServeD]=mkdir(['\\',Parallel(indPC).ComputerName,'\',Parallel(indPC).RemoteDrive,'$\',Parallel(indPC).RemoteDirectory,'\',PRCDir]);

View File

@ -37,7 +37,7 @@ end
for indPC=1:length(Parallel),
while (1)
if ~ispc
if ~ispc || strcmpi('unix',Parallel(indPC).OperatingSystem)
stat = system(['ssh ',Parallel(indPC).UserName,'@',Parallel(indPC).ComputerName,' rm -fr ',Parallel(indPC).RemoteDirectory,'/',PRCDir]);
break;
else

View File

@ -41,7 +41,7 @@ end
for indPC=1:length(Parallel),
if Parallel(indPC).Local==0,
if ~ispc, %isunix || (~matlab_ver_less_than('7.4') && ismac),
if ~ispc || strcmpi('unix',Parallel(indPC).OperatingSystem), %isunix || (~matlab_ver_less_than('7.4') && ismac),
for jfil=1:size(NamFileInput,1),
if ~isempty(NamFileInput{jfil,1})
[NonServeL NonServeR]=system(['ssh ',Parallel(indPC).UserName,'@',Parallel(indPC).ComputerName,' mkdir -p ',Parallel(indPC).RemoteDirectory,'/',PRCDir,'/',NamFileInput{jfil,1}]);