m0mchil / poclbm

PyOpenCL bitcoin miner
Other
681 stars 387 forks source link

LogicError: clFinish failed: invalid command queue #17

Open jors opened 13 years ago

jors commented 13 years ago

Miner breaks with this error while doing first hashings:

jors@backwards:~/BITCOIN_GPU$ python poclbm.py -d 0 --user myuser --pass mypass 6289 khash/sException in thread Thread-2:
Traceback (most recent call last): File "/usr/lib/python2.6/threading.py", line 532, in bootstrap_inner self.run() File "/usr/lib/python2.6/threading.py", line 484, in run self.__target(_self.args, *_self.__kwargs) File "/home/jors/BITCOIN_GPU/BitcoinMiner.py", line 336, in miningThread queue.finish() LogicError: clFinish failed: invalid command queue

Once this happens, processing stops. Debian Testing here with a Geforce Nvidia 8600GT. Python version is 2.6.6, and Followed that guide [1], even if I also replaced apps to its current version:

wget https://raw.github.com/m0mchil/poclbm/06cf386a358a416b4119482bdfaf0d4511ac91b7/BitcoinMiner.cl wget https://raw.github.com/m0mchil/poclbm/06cf386a358a416b4119482bdfaf0d4511ac91b7/BitcoinMiner.py wget https://raw.github.com/m0mchil/poclbm/06cf386a358a416b4119482bdfaf0d4511ac91b7/poclbm.py wget https://raw.github.com/m0mchil/poclbm/06cf386a358a416b4119482bdfaf0d4511ac91b7/sha256.py

Nvidia packages:

jors@backwards:~/BITCOIN_GPU$ dpkg -l | grep -i nvidia ii libcuda1 270.41.19-1 NVIDIA CUDA runtime library ii libcuda1-ia32 270.41.19-1 NVIDIA CUDA runtime library (32-bit) ii libgl1-nvidia-alternatives 270.41.19-1 simplifies replacing MESA libGL with GPU vendor libraries ii libgl1-nvidia-glx 270.41.19-1 NVIDIA binary OpenGL libraries ii libglx-nvidia-alternatives 270.41.19-1 simplifies replacing Xorg module libglx.so with GPU vendor library ii libnvidia-compiler 270.41.19-1 NVIDIA runtime compiler library ii libnvidia-compiler-ia32 270.41.19-1 NVIDIA runtime compiler library (32-bit) ii libnvidia-ml1 270.41.19-1 NVIDIA management library (NVML) runtime library ii nvidia-glx 270.41.19-1 NVIDIA binary Xorg driver ii nvidia-installer-cleanup 20110515+1 Cleanup after driver installation with the nvidia-installer rc nvidia-kernel-2.6.26-1-amd64 173.14.09+3 NVIDIA binary kernel module for Linux 2.6.26-1-amd64 ii nvidia-kernel-common 20110515+1 NVIDIA binary kernel module support files ii nvidia-kernel-dkms 270.41.19-1 NVIDIA binary kernel module DKMS source ii nvidia-libopencl1 270.41.19-1 NVIDIA OpenCL library ii nvidia-libopencl1-ia32 270.41.19-1 NVIDIA OpenCL 32-bit library ii nvidia-opencl-common 270.41.19-1 NVIDIA OpenCL driver ii nvidia-opencl-icd 270.41.19-1 NVIDIA OpenCL ICD ii nvidia-opencl-icd-ia32 270.41.19-1 NVIDIA OpenCL ICD (32-bit) ii nvidia-smi 270.41.19-1 NVIDIA System Management Interface ii nvidia-support 20110515+1 NVIDIA binary graphics driver support files ii nvidia-vdpau-driver 270.41.19-1 NVIDIA vdpau driver

Any other useful information you may need, please, ask for it and I will provide. Thanks.

jors commented 13 years ago

Ooops, the guide pointed from [1] is: http://foreverrising.wordpress.com/2011/04/09/bitcoin-and-ubuntu/

Sorry!

jors commented 13 years ago

This time I tried using a pool (instead of solo mining) and tweaking with parameters. Now it doesn't seem to break, but there are still communicacion problems which prevent the pool to receive miner updates (in fact, pool does never see the miner):

python poclbm.py -d 0 -w 128 --user=myuser --pass=mypass --host=uk.btcguild.com --port=8332 --backup=myuser:mypass@nl.btcguild.com:8332 --tolerance=1 --failback=1

I revised pool congestions and there's no problem with that.

mys721tx commented 11 years ago

The similar problem happens in 10.8.2

$ python2.7 poclbm.py http://myuser:mypass@api.bitcoin.cz:8332

OpenCL devices:

[0] Intel(R) Core(TM)2 Duo CPU T9600 @ 2.80GHz [1] GeForce 9400M [2] GeForce 9600M GT

No devices specified, using all GPU devices

09/03/2013 02:52:30, started OpenCL miner on platform 0, device 1 (GeForce 9400M) 09/03/2013 02:52:30, started OpenCL miner on platform 0, device 2 (GeForce 9600M GT) 09/03/2013 02:52:30, Setting server (myuser @ api.bitcoin.cz:8332)
api.bitcoin.cz:8332 09/03/2013 02:52:30, checking for stratum...
api.bitcoin.cz:8332 09/03/2013 02:52:30, diverted to stratum on api-stratum.bitcoin.cz:3333 api.bitcoin.cz:8332 [6.312 MH/s (~0 MH/s)] [Rej: 0/0 (0.00%)]Exception in thread Thread-2: Traceback (most recent call last): File "/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/threading.py", line 552, in bootstrap_inner self.run() File "/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/threading.py", line 505, in run self.__target(_self.args, *_self.__kwargs) File "/Users/mys_721tx/poclbm-master/OpenCLMiner.py", line 242, in mining_thread queue.finish() LogicError: clFinish failed: invalid command queue

mys721tx commented 11 years ago

After turn on CL_LOG_ERRORS="stdout", the error message is:

[CL_INVALID_COMMAND_QUEUE] : OpenCL Fatal Error : Finish detected an error that invalidated the queue (0x7f9e94a2a640). This might be due to a resource allocation or other execution time failure. Break on OpenCLFatalBreak to debug. [CL_INVALID_COMMAND_QUEUE] : OpenCL Error : clFinish failed: queue (0x7f9e94a2a640) has been invalidated. Break on OpenCLErrorBreak to debug. Exception in thread Thread-2: Traceback (most recent call last): File "/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/threading.py", line 552, in bootstrap_inner self.run() File "/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/threading.py", line 505, in run self.__target(_self.args, *_self.__kwargs) File "/Users/mys_721tx/poclbm-master/OpenCLMiner.py", line 242, in mining_thread queue.finish() LogicError: clFinish failed: invalid command queue

Another thing is that even if I use -d 2 to run poclbm on 9600M GT, it will still produce this error.

DigitalRogues commented 11 years ago

i started running into this error today too. it had been working just fine for a few days now. I too a running it on a 9600M GT and 9400M mint.bitminter.com:8332 [4.732 MH/s (~0 MH/s)] [Rej: 0/0 (0.00%)][CL_INVALID_COMMAND_QUEUE] : OpenCL Fatal Error : Read detected an error that invalidated the queue (0x7fb239a27ae0). This might be due to a resource allocation or other execution time failure. Break on OpenCLFatalBreak to debug. [CL_INVALID_COMMAND_QUEUE] : OpenCL Error : clEnqueueReadBuffer failed: Invalid command queue Break on OpenCLErrorBreak to debug. Exception in thread Thread-1: Traceback (most recent call last): File "/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/threading.py", line 552, in *bootstrap_inner self.run() File "/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/threading.py", line 505, in run self.__target(_self.__args, _self.kwargs) File "/Volumes/Macintosh HD/Users/punk/btc/poclbm/OpenCLMiner.py", line 243, in mining_thread cl.enqueue_read_buffer(queue, output_buffer, output) File "/Library/Python/2.7/site-packages/pyopencl-2013.1-py2.7-macosx-10.8-intel.egg/pyopencl/init*.py", line 780, in new_func return func(_args, _kwargs) LogicError: clEnqueueReadBuffer failed: invalid command queue