[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [HTCondor-users] accurate way to query the number of jobs globally



On Fri, Feb 28, 2014 at 03:03:44PM +0100, Pek Daniel wrote:
> Thanks for your answer!
> 
> This command gives me back the complete list of jobs in the cluster,
> which is undesirable in case of tens of millions of queued jobs - also
> the list includes the non-running jobs, although I can help on it by
> constraining the results.
> 
> But what I need is only the _number_ of the _running_ jobs.

condor_q [$username] [-glo] -constraint "JobStatus==2" | wc -l

(subtract 4 for the table header)


- S

-- 
Steffen Grunewald * Cluster Admin * steffen.grunewald(*)aei.mpg.de
MPI f. Gravitationsphysik (AEI) * Am Mühlenberg 1, D-14476 Potsdam
http://www.aei.mpg.de/ * ------- * +49-331-567-{fon:7274,fax:7298}