<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<style type="text/css">body p { margin-bottom: 0cm; margin-top: 0pt; } </style>
</head>
<body bidimailui-charset-is-forced="true">
<p>Use sbatch's wrapper command:</p>
<p><br>
</p>
<p>sbatch --wrap='ls -l /tmp'</p>
<p><br>
</p>
<p>Note that the output will be in the directory on the execution
node, by default with the name slurm-<jobid>.out</p>
<p><br>
</p>
<div class="moz-cite-prefix">On 12/18/19 8:40 PM, William Brown
wrote:<br>
</div>
<blockquote type="cite"
cite="mid:CAGdVoZh0SY2Ea9XJ5Z4P1g6CRwrY=qG2eUR5DfTAjBAE9u2gGw@mail.gmail.com">
<meta http-equiv="content-type" content="text/html; charset=UTF-8">
<div dir="auto">Sometimes the way is to make the shell the binary,
e.g. bash -c 'ls -lsh'
<div dir="auto"><br>
</div>
<div dir="auto"><br>
</div>
</div>
<br>
<div class="gmail_quote">
<div dir="ltr" class="gmail_attr">On Wed, 18 Dec 2019, 18:25
Dean Schulze, <<a href="mailto:dean.w.schulze@gmail.com"
moz-do-not-send="true">dean.w.schulze@gmail.com</a>>
wrote:<br>
</div>
<blockquote class="gmail_quote" style="margin:0 0 0
.8ex;border-left:1px #ccc solid;padding-left:1ex">
<div dir="ltr">This is a rookie question. I can use the srun
command to execute a simple command like "ls" or "hostname"
on a node. But I haven't found a way to add arguments like
"ls -lart".
<div><br>
</div>
<div>What I need to do is execute a binary that takes
arguments (like "a.out arg1 arg2 arg3) that exists on the
node.</div>
<div><br>
</div>
<div>Is srun the right way to do this or do I need a script
or something else?</div>
<div><br>
</div>
<div>Thanks.</div>
</div>
</blockquote>
</div>
</blockquote>
</body>
</html>