<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
<style type="text/css" style="display:none;"> P {margin-top:0;margin-bottom:0;} </style>
</head>
<body dir="ltr">
<div style="font-family: Calibri, Arial, Helvetica, sans-serif; font-size: 12pt; color: rgb(0, 0, 0);">
We use sacctmgr list stats for our Slurmdbd check</div>
<div style="font-family: Calibri, Arial, Helvetica, sans-serif; font-size: 12pt; color: rgb(0, 0, 0);">
<br>
</div>
<div style="font-family: Calibri, Arial, Helvetica, sans-serif; font-size: 12pt; color: rgb(0, 0, 0);">
Our Nagios check is</div>
<div style="font-family: Calibri, Arial, Helvetica, sans-serif; font-size: 12pt; color: rgb(0, 0, 0);">
<br>
</div>
<blockquote style="margin-top:0;margin-bottom:0">
<div style="font-family: Calibri, Arial, Helvetica, sans-serif; font-size: 12pt; color: rgb(0, 0, 0);">
RESULT=$(/usr/local/slurm/latest/bin/sacctmgr list stats)
<div>if [ $? -ne 0 ]</div>
<div>then</div>
<div> echo "ERROR: cannot connect to database"</div>
<div> exit 2</div>
<div>fi</div>
<div>echo "$RESULT" | head -n 4</div>
</div>
<div style="font-family: Calibri, Arial, Helvetica, sans-serif; font-size: 12pt; color: rgb(0, 0, 0);">
<span>exit 0</span><br>
</div>
</blockquote>
<div style="font-family: Calibri, Arial, Helvetica, sans-serif; font-size: 12pt; color: rgb(0, 0, 0);">
<br>
</div>
<div style="font-family: Calibri, Arial, Helvetica, sans-serif; font-size: 12pt; color: rgb(0, 0, 0);">
Sean</div>
<div id="appendonsend"></div>
<hr style="display:inline-block;width:98%" tabindex="-1">
<div id="divRplyFwdMsg" dir="ltr"><font face="Calibri, sans-serif" style="font-size:11pt" color="#000000"><b>From:</b> slurm-users <slurm-users-bounces@lists.schedmd.com> on behalf of Christoph Brüning <christoph.bruening@uni-wuerzburg.de><br>
<b>Sent:</b> Thursday, 10 June 2021 16:54<br>
<b>To:</b> slurm-users@lists.schedmd.com <slurm-users@lists.schedmd.com><br>
<b>Subject:</b> [EXT] Re: [slurm-users] Is there a scontrol ping slurmdbd?</font>
<div> </div>
</div>
<div class="BodyFragment"><font size="2"><span style="font-size:11pt;">
<div class="PlainText">External email: Please exercise caution<br>
<br>
Hello,<br>
<br>
I'd usually use some simple sacctmgr command.<br>
Something like "sacctmgr list cluster".<br>
<br>
That said, we're running a single slurmdbd instance since slurmctld does <br>
some caching etc. Do you have multiple that you need to check individually?<br>
<br>
Cheers,<br>
Christoph<br>
<br>
On 09/06/2021 23.23, Heitor wrote:<br>
> Hello,<br>
> <br>
> The docs about scontrol says that the command `scontrol ping` allows<br>
> one to query if slurmctld nodes are up and running.<br>
> <br>
> I'm wondering if there's something analogous for slurmdbd? A command to<br>
> check if slurmdbd nodes are up and running? I couldn't find it in the<br>
> docs.<br>
> <br>
> Kind regards,<br>
> Heitor<br>
> <br>
<br>
-- <br>
Dr. Christoph Brüning<br>
Universität Würzburg<br>
HPC & DataManagement @ ct.qmat & RZUW<br>
Am Hubland<br>
D-97074 Würzburg<br>
Tel.: +49 931 31-80499<br>
<br>
</div>
</span></font></div>
</body>
</html>