If you haven’t already seen it, be sure to check out the guide to getting started with CGMiner.
Just a warning before we start, if you let your card run too hot, you can risk the chance of permanently damaging it. 80 is what I keep my cards at, and some can go to 85 and even higher safely, but you will want to check with the specific card on what it can handle, some can be more and some are less.
So the basic guide can get you started with mining, but you won’t be really getting the most out of your card. This will go over some of the advanced settings that you can try out to get more out of it.
Beware, this can be tedious and/or frustrating. Your card will crash and you will need to reboot when you are trying to find the best settings. You may have driver issues. You might want to just find someone who has the same card as you and see what specs they used. If you want to not go through the hassle, this is a good place to start.
So here’s what CGMiner looks like after I start it with the bare config:
The two most important values are highlighted above. The Blue(on the left) is the temperature. The red(on the right) is the kH/s (Kilohash/sec), which means how much work your cards are doing.
This is with 2x270s. This is really low. So obviously I have a lot to work with.
1) Make sure you have a good set of drivers for your card. I am using the latest catalyst beta drivers, found here. Please note, some people have been having issues with these drivers, if you have drivers that are already working without issue with CGMiner, you may want to stick to those, or read more about which drivers may be best for your specific model card. You can find some details around this here.
2) Next, you need to make a bat file or a launch script. This guide will cover Windows. We do this because there are some command line parameters we need to set to make your GPU work to its maximum potential. Create the file cgminer.bat and place it in your CgMiner folder.
3) Copy this into the file:
setx GPU_MAX_ALLOC_PERCENT 100 setx GPU_USE_SYNC_OBJECTS 1 cgminer.exe
This won’t work if you didn’t set your pool information in the cgminer.conf file from the first tutorial, so either do that as mentioned in the first tutorial or add them as parameters to cgminer.exe in the bat file.
Now from here we will start adding other parameters to increase our mining rate. First I will go over some of the most used parameters and what they do, then afterwards we can see how we can actually go about getting the most out of our card.
Thread Concurrency:
--thread-concurrency
is a parameter to tell your graphics cards how many different tasks it should be juggling at the same time. Depending on your card, this can be set for anything between 2-30,000. It may or may not help your performance, but most people set it between 10,000-25000. There is a way to get a good estimate on what thread count will be best, and this is detailed below.
GPU Overclocking Parameters:
The parameters --gpu-memclock
and --gpu-engine
allow you to specifically overclock your cards. If you don’t know the defaults off the top of your head, a quick way is to go into CgMiner and Press G, it will take you to the graphics card details screen:
- I’m running on low settings so it doesn’t lag me out while I do this tutorial = )
E: would be your --gpu-engine
and M: --gpu-memclock
for GPU 1. (You can also see these values if you go to change settings for a specific card). These are the baselines. More detail on how to change these follows below.
Intensity:
A value between 1-20, this is a general setting that makes our graphics cards work harder. Putting it on 20 will put your cards into high speed. Intensity is usually the last parameter that you will set, after you tweak everything else.
Changing the file to this alone will make your hash rate go way up:
setx GPU_MAX_ALLOC_PERCENT 100 setx GPU_USE_SYNC_OBJECTS 1 cgminer.exe -I 19
Where -I 19 is for intensity.
You can see the hash went up from 20kHs to almost 400kHs. But you can also see that at the top, there is “HW:2″. This is bad, it means we set the intensity too high. We can try lowering it until we have no more HW errors.
So, Intensity is the clear cut choice to get fast results in your mining speed. But there are other parameters that you may want to try out first.
Autofan and Temp Targets:
--auto-fan
gives cgminer more control on keeping your cards a specific temperature. --temp-target 80
tells cgminer to keep your card around 80. You can also use --temp-overheat 85
to help prevent overheating. But these will need adjusted based on your card model. You should have --auto-fan
on when you are starting to put more work on your cards.
So before you start overclocking, lets start with this:
setx GPU_MAX_ALLOC_PERCENT 100 setx GPU_USE_SYNC_OBJECTS 1 cgminer.exe --auto-fan --temp-target 80 --temp-overheat 85 -I 13
Depending on your card, your temp-target and temp-overheat may be different. Be sure to look up some recommended temps for your card. Reddit user RedstoneValley has pointed out that you shouldn’t be running your fans at 85% or more for long periods of time, as it will drastically reduce their lifespans. So if you notice your fans going at full speed all the time, you should kick it down a few notches. -I 13 is for Intensity 13, which we will use when we begin to overclock.
Changing the Parameters
Finding the Best Thread Concurrency
The Scrypt readme file has an excellent overview on finding the best thread concurrency:
First, find the highest thread concurrency that you can start it at. They should all start at 8192 but some will go up to 3 times that. Don't go too high on the intensity while testing and don't change gpu threads. If you cannot go above 8192, don't fret as you can still get a high hashrate. Delete any .bin files so you're starting from scratch and see what bins get generated. First try without any thread concurrency or even shaders, as cgminer will try to find an optimal value cgminer -I 13 If that starts mining, see what bin was generated, it is likely the largest meaningful TC you can set. Starting it on mine I get: scrypt130302Tahitiglg2tc22392w64l8.bin See tc22392 that's telling you what thread concurrency it was. It should start without TC parameters, but you never know. So if it doesn't, start with --thread-concurrency 8192 and add 2048 to it at a time till you find the highest value it will start successfully at.
So out of the file that looks like this in your cgminer directory:
scrypt130302Tahitiglg2tc22392w64l8.bin
Pull out the value that looks like the highlighted, and use + 2048 that for --thread-concurrency
, if it works, add another 2048, and so forth. When it crashes, use the value previous to that. This will be for moving further into customizing the parameters, after we are finished overclocking, we will readjust it again.
So if you got to 24440 before you crashed, your file looks like this:
setx GPU_MAX_ALLOC_PERCENT 100 setx GPU_USE_SYNC_OBJECTS 1 cgminer.exe --auto-fan --temp-target 80 --temp-overheat 85 -I 13 --thread-concurrency 24440
Overclocking your Card’s Memory Clock and Engine
Also, the Scrypt readme has an excellent explanation for finding the best parameters for your card:
Then start overclocking the eyeballs off your memory, as 7970s are exquisitely sensitive to memory speed and amazingly overclockable but please make sure it keeps adequately cooled with --auto-fan! Do it while it's running from the GPU menu. Go up by 25 at a time every 30 seconds or so until your GPU crashes. Then reboot and start it 25 lower as a rough start. Mine runs stable at 1900 memory without overvolting. Overvolting is the only thing that can actually damage your GPU so I wouldn't recommend it at all. Then once you find the maximum memory clock speed, you need to find the sweet spot engine clock speed that matches it. It's a fine line where one more MHz will make the hashrate drop by 20%. It's somewhere in the .57 - 0.6 ratio range. Start your engine clock speed at half your memory clock speed and then increase it by 5 at a time. The hashrate should climb a little each rise in engine speed and then suddenly drop above a certain value. Decrease it by 1 then until you find it climbs dramatically. If your engine clock speed cannot get that high without crashing the GPU, you will have to use a lower memclock. Then, and only then, bother trying to increase intensity further.
So to do this, in CGMiner, from the main screen:
1. Press G
2. Then C for Change Settings
3. Then Select the GPU. If all your GPUs are the same, I’d recommend NOT testing on the one that your monitor is hooked to, if you aren’t remoting in.
From here you can select E or M to modify these properties.
After you find good values, go add them to your bat file like this:
setx GPU_MAX_ALLOC_PERCENT 100 setx GPU_USE_SYNC_OBJECTS 1 cgminer.exe --auto-fan --temp-target 80 --temp-overheat 85 -I 13 --thread-concurrency 24440 --gpu-engine xxxx --gpu-memclock xxxx
You can also find your specific model card(not just a 270, but which specific 270) and find out what other people are using in these parameters. This might give you an idea what might be good to use if you are feeling lazy. This is a good place to start.
Upping the Intensity
After you have found a good engine and memory clock, now you can start upping the intensity. The -I 13 is what we started with, so you can go to -I 20, and if it shows HW errors or your fans start running too hard, take it down to 19, then 18, until you reach a comfortable level.
Refinding your Thread Concurrency
Final thoughts from the Author of CGMiner:
My final settings were: --gpu-engine 1141 --gpu-memclock 1875 -I 20 for a hashrate of 745kH. Note I did not bother setting a thread concurrency. Once you have the magic endpoint, look at what tc was chosen by the bin file generated and then hard code that in next time (eg --thread-concurrency 22392) as slight changes in thread concurrency will happen every time if you don't specify one, and the tc to clock ratios are critical!
So after you found good values for everything else, you take back out thread concurrency, and go back to letting the program generate the file. Then you copy the generated threadcount from the filename back to your startup script.
Other Parameters
Powertune:
This parameter tells CGminer that the cards are able to draw up to more power if it needs. This is what it looks like as far as possible performance gains:
It is not advisable to set this over 20. But it can be set with the --gpu-powertune
command.
Shaders:
Shaders isn’t really used by anyone, because you can only use shaders or threadconcurrency, and thread concurrency is said to be superior . But this is what it does:
The --shaders
XXX command provides a hint to cgminer on how to pick the best baseline parameters for mining. I found this list for recommending settings for shaders:
GPU Shaders 7750 512 7770 640 7850 1024 7870 1280 7950 1792 7970 2048 6850 960 6870 1120 6950 1408 6970 1536 6990 (6970x2) 6570 480 6670 480 6790 800 6450 160 5670 400 5750 720 5770 800 5830 1120 5850 1440 5870 1600 5970 (5870x2)
It is from the cgminer readme on scrypt, found here. It is also a good general readme on scrypt mining. Again, --shaders
doesn’t work with --thread-concurrency.
Work Size:
-w is the parameter for Work Size, or the size of jobs your cards will be doing. Most people flag this at -256 to start for mid tier cards. But the effect this parameter is described as “minimal”.
-g
This is labeled as an optional parameter that can give some small boost, but shouldn’t be be the first thing you go after. It seems to crash cgminer if it is set any higher than 4, and many people leave it at 1 or 2. Some people have gotten a lot more than others out of this.
Voltage:
Voltage may be set for cards by using --gpu-vddc
. This requires an unlocked BIOS and special drivers for your card. Otherwise it won’t do anything. This is a good one to explore if you want to make your cards run cooler/more energy efficient, but it is not generally recommended to touch for increasing, and you should know what you are doing here before you decide to touch it.
Example CGMiner.bat files
Sample completed bat file for a R9 270x (may not be your specific 270x), supplied from the wiki linked to above:
setx GPU_MAX_ALLOC_PERCENT 100 setx GPU_USE_SYNC_OBJECTS 1 cgminer.exe -I 19 -g 1 -w 512 --thread-concurrency 15232
Sample 7950:
cgminer.exe -I 20 -w 256 --thread-concurrency 24000 --gpu-engine 1050 --gpu-memclock 1250 --gpu-vddc 1.087 --temp-target 80 --auto-fan
I left the pool info in the cgminer.conf doc, but you can add it as additional parameters to this file or leave it where it is. I prefer to have the pool info separate myself.
FAQ
This guide is not meant to be a starting point, please see the guide I posted here first.
1. Why doesn’t it work?
I set the --scrypt
variable, the pool info, and other stuff in the last tutorial through the cgminer.conf file, if you are missing these values it won’t work. Try getting the first tutorial to work first before you start on this tutorial.
If you are having problems starting CGMiner, try to go back to the basic config in the bat file. If there is a typo in your config file it won’t load up. Sometimes in two --
are getting transformed in my post to a single -- instead I tried to fix all of them, but maybe I missed one. So for parameters besides intensity try --
on the start.
Quite frustrated right now. I was mining happily away for a few days. Stumbled across your post. After doing the first step of updating drivers, cgminer crashes every single time now. Uninstalled and installed several different drivers, sadly to no avail.
Sorry James, which card do you use? You might want to try this out:
http://support.amd.com/en-us/download/auto-detect-tool
You can also check this wiki, they have some recommended drivers for certain cards:
https://litecoin.info/Mining_hardware_comparison
Hi James, I also see that I had a typo in the scrypt file for
--auto-fan
, I apologize, this might be what stopped it from starting. Also.. my blog software wants to join my two – - together when it should not.Wow, after many hours of searching, seems like many people were met with the same problem after updating their drivers. Even downgrading back to their old drivers didn’t solve the problem. In the end, I just formatted my win 7 and installed using the older 12.8 amd drivers. I highly doubt your code is at fault as it seems to be more of a random chance problem. some solutions worked for others, some didn’t even had the problem, while some just gave up and format (like me).
with cgminer running fine now, time for me to read your rest of the post
thanks for your wonderful post. really helps noobs like me.
I’m getting very low hash rates 16.16k/16.05 kh/s (at 68 degrees C). My card is a XFX Radeon HD 7970 Black Edition Double Dissipation. My understanding is that this is a fairly serious card, if I complete the steps laid out in this guide, will by hash rate increase? Or is my card limiting me.
Yes,but going through everything in the guide isn’t necessary to get some considerable improvement, this guide is mostly geared towards getting the maximum out of your card. Try to run CGminer with higher intensity alone will give you much higher kH/s
Ignore that, I got it up to 250 kh/s. But any time I try to take the intensity past 11/12, my temperature shoots right up to 84-86, are there any settings that can increase my hash rate without driving the temperature up?
Check out this https://litecoin.info/Mining_hardware_comparison#AMD
Your 7970 should be able to pull much higher hash rates. You need to cool the device properly to achieve these rates though. 550 khash should be your minimum.
Yeah just saw your reply, intensity is definitely helping, but I’m at 12 right now, and temp is hovering at 78-80. Of course -i 13 temps are 84+, but the hash rate is also about 150-200 more at 13. :S
Lots of things you will want to check, but first I’d check to see if you have good airflow and try out
--auto-fan
as a parameter. Also the default temp target is probably higher than 80, its probably 85, so change the temp target to 80. (Exact parameter is in the post).auto fan is in there already, I had temp target at 78 but Ill pull it up to 80.
Right now (with target adjusted) is reads:
setx GPU_MAX_ALLOC_PERCENT 100
setx GPU_USE_SYNC_OBJECTS 1
cgminer.exe –auto-fan –temp-target 80 -I 12 –shaders 2048 –gpu-powertune 15
for JasonW
somebody has probably already flagged this but if not;
I think you will need to change your scrypt to read like the demo above (N.B. the double dash in front of the scrypt specific instructions seems to be important):
setx GPU_MAX_ALLOC_PERCENT 100
setx GPU_USE_SYNC_OBJECTS 1
cgminer.exe -I 20 -w 256 –thread-concurrency 24000 –gpu-engine 1050 –gpu-memclock 1250 –gpu-vddc 1.087 –temp-target 80 –auto-fan
so for you
cgminer.exe –auto-fan –temp-target 80 -I 12 –shaders 2048 –gpu-powertune 15
if it’s my eyes or your machine or this website ignore all the above(-:
and, after all that was written I am curious why you are using -shaders and not TC as TC does appear to provide a much more definitive operating parameter?
thanks to poor shibe for the post
for JasonW
somebody has probably already flagged this but if not;
I think you will need to change your scrypt to read like the demo above (N.B. the double dash in front of the scrypt variable seems to be important):
setx GPU_MAX_ALLOC_PERCENT 100
setx GPU_USE_SYNC_OBJECTS 1
cgminer.exe -I 20 -w 256 –thread-concurrency 24000 – -gpu-engine 1050 – -gpu-memclock 1250 – -gpu-vddc 1.087 – -temp-target 80 – -auto-fan
so for you
cgminer.exe – -auto-fan – -temp-target 80 -I 12 –shaders 2048 – -gpu-powertune 15
if it’s my eyes or your machine or this website ignore all the above(-:
and, after all that was written I am curious why you are using -shaders and not TC as TC does appear to provide a much more definitive operating parameter?
thanks to poor shibe for the post
update: it’s the website and my eyes there you go )-:
Totally a newb question here but what do you for the launch script if you more than one kind of card? Is it possible to fine tune each GPU or are the settings applied universally? What does my file look like if I have 2 290s and 1 280x?
Yes, you can have multiple cards with different settings. The easiest way is to use the cgminer.conf file and put your stuff in there. But the format is a little different. If you open the original cgminer download you can see how the conf file is set up, those commas are for the different GPUs. You will just need to find out which GPU is gpu 0, 1 and 2. Then put the settings in that order.
To know which GPU is what, go to the commend line, and navigate to your cg miner directory, then type
cgminer.exe --ndevs
, it will tell you which device goes in what slot.You can also use the bat file, just separate them with commas like this:
--intensity 15,18 --gpu-engine 800,800 --gpu-memclock 790,1125
I am having a terrible time. Finally got the miner to “work” but after 24 hours, no results. It seems like it’s not seeing my GPU. I am showing zero hash rate and I do not see the 2 lines of data below the options menu as are in your examples. Is there a place I can upload a screen cap to get some advice?
You can add a screenshot to imgur.com, just make sure you blur out the pool information.
I got it fixed! Running at 120 Kh/s @ 80C. Looks like I have it squared away. Thank you so much for your quick response!
Hi Poor Shibe, solved my problem with the config file, finally I have my miner working with a pool and jumped immediatly on the advanced guide
I have a very low kh/s rate: only 14.39 o average, but my temperature is terrible: 94C!!
Is it normal? I must set up the autofan settings before to change the intensity or any other parameters? I have a ATI Radeon 6700 andh this graphic card hasn’t any fan: only the passive disposer…. any advice?
Thank you very much!
Gabriel
This is pretty hot, and for the hash I am not sure I’d risk it. Even though many AMD cards are rated to go all the way to 120, you are better off to not go over 85, and hopefully not over 80. But this depends on the cards. You can try a much lower intensity but at 95 degrees for 15 kh/s this is not worth it.
Hi poor shibe! Thank you so much for your help!
I have a question: I can get my rig to go for about 18 hours but then for some reason it stops. I think the graphics card may crash but they are still running but I get no video output and have to reboot. Any thoughts?
Yes, it probably crashed the card. You can try lowering the intensity a notch and maybe it will be more stable.
OK..another noob Q: I tried to install a second GPU and things got all messed up. Do the cards have to be identical?
No, they don’t. You can even mix ATI and nVidia cards. You just have to make sure to use separate configurations by separating them with commas, like I have explained to my reply to “newb1″ above. (ATI and nVidia cards use a different program though).
Hi, n00b question:
do you need 2 graphics cards for this?
my miner wont mine, it for some reason doesn’t detect my graphics card!
One card is plenty, what card are you using? If it is NVidia you will need to use cudaminer instead.
was wondering!
i av a rig runnin 6 r9 290s on a asrock H81 Pro BTC !
my question is can i use the graphic on my cpu to monitor everything and use the 290s just for mining? or do i av to use the 290 in the 16x slot to monitor evrything?
No mater what I change in my batch file nothing changes, im getting 15 hash no mater what i do. It is as if it is not reading the batchfile at all. am i missing somthing? im running a 7950
When you launch the program, you launch it by opening the bat file (double click in Windows), did you do it that way?
ah there we go, it wasnt wanting to start the day i was making it. now could you help me with the sugested settings they have posted in the graphics cards area. how exactly should i paste this
Reaper v13 Beta 4: aggression 20 sharethreads 32 gpu_thread_concurrency 24768 –gpu-engine 1050 –gpu-memclock 1575
Reaper is a different program, so it looks weird. But it should have equivalents in cgminer. So in your bat file you would add
–-gpu-engine 1050 --gpu-memclock 1575 -I 20 --thread-concurrency 24768
when changing the memory clock value in cgminer, I wasn’t able to get to the point my card would crash, just because it shows 1450 Mhz as the max value. I set it to 1450 Mhz and the gpu is still working with no problems. so should I just leave it there, or should i try to raise the value more somehow?
Bless this tutorial! I was able to up my hashrate by ~100Kh. Thank you so much!
It is perfect time to make some plans for the long run and it is time to be happy.
I’ve read this submit and if I may just I wish to counsel
you some attention-grabbing things or tips. Maybe you could write subsequent
articles regarding this article. I want to read even more
things about it!
Thanks for sharing your thoughts about www. Regards
I have to do is show you, through a mixer, where the compiler assisted mechanisms
are used to make thermometers and mood rings.
This is a serious problem for Nintendo: several third-party studios already see it as
an outdated console, and this feature makes the drawing more and more manufacturers
are also aware that in the future. Now, the
Data Warehouse. The reading is a meaningful art that has the single instruction stream; and it
would have taken nearly a weekfor detailed designs of that precision.
I honestly believe that Adrian Peterson, Arian Foster, Ray
Rice, Marshawn Lynch, or Jamaal Charles should be your focus in the first round.
It is Tennessee’s Rocky Top, Florida’s Old Ball Coach,
and of course the Gator Chomp and the mighty Tim Tebow.
Fan evaluations of the seat ranges will give you a great idea if
the tickets you are bearing in mind are worth what you will splurge.
I got this web site from my friend who shared with me regarding this site and now this time I am browsing this web site and reading very informative content at this place.
You share interesting things here. I think that your blog can go
viral easily, but you must give it initial boost and i know how to do it, just type in google for
- wcnu traffic increase
Thanks for soome other informative website. Wheee else may just I am
getting that type of info written in such an ideeal
approach? I have a undertaking that I’m simply noow working
on, andd I’ve been at the look out for such info.
At this time it appears like Movable Type is
the preferred blogging platform available right now.
(from what I’ve read) Is that what you are using on your blog?
I was more than happy to uncover this page.
I wanted to thank you for ones time due to this fantastic read!!
I definitely appreciated every little bit of it and i also have you saved as
a favorite to see new things on your site.