Post
Topic
Board Mining (Altcoins)
Re: Need simple batch restart miner when GPU not working
by
mshordja
on 15/01/2018, 16:24:15 UTC
Totally agree!  One way I helped with the automation on that is to have a non-mining PC that is on the same network do a ping to the miner at a specific time interval.  If the ping fails, then it sends a text to my phone and make it my decision on whether or not to re-boot via the smart plug.  (That central PC could also issue the command to the smart plug to reboot, but I figured at some point a human has to get involved).

Here's a snippet of code from that .bat


:STARTPING1

PING -n 1 %IPV4_MINER1%
PING -n 1 %IPV4_MINER1%|find "TTL" >NUL
IF     ERRORLEVEL 1 goto :MINER1OFFLINE
IF %MINER1_CTR% NEQ 1 (
   blat -server %SERVER% -f %FROMNAME% -u %USER% -pw %PW% -to %TO% -subject %ONLINE1% -body "%DATE% - %TIME%"
   set /a MINER1_CTR=1
   )
goto :STARTPING2

:MINER1OFFLINE

if %MINER1_CTR% gtr 2 goto :STARTPING2
blat -server %SERVER% -f %FROMNAME% -u %USER% -pw %PW% -to %TO% -subject %SUBJECT1% -body "%DATE% - %TIME%"
set /a MINER1_CTR+=1

:STARTPING2

can you attach here the bat file Smiley not so practice with that Cheesy