Changeset 3119
- Timestamp:
- 02/24/10 13:20:40 (15 years ago)
- Location:
- issm/trunk/src/m/classes/public
- Files:
-
- 2 added
- 11 edited
Legend:
- Unmodified
- Added
- Removed
-
issm/trunk/src/m/classes/public/ClusterParameters.m
r227 r3119 1 function [cluster_codepath cluster_executionpath ]=ClusterParameters(cluster_name,cluster_rc_location)1 function [cluster_codepath cluster_executionpath cluster_login]=ClusterParameters(cluster_name,cluster_rc_location) 2 2 %CLUSTERPARAMETERS - from cluster_name, find out cluster parameters in cluster.rc file 3 3 % … … 6 6 % 7 7 % Usage: 8 % [cluster_codepath cluster_executionpath ]=ClusterParameters(cluster_name,cluster_rc_location)8 % [cluster_codepath cluster_executionpath cluster_login ]=ClusterParameters(cluster_name,cluster_rc_location) 9 9 10 lines_per_cluster= 3;10 lines_per_cluster=4; 11 11 12 12 %open cluster.rc file … … 49 49 if length(line)>12, 50 50 if strcmp(line(1:12),'cluster_name'), 51 %ok, the next 2lines deal with one cluster settings.51 %ok, the next 3 lines deal with one cluster settings. 52 52 %check if this is the cluster we are looking for. 53 53 splittedstring=strsplit(line,'='); … … 77 77 cluster_executionpath=value; 78 78 79 %Get next line for cluster loging name 80 line=fgetl(fid); 81 splittedstring=strsplit(line,'='); 82 descriptor=splittedstring{1}; 83 value=splittedstring{2}; 84 if ~strcmp(descriptor,'cluster_login'), 85 error('cluster settings in cluster.rc don''t follow the correct syntax'); 86 end 87 cluster_login=value; 88 79 89 else 80 90 %Wrong cluster name, skip next lines_per_cluster lines and continue; -
issm/trunk/src/m/classes/public/loadmultipleresultsfromcluster.m
r2889 r3119 11 11 name=md_list{1}.name; 12 12 cluster_rc_location=which('cluster.rc'); 13 [codepath,executionpath ]=ClusterParameters(cluster,cluster_rc_location);13 [codepath,executionpath,login]=ClusterParameters(cluster,cluster_rc_location); 14 14 15 15 %Remote tar: -
issm/trunk/src/m/classes/public/loadresultsfromcluster.m
r3035 r3119 9 9 10 10 %Figure out parameters for this particular cluster 11 [codepath,executionpath ]=ClusterParameters(md.cluster,cluster_rc_location);11 [codepath,executionpath,login]=ClusterParameters(md.cluster,cluster_rc_location); 12 12 13 13 %What packages are we picking up from remote cluster -
issm/trunk/src/m/classes/public/peek.m
r227 r3119 11 11 12 12 %Figure out parameters for this particular cluster 13 [codepath,executionpath ]=ClusterParameters(md.cluster,cluster_rc_location);13 [codepath,executionpath,login]=ClusterParameters(md.cluster,cluster_rc_location); 14 14 15 15 %peek at the queued job -
issm/trunk/src/m/classes/public/queue/LaunchMultipleQueueJobgemini.m
r2912 r3119 20 20 21 21 disp('launching solution sequence on remote cluster'); 22 issmssh(cluster, ['"cd ' executionpath ' && source ' name '.queue "']);22 issmssh(cluster,login,['"cd ' executionpath ' && source ' name '.queue "']); -
issm/trunk/src/m/classes/public/queue/LaunchQueueJob.m
r2880 r3119 1 function md=LaunchQueueJob(md,executionpath,options )1 function md=LaunchQueueJob(md,executionpath,options,login) 2 2 %LAUNCHQUEUEJOB - ... 3 3 % … … 15 15 if exist(function_name,'file'), 16 16 %Call this function: 17 eval(['md=' function_name '(md,executionpath,options );']);17 eval(['md=' function_name '(md,executionpath,options,login);']); 18 18 else 19 19 %Call the generic LaunchQueueJob: 20 md=LaunchQueueJobGeneric(md,executionpath,options );20 md=LaunchQueueJobGeneric(md,executionpath,options,login); 21 21 end -
issm/trunk/src/m/classes/public/queue/LaunchQueueJobGeneric.m
r2880 r3119 1 function md=LaunchQueueJobGeneric(md,executionpath,options )1 function md=LaunchQueueJobGeneric(md,executionpath,options,login) 2 2 %LAUNCHQUEUEJOBGENERIC - Generic routine to launch queueing job 3 3 % … … 26 26 27 27 disp('launching solution sequence on remote cluster'); 28 issmssh(md.cluster, ['cd ' executionpath ' && source ' md.name '.queue ']);28 issmssh(md.cluster,login,['cd ' executionpath ' && source ' md.name '.queue ']); 29 29 30 30 else -
issm/trunk/src/m/classes/public/queue/LaunchQueueJobcosmos.m
r2880 r3119 1 function md=LaunchQueueJobcosmos(md,executionpath,options )1 function md=LaunchQueueJobcosmos(md,executionpath,options,login) 2 2 %LAUNCHQUEUEJOBCOSMOS- Launch queue script for Cosmos cluster 3 3 % … … 24 24 25 25 disp('launching solution sequence on remote cluster'); 26 issmssh(md.cluster, ['"cd ' executionpath ' && qsub -S/bin/sh ' md.name '.queue "']);26 issmssh(md.cluster,login,['"cd ' executionpath ' && qsub -S/bin/sh ' md.name '.queue "']); 27 27 else 28 28 disp('batch mode requested: not launching job interactively'); -
issm/trunk/src/m/classes/public/queue/LaunchQueueJobgemini.m
r2880 r3119 1 function md=LaunchQueueJobgemini(md,executionpath,options )1 function md=LaunchQueueJobgemini(md,executionpath,options,login) 2 2 %LAUNCHQUEUEJOBGEMINI - Launch queueing script on Gemini cluster 3 3 % … … 24 24 25 25 disp('launching solution sequence on remote cluster'); 26 issmssh(md.cluster, ['"cd ' executionpath ' && qsub ' md.name '.queue "']);26 issmssh(md.cluster,login,['"cd ' executionpath ' && qsub ' md.name '.queue "']); 27 27 else 28 28 disp('batch mode requested: not launching job interactively'); -
issm/trunk/src/m/classes/public/queue/LaunchQueueJobgreenplanet.m
r2880 r3119 1 function md=LaunchQueueJobgreenplanet(md,executionpath,options )1 function md=LaunchQueueJobgreenplanet(md,executionpath,options,login) 2 2 %LAUNCHQUEUEJOBGEMINI - ... 3 3 % -
issm/trunk/src/m/classes/public/solveparallel.m
r2912 r3119 10 10 11 11 %Figure out parameters for this particular cluster 12 [codepath,executionpath ]=ClusterParameters(md.cluster,cluster_rc_location);12 [codepath,executionpath,login]=ClusterParameters(md.cluster,cluster_rc_location); 13 13 14 14 %Append name of directory if specified in options: … … 27 27 28 28 %Now, launch the queueing script 29 md=LaunchQueueJob(md,executionpath,options );29 md=LaunchQueueJob(md,executionpath,options,login); 30 30 31 31 %Do we return, or just wait for results?
Note:
See TracChangeset
for help on using the changeset viewer.