Last active
January 15, 2024 14:41
-
-
Save moeiscool/e4ea3ecfdcf0a29da21c5b7a687726b7 to your computer and use it in GitHub Desktop.
Install XMRig with GPU support Quick and Easy on Ubuntu 20.04
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
echo "Installing dependencies" | |
sudo apt install gcc-7 g++-7 cmake git -y | |
sudo update-alternatives --install /usr/bin/gcc gcc /usr/bin/gcc-7 800 --slave /usr/bin/g++ g++ /usr/bin/g++-7 | |
echo "=============" | |
echo "Installing Node.js : For using PM2 daemon manager" | |
wget https://deb.nodesource.com/setup_12.x | |
chmod +x setup_12.x | |
./setup_12.x | |
sudo apt install nodejs -y | |
sudo apt install node-pre-gyp -y | |
rm setup_12.x | |
if ! [ -x "$(command -v npm)" ]; then | |
sudo apt install npm -y | |
fi | |
sudo npm install [email protected] -g | |
echo "=============" | |
echo "Install NVIDIA Drivers with CUDA 10.0 and CUDNN, CUDNN-dev" | |
echo "Probably don't need them all but I used this script and does have them." | |
echo "Reboot will be required before running part2.sh!!!!" | |
wget https://gitlab.com/Shinobi-Systems/Shinobi/-/raw/dev/INSTALL/cuda-10.sh | |
./cuda-10.sh | |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
echo "I really hope you rebooted after part1.sh! Here we go!" | |
wget https://github.com/xmrig/xmrig/releases/download/v6.15.3/xmrig-6.15.3-linux-x64.tar.gz | |
tar -xvf xmrig-6.15.3-linux-x64.tar.gz | |
echo "=============" | |
echo "Get and Build XMRig CUDA Plugin" | |
git clone https://github.com/xmrig/xmrig-cuda.git | |
cd xmrig-cuda | |
mkdir build | |
cd build | |
cmake .. | |
make | |
cp libxmrig-cuda.so ../xmrig-6.15.3/libxmrig-cuda.so | |
cd ../xmrig-6.15.3 | |
echo "edit config.json and set the following :" | |
echo "cuda.enabled : true" | |
echo 'cuda.loader : "./libxmrig-cuda.so"' |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
cd ./xmrig-6.15.3 | |
pm2 start xmrig -- --config config.json |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment