GNOME Desktop will cause CUDA environment does not work.

Dear all,

Before I installed Gnome Desktop, nvidia-smi can show following information.

[root@vm10-0-6-21 ~]# nvidia-smi
Sun Nov 12 17:48:02 2017       
+-----------------------------------------------------------------------------+
| NVIDIA-SMI 375.26                 Driver Version: 375.26                    |
|-------------------------------+----------------------+----------------------+
| GPU  Name        Persistence-M| Bus-Id        Disp.A | Volatile Uncorr. ECC |
| Fan  Temp  Perf  Pwr:Usage/Cap|         Memory-Usage | GPU-Util  Compute M. |
|===============================+======================+======================|
|   0  Tesla P40           On   | 0000:00:07.0     Off |                    0 |
| N/A   14C    P8    10W / 250W |      0MiB / 22912MiB |      0%      Default |
+-------------------------------+----------------------+----------------------+
                                                                               
+-----------------------------------------------------------------------------+
| Processes:                                                       GPU Memory |
|  GPU       PID  Type  Process name                               Usage      |
|=============================================================================|
|  No running processes found                                                 |
+-----------------------------------------------------------------------------+

But after install gnome desktop with "yum groups install “GNOME Desktop” and run nvidia-smi again, I get following error information.

[root@vm10-0-6-21 ~]# nvidia-smi
NVIDIA-SMI has failed because it couldn't communicate with the NVIDIA driver. Make sure that the latest NVIDIA driver is installed and running.

My environment is CentOS 7.3 64bit.

How to solve this problem?

Thanks a lot.

Michael