freewso / pyrit

Automatically exported from code.google.com/p/pyrit
0 stars 0 forks source link

CPyrit-CUDA fails with CUDA_ERROR_UNKNOWN on xen kernels #339

Open GoogleCodeExporter opened 8 years ago

GoogleCodeExporter commented 8 years ago
after installation i got only

#pyrit list_cores
Pyrit 0.4.0 (C) 2008-2011 Lukas Lueg http://pyrit.googlecode.com
This code is distributed under the GNU General Public License v3+

Traceback (most recent call last):
  File "/usr/local/bin/pyrit", line 6, in <module>
    pyrit_cli.Pyrit_CLI().initFromArgv()
  File "/usr/local/lib/python2.6/dist-packages/pyrit_cli.py", line 115, in initFromArgv
    func(self, **options)
  File "/usr/local/lib/python2.6/dist-packages/pyrit_cli.py", line 291, in list_cores
    with cpyrit.cpyrit.CPyrit() as cp:
  File "/usr/local/lib/python2.6/dist-packages/cpyrit/cpyrit.py", line 440, in __init__
    self.cores.append(CUDACore(queue=self, dev_idx=dev_idx))
  File "/usr/local/lib/python2.6/dist-packages/cpyrit/cpyrit.py", line 245, in __init__
    _cpyrit_cuda.CUDADevice.__init__(self, dev_idx)
SystemError: CUDA_ERROR_UNKNOWN

# pyrit benchmark
Pyrit 0.4.0 (C) 2008-2011 Lukas Lueg http://pyrit.googlecode.com
This code is distributed under the GNU General Public License v3+

Traceback (most recent call last):
  File "/usr/local/bin/pyrit", line 6, in <module>
    pyrit_cli.Pyrit_CLI().initFromArgv()
  File "/usr/local/lib/python2.6/dist-packages/pyrit_cli.py", line 115, in initFromArgv
    func(self, **options)
  File "/usr/local/lib/python2.6/dist-packages/pyrit_cli.py", line 1170, in benchmark
    with cpyrit.cpyrit.CPyrit() as cp:
  File "/usr/local/lib/python2.6/dist-packages/cpyrit/cpyrit.py", line 440, in __init__
    self.cores.append(CUDACore(queue=self, dev_idx=dev_idx))
  File "/usr/local/lib/python2.6/dist-packages/cpyrit/cpyrit.py", line 245, in __init__
    _cpyrit_cuda.CUDADevice.__init__(self, dev_idx)
SystemError: CUDA_ERROR_UNKNOWN

i use GeForce 9500 GT

i installed devdriver_4.0_linux_64_270.41.19.run and 
cudatoolkit_4.0.17_linux_64_ubuntu10.10.run bevor building and install pyrit

Original issue reported on code.google.com by velten.s...@gmail.com on 25 Jul 2011 at 1:36

GoogleCodeExporter commented 8 years ago
CUDA_ERROR_UNKNOWN comes directly from the driver, there is nothing Pyrit can 
do about it. Did you really rebuild CPyrit-CUDA with the new toolkit? Watch the 
output of "setup.py build" carefully.

Original comment by lukas.l...@gmail.com on 25 Jul 2011 at 1:39

GoogleCodeExporter commented 8 years ago
# python setup.py build
running build
running build_ext
Compiling CUDA module using nvcc 4.0, V0.2.1221...
Executing '/usr/local/cuda/bin/nvcc -m64 --host-compilation C -Xcompiler 
"-fPIC" --ptx ./_cpyrit_cudakernel.cu'
nvcc warning : option 'host-compilation' has been deprecated and is ignored
Building modules...
building 'cpyrit._cpyrit_cuda' extension
creating build
creating build/temp.linux-x86_64-2.6
gcc-4.4 -fno-strict-aliasing -DNDEBUG -g -fwrapv -O2 -Wall -Wstrict-prototypes 
-fPIC -I/usr/local/cuda/include -I/usr/include/python2.6 -c _cpyrit_cuda.c -o 
build/temp.linux-x86_64-2.6/_cpyrit_cuda.o -Wall -fno-strict-aliasing 
-DVERSION="0.4.0"
creating build/lib.linux-x86_64-2.6
creating build/lib.linux-x86_64-2.6/cpyrit
gcc -pthread -shared -Wl,-O1 -Wl,-Bsymbolic-functions 
build/temp.linux-x86_64-2.6/_cpyrit_cuda.o -lcrypto -lcuda -lz -o 
build/lib.linux-x86_64-2.6/cpyrit/_cpyrit_cuda.so

# python setup.py install
running install
running build
running build_ext
Skipping rebuild of Nvidia CUDA kernel ...
Building modules...
running install_lib
copying build/lib.linux-x86_64-2.6/cpyrit/_cpyrit_cuda.so -> 
/usr/local/lib/python2.6/dist-packages/cpyrit
running install_egg_info
Writing /usr/local/lib/python2.6/dist-packages/cpyrit_cuda-0.4.0.egg-info

there was a pyrit 0.3.0 installed bevor, can this be the problem ?

Original comment by velten.s...@gmail.com on 25 Jul 2011 at 1:42

GoogleCodeExporter commented 8 years ago
not really

Original comment by lukas.l...@gmail.com on 25 Jul 2011 at 1:46

GoogleCodeExporter commented 8 years ago
it was an error with xen kernel, it's working with the normal debian-kernel

Original comment by velten.s...@gmail.com on 27 Jul 2011 at 1:24

GoogleCodeExporter commented 8 years ago
Then it's a problem with the xen kernel. Are you running Pyrit on the host or 
in the guest?

Original comment by lukas.l...@gmail.com on 27 Jul 2011 at 4:40

GoogleCodeExporter commented 8 years ago
damn these sausage-fingers

Original comment by lukas.l...@gmail.com on 27 Jul 2011 at 4:41

GoogleCodeExporter commented 8 years ago
on the host, i can't passthrough vga with my board

Original comment by velten.s...@gmail.com on 27 Jul 2011 at 5:43