Pastebin launched a little side project called VERYVIRAL.com, check it out ;-) Want more features on Pastebin? Sign Up, it's FREE!
Guest

Untitled

By: a guest on Nov 18th, 2013  |  syntax: None  |  size: 40.35 KB  |  views: 164  |  expires: Never
download  |  raw  |  embed  |  report abuse  |  print
Text below is selected. Please press Ctrl+C to copy to your clipboard. (⌘+C on Mac)
  1. BFGMiner:
  2. St. Barbara's Faithfully Glorified Mining Initiative Naturally Exceeding Rivals
  3. or Basically a Freaking Good Miner
  4.  
  5. This is a multi-threaded multi-pool ASIC, FPGA, GPU and CPU miner with dynamic
  6. clocking, monitoring, and fanspeed support for bitcoin. Do not use on multiple
  7. block chains at the same time!
  8.  
  9. This code is provided entirely free of charge by the programmer in his spare
  10. time so donations would be greatly appreciated. Please consider donating to the
  11. address below.
  12.  
  13. Luke-Jr <luke-jr+bfgminer@utopios.org>
  14. 1QATWksNFGeUJCWBrN4g6hGM178Lovm7Wh
  15.  
  16. DOWNLOADS:
  17.  
  18. http://luke.dashjr.org/programs/bitcoin/files/bfgminer
  19.  
  20. GIT TREE:
  21.  
  22. https://github.com/luke-jr/bfgminer
  23.  
  24. Bug reports:
  25.  
  26. https://github.com/luke-jr/bfgminer/issues
  27.  
  28. IRC Channel:
  29.  
  30. irc://irc.freenode.net/eligius
  31.  
  32. License: GPLv3.  See COPYING for details.
  33.  
  34. SEE ALSO README.ASIC, README.FPGA, README.GPU, README.RPC, AND README.scrypt FOR
  35. MORE INFORMATION ON EACH.
  36.  
  37. ---
  38.  
  39. EXECUTIVE SUMMARY ON USAGE:
  40.  
  41. Single pool:
  42.  
  43. bfgminer -o http://pool:port -u username -p password
  44.  
  45. Multiple pools:
  46.  
  47. bfgminer -o http://pool1:port -u pool1username -p pool1password -o http://pool2:port -u pool2usernmae -p pool2password
  48.  
  49. Single pool with a standard http proxy:
  50.  
  51. bfgminer -o http://pool:port -x http://proxy:port -u username -p password
  52.  
  53. Single pool with a socks5 proxy:
  54.  
  55. bfgminer -o http://pool:port -x socks5://proxy:port -u username -p password
  56.  
  57. The list of proxy types are:
  58.  http:    standard http 1.1 proxy
  59.  socks4:  socks4 proxy
  60.  socks5:  socks5 proxy
  61.  socks4a: socks4a proxy
  62.  socks5h: socks5 proxy using a hostname
  63.  
  64. Proxy support requires cURL version 7.21.7 or newer.
  65.  
  66. If you specify the --socks-proxy option to BFGMiner, it will only be applied to
  67. all pools that don't specify their own proxy setting like above
  68.  
  69.  
  70. After saving configuration from the menu, you do not need to give BFGMiner any
  71. arguments, it will load your configuration instead.
  72.  
  73. Any configuration file may also contain a single
  74.         "include" : "filename"
  75. to recursively include another configuration file.
  76. Writing the configuration will save all settings from all files to the output
  77. configuration file.
  78.  
  79.  
  80. ---
  81. BUILDING BFGMINER
  82.  
  83. Everything you probably want, condensed:
  84.         build-essential autoconf automake libtool pkg-config libcurl4-gnutls-dev
  85.         libjansson-dev uthash-dev libncursesw5-dev libudev-dev libusb-1.0-0-dev
  86.         libevent-dev libmicrohttpd-dev hidapi
  87.  
  88. Dependencies:
  89.         autoconf             http://www.gnu.org/software/autoconf/
  90.         automake             http://www.gnu.org/software/automake/
  91.         libtool              http://www.gnu.org/software/libtool/
  92.         pkg-config           http://www.freedesktop.org/wiki/Software/pkg-config
  93.         ...or pkgconf        https://github.com/pkgconf/pkgconf
  94.  
  95.         libcurl4-gnutls-dev  http://curl.haxx.se/libcurl/
  96.  
  97.         libjansson-dev 2.0+  http://www.digip.org/jansson/
  98.        
  99.         uthash-dev 1.9.2+    http://troydhanson.github.io/uthash/
  100.  
  101. Optional Dependencies:
  102.         Text-User-Interface (TUI): curses dev library; any one of:
  103.           libncurses5-dev    http://www.gnu.org/software/ncurses/ (Linux and Mac)
  104.           libncursesw5-dev       ^ same
  105.           libpdcurses        http://pdcurses.sourceforge.net/ (Linux/Mac/Windows)
  106.  
  107.         Multiple ASIC/FPGA autodetection: any one of:
  108.           sysfs              (built-in to most Linux kernels, just mount on /sys)
  109.           libudev-dev        http://www.freedesktop.org/software/systemd/libudev/
  110.        
  111.         HashBuster & NanoFury USB devices:
  112.           hidapi             https://github.com/signal11/hidapi
  113.        
  114.         getwork server for Block Erupter Blades:
  115.           libmicrohttpd-dev 0.9.5+  http://www.gnu.org/software/libmicrohttpd/
  116.        
  117.         Stratum proxy:
  118.           libevent 2.0.3+    http://libevent.org/
  119.  
  120.         Klondike, X6500 and ZTEX FPGA boards:
  121.           libusb-1.0-0-dev   http://www.libusb.org/
  122.  
  123.         Video card GPU mining (free):
  124.           llvm 3.3+          http://llvm.org/
  125.           clang 3.3+         http://clang.llvm.org/
  126.           libclc             http://libclc.llvm.org/
  127.           Mesa 9.2.0+        http://www.mesa3d.org/
  128.        
  129.         ATi/AMD video card GPU mining (non-free):
  130.           AMD APP SDK        http://developer.amd.com/tools/heterogeneous-computing/amd-accelerated-parallel-processing-app-sdk/
  131.  
  132.         CPU mining optimized assembly algorithms:
  133.           yasm 1.0.1+        http://yasm.tortall.net/
  134.  
  135.  
  136. BFGMiner specific configuration options:
  137.         --disable-avalon        Compile support for Avalon (default enabled)
  138.         --enable-cpumining      Build with cpu mining support(default disabled)
  139.         --disable-opencl        Build without support for OpenCL (default enabled)
  140.         --disable-adl           Build without ADL monitoring (default enabled)
  141.         --disable-bitfury       Compile support for Bitfury (default enabled)
  142.         --enable-bfsb           Compile support for BFSB (default disabled)
  143.         --disable-bigpic        Compile support for Big Picture Mining USB (default
  144.                                 enabled)
  145.         --disable-littlefury    Compile support for LittleFury (default enabled)
  146.         --disable-nanofury      Compile support for NanoFury (default enabled)
  147.         --enable-metabank       Compile support for Metabank (default disabled)
  148.         --disable-bitforce      Compile support for BitForce (default enabled)
  149.         --disable-icarus        Compile support for Icarus (default enabled)
  150.         --enable-klondike       Compile support for Klondike (default disabled)
  151.         --enable-knc            Compile support for KnC (default disabled)
  152.         --disable-modminer      Compile support for ModMiner (default enabled)
  153.         --disable-x6500         Compile support for X6500 (default enabled)
  154.         --disable-ztex          Compile support for ZTEX (default if libusb)
  155.         --enable-scrypt         Compile support for scrypt mining (default disabled)
  156.         --with-system-libblkmaker  Use system libblkmaker rather than bundled one
  157.                                    (default disabled)
  158.         --without-sensors       Build with libsensors monitoring (default enabled)
  159.         --without-curses        Compile support for curses TUI (default enabled)
  160.         --without-libmicrohttpd Compile support for libmicrohttpd getwork server
  161.                                 (default enabled)
  162.         --without-libudev       Autodetect FPGAs using libudev (default enabled)
  163.  
  164. Basic *nix build instructions:
  165.  
  166. ./autogen.sh    # only needed if building from git repo
  167. ./configure
  168. make
  169.  
  170. No installation is necessary. You may run BFGMiner from the build directory
  171. directly.
  172.  
  173. On Mac OS X, you can use Homebrew to install the dependency libraries. When you
  174. are ready to build BFGMiner, you may need to point the configure script at one
  175. or more pkg-config paths. For example:
  176.         ./configure PKG_CONFIG_PATH=/usr/local/opt/curl/lib/pkgconfig:/usr/local/opt/jansson/lib/pkgconfig
  177.  
  178. Native WIN32 build instructions: see windows-build.txt
  179.  
  180. If you build BFGMiner from source, it is recommended that you run it from the
  181. build directory. On *nix, you will usually need to prepend your command with a
  182. path like this (if you are in the bfgminer directory already): ./bfgminer
  183.  
  184. ---
  185.  
  186. Usage instructions:  Run "bfgminer --help" to see options:
  187.  
  188. Usage: bfgminer [-DdElmpPQqUsTouOchnV]
  189.  
  190. Options for both config file and command line:
  191. --api-allow         Allow API access (if enabled) only to the given list of [W:]IP[/Prefix] address[/subnets]
  192.                     This overrides --api-network and you must specify 127.0.0.1 if it is required
  193.                     W: in front of the IP address gives that address privileged access to all api commands
  194. --api-description   Description placed in the API status header (default: BFGMiner version)
  195. --api-groups        API one letter groups G:cmd:cmd[,P:cmd:*...]
  196.                     See README.RPC for usage
  197. --api-listen        Listen for API requests (default: disabled)
  198.                     By default any command that does not just display data returns access denied
  199.                     See --api-allow to overcome this
  200. --api-mcast         Enable API Multicast listener, default: disabled
  201. --api-mcast-addr <arg> API Multicast listen address (default: "224.0.0.75")
  202. --api-mcast-code <arg> Code expected in the API Multicast message, don't use '-' (default: "FTW")
  203. --api-mcast-port <arg> API Multicast listen port (default: 4028)
  204. --api-network       Allow API (if enabled) to listen on/for any address (default: only 127.0.0.1)
  205. --api-port          Port number of miner API (default: 4028)
  206. --balance           Change multipool strategy from failover to even share balance
  207. --benchmark         Run BFGMiner in benchmark mode - produces no shares
  208. --chroot-dir <arg>  Chroot to a directory right after startup
  209. --cmd-idle <arg>    Execute a command when a device is allowed to be idle (rest or wait)
  210. --cmd-sick <arg>    Execute a command when a device is declared sick
  211. --cmd-dead <arg>    Execute a command when a device is declared dead
  212. --coinbase-addr <arg> Set coinbase payout address for solo mining
  213. --coinbase-sig <arg> Set coinbase signature when possible
  214. --compact           Use compact display without per device statistics
  215. --debug|-D          Enable debug output
  216. --debuglog          Enable debug logging
  217. --device|-d <arg>   Enable only devices matching pattern (default: all)
  218. --disable-rejecting Automatically disable pools that continually reject shares
  219. --http-port <arg>   Port number to listen on for HTTP getwork miners (-1 means disabled) (default: -1)
  220. --expiry|-E <arg>   Upper bound on how many seconds after getting work we consider a share from it stale (w/o longpoll active) (default: 120)
  221. --expiry-lp <arg>   Upper bound on how many seconds after getting work we consider a share from it stale (with longpoll active) (default: 3600)
  222. --failover-only     Don't leak work to backup pools when primary pool is lagging
  223. --force-dev-init    Always initialize devices when possible (such as bitstream uploads to some FPGAs)
  224. --kernel-path|-K <arg> Specify a path to where bitstream and kernel files are (default: "/usr/local/bin")
  225. --load-balance      Change multipool strategy from failover to quota based balance
  226. --log|-l <arg>      Interval in seconds between log output (default: 5)
  227. --log-file|-L <arg> Append log file for output messages
  228. --log-microseconds  Include microseconds in log output
  229. --monitor|-m <arg>  Use custom pipe cmd for output messages
  230. --net-delay         Impose small delays in networking to avoid overloading slow routers
  231. --no-gbt            Disable getblocktemplate support
  232. --no-getwork        Disable getwork support
  233. --no-longpoll       Disable X-Long-Polling support
  234. --no-restart        Do not attempt to restart devices that hang
  235. --no-stratum        Disable Stratum detection
  236. --no-submit-stale   Don't submit shares if they are detected as stale
  237. --no-opencl-binaries Don't attempt to use or save OpenCL kernel binaries
  238. --no-unicode        Don't use Unicode characters in TUI
  239. --noncelog <arg>    Create log of all nonces found
  240. --pass|-p <arg>     Password for bitcoin JSON-RPC server
  241. --per-device-stats  Force verbose mode and output per-device statistics
  242. --pool-proxy|-x     Proxy URI to use for connecting to just the previous-defined pool
  243. --protocol-dump|-P  Verbose dump of protocol-level activities
  244. --queue|-Q <arg>    Minimum number of work items to have queued (0 - 10) (default: 1)
  245. --quiet|-q          Disable logging output, display status and errors
  246. --real-quiet        Disable all output
  247. --remove-disabled   Remove disabled devices entirely, as if they didn't exist
  248. --request-diff <arg> Request a specific difficulty from pools (default: 1.0)
  249. --retries <arg>     Number of times to retry failed submissions before giving up (-1 means never) (default: -1)
  250. --rotate <arg>      Change multipool strategy from failover to regularly rotate at N minutes (default: 0)
  251. --round-robin       Change multipool strategy from failover to round robin on failure
  252. --scan-time|-s <arg> Upper bound on time spent scanning current work, in seconds (default: 60)
  253. --sched-start <arg> Set a time of day in HH:MM to start mining (a once off without a stop time)
  254. --sched-stop <arg>  Set a time of day in HH:MM to stop mining (will quit without a start time)
  255. --scrypt            Use the scrypt algorithm for mining (non-bitcoin)
  256. --set-device <arg>  Set default parameters on devices; eg, NFY:osc6_bits=50
  257. --setuid <arg>      Username of an unprivileged user to run as
  258. --sharelog <arg>    Append share log to file
  259. --shares <arg>      Quit after mining N shares (default: unlimited)
  260. --show-processors   Show per processor statistics in summary
  261. --skip-security-checks <arg> Skip security checks sometimes to save bandwidth; only check 1/<arg>th of the time (default: never skip)
  262. --socks-proxy <arg> Set socks proxy (host:port) for all pools without a proxy specified
  263. --stratum-port <arg> Port number to listen on for stratum miners (-1 means disabled) (default: -1)
  264. --submit-threads    Minimum number of concurrent share submissions (default: 64)
  265. --syslog            Use system log for output messages (default: standard error)
  266. --temp-cutoff <arg> Maximum temperature devices will be allowed to reach before being disabled, one value or comma separated list
  267. --temp-hysteresis <arg> Set how much the temperature can fluctuate outside limits when automanaging speeds (default: 3)
  268. --temp-target <arg> Target temperature when automatically managing fan and clock speeds
  269. --text-only|-T      Disable ncurses formatted screen output
  270. --unicode           Use Unicode characters in TUI
  271. --url|-o <arg>      URL for bitcoin JSON-RPC server
  272. --user|-u <arg>     Username for bitcoin JSON-RPC server
  273. --verbose           Log verbose output to stderr as well as status output
  274. --userpass|-O <arg> Username:Password pair for bitcoin JSON-RPC server
  275. Options for command line only:
  276. --config|-c <arg>   Load a JSON-format configuration file
  277. See example.conf for an example configuration.
  278. --help|-h           Print this message
  279. --version|-V        Display version and exit
  280.  
  281.  
  282. GPU only options:
  283.  
  284. --auto-fan          Automatically adjust all GPU fan speeds to maintain a target temperature
  285. --auto-gpu          Automatically adjust all GPU engine clock speeds to maintain a target temperature
  286. --gpu-threads|-g <arg> Number of threads per GPU (1 - 10) (default: 2)
  287. --gpu-dyninterval <arg> Set the refresh interval in ms for GPUs using dynamic intensity (default: 7)
  288. --gpu-engine <arg>  GPU engine (over)clock range in MHz - one value, range and/or comma separated list (e.g. 850-900,900,750-850)
  289. --gpu-fan <arg>     GPU fan percentage range - one value, range and/or comma separated list (e.g. 25-85,85,65)
  290. --gpu-map <arg>     Map OpenCL to ADL device order manually, paired CSV (e.g. 1:0,2:1 maps OpenCL 1 to ADL 0, 2 to 1)
  291. --gpu-memclock <arg> Set the GPU memory (over)clock in MHz - one value for all or separate by commas for per card.
  292. --gpu-memdiff <arg> Set a fixed difference in clock speed between the GPU and memory in auto-gpu mode
  293. --gpu-platform <arg> Select OpenCL platform ID to use for GPU mining
  294. --gpu-powertune <arg> Set the GPU powertune percentage - one value for all or separate by commas for per card.
  295. --gpu-reorder       Attempt to reorder GPU devices according to PCI Bus ID
  296. --gpu-vddc <arg>    Set the GPU voltage in Volts - one value for all or separate by commas for per card.
  297. --intensity|-I <arg> Intensity of GPU scanning (d or -10 -> 10, default: d to maintain desktop interactivity)
  298. --kernel|-k <arg>   Override kernel to use (diablo, poclbm, phatk or diakgcn) - one value or comma separated
  299. --ndevs|-n          Enumerate number of detected GPUs and exit
  300. --no-adl            Disable the ATI display library used for monitoring and setting GPU parameters
  301. --temp-overheat <arg> Overheat temperature when automatically managing fan and GPU speeds (default: 85)
  302. --vectors|-v <arg>  Override detected optimal vector (1, 2 or 4) - one value or comma separated list
  303. --worksize|-w <arg> Override detected optimal worksize - one value or comma separated list
  304.  
  305. GPU mining is disabled by default for SHA256d if you have any dedicated mining
  306. devices, but can be enabled explicitly specifying the -S opencl:auto option.
  307.  
  308. See README.GPU for more information regarding GPU mining.
  309.  
  310. scrypt only options:
  311.  
  312. --lookup-gap <arg>  Set GPU lookup gap for scrypt mining, comma separated
  313. --shaders <arg>     GPU shaders per card for tuning scrypt, comma separated
  314. --thread-concurrency <arg> Set GPU thread concurrency for scrypt mining, comma separated
  315.  
  316. See README.scrypt for more information regarding (non-bitcoin) scrypt mining.
  317.  
  318. ASIC/FPGA mining device options:
  319.  
  320. --scan-serial|-S <arg> Serial port to probe for mining devices
  321.  
  322. To use ASICs or FPGAs, you will need to be sure the user BFGMiner is running as
  323. has appropriate permissions. This varies by operating system.
  324. On Gentoo: sudo usermod <username> -a -G uucp
  325. On Ubuntu: sudo usermod <username> -a -G dialout
  326. Note that on GNU/Linux systems, you will usually need to login again before
  327. group changes take effect.
  328.  
  329. By default, BFGMiner will scan for autodetected devices. If you want to prevent
  330. BFGMiner from doing this, you can use "-S noauto". If you want to probe all
  331. serial ports, you can use "-S all"; note that this may write data to non-mining
  332. devices which may then behave in unexpected ways!
  333.  
  334. On Linux, <arg> is usually of the format /dev/ttyUSBn
  335. On Mac OS X, <arg> is usually of the format /dev/cu.usb*
  336. On Windows, <arg> is usually of the format \\.\COMn
  337. (where n = the correct device number for the device)
  338.  
  339. The official supplied binaries are compiled with support for all ASICs/FPGAs.
  340. To force the code to only attempt detection with a specific driver,
  341. prepend the argument with the driver name followed by a colon.
  342. For example, "icarus:/dev/ttyUSB0" or "bitforce:\\.\COM5"
  343. or using the short name: "ica:/dev/ttyUSB0" or "bfl:\\.\COM5"
  344.  
  345. Some FPGAs do not have non-volatile storage for their bitstreams and must be
  346. programmed every power cycle, including first use. To use these devices, you
  347. must download the proper bitstream from the vendor's website and copy it to the
  348. "bitstreams" directory into your BFGMiner application directory.
  349.  
  350. See README.ASIC and README.FPGA for more information regarding these.
  351.  
  352. CPU only options (not included in binaries):
  353.  
  354. --algo|-a <arg>     Specify sha256 implementation for CPU mining:
  355.         fastauto*       Quick benchmark at startup to pick a working algorithm
  356.         auto            Benchmark at startup and pick fastest algorithm
  357.         c               Linux kernel sha256, implemented in C
  358.         4way            tcatm's 4-way SSE2 implementation
  359.         via             VIA padlock implementation
  360.         cryptopp        Crypto++ C/C++ implementation
  361.         cryptopp_asm32  Crypto++ 32-bit assembler implementation
  362.         sse2_32         SSE2 32 bit implementation for i386 machines
  363.         sse2_64         SSE2 64 bit implementation for x86_64 machines
  364.         sse4_64         SSE4.1 64 bit implementation for x86_64 machines
  365.         altivec_4way    Altivec implementation for PowerPC G4 and G5 machines
  366. --cpu-threads|-t <arg> Number of miner CPU threads (default: 4)
  367.  
  368.  
  369. ---
  370.  
  371. WHILE RUNNING:
  372.  
  373. The following options are available while running with a single keypress:
  374.  
  375. [M]anage devices [P]ool management [S]ettings [D]isplay options  [H]elp [Q]uit
  376.  
  377. M gives you something like:
  378.  
  379. Select processor to manage using up/down arrow keys
  380.  BFL 0a: 78.0C |  3.64/ 3.70/ 2.91Gh/s | A:46 R:0+0(none) HW:  2/none
  381.   BitFORCE SHA256 SC from Butterfly Labs
  382. Serial: FTWN6T67
  383.  
  384. [D]isable
  385. Or press Enter when done
  386.  
  387.  
  388. P gives you:
  389.  
  390. Current pool management strategy: Failover
  391. [F]ailover only disabled
  392. [A]dd pool [R]emove pool [D]isable pool [E]nable pool
  393. [C]hange management strategy [S]witch pool [I]nformation
  394.  
  395.  
  396. S gives you:
  397.  
  398. [L]ongpoll: On
  399. [Q]ueue: 1
  400. [S]cantime: 60
  401. [E]xpiry: 120
  402. [R]etries: -1
  403. [W]rite config file
  404. [B]FGMiner restart
  405.  
  406.  
  407. D gives you:
  408.  
  409. [N]ormal [C]lear [S]ilent mode (disable all output)
  410. [D]ebug:off
  411. [P]er-device:off
  412. [Q]uiet:off
  413. [V]erbose:off
  414. [R]PC debug:off
  415. [W]orkTime details:off
  416. co[M]pact: off
  417. [L]og interval:5
  418.  
  419.  
  420. Q quits the application.
  421.  
  422.  
  423. The running log shows output similar to that below:
  424.  
  425.  [2013-02-13 00:26:30] Accepted 1758e8df BFL 0  pool 0 Diff 10/1
  426.  [2013-02-13 00:26:32] Accepted 1d9a2199 MMQ 0a pool 0 Diff 8/1
  427.  [2013-02-13 00:26:33] Accepted b1304924 ZTX 0  pool 0 Diff 1/1
  428.  [2013-02-13 00:26:33] Accepted c3ad22f4 XBS 0b pool 0 Diff 1/1
  429.  
  430. The 8 byte hex value are the 2nd set of 32 bits from the share submitted to the
  431. pool. The 2 diff values are the actual difficulty target that share reached
  432. followed by the difficulty target the pool is currently asking for.
  433.  
  434. ---
  435. Also many issues and FAQs are covered in the forum threads
  436. dedicated to this program,
  437.         https://bitcointalk.org/?topic=78192
  438.         https://bitcointalk.org/?topic=168174
  439.  
  440. The block display shows:
  441. Block: ...1b89f8d3 #217364  Diff:7.67M (54.93Th/s)  Started: [17:17:22]
  442.  
  443. This shows a short stretch of the current block, the next block's height and
  444. difficulty (including the network hashrate that difficulty represents), and when
  445. the search for the new block started.
  446.  
  447. The BFGMiner status line shows:
  448.  ST:1  F:0  NB:1  AS:0  BW:[ 75/241 B/s]  E:2.42  I:12.99mBTC/hr  BS:2.71k
  449.  
  450. ST is STaged work items (ready to use).
  451. F  is network Failure occasions (server down or slow to provide work)
  452. NB is New Blocks detected on the network
  453. AS is Active Submissions (shares in the process of submitting)
  454. BW is BandWidth usage on the network (received/sent)
  455. E  is Efficiency defined as number of shares accepted (multiplied by their
  456.           difficulty) per 2 KB of bandwidth
  457. I  is expected Income, calculated by actual shares submitted in 100% PPS value
  458.           (assumes Bitcoin, does not account for altcoin conversions!)
  459. BS is the all time Best Share difficulty you've found
  460.  
  461. The totals line shows the following:
  462.  6/32   75.0C | 171.3/170.8/171.2Gh/s | A:729 R:8+0(.01%) HW:0/.81%
  463.  
  464. Each column is as follows:
  465.   The number of devices and processors currently mining
  466.   Hottest temperature reported by any processor
  467.   5 second exponentially decaying average hash rate
  468.   An all time average hash rate
  469.   An all time average hash rate based on actual nonces found, adjusted for pool
  470.       reject and stale rate
  471.   The number of Accepted shares
  472.   The number of Rejected shares and stale shares discarded (never submitted),
  473.       and the percentage these are of total found.
  474.   The number of HardWare errors, and percentage invalid of nonces returned
  475.  
  476. Each device shows:
  477.  BFL 2: 74.0C | 51.97/58.90/57.17Gh/s | A:847 R:15+0(.54%) HW:496/.91%
  478.  
  479. Columns are the same as in the totals line.
  480.  
  481.  
  482. ---
  483. MULTIPOOL
  484.  
  485. FAILOVER STRATEGIES WITH MULTIPOOL:
  486. A number of different strategies for dealing with multipool setups are
  487. available. Each has their advantages and disadvantages so multiple strategies
  488. are available by user choice, as per the following list:
  489.  
  490. FAILOVER:
  491. The default strategy is failover. This means that if you input a number of
  492. pools, it will try to use them as a priority list, moving away from the 1st
  493. to the 2nd, 2nd to 3rd and so on. If any of the earlier pools recover, it will
  494. move back to the higher priority ones.
  495.  
  496. ROUND ROBIN:
  497. This strategy only moves from one pool to the next when the current one falls
  498. idle and makes no attempt to move otherwise.
  499.  
  500. ROTATE:
  501. This strategy moves at user-defined intervals from one active pool to the next,
  502. skipping pools that are idle.
  503.  
  504. LOAD BALANCE:
  505. This strategy sends work to all the pools on a quota basis. By default, all
  506. pools are allocated equal quotas unless specified with --quota. This
  507. apportioning of work is based on work handed out, not shares returned so is
  508. independent of difficulty targets or rejected shares. While a pool is disabled
  509. or dead, its quota is dropped until it is re-enabled. Quotas are forward
  510. looking, so if the quota is changed on the fly, it only affects future work.
  511. If all pools are set to zero quota or all pools with quota are dead, it will
  512. fall back to a failover mode. See quota below for more information.
  513.  
  514. The failover-only flag has special meaning in combination with load-balance
  515. mode and it will distribute quota back to priority pool 0 from any pools that
  516. are unable to provide work for any reason so as to maintain quota ratios
  517. between the rest of the pools.
  518.  
  519. BALANCE:
  520. This strategy monitors the amount of difficulty 1 shares solved for each pool
  521. and uses it as a basis for trying to doing the same amount of work for each
  522. pool.
  523.  
  524.  
  525. ---
  526. SOLO MINING
  527.  
  528. BFGMiner supports solo mining with any GBT-compatible bitcoin node (such as
  529. bitcoind). To use this mode, you need to specify the URL of your bitcoind node
  530. using the usual pool options (--url, --userpass, etc), and the --coinbase-addr
  531. option to specify the Bitcoin address you wish to receive the block rewards
  532. mined. If you are solo mining with more than one instance of BFGMiner (or any
  533. other software) per payout address, you must also specify data using the
  534. --coinbase-sig option to ensure each miner is working on unique work. Note
  535. that this data will be publicly seen if your miner finds a block using any
  536. GBT-enabled pool, even when not solo mining (such as failover). If your
  537. bitcoin node does not support longpolling (for example, bitcoind 0.8.x), you
  538. should consider setting up a failover pool to provide you with block
  539. notifications. Note that solo mining does not use shares, so BFGMiner's adjusted
  540. hashrate (third column) may suddenly drop to zero if a block you submit is
  541. rejected; this does not indicate that it has stopped mining.
  542.  
  543. Example solo mining usage:
  544.  
  545. bfgminer -o http://localhost:8332 -u username -p password \
  546.     --coinbase-addr 1QATWksNFGeUJCWBrN4g6hGM178Lovm7Wh \
  547.     --coinbase-sig "rig1: This is Joe's block!"
  548.  
  549.  
  550. ---
  551. QUOTAS
  552.  
  553. The load-balance multipool strategy works off a quota based scheduler. The
  554. quotas handed out by default are equal, but the user is allowed to specify any
  555. arbitrary ratio of quotas. For example, if all the quota values add up to 100,
  556. each quota value will be a percentage, but if 2 pools are specified and pool0
  557. is given a quota of 1 and pool1 is given a quota of 9, pool0 will get 10% of
  558. the work and pool1 will get 90%. Quotas can be changed on the fly with RPC,
  559. and do not act retrospectively. Setting a quota to zero will effectively
  560. disable that pool unless all other pools are disabled or dead. In that
  561. scenario, load-balance falls back to regular failover priority-based strategy.
  562. While a pool is dead, it loses its quota and no attempt is made to catch up
  563. when it comes back to life.
  564.  
  565. To specify quotas on the command line, pools should be specified with a
  566. semicolon separated --quota(or -U) entry instead of --url. Pools specified with
  567. --url are given a nominal quota value of 1 and entries can be mixed.
  568.  
  569. For example:
  570. --url poola:porta -u usernamea -p passa --quota "2;poolb:portb" -u usernameb -p passb
  571. Will give poola 1/3 of the work and poolb 2/3 of the work.
  572.  
  573. Writing configuration files with quotas is likewise supported. To use the above
  574. quotas in a configuration file they would be specified thus:
  575.  
  576. "pools" : [
  577.         {
  578.                 "url" : "poola:porta",
  579.                 "user" : "usernamea",
  580.                 "pass" : "passa"
  581.         },
  582.         {
  583.                 "quota" : "2;poolb:portb",
  584.                 "user" : "usernameb",
  585.                 "pass" : "passb"
  586.         }
  587. ]
  588.  
  589.  
  590. ---
  591. LOGGING
  592.  
  593. BFGMiner will log to stderr if it detects stderr is being redirected to a file.
  594. To enable logging simply add 2>logfile.txt to your command line and logfile.txt
  595. will contain the logged output at the log level you specify (normal, verbose,
  596. debug etc.)
  597.  
  598. In other words if you would normally use:
  599. ./bfgminer -o xxx -u yyy -p zzz
  600. if you use
  601. ./bfgminer -o xxx -u yyy -p zzz 2>logfile.txt
  602. it will log to a file called logfile.txt and otherwise work the same.
  603.  
  604. There is also the -m option on linux which will spawn a command of your choice
  605. and pipe the output directly to that command.
  606.  
  607. The WorkTime details 'debug' option adds details on the end of each line
  608. displayed for Accepted or Rejected work done. An example would be:
  609.  
  610.  <-00000059.ed4834a3 M:X D:1.0 G:17:02:38:0.405 C:1.855 (2.995) W:3.440 (0.000) S:0.461 R:17:02:47
  611.  
  612. The first 2 hex codes are the previous block hash, the rest are reported in
  613. seconds unless stated otherwise:
  614. The previous hash is followed by the getwork mode used M:X where X is one of
  615. P:Pool, T:Test Pool, L:LP or B:Benchmark,
  616. then D:d.ddd is the difficulty required to get a share from the work,
  617. then G:hh:mm:ss:n.nnn, which is when the getwork or LP was sent to the pool and
  618. the n.nnn is how long it took to reply,
  619. followed by 'O' on its own if it is an original getwork, or 'C:n.nnn' if it was
  620. a clone with n.nnn stating how long after the work was recieved that it was
  621. cloned, (m.mmm) is how long from when the original work was received until work
  622. started,
  623. W:n.nnn is how long the work took to process until it was ready to submit,
  624. (m.mmm) is how long from ready to submit to actually doing the submit, this is
  625. usually 0.000 unless there was a problem with submitting the work,
  626. S:n.nnn is how long it took to submit the completed work and await the reply,
  627. R:hh:mm:ss is the actual time the work submit reply was received
  628.  
  629. If you start BFGMiner with the --sharelog option, you can get detailed
  630. information for each share found. The argument to the option may be "-" for
  631. standard output (not advisable with the ncurses UI), any valid positive number
  632. for that file descriptor, or a filename.
  633.  
  634. To log share data to a file named "share.log", you can use either:
  635. ./bfgminer --sharelog 50 -o xxx -u yyy -p zzz 50>share.log
  636. ./bfgminer --sharelog share.log -o xxx -u yyy -p zzz
  637.  
  638. For every share found, data will be logged in a CSV (Comma Separated Value)
  639. format:
  640.     timestamp,disposition,target,pool,dev,thr,sharehash,sharedata
  641. For example (this is wrapped, but it's all on one line for real):
  642.     1335313090,reject,
  643.     ffffffffffffffffffffffffffffffffffffffffffffffffffffffff00000000,
  644.     http://localhost:8337,GPU0,0,
  645.     6f983c918f3299b58febf95ec4d0c7094ed634bc13754553ec34fc3800000000,
  646.     00000001a0980aff4ce4a96d53f4b89a2d5f0e765c978640fe24372a000001c5
  647.     000000004a4366808f81d44f26df3d69d7dc4b3473385930462d9ab707b50498
  648.     f681634a4f1f63d01a0cd43fb338000000000080000000000000000000000000
  649.     0000000000000000000000000000000000000000000000000000000080020000
  650.  
  651. ---
  652.  
  653. RPC API
  654.  
  655. For RPC API details see the README.RPC file
  656.  
  657. ---
  658.  
  659. FAQ
  660.  
  661. Q: Why can't BFGMiner find lib<something> even after I installed it from source
  662. code?
  663. A: On UNIX-like operating systems, you often need to run one or more commands to
  664. reload library caches, such as "ldconfig" or similar. A couple of systems (such
  665. as Fedora) ship with /usr/local/lib missing from their library search path. In
  666. this case, you can usually add it like this:
  667.     echo /usr/local/lib >/etc/ld.so.conf.d/local.conf
  668. Please note that if your libraries installed into lib64 instead of lib, you
  669. should use that in the ld.so config file above instead.
  670.  
  671. Q: BFGMiner segfaults when I change my shell window size.
  672. A: Older versions of libncurses have a bug to do with refreshing a window
  673. after a size change. Upgrading to a new version of curses will fix it.
  674.  
  675. Q: Can I mine on servers from different networks (eg smartcoin and bitcoin) at
  676. the same time?
  677. A: No, BFGMiner keeps a database of the block it's working on to ensure it does
  678. not work on stale blocks, and having different blocks from two networks would
  679. make it invalidate the work from each other.
  680.  
  681. Q: Can I configure BFGMiner to mine with different login credentials or pools
  682. for each separate device?
  683. A: No such feature has been implemented to support this.
  684.  
  685. Q: Can I put multiple pools in the config file?
  686. A: Yes, check the example.conf file. Alternatively, set up everything either on
  687. the command line or via the menu after startup and choose settings->write
  688. config file and the file will be loaded one each startup.
  689.  
  690. Q: The build fails with gcc is unable to build a binary.
  691. A: Remove the "-march=native" component of your CFLAGS as your version of GCC
  692. does not support it.
  693.  
  694. Q: Can you implement feature X?
  695. A: I can, but time is limited, and people who donate are more likely to get
  696. their feature requests implemented.
  697.  
  698. Q: Work keeps going to my backup pool even though my primary pool hasn't
  699. failed?
  700. A: BFGMiner checks for conditions where the primary pool is lagging and will
  701. pass some work to the backup servers under those conditions. The reason for
  702. doing this is to try its absolute best to keep the devices working on something
  703. useful and not risk idle periods. You can disable this behaviour with the
  704. option --failover-only.
  705.  
  706. Q: Is this a virus?
  707. A: As BFGMiner is being packaged with other trojan scripts, some antivirus
  708. software is falsely accusing bfgminer.exe as being the actual virus, rather than
  709. whatever it is being packaged with. If you installed BFGMiner yourself from a
  710. reputable source then you do not have a virus on your computer. Complain to your
  711. antivirus software company. They seem to be flagging even source code from
  712. BFGMiner as malicious now, even though text source files can't do anything by
  713. themselves.
  714.  
  715. Q: Can you modify the display to include more of one thing in the output and
  716. less of another, or can you change the quiet mode or can you add yet another
  717. output mode?
  718. A: Everyone will always have their own view of what is important to monitor.
  719. The defaults are very sane and I have very little interest in changing this
  720. any further.
  721.  
  722. Q: Why is my efficiency above/below 1.00?
  723. A: Efficiency simply means how many shares you return for the amount of
  724. bandwidth used. It does not correlate with efficient use of your hardware, and
  725. is a measure of a combination of hardware speed, block luck, pool design and
  726. many other factors.
  727.  
  728. Q: What are the best parameters to pass for X pool/hardware/device.
  729. A: Virtually always, the DEFAULT parameters give the best results. Most user
  730. defined settings lead to worse performance.
  731.  
  732. Q: What happened to CPU mining?
  733. A: Being increasingly irrelevant for most users, and a maintenance issue, it is
  734. no longer under active development and will not be supported unless someone
  735. steps up to help maintain it. No binary builds supporting CPU mining will be
  736. released for Windows but CPU mining can be built into BFGMiner when it is
  737. compiled. For builds which do support CPU mining, it is still disabled by
  738. default, and must be enabled using the -S cpu:auto option.
  739.  
  740. Q: Will there ever be a GUI version?
  741. A: No, however the RPC interface makes it possible for someone else to write one
  742. if they choose.
  743.  
  744. Q: I'm having an issue. What debugging information should I provide?
  745. A: Start BFGMiner with your regular commands and add -D -T --verbose and provide
  746. the full startup output and a summary of your hardware, operating system, and if
  747. applicable, ATI driver version and ATI stream version.
  748.  
  749. Q: Can I mine with BFGMiner on a Mac?
  750. A: BFGMiner will compile on OS X, but the performance of GPU mining is
  751. compromised due to the OpenCL implementation on OS X, there is no temperature or
  752. fanspeed monitoring and the cooling design of most Macs, despite having
  753. powerful GPUs, will usually not cope with constant usage leading to a high risk
  754. of thermal damage. It is highly recommended not to mine on a Mac unless it is
  755. with an external USB device.
  756.  
  757. Q: My network gets slower and slower and then dies for a minute?
  758. A; Try the --net-delay option if you are on a getwork or GBT server.
  759.  
  760. Q: How do I tune for P2Pool?
  761. A: P2Pool has very rapid expiration of work and new blocks, it is suggested you
  762. decrease intensity by 1 from your optimal value, and decrease GPU threads to 1
  763. with -g 1. It is also recommended to use --failover-only since the work is
  764. effectively like a different block chain. If mining with a Mini Rig, it is worth
  765. adding the --bfl-range option.
  766.  
  767. Q: Are OpenCL kernels from other mining software useable in BFGMiner?
  768. A: No, the APIs are slightly different between the different software and they
  769. will not work.
  770.  
  771. Q: I run PHP on windows to access the API with the example miner.php. Why does
  772. it fail when php is installed properly but I only get errors about Sockets not
  773. working in the logs?
  774. A: Please check http://us.php.net/manual/en/sockets.installation.php
  775.  
  776. Q: What is a PGA?
  777. A: At the moment, BFGMiner supports 5 FPGAs: BitForce, Icarus, ModMiner, X6500,
  778. and ZTEX.
  779. They are Field-Programmable Gate Arrays that have been programmed to do Bitcoin
  780. mining. Since the acronym needs to be only 3 characters, the "Field-" part has
  781. been skipped. "PGA" is also used for devices built with Application-Specific
  782. Integrated Circuits (ASICs).
  783.  
  784. Q: What is an ASIC?
  785. A: They are Application Specify Integrated Circuit devices and provide the
  786. highest performance per unit power due to being dedicated to only one purpose.
  787.  
  788. Q: How do I get my BFL/Icarus/Lancelot/Cairnsmore device to auto-recognise?
  789. A: On Linux, if the /dev/ttyUSB* devices don't automatically appear, the only
  790. thing that needs to be done is to load the driver for them:
  791.   BitForce:   sudo modprobe ftdi_sio vendor=0x0403 product=0x6014
  792.   Erupter:    sudo modprobe cp210x   vendor=0x10c4 product=0xea60
  793.   Icarus:     sudo modprobe pl2303   vendor=0x067b product=0x0230
  794.   Lancelot:   sudo modprobe ftdi_sio vendor=0x0403 product=0x6001
  795.   Cairnsmore: sudo modprobe ftdi_sio vendor=0x0403 product=0x8350
  796. On some systems you must manally install the driver required for the device.
  797. OpenWrt drivers (install with opkg):
  798.   FTDI:       kmod-usb-serial-ftdi
  799.   Erupter:    kmod-usb-serial-cp210x
  800.   Icarus:     kmod-usb-serial-pl2303
  801. Windows drivers:
  802.   FTDI:       http://www.ftdichip.com/Drivers/VCP.htm
  803.   Erupter:    http://www.silabs.com/products/mcu/pages/usbtouartbridgevcpdrivers.aspx
  804.   Icarus:     http://prolificusa.com/pl-2303hx-drivers/
  805.  
  806. Q: I ran cgminer, and now BFGMiner doesn't work!
  807. A: cgminer has its own non-standard implementations of the drivers for most USB
  808. devices, and requires you to replace the official drivers with WinUSB on Windows
  809. (usually using Zadig). Before you can use BFGMiner, you will need to restore the
  810. original driver. Removing the device from Device Manager and re-plugging it will
  811. usually trigger driver re-installation to the default drivers.
  812.  
  813. Q: On Linux I can see the /dev/ttyUSB* devices for my ICA/BFL/MMQ FPGA, but
  814. BFGMiner can't mine on them?
  815. A: Make sure you have the required privileges to access the /dev/ttyUSB*
  816. devices:
  817.  sudo ls -las /dev/ttyUSB*
  818. will give output like:
  819.  0 crw-rw---- 1 root dialout 188, 0 2012-09-11 13:49 /dev/ttyUSB0
  820. This means your account must have the group 'dialout' or root privileges
  821. To permanently give your account the 'dialout' group:
  822.  sudo usermod -G dialout -a `whoami`
  823. Then logout and back in again
  824.  
  825. Q: Can I mine scrypt with FPGAs or ASICs?
  826. A: Currently no. Bitcoin ASICs are only useful for SHA256d systems and FPGAs
  827. generally aren't designed to handle scrypt efficiently.
  828.  
  829. Q: Why does BFGMiner show difficulty 0 when mining scrypt?
  830. A: BFGMiner consistently uses pdiff measurement for difficulty everywhere,
  831. rather than other measurements that may exist. For scrypt, pdiff 1 is very
  832. difficult, and higher get exponentially harder. It is unlikely you will want to
  833. use pdiff 1+ with scrypt until you have FPGAs and/or ASICs for it.
  834.  
  835. Q: What is stratum and how do I use it?
  836. A: Stratum is a protocol designed to reduce resources for mining pools at the
  837. cost of keeping the miner in the dark and blindly transferring his mining
  838. authority to the pool. It is a return to the problems of the old centralized
  839. "getwork" protocol, but capable of scaling to hardware of any speed like the
  840. standard GBT protocol. If a pool uses stratum instead of GBT, BFGMiner will
  841. automatically detect it and switch to the support as advertised if it can.
  842. Stratum uses direct TCP connections to the pool and thus it will NOT currently
  843. work through a http proxy but will work via a socks proxy if you need to use
  844. one. If you input the stratum port directly into your configuration, or use the
  845. special prefix "stratum+tcp://" instead of "http://", BFGMiner will ONLY try to
  846. use stratum protocol mining.
  847.  
  848. Q: Why don't the statistics add up: Accepted, Rejected, Stale, Hardware Errors,
  849. Diff1 Work, etc. when mining greater than 1 difficulty shares?
  850. A: As an example, if you look at 'Difficulty Accepted' in the RPC API, the number
  851. of difficulty shares accepted does not usually exactly equal the amount of work
  852. done to find them. If you are mining at 8 difficulty, then you would expect on
  853. average to find one 8 difficulty share, per 8 single difficulty shares found.
  854. However, the number is actually random and converges over time as it is an
  855. average, not an exact value, thus you may find more or less than the expected
  856. average.
  857.  
  858. ---
  859.  
  860. This code is provided entirely free of charge by the programmer in his spare
  861. time so donations would be greatly appreciated. Please consider donating to the
  862. address below.
  863.  
  864. Luke-Jr <luke-jr+bfgminer@utopios.org>
  865. 1QATWksNFGeUJCWBrN4g6hGM178Lovm7Wh