Score:0

Ubuntu server 20.04 LTS - Installing nvidia & cuda installs gnome as well

uz flag

I have a GPU server which requires cuda for example for machine learning tasks.

unfortunately, as soon as I install the NVIDIA drivers and cuda, apparently a variant of gnome is installed as well. This gnome variant can almost do nothing, the shell is not working and apparently it comes with some desktop settings which are really annoying me.

For example per default, it sets shutdown after 20 minutes inactivity. For a Server, this is very suboptimal to call it this way.

Do you know how to install the drivers and the cuda toolkit without gnome or (less preferrably) remove gnome after the fact and all its stuff (such as the 20 minute idle setting) which I definitely do not want on my Server?

Score:0
uz flag

Using the headless nvidia Driver did not help. The gnome comes from the cuda toolkit I guess.

I have been able to remove gnome but I am unsure, if this is a proper removal so I leave the question open for now. Note the two last steps in cuda installation:
sudo apt-get remove *gnome* && sudo apt-get purge *gnome*

Install Nvidia Drivers

Step Command Description
1. sudo apt-get update && apt search nvidia-driver Get nvidia drivers, pick the highest version number (for server)
2. sudo apt-get install [package name] install driver
3. sudo shutdown -r 0 reboot
4. sudo lshw -C display check gpus (if driver is installed properly)

Install Cuda toolkit

Step Command Description
1. sudo apt-get install gcc --yes Install gcc compiler (check if installed with gcc --version)
2. uname -r Verify this command works and a kernel version is shown
3. sudo apt-get install linux-headers-$(uname -r) Install kernel (might come with drivers already but safe is safe)
4. https://developer.nvidia.com/cuda-downloads Generate installation code here (and execute it)
5. sudo apt-get remove *gnome* Uninstall the broken gnome
6. sudo apt-get purge *gnome* Uninstall the broken gnome

make sure to not sudo apt-get --auto-remove as this will remove coda toolkit as well again...

unkilbeeg avatar
ls flag
I just ran into the same problem. When I tried to remove *gnome* it tried to remove cuda and all the cuda stuff. This wasn't auto-remove -- it ALSO told me I should auto-remove a page or so of stuff, 4 or 5 times as much. I ended up removing gdm3, and so far it doesn't look like it starts up the GUI crap.
mangohost

Post an answer

Most people don’t grasp that asking a lot of questions unlocks learning and improves interpersonal bonding. In Alison’s studies, for example, though people could accurately recall how many questions had been asked in their conversations, they didn’t intuit the link between questions and liking. Across four studies, in which participants were engaged in conversations themselves or read transcripts of others’ conversations, people tended not to realize that question asking would influence—or had influenced—the level of amity between the conversationalists.