John the Ripper can check if there are running a CGMiner instance and pause to mine in those GPUs that are going to be used in a cracking session. When John the Ripper ends, the paused GPUs will start again to mine.
Furthermore you can set John the Ripper to start a new CGMiner Instance when the cracking session ends if there are not any other CGMiner instance.
In order to build it, you need to clone the LordRafa's git repository:
git clone https://github.com/LordRafa/JohnTheRipper
after you have to go inside of src folder:
cd JohnTheRipper/src
change to bleeding-jumbo branch:
git checkout bleeding-jumbo
and compile the code with GPU support:
make linux-x86-64-gpu
--api-listen --api-allow W:127.0.0.1/24 --api-port PORT
... [Options:Miner] ... APIPort=PORT # PORT must be equal to CGMiner API port. ...
... [Options:Miner] ... AfterEnd=1 # 1 - to enable Mine After End # 0 - to disable Mine After End AfterEndOptions= # CGMiner instance parameters. ...
The new CGMiner instance will be created with the parameters:
--api-listen --api-allow W:127.0.0.1/24