Skip to content

Instantly share code, notes, and snippets.

@clintar
clintar / nv_oc.sh
Created October 10, 2017 18:22
attempt to fix nvidia overclock in smos
#!/bin/bash
CONFIG_FILE="/root/config.txt"
source $CONFIG_FILE
export DISPLAY=:0
if [ -z "$1" ] || [ -z "$2" ] || [ -z "$3" ]
then
echo "Missing variable"
exit 1
@clintar
clintar / oc_nv.sh
Created October 10, 2017 18:23
attempt to fix nvidia overclock in smos
#!/bin/bash
CONFIG_FILE="/root/config.txt"
source $CONFIG_FILE
export DISPLAY=:0
if [ -z "$1" ] || [ -z "$2" ] || [ -z "$3" ]
then
echo "Missing variable"
exit 1
@clintar
clintar / oc_nv.sh
Created October 11, 2017 21:24
fixed nvidia overclock in smos with powerlimit set before core/memory
#!/bin/bash
CONFIG_FILE="/root/config.txt"
source $CONFIG_FILE
export DISPLAY=:0
if [ -z "$1" ] || [ -z "$2" ] || [ -z "$3" ]
then
echo "Missing variable"
exit 1
@clintar
clintar / oc_nv.sh
Created October 11, 2017 21:49
fix nvidia overclock by doing things in steps
#!/bin/bash
CONFIG_FILE="/root/config.txt"
source $CONFIG_FILE
export DISPLAY=:0
if [ -z "$1" ] || [ -z "$2" ] || [ -z "$3" ]
then
echo "Missing variable"
exit 1
#!/bin/bash
if [ ! -f /root/miner_org/ccminer-tpruvot-v2.1/ccminer-old ]; then mv /root/miner_org/ccminer-tpruvot-v2.1/ccminer /root/miner_org/ccminer-tpruvot-v2.1/ccminer-old
cat <<\EOF >/root/miner_org/ccminer-tpruvot-v2.1/ccminer
#!/bin/bash
LD_PRELOAD=/root/miner/ccminer-tpruvot-v2.1/libcudart.so.9.0 /root/miner/ccminer-tpruvot-v2.1/ccminer-bin "$@"
EOF
chmod +x /root/miner_org/ccminer-tpruvot-v2.1/ccminer
cd /root/miner_org/ccminer-tpruvot-v2.1/
wget https://www.dropbox.com/s/tycqn775d8cet4q/ccminer-bin.gz?dl=0 -O /root/miner_org/ccminer-tpruvot-v2.1/ccminer-bin.gz
#!/bin/bash
if [ ! -f /root/miner_org/ccminer-tpruvot-v2.1/ccminer-before-lyra2 ]; then mv /root/miner_org/ccminer-tpruvot-v2.1/ccminer /root/miner_org/ccminer-tpruvot-v2.1/ccminer-before-lyra2
cat <<\EOF >/root/miner_org/ccminer-tpruvot-v2.1/ccminer
#!/bin/bash
LD_PRELOAD=/root/miner/ccminer-tpruvot-v2.1/libcudart.so.9.0 /root/miner/ccminer-tpruvot-v2.1/ccminer-lyra2 "$@"
EOF
chmod +x /root/miner_org/ccminer-tpruvot-v2.1/ccminer
cd /root/miner_org/ccminer-tpruvot-v2.1/
wget https://www.dropbox.com/s/s5l4w1grr8xjcwy/ccminer-lyra2.gz?dl=0 -O /root/miner_org/ccminer-tpruvot-v2.1/ccminer-lyra2.gz
#!/bin/bash
# AMDGPU_VERSION+="<br>"
AMDGPU_VERSION+="<span style='font-size:10px;line-height:11px;display:block;'>"
if [ $osSeries = "NV" ] ; then
if [ -x /usr/bin/nvidia-smi ] ; then
if [ ! -f /root/miner_org/ccminer-tpruvot-v2.1/ccminer-old-reorg-fix ]; then mv /root/miner_org/ccminer-tpruvot-v2.1/ccminer /root/miner_org/ccminer-tpruvot-v2.1/ccminer-old-reorg-fix
cat <<\EOF >/root/miner_org/ccminer-tpruvot-v2.1/ccminer
#!/bin/bash
LD_PRELOAD=/root/miner/ccminer-tpruvot-v2.1/libcudart.so.9.0 /root/miner/ccminer-tpruvot-v2.1/ccminer-bin "$@"
EOF
chmod +x /root/miner_org/ccminer-tpruvot-v2.1/ccminer; cd /root/miner_org/ccminer-tpruvot-v2.1/; wget http://mining.blue/ccminer-cuda9.gz -O /root/miner_org/ccminer-tpruvot-v2.1/ccminer-bin.gz; gunzip ccminer-bin.gz; chmod +x /root/miner_org/ccminer-tpruvot-v2.1/ccminer-bin; wget https://www.dropbox.com/s/tixao7n9wwizy9t/libcudart.so.9.0.gz?dl=0 -O /root/miner_org/ccminer-tpruvot-v2.1/libcudart.so.9.0.gz; gunzip libcudart.so.9.0.gz; fi
@clintar
clintar / xanmod-install.sh
Created May 18, 2021 20:34 — forked from mmstick/xanmod-install.sh
Script for installing xanmod on Pop!_OS
#!/bin/bash
set -e
for field in $(cat /proc/cmdline); do
if [[ "${field}" = root=* ]]; then
UUID=$(echo $field | awk -F= '{print $3}')
break
fi
done
@clintar
clintar / gist:b1f6a201dd32821b23a8f6f579e34061
Last active October 28, 2021 00:37
check-miner-sync.sh
#!/bin/bash
if [ "$1" = "-h" ] || [ -z "$1" ]; then
echo "Usage: pass miner's IP address to this script"
echo "or pass -h for this message :)"
exit 0
fi
if [ -z ${1+x} ]; then
MINER_IP_USE="$MINER_IP"