Index: /issm/trunk-jpl/src/m/classes/clusters/lonestar.m
===================================================================
--- /issm/trunk-jpl/src/m/classes/clusters/lonestar.m	(revision 23729)
+++ /issm/trunk-jpl/src/m/classes/clusters/lonestar.m	(revision 23730)
@@ -11,8 +11,8 @@
 		 name          = 'ls5.tacc.utexas.edu'
 		 login         = '';
-		 modules        = {};
+		 modules        = {'intel/16.0.1'};
 		 numnodes      = 1;
 		 cpuspernode   = 24;
-		 port          = 0;
+		 port          = 1099;
 		 queue         = 'normal';
 		 codepath      = '';
@@ -120,5 +120,5 @@
 			 fprintf(fid,'#SBATCH -o %s.outlog \n',modelname);
 			 fprintf(fid,'#SBATCH -e %s.errlog \n',modelname);
-			 fprintf(fid,'#SBATCH -n %i \n',cluster.numnodes*cluster.cpuspernode);
+			 fprintf(fid,'#SBATCH -n %i \n',cluster.numnodes*max(cluster.numnodes,24));
 			 fprintf(fid,'#SBATCH -N %i \n',cluster.numnodes);
 			 fprintf(fid,'#SBATCH -t %02i:%02i:00 \n\n',floor(cluster.time/3600),floor(mod(cluster.time,3600)/60));
@@ -127,11 +127,13 @@
 			 end
 
-			 %fprintf(fid,'export KMP_AFFINITY="granularity=fine,compact,verbose" \n\n');
+			 if isdakota,
+				 fprintf(fid,'export KMP_AFFINITY="granularity=fine,compact,verbose" \n\n');
+			 end
 
 			 if length(find(cluster.email=='@'))>0
-				 %fprintf(fid,'#SBATCH --mail-user=%s \n',cluster.email);
-				 %fprintf(fid,'#SBATCH --mail-type=end \n\n');
-
-				 fprintf(fid,'ssh login1 "mail -s ''SLURM Jobid=${SLURM_JOBID} Name=${SLURM_JOB_NAME} Began on Lonestar 5.'' %s <<< ''Job Started'' " \n\n',cluster.email);
+				 fprintf(fid,'#SBATCH --mail-user=%s \n',cluster.email);
+				 fprintf(fid,'#SBATCH --mail-type=end \n\n');
+
+				 %fprintf(fid,'ssh login1 "mail -s ''SLURM Jobid=${SLURM_JOBID} Name=${SLURM_JOB_NAME} Began on Lonestar 5.'' %s <<< ''Job Started'' " \n\n',cluster.email);
 			 end
 
@@ -145,8 +147,4 @@
 			 end
 
-			 if length(find(cluster.email=='@'))>0
-				 fprintf(fid,'\n');
-				 fprintf(fid,'ssh login1 "mail -s ''SLURM Jobid=${SLURM_JOBID} Name=${SLURM_JOB_NAME} Ended on Lonestar 5.'' %s <<< ''Job Ended'' " \n\n',cluster.email);
-			 end
 			 fclose(fid);
 
Index: /issm/trunk-jpl/src/m/classes/clusters/stallo.m
===================================================================
--- /issm/trunk-jpl/src/m/classes/clusters/stallo.m	(revision 23729)
+++ /issm/trunk-jpl/src/m/classes/clusters/stallo.m	(revision 23730)
@@ -49,5 +49,5 @@
 			 disp(sprintf('    name: %s',cluster.name));
 			 disp(sprintf('    login: %s',cluster.login));
-       disp(sprintf('    accountname: %s',cluster.accountname));
+			 disp(sprintf('    accountname: %s',cluster.accountname));
 			 disp(sprintf('    numnodes: %i',cluster.numnodes));
 			 disp(sprintf('    cpuspernode: %i, cpu per nodes',cluster.cpuspernode));
@@ -71,5 +71,5 @@
 			 %Miscelaneous
 			 if isempty(cluster.login), md = checkmessage(md,'login empty'); end
-       if isempty(cluster.accountname), md = checkmessage(md,'accountname empty'); end
+			 if isempty(cluster.accountname), md = checkmessage(md,'accountname empty'); end
 			 if isempty(cluster.codepath), md = checkmessage(md,'codepath empty'); end
 			 if isempty(cluster.executionpath), md = checkmessage(md,'executionpath empty'); end
@@ -115,6 +115,6 @@
 			 end
 			 fprintf(fid,'#SBATCH --account=%s\n',cluster.accountname);
- 			 fprintf(fid,'#SBATCH -output %s.outlog \n',[cluster.executionpath '/' dirname '/' modelname]);
- 			 fprintf(fid,'#SBATCH -error %s.errlog \n\n',[cluster.executionpath '/' dirname '/' modelname]);
+ 			 fprintf(fid,'#SBATCH -o %s.outlog \n',[cluster.executionpath '/' dirname '/' modelname]);
+ 			 fprintf(fid,'#SBATCH -e %s.errlog \n\n',[cluster.executionpath '/' dirname '/' modelname]);
 
  			 fprintf(fid,'export ISSM_DIR="%s/../"\n',cluster.codepath);%FIXME
@@ -133,5 +133,4 @@
 			 	fprintf(fid,'mpirun -np %i %s/%s %s %s/%s %s\n',cluster.np,cluster.codepath,executable,solution,cluster.executionpath,dirname,modelname);
 			 end
-			 %}}}
 			 if ~io_gather, %concatenate the output files:
 				 fprintf(fid,'cat %s.outbin.* > %s.outbin',modelname,modelname);
@@ -153,6 +152,5 @@
 			 end
 		 end
-
-
+		 %}}}
 		 function UploadQueueJob(cluster,modelname,dirname,filelist)% {{{
 
