TeamBlackMiner icon indicating copy to clipboard operation
TeamBlackMiner copied to clipboard

oc coreclock an memclock on linux

Open konwin opened this issue 3 years ago • 7 comments

Could you fix the OC function on linux? At the moment it is not possible to set the memclock to high values! I'm using an external script to adjust powerlimit, p-state, coreclock, lock coreclock, memclock and to controll the fans which is running fine parallel to TBM, but if TBM restarts dag verification fails because the script doesn't know TBM need to verify dag and keeps all oc-clocks! For the scirpt to work without password promt I just had to add myUSERNAME ALL=(ALL:ALL) NOPASSWD:/usr/bin/nvidia-smi to /etc/sudoers It's using the following commands to set: [in brackets my values for 3060ti NLHR]

persistence-mode

sudo nvidia-smi --persistence-mode=1 --id="$GPUID" 1> /dev/null

powerlimit [65]

sudo nvidia-smi --id="$GPUID" -pl "$POWERDRAW" 1> /dev/null

PowerMizerMode

nvidia-settings --assign [gpu:$GPUID]/GPUPowerMizerMode=0 1> /dev/null

coreclock-offset (GPUGraphicsClockOffset "4" for RTX 3xxx, "3" for <= RTX 2xxx) [-500]

nvidia-settings --assign [gpu:$GPUID]/GPUGraphicsClockOffset["4"]="$CORECLOCK" 1> /dev/null

lock coreclock [850]

sudo nvidia-smi --id="$GPUID" -lgc "$LOCKCORECLOCK" 1> /dev/null

set memclock (GPUMemoryTransferRateOffset "4" for RTX 3xxx, "3" for <= RTX 2xxx) [2400]

nvidia-settings --assign [gpu:$GPUID]/GPUMemoryTransferRateOffset["4"]="$MEMCLOCK" 1> /dev/null

konwin avatar Feb 08 '22 10:02 konwin

Lower the clocks on one of the gpus in the rig. If the verification fails, the other gpus will copy the dag from the working gpu. You can even clock cards higher with this trick.

TBMiner 1.48 or greater is needed.

--lock-cclock [850,850] is doing the same thing on the coreclock.

sp-hash avatar Feb 08 '22 10:02 sp-hash

But why not lowering the clock for dag verification and then clock them higher? I don't want to have one GPU running all the time with lower clocks! Also --lock-mclock ist not working correctly. I can't get my cards to >8000MHz! Can you implement nvidia-settings --assign [gpu:$GPUID]/GPUMemoryTransferRateOffset["4"]="$MEMCLOCK" for mclock. Because this allows higher clocks!

konwin avatar Feb 08 '22 11:02 konwin

sure. thanks

sp-hash avatar Feb 08 '22 11:02 sp-hash

Tested on ubuntu 20.04 GPUMemoryTransferRateOffset has no effect. (rtx 2060)

sp-hash avatar Feb 14 '22 12:02 sp-hash

for cards before RTX 3xxx it has to be "3" in nvidia-settings --assign [gpu:$GPUID]/GPUMemoryTransferRateOffset["3"]="$MEMCLOCK"

konwin avatar Feb 14 '22 13:02 konwin

On the 495.29.05 driver on a laptop, this option is not there

~$ nvidia-settings -q all | grep GPUMemory Attribute 'GPUMemoryInterface' (xxx:1.0): 192. 'GPUMemoryInterface' is an integer attribute. 'GPUMemoryInterface' is a read-only attribute. 'GPUMemoryInterface' can use the following target types: X Screen, GPU. Attribute 'TotalDedicatedGPUMemory' (xxx:1[gpu:0]): 5926. 'TotalDedicatedGPUMemory' is an integer attribute. 'TotalDedicatedGPUMemory' is a read-only attribute. 'TotalDedicatedGPUMemory' can use the following target types: GPU. Attribute 'UsedDedicatedGPUMemory' (xxx:1[gpu:0]): 5558. 'UsedDedicatedGPUMemory' is an integer attribute. 'UsedDedicatedGPUMemory' is a read-only attribute. 'UsedDedicatedGPUMemory' can use the following target types: GPU. Attribute 'GPUMemoryInterface' (xxx:1[gpu:0]): 192. 'GPUMemoryInterface' is an integer attribute. 'GPUMemoryInterface' is a read-only attribute. 'GPUMemoryInterface' can use the following target types: X Screen, GPU.

sp-hash avatar Feb 14 '22 13:02 sp-hash

I also don't get it as an option (ubuntu 21.04, driver 495.46, 10x 3060ti):

~$ nvidia-settings -q all | grep GPUMemory Attribute 'GPUMemoryInterface' (xxx:0.0): 256. 'GPUMemoryInterface' is an integer attribute. 'GPUMemoryInterface' is a read-only attribute. 'GPUMemoryInterface' can use the following target types: X Screen, GPU. Attribute 'GPUMemoryInterface' (xxx:0.1): 256. 'GPUMemoryInterface' is an integer attribute. 'GPUMemoryInterface' is a read-only attribute. 'GPUMemoryInterface' can use the following target types: X Screen, GPU. Attribute 'GPUMemoryInterface' (xxx:0.2): 256. 'GPUMemoryInterface' is an integer attribute. 'GPUMemoryInterface' is a read-only attribute. 'GPUMemoryInterface' can use the following target types: X Screen, GPU. Attribute 'GPUMemoryInterface' (xxx:0.3): 256. 'GPUMemoryInterface' is an integer attribute. 'GPUMemoryInterface' is a read-only attribute. 'GPUMemoryInterface' can use the following target types: X Screen, GPU. Attribute 'GPUMemoryInterface' (xxx:0.4): 256. 'GPUMemoryInterface' is an integer attribute. 'GPUMemoryInterface' is a read-only attribute. 'GPUMemoryInterface' can use the following target types: X Screen, GPU. Attribute 'GPUMemoryInterface' (xxx:0.5): 256. 'GPUMemoryInterface' is an integer attribute. 'GPUMemoryInterface' is a read-only attribute. 'GPUMemoryInterface' can use the following target types: X Screen, GPU. Attribute 'GPUMemoryInterface' (xxx:0.6): 256. 'GPUMemoryInterface' is an integer attribute. 'GPUMemoryInterface' is a read-only attribute. 'GPUMemoryInterface' can use the following target types: X Screen, GPU. Attribute 'GPUMemoryInterface' (xxx:0.7): 256. 'GPUMemoryInterface' is an integer attribute. 'GPUMemoryInterface' is a read-only attribute. 'GPUMemoryInterface' can use the following target types: X Screen, GPU. Attribute 'GPUMemoryInterface' (xxx:0.8): 256. 'GPUMemoryInterface' is an integer attribute. 'GPUMemoryInterface' is a read-only attribute. 'GPUMemoryInterface' can use the following target types: X Screen, GPU. Attribute 'GPUMemoryInterface' (xxx:0.9): 256. 'GPUMemoryInterface' is an integer attribute. 'GPUMemoryInterface' is a read-only attribute. 'GPUMemoryInterface' can use the following target types: X Screen, GPU. Attribute 'TotalDedicatedGPUMemory' (xxx:0[gpu:0]): 7976. 'TotalDedicatedGPUMemory' is an integer attribute. 'TotalDedicatedGPUMemory' is a read-only attribute. 'TotalDedicatedGPUMemory' can use the following target types: GPU. Attribute 'UsedDedicatedGPUMemory' (xxx:0[gpu:0]): 5000. 'UsedDedicatedGPUMemory' is an integer attribute. 'UsedDedicatedGPUMemory' is a read-only attribute. 'UsedDedicatedGPUMemory' can use the following target types: GPU. Attribute 'GPUMemoryInterface' (xxx:0[gpu:0]): 256. 'GPUMemoryInterface' is an integer attribute. 'GPUMemoryInterface' is a read-only attribute. 'GPUMemoryInterface' can use the following target types: X Screen, GPU. Attribute 'TotalDedicatedGPUMemory' (xxx:0[gpu:1]): 7982. 'TotalDedicatedGPUMemory' is an integer attribute. 'TotalDedicatedGPUMemory' is a read-only attribute. 'TotalDedicatedGPUMemory' can use the following target types: GPU. Attribute 'UsedDedicatedGPUMemory' (xxx:0[gpu:1]): 4957. 'UsedDedicatedGPUMemory' is an integer attribute. 'UsedDedicatedGPUMemory' is a read-only attribute. 'UsedDedicatedGPUMemory' can use the following target types: GPU. Attribute 'GPUMemoryInterface' (xxx:0[gpu:1]): 256. 'GPUMemoryInterface' is an integer attribute. 'GPUMemoryInterface' is a read-only attribute. 'GPUMemoryInterface' can use the following target types: X Screen, GPU. Attribute 'TotalDedicatedGPUMemory' (xxx:0[gpu:2]): 7982. 'TotalDedicatedGPUMemory' is an integer attribute. 'TotalDedicatedGPUMemory' is a read-only attribute. 'TotalDedicatedGPUMemory' can use the following target types: GPU. Attribute 'UsedDedicatedGPUMemory' (xxx:0[gpu:2]): 4957. 'UsedDedicatedGPUMemory' is an integer attribute. 'UsedDedicatedGPUMemory' is a read-only attribute. 'UsedDedicatedGPUMemory' can use the following target types: GPU. Attribute 'GPUMemoryInterface' (xxx:0[gpu:2]): 256. 'GPUMemoryInterface' is an integer attribute. 'GPUMemoryInterface' is a read-only attribute. 'GPUMemoryInterface' can use the following target types: X Screen, GPU. Attribute 'TotalDedicatedGPUMemory' (xxx:0[gpu:3]): 7982. 'TotalDedicatedGPUMemory' is an integer attribute. 'TotalDedicatedGPUMemory' is a read-only attribute. 'TotalDedicatedGPUMemory' can use the following target types: GPU. Attribute 'UsedDedicatedGPUMemory' (xxx:0[gpu:3]): 4957. 'UsedDedicatedGPUMemory' is an integer attribute. 'UsedDedicatedGPUMemory' is a read-only attribute. 'UsedDedicatedGPUMemory' can use the following target types: GPU. Attribute 'GPUMemoryInterface' (xxx:0[gpu:3]): 256. 'GPUMemoryInterface' is an integer attribute. 'GPUMemoryInterface' is a read-only attribute. 'GPUMemoryInterface' can use the following target types: X Screen, GPU. Attribute 'TotalDedicatedGPUMemory' (xxx:0[gpu:4]): 7982. 'TotalDedicatedGPUMemory' is an integer attribute. 'TotalDedicatedGPUMemory' is a read-only attribute. 'TotalDedicatedGPUMemory' can use the following target types: GPU. Attribute 'UsedDedicatedGPUMemory' (xxx:0[gpu:4]): 4957. 'UsedDedicatedGPUMemory' is an integer attribute. 'UsedDedicatedGPUMemory' is a read-only attribute. 'UsedDedicatedGPUMemory' can use the following target types: GPU. Attribute 'GPUMemoryInterface' (xxx:0[gpu:4]): 256. 'GPUMemoryInterface' is an integer attribute. 'GPUMemoryInterface' is a read-only attribute. 'GPUMemoryInterface' can use the following target types: X Screen, GPU. Attribute 'TotalDedicatedGPUMemory' (xxx:0[gpu:5]): 7982. 'TotalDedicatedGPUMemory' is an integer attribute. 'TotalDedicatedGPUMemory' is a read-only attribute. 'TotalDedicatedGPUMemory' can use the following target types: GPU. Attribute 'UsedDedicatedGPUMemory' (xxx:0[gpu:5]): 4957. 'UsedDedicatedGPUMemory' is an integer attribute. 'UsedDedicatedGPUMemory' is a read-only attribute. 'UsedDedicatedGPUMemory' can use the following target types: GPU. Attribute 'GPUMemoryInterface' (xxx:0[gpu:5]): 256. 'GPUMemoryInterface' is an integer attribute. 'GPUMemoryInterface' is a read-only attribute. 'GPUMemoryInterface' can use the following target types: X Screen, GPU. Attribute 'TotalDedicatedGPUMemory' (xxx:0[gpu:6]): 7982. 'TotalDedicatedGPUMemory' is an integer attribute. 'TotalDedicatedGPUMemory' is a read-only attribute. 'TotalDedicatedGPUMemory' can use the following target types: GPU. Attribute 'UsedDedicatedGPUMemory' (xxx:0[gpu:6]): 4957. 'UsedDedicatedGPUMemory' is an integer attribute. 'UsedDedicatedGPUMemory' is a read-only attribute. 'UsedDedicatedGPUMemory' can use the following target types: GPU. Attribute 'GPUMemoryInterface' (xxx:0[gpu:6]): 256. 'GPUMemoryInterface' is an integer attribute. 'GPUMemoryInterface' is a read-only attribute. 'GPUMemoryInterface' can use the following target types: X Screen, GPU. Attribute 'TotalDedicatedGPUMemory' (xxx:0[gpu:7]): 7982. 'TotalDedicatedGPUMemory' is an integer attribute. 'TotalDedicatedGPUMemory' is a read-only attribute. 'TotalDedicatedGPUMemory' can use the following target types: GPU. Attribute 'UsedDedicatedGPUMemory' (xxx:0[gpu:7]): 4957. 'UsedDedicatedGPUMemory' is an integer attribute. 'UsedDedicatedGPUMemory' is a read-only attribute. 'UsedDedicatedGPUMemory' can use the following target types: GPU. Attribute 'GPUMemoryInterface' (xxx:0[gpu:7]): 256. 'GPUMemoryInterface' is an integer attribute. 'GPUMemoryInterface' is a read-only attribute. 'GPUMemoryInterface' can use the following target types: X Screen, GPU. Attribute 'TotalDedicatedGPUMemory' (xxx:0[gpu:8]): 7982. 'TotalDedicatedGPUMemory' is an integer attribute. 'TotalDedicatedGPUMemory' is a read-only attribute. 'TotalDedicatedGPUMemory' can use the following target types: GPU. Attribute 'UsedDedicatedGPUMemory' (xxx:0[gpu:8]): 4957. 'UsedDedicatedGPUMemory' is an integer attribute. 'UsedDedicatedGPUMemory' is a read-only attribute. 'UsedDedicatedGPUMemory' can use the following target types: GPU. Attribute 'GPUMemoryInterface' (xxx:0[gpu:8]): 256. 'GPUMemoryInterface' is an integer attribute. 'GPUMemoryInterface' is a read-only attribute. 'GPUMemoryInterface' can use the following target types: X Screen, GPU. Attribute 'TotalDedicatedGPUMemory' (xxx:0[gpu:9]): 7982. 'TotalDedicatedGPUMemory' is an integer attribute. 'TotalDedicatedGPUMemory' is a read-only attribute. 'TotalDedicatedGPUMemory' can use the following target types: GPU. Attribute 'UsedDedicatedGPUMemory' (xxx:0[gpu:9]): 4957. 'UsedDedicatedGPUMemory' is an integer attribute. 'UsedDedicatedGPUMemory' is a read-only attribute. 'UsedDedicatedGPUMemory' can use the following target types: GPU. Attribute 'GPUMemoryInterface' (xxx:0[gpu:9]): 256. 'GPUMemoryInterface' is an integer attribute. 'GPUMemoryInterface' is a read-only attribute. 'GPUMemoryInterface' can use the following target types: X Screen, GPU.

but it works (2450=8025 effective clock): ~$ nvidia-settings --assign [gpu:9]/GPUMemoryTransferRateOffset["4"]="2450"

Attribute 'GPUMemoryTransferRateOffset' (xxx:0[gpu:9]) assigned value 2450.

konwin avatar Feb 14 '22 14:02 konwin