Configure Settings cgminer


Now we can create a configuration file to store the settings we'll use with cgminer.
Create the file and begin editing it by entering the following command:
Copy Code
  1. sudo nano cgminer.conf
Update the below template with your mining pool credentials by replacing "PoolAddress:Port", "UserName.WorkerName", and "Password" with your info, then copy & paste into the nano editor:
Copy Code
  1. {
  2. "pools" : [
  3. {
  4. "url" : "PoolAddress:Port",
  5. "user" : "UserName.WorkerName",
  6. "pass" : "Password"
  7. }
  8. ]
  9. ,
  10. "api-listen" : true,
  11. "api-port" : "4028",
  12. "expiry" : "120",
  13. "failover-only" : true,
  14. "log" : "5",
  15. "no-pool-disable" : true,
  16. "queue" : "2",
  17. "scan-time" : "60",
  18. "worktime" : true,
  19. "shares" : "0",
  20. "kernel-path" : "/usr/local/bin",
  21. "api-allow" : "0/0",
  22. "icarus-options" : "115200:1:1",
  23. "icarus-timing" : "3.0=100"
  24. }
The above lines containing "icarus" were included for Block Erupter USB devices, be sure to update them if you are using a different mining device!
For example, if you mine using Slush's pool you would replace "PoolAddress:Port", with:
Copy Code
  1. "http://stratum.bitcoin.cz:3333",
Once you've updated and pasted the above text, do the following:

  1. press ctl+x to begin exiting the file
  2. press y to confirm changes
  3. press return to save the file
Settings are now saved. We'll reference them later when starting cgminer.