CAUTION PROCEED AT YOUR OWN RISK. THIS COULD CAUSE IRREPARABLE DAMAGE TO YOUR GPU. CAUTION IF YOU PROCEED YOU ARE TAKING A MAJOR GAMBLE
When I first started using Linux for mining, I searched and searched for a way to backup and flash my VBIOS. The only process that I could find required Windows and I basically hate Windows.
Please note: I only run NVIDIA cards, so I have only tested on them.
After a lot of trial and error, I have come up with a guide that has worked every time for me. Below is the guide. Feel free to test it out and leave feed back. I will do my best to answer questions as they arise. I am not saying that I can or will support you, if you decide to go forward with this. If you do copy this and post it elsewhere, I ask that you reference with link to the original guide.
Step 1. You will need to download the Linux version of nvflash from the below link.
https://techpowerup.com/download/nvidia-nvflash/
If you want to download the file directly to the miner, you will need to get the direct link. From what I have found, it looks like they provide a temporary link when you initiate a download, so you will have to make sure to use the link quickly.
You can also use SCP to copy the file to the rig.
Here is how I download it to the rig directly:
[list]
[] Select the download button from the link above.
[] On the next screen, select the mirror that you would like to use.
[*] I use download helper for this step. You can download the software here. https://downloadhelper.net/
[] Cancel the download once it begins and then go to the download helper widget to find the download listed that you just initiated. Copy the link from this screen.
[] Log into the Mining rig that you want to run NVFLASH on.
[*] Run the following command
wget {INSERT THE LINK COPIED ABOVE HERE}
Example:
wget http://us1-dl.techpowerup.com/files/TXNClDg4ct9aOJnaL8pTAA/1522950144/nvflash_5.414.0_linux.zip
[/list]
Step 2. Make sure that you are in the directory that you copied the file to. Use the cd command to browse to the directory. Then unzip the archive.
unzip nvflash
Step 3. Make the nvflash file executable.
chmod +x nvflash
Step 4. Stop the miner from running.
miner stop
Step 5. Check to see the version of Nvidia driver that you have installed.
dkms status | grep nvidia
Output:
nvidia, 390.25, 4.10.17-hiveos, x86_64: installed
The number right after nvidia, is the driver version.
Step 6. Unload the Nvidia driver.
Make sure the version number after the -v matches what you found in the previous step.
dkms remove -m nvidia -v 390.25 --all
Step 7. Kill the process for Xorg.
pkill Xorg
Verification:
ps -ef | grep Xorg
or
pgrep Xorg
Step 8. Unload the following modules in this order:
rmmod -f nvidia_uvm
rmmod -f nvidia_drm
rmmod -f nvidia_modeset
rmmod -f nvidia
Verification:
lsmod | grep nvidia
If there are still modules showing in this section, there may be other modules that have to be unloaded. The key here is that the nvidia module has to be unloaded for nvflash to function.
Step 9. From the directory that you unzipped nvflash into, run the following command to list the cards you have installed.
./nvflash_linux --list
Step 10. List the version of VBIOS that each card has installed.
Please note: different sub system id’s generally refer to the ram that is installed on the card, if you are running the same cards in the rig.
./nvflash_linux -v
Step 11. Backup the ROM that is loaded in the VBIOS.
***Do not skip this step.***
If the version is the same across all cards, run this command:
./nvflash_linux -b 86.06.68.00.6B.rom
The information after the -b is the name of the file you are backing up. Make sure to give it a descriptive name. Also, the file has to end in the .rom extension.
If the version is different across multiple cards, use this command:
./nvflash_linux -i0 -b 86.06.68.00.6B.rom
The number after the -i is the card number identified in steps 9 and 10.
Step 12. Flash the GPU with the ROM of your choice.
If you want to flash all the cards with the same VBIOS version, use the following command:
./nvflash_linux 86.06.68.00.6B.rom
If you get an error message that there is a subsystem id mismatch, you can use the following command:
./nvflash_linux -6 86.06.68.00.6B.rom
Note: This could cause more problems than it is worth
If you want to flash a specific card in the rig, use the following command:
./nvflash_linux -i0 86.06.68.00.6B.rom
The number after the -i is the GPU id that was identified in steps 9 and 10.
If you get an error message that there is a subsystem id mismatch, you can use the following command:
./nvflash_linux -i0 -6 86.06.68.00.6B.rom
Step 13: Reload the Nvidia driver that was unloaded earlier. Make sure to use the version determined in step 5.
dkms install -m nvidia -v 390.25
Step 14: Reboot rig.
reboot
Step 15: Verify code upgrade:
nvidia-smi -q | grep -E 'VBIOS|GPU [0-9]'
If all went well, your VBIOS has been updated and your miner is back up and running.
Happy Mining!