Title: [GUIDE][NVIDIA] How to setup a headless Ubuntu 16 Server with Overclocking Post by: slazarov on November 20, 2017, 06:28:31 PM This guide will help you setup multiple NVIDIA GPUs (proprietary drivers) on Ubuntu 16.04.03 headless* server, enabling overclock and fan control.
*Headless means without a monitor connected to the rig Prerequisites:
Steps 1. Since it's a freshly installed OS, SSH into the system and update: Quote sudo apt-get update && sudo apt-get upgrade -y && sudo apt-get dist-upgrade -y 2. Install a lightweight X server Quote sudo apt-get install --no-install-recommends xorg lightdm 3. Disable the X server from auto starting on boot. Otherwise it would cause conflicts when you try to overclock the cards later on. Quote sudo systemctl disable lightdm.service 4. Install GCC and MAKE in order to be able to install the NVIDIA proprietary drivers Quote sudo apt-get install gcc make -y 5. Install GTK in order to be able to use nvidia-settings Quote sudo apt-get install libgtk-3-dev -y 6. Download the latest NVIDIA proprietary drivers. Right now they are 384.98, so check for updates from NVIDIA's website Quote wget http://us.download.nvidia.com/XFree86/Linux-x86_64/384.98/NVIDIA-Linux-x86_64-384.98.run 7. Reboot Quote sudo reboot 8. Make the file executable and start the installation: Quote chmod +x NVIDIA-Linux-x86_64-384.98.run sudo ./NVIDIA-Linux-x86_64-384.98.run 8.1 At a certain point you will be greeted by the following error. Code: WARNING: Unable to find a suitable destination to install 32-bit compatibility libraries. Your system may not be set up for 32-bit Ignore it, it's all ok. 8.2 At the end of the installation you will be asked: Code: Would you like to run the nvidia-xconfig utility to automatically update your X configuration file so that the NVIDIA X driver will be used when you restart X? Any pre-existing X configuration file will be backed up. 8.3 Generate xorg.conf Quote sudo nvidia-xconfig -a --allow-empty-initial-configuration --cool-bits=31 --use-display-device="DFP-0" --connected-monitor="DFP-0" cool-bits enables overclocking; the rest tricks the rig that there is a monitor connected to it.You will get this message: Code: Package xorg-server was not found in the pkg-config search path. 8.4 Reboot Quote sudo reboot 9. Boot up and check if all the GPUs are shown Quote nvidia-smi You should get something like this:Code: +-----------------------------------------------------------------------------+ 10. We are nearly done. Let's add some additional stuff and setup overclocking. We are going to make them boot together with Ubuntu, so we don't have to do them manually every single time. Quote sudo nano /etc/rc.local Sample file:Code: # Add some error logging, you can disable it after when you are certain everything is working: Reboot: Quote sudo reboot Check for error Quote cat /tmp/rc.local.log If the file ends with +exit 0 then you have successfully managed to overclock and set the fan speed.11. Let's try some mining: 11.1 Download EWBF from the official bitcointalk thread on your main computer https://bitcointalk.org/index.php?topic=1707546.0 (https://bitcointalk.org/index.php?topic=1707546.0) 11.2 Upload miner, unarchive and create a run script From your computer Quote scp /Users/xxxx/Downloads/Zec\ Miner\ 0.3.4b\ Linux\ Bin.tar.gz your_user_name@ip_of_rig:/home/your_user_name From the rig Quote tar xvf Zec\ Miner\ 0.3.4b\ Linux\ Bin.tar.gz cd 0.3.4b echo "./miner --server eu.zenmine.pro --user znWvyc22usByJRRjijeFeD2D7yNF9P11MAG.rig1 --pass x --port 9009 --log 2 --api 0.0.0.0:3333" > run.sh chmod +x run.sh 11.3 Run the script Quote ./run.sh & Don't forget the prefix &. It makes sure that the miner keeps running after you exit the session. 12. CTRL+D out of the SSH session and enjoy. Note If you get an error message regarding the drivers at any point in time, redo STEP 8 and all of its subsets. If you want I will add additional watchdog scripts. If you find this guide helpful, you could buy me a beer ;). [ BTC ] 18n4eKg8PB1USs5f95MK34JA4KmaV1YhT2 [ ETH ] 0xf5a6431ac4acd8b1e5c8b56b9b45e04cdea20e6e [ LTC ] LZT8o523jwa8ZmgMjPLNMJeVeBnLuAvRvc Title: Re: [GUIDE][NVIDIA] How to setup a headless Ubuntu 16 Server with Overclocking Post by: NameTaken on November 20, 2017, 06:48:24 PM Install Nvidia driver from repo instead of .run.
No need to install build packages. Coolbits 1 and 2 are unnecessary. Quote 1 (bit 0) - Enables overclocking of older (pre-Fermi) cores on the Clock Frequencies page in nvidia-settings. 2 (bit 1) - When this bit is set, the driver will "attempt to initialize SLI when using GPUs with different amounts of video memory". Code: systemctl disable lightdm Code: systemctl set-default multi-user.target All major distros have adopted systemd for process management and logging so take advantage of that instead of using antiquated rc.local, screen, cron, &, >, etc. Title: Re: [GUIDE][NVIDIA] How to setup a headless Ubuntu 16 Server with Overclocking Post by: slazarov on November 20, 2017, 08:11:22 PM Lightdm disable fixed - wrong copy pasta.
Agree with the rest. The drivers in the repo are not the most recent tho. Title: Re: [GUIDE][NVIDIA] How to setup a headless Ubuntu 16 Server with Overclocking Post by: NameTaken on November 20, 2017, 08:19:11 PM Lightdm disable fixed - wrong copy pasta. nvidia-384 is in default 16.04 repo.Agree with the rest. The drivers in the repo are not the most recent tho. https://launchpad.net/~graphics-drivers/+archive/ubuntu/ppa If you want 387. Title: Re: [GUIDE][NVIDIA] How to setup a headless Ubuntu 16 Server with Overclocking Post by: slazarov on November 20, 2017, 08:32:43 PM Note taken.
Will edit it later. Leaving the OC part as it is for now. Title: Re: [GUIDE][NVIDIA] How to setup a headless Ubuntu 16 Server with Overclocking Post by: huglester on October 18, 2018, 08:32:07 PM any updates to this script?
Title: Re: [GUIDE][NVIDIA] How to setup a headless Ubuntu 16 Server with Overclocking Post by: Rabinovitch on March 06, 2019, 08:55:48 AM Coolbits 1 and 2 are unnecessary. Quote 1 (bit 0) - Enables overclocking of older (pre-Fermi) cores on the Clock Frequencies page in nvidia-settings. 2 (bit 1) - When this bit is set, the driver will "attempt to initialize SLI when using GPUs with different amounts of video memory". So what value should we use for 'coolbits'? any updates to this script? I highly doubt there will ever be any... Title: Re: [GUIDE][NVIDIA] How to setup a headless Ubuntu 16 Server with Overclocking Post by: Rabinovitch on March 06, 2019, 09:01:34 AM This guide will help you setup multiple NVIDIA GPUs (proprietary drivers) on Ubuntu 16.04.03 headless* server, enabling overclock and fan control. Sample file: Code: ... Excellent, thank you so much! But for some reason I can't see 90% of fan speed on one of my GPUs: http://screenshot.ru/00488f2ad89c0891b492b93e1bb36c72.png But all commands has been accepted by OS! http://screenshot.ru/39d587e607ca7d71abc3b6c03149aac8.png How to fix it? p.s. actually this trick is working only for GPU0 and GPU1. On GPU2 and GPU3 it looks that the fan speed remains the same as without all those commands. Title: Re: [GUIDE][NVIDIA] How to setup a headless Ubuntu 16 Server with Overclocking Post by: jintruder on March 12, 2019, 10:14:20 PM Guys, check this out : https://bitcointalk.org/index.php?topic=1854250.0
Also would be great to have such a tutorial for AMD gpus |