cbuchner1 / CudaMiner

a CUDA accelerated litecoin mining application based on pooler's CPU miner
Other
692 stars 304 forks source link

Unable to query CUDA driver version! #110

Closed sjtoik closed 10 years ago

sjtoik commented 10 years ago

Driver Version: 334.21 returns garbage instead of reasonable results. Haven't find a way around yet.

shunix commented 10 years ago

I have the same problem with my Archlinux. When I try to use the cudaminer, it showed "Unable to query CUDA driver version! Is an nVidia driver installed?". BTW, I used bumblebee to manage my card. The dmesg shows as below:

[ 9943.711007] bbswitch: enabling discrete graphics
[ 9944.232695] [drm] Initialized nvidia-drm 0.0.0 20130102 for 0000:01:00.0 on minor 1
[ 9944.232700] NVRM: loading NVIDIA UNIX x86_64 Kernel Module  334.21  Thu Feb 27 15:55:45 PST 2014
[ 9944.292589] vgaarb: this pci device is not a vga device
[ 9944.292914] nvidia 0000:01:00.0: irq 49 for MSI/MSI-X
[ 9944.298238] ACPI Warning: \_SB_.PCI0.PEG0.PEGP._DSM: Argument #4 type mismatch - Found [Buffer], ACPI requires [Package] (20131115/nsarguments-95)
[ 9944.298285] ACPI Warning: \_SB_.PCI0.PEG0.PEGP._DSM: Argument #4 type mismatch - Found [Buffer], ACPI requires [Package] (20131115/nsarguments-95)
[ 9944.298311] ACPI Warning: \_SB_.PCI0.PEG0.PEGP._DSM: Argument #4 type mismatch - Found [Buffer], ACPI requires [Package] (20131115/nsarguments-95)
[ 9944.298343] ACPI Warning: \_SB_.PCI0.PEG0.PEGP._DSM: Argument #4 type mismatch - Found [Buffer], ACPI requires [Package] (20131115/nsarguments-95)
[ 9944.298367] ACPI Warning: \_SB_.PCI0.PEG0.PEGP._DSM: Argument #4 type mismatch - Found [Buffer], ACPI requires [Package] (20131115/nsarguments-95)
[ 9944.298391] ACPI Warning: \_SB_.PCI0.PEG0.PEGP._DSM: Argument #4 type mismatch - Found [Buffer], ACPI requires [Package] (20131115/nsarguments-95)
[ 9944.298420] ACPI Warning: \_SB_.PCI0.PEG0.PEGP._DSM: Argument #4 type mismatch - Found [Buffer], ACPI requires [Package] (20131115/nsarguments-95)
[ 9944.298444] ACPI Warning: \_SB_.PCI0.PEG0.PEGP._DSM: Argument #4 type mismatch - Found [Buffer], ACPI requires [Package] (20131115/nsarguments-95)
[ 9947.970452] ACPI Error: Field [TMPB] at 274432 exceeds Buffer [ROM1] size 262144 (bits) (20131115/dsopcode-236)
[ 9947.970457] ACPI Error: Method parse/execution failed [\_SB_.PCI0.PEG0.PEGP._ROM] (Node ffff8804194adcf8), AE_AML_BUFFER_LIMIT (20131115/psparse-536)
[ 9947.978229] ACPI Warning: \_SB_.PCI0.PEG0.PEGP._DSM: Argument #4 type mismatch - Found [Buffer], ACPI requires [Package] (20131115/nsarguments-95)
[ 9948.386834] vgaarb: this pci device is not a vga device
[ 9949.031477] ACPI Warning: \_SB_.PCI0.PEG0.PEGP._DSM: Argument #4 type mismatch - Found [Buffer], ACPI requires [Package] (20131115/nsarguments-95)
[ 9949.066450] [drm] Module unloaded
[ 9949.067462] bbswitch: disabling discrete graphics
[ 9949.067471] ACPI Warning: \_SB_.PCI0.PEG0.PEGP._DSM: Argument #4 type mismatch - Found [Buffer], ACPI requires [Package] (20131115/nsarguments-95)
[ 9949.077887] pci 0000:01:00.0: Refused to change power state, currently in D0

And my linux kernel is 3.13.5-1-ARCH. My driver version is 334.21.

tszym commented 10 years ago

Hi, Using Archlinux with the same config as @Shunix (I mean kernel & driver versions) I have the same issue, except I don't have any warning following the nvidia lines running $ dmesg.

$ ./cudaminer -v give me the following after the donnation addresses :

Unable to query CUDA driver version! Is an nVidia driver installed?

I'm trying this with the 2014-02-28 tagged version (latest of master does not compile but this is another issue).

Hope it could help!

Edit: Note that on ArchLinux, the CUDA directory is /opt/cuda and contains bin/ lib64/ etc folders. This is the path i gave to the configure.sh file at the --with-cuda option. So the result was: --with-cuda=/opt/cuda.

cbuchner1 commented 10 years ago

If you're not also running a display on the nVidia cards, maybe the device nodes for CUDA haven't been created yet.

You will find a script here that does that (run with root privileges)

https://devtalk.nvidia.com/default/topic/465959/automatically-creating-device-nodes/

2014-03-07 12:30 GMT+01:00 Thomas Szymanski notifications@github.com:

Hi, Using Archlinux with the same config as @Shunixhttps://github.com/Shunix(I mean kernel & driver versions) I have the same issue, except I don't have any warning following the nvidia lines running $ dmesg.

$ ./cudaminer -v give me the following after the donnation addresses :

Unable to query CUDA driver version! Is an nVidia driver installed?

I'm trying this with the 2014-02-28 tagged version (latest of master does not compile but this is another issue).

Hope it could help!

Reply to this email directly or view it on GitHubhttps://github.com/cbuchner1/CudaMiner/issues/110#issuecomment-37016335 .

tszym commented 10 years ago

Thanks,

I assume you're talking about the perl script from the last reply. As I'm pretty much bad at perl, I'm not sure of what it is doing, but here's the result:

Before running the script:

$ ls /dev | grep nvidia
nvidia0 nvidiactl

Then I ran the script as root. Unfortunately, I got the same error from cudaminer, but the ls result changed:

$ ls /dev | grep nvidia
nvidia0 nvidiactl nvidia0000:01:00.0

So with that, I still can't run cudaminer.

Thanks for your help, I really appreciate.

SteveGotthardt commented 10 years ago

Run as sudo or root first. Somehow it fixes the cuda driver installation.

Sent from my iPad

On Mar 7, 2014, at 4:30 AM, Thomas Szymanski notifications@github.com wrote:

Hi, Using Archlinux with the same config as @Shunix (I mean kernel & driver versions) I have the same issue, except I don't have any warning following the nvidia lines running $ dmesg.

$ ./cudaminer -v give me the following after the donnation addresses :

Unable to query CUDA driver version! Is an nVidia driver installed?

I'm trying this with the 2014-02-28 tagged version (latest of master does not compile but this is another issue).

Hope it could help!

— Reply to this email directly or view it on GitHub.

shunix commented 10 years ago

@SteveGotthardt It works now, thanks.

tszym commented 10 years ago

Works for me too, thanks @SteveGotthardt :) Could be marked as close ? Unless you want to patch in order to run it directly as simple user.

MikeyCarter commented 10 years ago

I was having the same issue and after much playing found out my issue was I need to run cudaminer as root. (at least after I got this working sudo NVIDIA_CUDA-5.5_Samples/bin/x86_64/linux/release/deviceQuery)

tszym commented 10 years ago

Yes, if you got the same problem, you could certainly solve it using first sudo cudaminer -V. Then you can use it as your user as usual.

Note: You have to do this every time you reboot your computer.

sjtoik commented 10 years ago

I'm running arch also. There could be some problems with the AUR package, that are a common problem in this thread. I haven't looked into this as my experimentations on mining practically stopped with after this error.

There are also some improvements one could make to the automake configuration and to the make file itself, that would make it more easier for arch users to compile directly from source. Currently, you have to change couple of paths, from the Makefile.

sjtoik commented 10 years ago

What comes to running as superuser, it is not an option. Running one command after each restart is a hack, but if it works...

Maybe I'll iron out these hacks in some point, if I have some spare time. For now, this issue can be resolved.

alfonsonishikawa commented 9 years ago

Thanks, @SteveGotthardt !