CUDA missing library libcuda.so.1
9 次查看(过去 30 天)
显示 更早的评论
Hi, im trying to use GPU but when i try to run some command a get this error:
Error using gpuDevice (line 26)
There is a problem with the CUDA driver associated with this GPU device. See
www.mathworks.com/gpudriver to find and install the latest supported driver.
Caused by:
The CUDA driver could not be loaded. The library name used was: libcuda.so.1. The error was:
libcuda.so.1: cannot open shared object file: No such file or directory.
My Matlab client is on server called "mdcstest" and the GPU on another called "comp01", im using Matlab Job Scheduler. Normal task, matlabpool is running without problem. On "comp01" i have cuda 5.0.
What i need to do, to use the GPU on "comp01" ?
Thanks.
8 个评论
Ben Tordoff
2012-12-24
If you didn't put the gpuDevice call inside SPMD then it will run on your client machine (which presumably does not have a GPU or the CUDA drivers). Putting it inside SPMD causes it to run on the worker(s). Equally, trying to use the GPU inside a PARFOR or from within a task function would probably have worked fine as that also happens on the worker.
I believe Thomas's answer below is the correct one.
rahul srivastava
2014-5-14
in my case this error is shown ..nd when i use gpudevice count it is showing 0.please solve my problem > mjs = parcluster mjs.matlabpool spmd, gpuDevice, end matlabpool close
mjs =
Local Cluster Information
=========================
Profile: local
Modified: false
Host: robo-PC
NumWorkers: 2
JobStorageLocation: C:\Users\robo\AppData\Roaming\MathWorks\MATLAB\local_cluster_jobs\R2012b
ClusterMatlabRoot: C:\Program Files\MATLAB\R2012b
OperatingSystem: windows
RequiresMathWorksHostedLicensing: false
- Assigned Jobs
Number Pending: 0
Number Queued: 1
Number Running: 1
Number Finished: 0
Error using parallel.Cluster/matlabpool (line 64) Failed to open matlabpool. (For information in addition to the causing error, validate the profile 'local' in the Cluster Profile Manager.)
Caused by: Error using distcomp.interactiveclient/start (line 11) Found an interactive session. You cannot have multiple interactive sessions open simultaneously. To terminate the existing session, use 'matlabpool close'.
>>
回答(2 个)
Jason Ross
2012-11-19
编辑:Jason Ross
2012-11-19
It sounds like the GPU driver is not installed correctly on comp01. Perhaps you installed the SDK and toolkit and not the driver?
nVidia ships a utility called "nvidia-smi" (by default, in /usr/bin) that will list all the installed GPUs in a system. I'm betting you'll get the same error at the command line as you do in MATLAB if you run nvidia-smi. If things are working properly, you should see something like the following:
% nvidia-smi
Mon Nov 19 15:33:41 2012
+------------------------------------------------------+
| NVIDIA-SMI 4.304.54 Driver Version: 304.54 |
|-------------------------------+----------------------+----------------------+
| GPU Name | Bus-Id Disp. | Volatile Uncorr. ECC |
| Fan Temp Perf Pwr:Usage/Cap| Memory-Usage | GPU-Util Compute M. |
|===============================+======================+======================|
| 0 Quadro FX 370 | 0000:01:00.0 N/A | N/A |
| 60% 60C N/A N/A / N/A | 4% 11MB / 255MB | N/A Default |
+-------------------------------+----------------------+----------------------+
| 1 Tesla C1060 | 0000:08:00.0 Off | N/A |
| 35% 56C P8 N/A / N/A | 0% 3MB / 4095MB | 0% Default |
+-------------------------------+----------------------+----------------------+
+-----------------------------------------------------------------------------+
| Compute processes: GPU Memory |
| GPU PID Process name Usage |
|=============================================================================|
| 0 Not Supported |
+-----------------------------------------------------------------------------+
3 个评论
Edric Ellis
2012-11-22
As you can see, that nvidia-smi output shows that MATLAB is already accessing the GPU. Perhaps the device is in exclusive mode? (Can I also just confirm that you ran this command on the cluster node "comp01"). If you run
nvidia-smi -q
You should be able to see what compute mode the device is in.
Thomas Ibbotson
2012-11-23
When you open a matlabpool and use 'spmd', the code in that block is run on all the workers in the pool. As your workers are running on 'comp01', which has the GPU, this means that the GPU code will be able to run. Without the 'spmd' any code you run will run on your local machine (in your case this did not have the GPU driver and a supported GPU and it failed.)
Note that spmd is not the only way to run code on the cluster, you can also use the 'batch' function. In this case you give 'batch' the name of a script you want to run, and that will run on one of the workers on the cluster. For example:
mjs = parcluster;
job = mjs.batch('myScript');
wait(job);
load(job);
Where 'myScript' has the code you want to run on the GPU on 'comp01'.
For more information about 'batch' see the batch processing documentation, and for 'spmd' see the spmd documentation.
0 个评论
另请参阅
类别
在 Help Center 和 File Exchange 中查找有关 Parallel and Cloud 的更多信息
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!