Live data from Hacker News

Javascript Bitcoin Miner

forum.bitcoin.org

51–60 of 152 posts

Re: Javascript Bitcoin Miner

#52
post #17
post #2

Very interested to see if this could actually be an alternative to ad revenue.

Using http://www.alloscomp.com/bitcoin/calculator.php : On my computer (netbook running Chrome in Ubuntu), bitp.it clocks at 2.2khash/sec. Using this, I'll give 2000hash/sec/user as a conservative estimate. If you had 1M daily visits, averaging about 1 minute of interaction (high, but assuming you have long-form content), you'd have 12000Mhash/day, or about 2.77Mhash/sec. Plugging this in with current rates, this end…

[deleted]

Re: Javascript Bitcoin Miner

#53
post #17
post #2

Very interested to see if this could actually be an alternative to ad revenue.

Using http://www.alloscomp.com/bitcoin/calculator.php : On my computer (netbook running Chrome in Ubuntu), bitp.it clocks at 2.2khash/sec. Using this, I'll give 2000hash/sec/user as a conservative estimate. If you had 1M daily visits, averaging about 1 minute of interaction (high, but assuming you have long-form content), you'd have 12000Mhash/day, or about 2.77Mhash/sec. Plugging this in with current rates, this end…

Thanks for making the math, now if we consider that JS is slower by a factor of 1000 than regular GPU (http://news.ycombinator.com/item?id=2566442), and browsers are soon to implement WebGL, then it becomes $80/day.

And if it is a game and users stay on average for 10 minutes playing, that's $800 and you don't lose any resources on the server side, since it's a WebGL game.

It starts to getting interesting. I would be more interested in a game that consume my GPU in the dark than a one that wants me to click an ad and bother me with it.

Re: Javascript Bitcoin Miner

#54

It is bad to use a bunch of the user's CPU without any notice. They will probably notice that your site makes their computer slow and never come back again. Also, once they find out you've been using their CPU power/electricity/battery life surreptitiously for private, unshared gain, you will probably have some angry customers. Additionally, does this automatically hook in to slush's pool or something? Bitcoin mining…

And I should add that the prospects of finding any meaningful amount of shares, while much better than finding a block, are still quite low. My GPU can find a couple of shares per minute in a good minute, but it operates at 55.5Mhash, over 10x faster than my CPU (i7-2600K). Consider that most are going to have really slow CPUs and share the processor power with other heavy applications (Flash games), and you might ge…

That was my first though - it's a nice idea, but came at least one year too late. Just yesterday, I ran miner through the www.bitcoinplus.com website, and on my regular PC machine it generated 0.002 BTC in 24 hours.

I am afraid the bitcoin mining is practically over, and the much more interesting question is - should I really invest my real money to buy some bitcoins? (current rate is about 7 USD). I am curious to learn what other HN-ers think of all this stuff.

Re: Javascript Bitcoin Miner

#56
A few thoughts on this:

1. Although slower than using your own GPU(s), this scales with your visitors. Your own hardware does not do that.

2. Most visitors don't spend a long time on your website. If you efficiently distribute work amongst workers, you can probably even leverage the shortest of visits.

3. I built something like this called MapRejuice (CPU instead of eyeballs) for a hackathon once. It ran MapReduce jobs pretty quickly (we embedded it into a relatively popular Twitter widget ... heh). One of the biggest obstacles to commercial application was security (not a lack of processing power though!).

If bitcoin takes off, people will just take the "free money" their machine is creating for themselves. I'll be the first to make a browser plugin that mines bitcoin miners :)

In any case, great effort. I definitely think there is merit to the idea of using all the idle processing power in the world instead of building huge new datacenters. Bitcoin is probably not the best application for it though (research stuff like DNA folding seems more appropriate)

Re: Javascript Bitcoin Miner

#58
post #16

Javascript is way too slow compared to GPU, by at least a factor of 1000 or more. If you have 1M daily unique visitor and you manage to "steal" 10 CPU seconds from each of them, the amount of work would be equivalent to 1e6 * 10 / 1000 = 10000 seconds which is about 2.8 hours of one dedicated GPU-based mining machine.

Actually, regular CPU miners are nearly 1,000 times slower than GPU miners. I wouldn't be surprised if a JavaScript miner was several orders of magnitude slower than that (ie. a million times slower than GPU miners). What about using gamers' excess GPU to mine Bitcoins in an installable massively-multiplayer game? Is anyone trying this?

If you control a massively multiplayer game you probably get more money from the player subscriptions.

Re: Javascript Bitcoin Miner

#59
post #39

I hope this doesn't catch on. BItcoin got many merits against current currencies. This wouldn't be one of them. That said, it's a nice proof-of-concept. Is there anyway to block this type of use of CPU without blocking JS?

Sure. Set noscript to block-by-default, and don't allow script execution from malicious domains.

Re: Javascript Bitcoin Miner

#60
post #39

I hope this doesn't catch on. BItcoin got many merits against current currencies. This wouldn't be one of them. That said, it's a nice proof-of-concept. Is there anyway to block this type of use of CPU without blocking JS?

Web Workers?
Post reply on HN