View Single Post
Staro 29.12.2017., 20:26   #3645
De5tr0yer
Avocado
Moj komp
 
De5tr0yer's Avatar
 
Datum registracije: Aug 2005
Lokacija: Zagreb
Postovi: 7,856
Citiraj:
Autor BBminer Pregled postova
Pokušavam složiti da se rig pali automatski nakon sto se dogodila greška na nekoj od gpu.
Npr. Rig je radio 36h bez prestanka savršeno i onda se jutros u 4 odlučio zaustaviti. Resetirao ga kad sam se probudio i radi savrseno.
Probao sam u config ubaciti -wd 1 i -r 120 tako da ga resetira svaka 2h, ali mi prilikom paljenja, prije nego ucita DAG zapocne restart by timer.

Da li netko zna rijesenje?
Preko nekoliko rješenja je moguće, jedno ću predstaviti.

Jučer sam napravio powershell mikroskriptu koja automatski restarta miner ako proces minera padne.
Radi provjereno na DSTM mineru. Moguće su korekcije u bilo kojem smjeru, powershell je moćan što se takvih stvari tiče.

Code:
#quick and dirty from De5tr0yer@PCekspert forum
#Shows INFO block and waits for ENTER key

Read-Host -Prompt "
---------------------------------------------------------------------
*********************************************************************

This script will automatically start miner if miner process stops.
If you want to stop mining, please stop this script first (CTRL + C)

*********************************************************************
---------------------------------------------------------------------

PRESS ENTER KEY TO CONTINUE" 

#INFINITE LOOP for restarting miner
while(1){

  #I recommend to start the miner through external script file, where you will enter all your miner info.
  #Alternatively, one can start miner exe with arguments here directly using -ArgumentList.
  #If your script already worked, no need to copy and paste everything here, just copy filepath to script.

  #Start-Process MINER.exe -ArgumentList "--server srvr.imaginary.kom  --port 1337 --user De5tr0yer --pass 1337" -NoNewWindow

  #Start through already available script
  Start-Process start_MINER_X.bat -NoNewWindow

  #Sleep for 500ms to allow the miner to start and to avoid multiple MINER.exe starts
  Start-Sleep -Milliseconds 500

  #Access process ID (PID) for the MINER.exe. 
  #IMPORTANT: here comes the name of the process without .exe
  $minerID = get-process MINER |select -expand id 

  #Wait until miner process is killed, when killed return to start of the loop
  Wait-Process -Id $minerID
}
__________________
Spoiler alert!

Zadnje izmijenjeno od: De5tr0yer. 20.01.2018. u 23:30.
De5tr0yer je offline   Reply With Quote