Bitcoin Forum
July 20, 2018, 03:19:32 PM *
News: Latest stable version of Bitcoin Core: 0.16.1  [Torrent]. (New!)
 
   Home   Help Search Donate Login Register  
Pages: 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 [All]
  Print  
Author Topic: CKPOOL - Open source pool/proxy/passthrough/redirector/library in c for Linux  (Read 102888 times)
-ck
Moderator
Legendary
*
Offline Offline

Activity: 2590
Merit: 1111


Ruu \o/


View Profile WWW
September 21, 2014, 12:02:38 AM
Merited by ezeminer (7), HagssFIN (1)
 #1

CKPOOL + libckpool by the cgminer development team.

Ultra low overhead massively scalable multi-process, multi-threaded modular
bitcoin mining pool, proxy, passthrough, library and database interface in c
for Linux.

ckpool code by ckolivas / -ck
ckdb code by kano

Note that as maintainer of ckpool am FOR segwit and AGAINST Emergent Consensus.

Source code downloads:

https://bitbucket.org/ckolivas/ckpool

Current release status: Beta v0.94, from git source only.

IRC channel: irc://irc.freenode.net/ckpool

LICENSE: GNU Public license V3. See included COPYING for details.

About ckpool: https://bitcointalk.org/index.php?topic=790323.msg8907250#msg8907250

About ckdb: https://bitcointalk.org/index.php?topic=790323.msg8907583#msg8907583

About ckproxy: https://bitcointalk.org/index.php?topic=790323.msg8907589#msg8907589

About libckpool: https://bitcointalk.org/index.php?topic=790323.msg8907597#msg8907597

About ckpmsg: https://bitcointalk.org/index.php?topic=790323.msg8907597#msg8907597

About notifier: https://bitcointalk.org/index.php?topic=790323.msg8907597#msg8907597

Building: https://bitcointalk.org/index.php?topic=790323.msg8907600#msg8907600

Configuration: https://bitcointalk.org/index.php?topic=790323.msg8907601#msg8907601

Stratum extensions: https://bitcointalk.org/index.php?topic=790323.msg8907604#msg8907604

FAQs: https://bitcointalk.org/index.php?topic=790323.msg8908863#msg8908863

Discussion/Future directions: https://bitcointalk.org/index.php?topic=790323.msg8908866#msg8908866



List of current ckpools:

http://www.kano.is
http://hashmine.io (private for now)
http://solo.ckpool.org (anonymous solo mining)
http://testnet.ckpool.org (testnet only)

Primary developer/maintainer for cgminer and ckpool/ckproxy.
ZERO FEE Pooled mining at ckpool.org 1% Fee Solo mining at solo.ckpool.org
-ck
Advertised sites are not endorsed by the Bitcoin Forum. They may be unsafe, untrustworthy, or illegal in your jurisdiction. Advertise here.
1532099972
Hero Member
*
Offline Offline

Posts: 1532099972

View Profile Personal Message (Offline)

Ignore
1532099972
Reply with quote  #2

1532099972
Report to moderator
1532099972
Hero Member
*
Offline Offline

Posts: 1532099972

View Profile Personal Message (Offline)

Ignore
1532099972
Reply with quote  #2

1532099972
Report to moderator
1532099972
Hero Member
*
Offline Offline

Posts: 1532099972

View Profile Personal Message (Offline)

Ignore
1532099972
Reply with quote  #2

1532099972
Report to moderator
-ck
Moderator
Legendary
*
Offline Offline

Activity: 2590
Merit: 1111


Ruu \o/


View Profile WWW
September 21, 2014, 12:20:20 AM
 #2

About ckpool

Ckpool is a project by the cgminer development team designed to complete the circle between miners and pools from cgminer to ckpool. The bulk of the code work for this was commissioned and paid for, however I provided an incentive to the group commissioning the code to open the software up to all by charging less for free software than for closed code. Ultimately this should benefit bitcoin far more than me simply working on code for another pool. I intentionally chose to write most of the code from the ground up and not use external libraries to have complete control over all the code given past experiences of difficulty to debug failures in library code that was outside our domain with cgminer. The separation of the pool code from the database code allows the pool code to be ultra-scalable and extremely low overhead by dissociating any concept of share counts, user accounts, authentication, front ends, payschemes etc. etc. These can be as vastly different from the envisioned ckdb+postgresql+php interface as the administrator desires without any change to the core pool functionality.


Rationale:

The aim of this project is to provide the most low overhead, massively scalable pool software available by creating the code from the ground up using the same programming techniques and tools as those used when the author codes for the linux kernel. It was decided early on that to speed development and maintain consistent behaviour that only Linux would be supported. Even with massive numbers of miners, the core ckpool code uses very little CPU and only 100s of megabytes of ram.

We aim to remove the dependency of pool owners on custom software and the requirement for massive hardware infrastructure to run a stable and performant mining pool, thus dramatically lowering the barrier for entry for more pools to be created. In the process, we also aim to be providing tools to allow large mining farms to mine for themselves instead of directing their power to a large pool which would otherwise make them even larger and risking the security of the bitcoin network. While it may seem counter to the small miner's benefit to make large miners capable of running their own pool, it is an acceptance of where the bulk of the mining power is coming from and not make that mining power a risk to bitcoin. By providing them with software to mine in a manner that isn't designed to just mine blocks quickly but does so in a way that can lay down all transactions currently in flight without detriment to their block generating capacity, this will benefit the bitcoin network far more than them adding their hashes to a large pool.

Despite the pool software being provided to large miners to run standalone, the bulk of the development effort was actually directed to providing a reliable consistent and performing pooled mining solution (in the traditional pooled mining sense) with a stratum mining module at the core of the miner's experience that is not hindered in its ability to serve any sized miners with expedience and to create a platform for expanding on the existing stratum design as the need arises. As the core is modular in design, there is scope for plugging in extra components in the future as desired. Also as the same code is used by the pool software, the optional proxy included, the associated library, and the developers maintain the code at both ends, there is assurance the two ends will talk optimally.


DESIGN:

Architecture:

- Low level hand coded architecture relying on minimal outside libraries beyond
basic glibc functions for maximum flexibility and minimal overhead that can be
built and deployed on any Linux installation.
- Multiprocess+multithreaded design to scale to massive deployments and
capitalise on modern multicore/multithread CPU designs.
- Minimal memory overhead.
- Utilises ultra reliable unix sockets for communication with dependent
processes.
- Modular code design to streamline further development.
- Standalone library code that can be utilised independently of ckpool.
- Same code can be deployed in many different modes designed to talk to each
other on the same machine, local lan or remote internet locations.


Modes of deployment:
- Comprehensive pooled mining solution with a postgresql database interface.
- Passthrough node(s) that combine connections to a single socket which can
be used to scale to millions of clients and allow the main pool to be isolated
from direct communication with clients.
- Proxy nodes with a database that act as a single client to the upstream pool
while storing full client data of their own.
- Simple proxy without the limitations of hashrate inherent in other proxy
solutions when talking to ckpool.
- Simple pool without a database.
- Library for use by other software.


Features:
- Bitcoind communication to unmodified bitcoind with multiple failover to local
or remote locations.
- Local pool instance worker limited only by operating system resources and
can be made virtually limitless through use of multiple downstream passthrough
nodes.
- Proxy and passthrough modes can set up multiple failover upstream pools.
- Optional share logging.
- Virtually seamless restarts for upgrades through socket handover from exiting
instances to new starting instance.
- Configurable custom coinbase signature.
- Configurable instant starting and minimum difficulty.
- Rapid vardiff adjustment with stable unlimited maximum difficulty handling.
- New work generation on block changes incorporate full bitcoind transaction
set without delay or requiring to send transactionless work to miners thereby
providing the best bitcoin network support and rewarding miners with the most
transaction fees.
- Event driven communication based on communication readiness preventing
slow communicating clients from delaying low latency ones.
- Stratum messaging system to running clients.
- Accurate pool and per client statistics.
- Multiple named instances can be run concurrently on the same machine.


Processes:
When ckpool is run, a number of separate processes are spawned in order to capitalise on multi-core CPUs by offloading dedicated tasks to one process at a time in order to not allow any one process to slow any other. They talk to each other using unix sockets which by only talking on the local system cannot be influenced by the outside world.

The processes generated are:

The main process, AKA listener - this is the core process that listens for incoming requests from an admin socket and watches the running of the child processes.

The generator - this process is designed to only talk to bitcoind to generate work templates, check the current block hashes, check bitcoin addresses, submit block solves, or in proxy mode talks to an upstream stratum server to emulate generation of work. This also runs a watchdog thread to check the running of the upstream bitcoind/or upstream stratum pool and can perform failover should the bitcoind fail for whatever reason.

The connector - this process accepts incoming connections from miners, handling requests for new worker connections, receiving and sending data to the miners. It does this in an event driven manner with multiple send/receive/listen threads, automatically prioritising sends to downstream miners according to their readiness to receive data, thus preventing any one worker affecting any others.

The stratifier - this is the core stratum code implementation that receives data from the connector and runs multiple threads to create work templates, process incoming data, check for valid work, queue outgoing data, authenticate new users, and optionally talks to the ckdb process to store all manner of data for running a full database based pool.

Each process runs additional threads to perform logging in a queued manner that does not hinder the underlying running code.


Advantages to miners:

A stratum implementation with extremely rapid and accurate adjustment of diff to an optimal value both up and down in diff per worker.
Once diff has stabilised, it is extremely rare for diff to be adjusted again unless you add or remove hashes.
Diff is actually properly associated with work templates which means you don't "leak" rejected low diff shares when the diff changes.
Stable diff levels and proper work association with diff leads to lower rates of rejects.
Very rapid block propagation support to all miners means all miners get notification of, and work on, the latest block work as quickly as possible to not waste work.
No extra work restart messages for the inefficient zero-transaction work that other pool software means much less lost work.
Hashrates should hold much more stable at higher levels as a result of all these benefits.
Reconnect support: If you have temporary glitches in your networking, ckpool supports resuming and accepting of valid cached shares.
Messaging: Miners watching their console will see stratum messages as sent to them by the pool (such as block solves).
Virtually no downtime for pool restart: Pool restarts only register as an interruption and then reconnect instead of failing over to backup pools due to the unique socket handover mechanism in use.
Rewards: Maximum rewards are guaranteed by incorporating transactions into every work template instead of mining transaction-less blocks.
Confidence: Improving the bitcoin network through seamless transaction processing increases the confidence in bitcoin in general allowing expansion of the bitcoin network in terms of numbers of transactions and block sizes.
Code auditing: With the ckpool code all freely available, miners are able to audit the code for themselves.
Transaction auditing: Ckpool automatically includes transaction hash reporting to enable auditing of mining work for miners/auditors that request it.

Primary developer/maintainer for cgminer and ckpool/ckproxy.
ZERO FEE Pooled mining at ckpool.org 1% Fee Solo mining at solo.ckpool.org
-ck
kano
Legendary
*
Offline Offline

Activity: 2520
Merit: 1045


Linux since 1997 RedHat 4


View Profile
September 21, 2014, 01:20:52 AM
 #3

About ckdb

Backend database for full user management of ckpool.

Basic concept is a memory resident database with PostgreSQL as the backend DB for permanent storage.
Performance is the priority of ckdb.

Running live and stable on my pool and the hashmine pool.

Still in development ... see the git source code Smiley

Pool: https://kano.is Here on Bitcointalk: Forum BTC: 1KanoPb8cKYqNrswjaA8cRDk4FAS9eDMLU
FreeNode IRC: irc.freenode.net channel #kano.is Majority developer of the ckpool code
Help keep Bitcoin secure by mining on pools with full block verification on all blocks - and NO empty blocks!
-ck
Moderator
Legendary
*
Offline Offline

Activity: 2590
Merit: 1111


Ruu \o/


View Profile WWW
September 21, 2014, 01:21:26 AM
 #4

About ckproxy

Ckproxy uses the same core code as ckpool and acts as a proxy with a simple switch (-p). It acts as a stratum-to-stratum proxy, or stratum-through-stratum proxy in passthrough mode (see below).

It is most useful to regular miners who wish to consolidate their mining hardware into one connection for minimal upstream/downstream bandwidth in standalone mode (with the additional -A switch). Ckproxy uses multiple modes to maintain as many miners as possible communicating with the upstream pool. It works by splitting up nonce2 sizes if the upstream pool's nonce2 is large enough and then it recruits extra upstream connections as needed to allow the number of downstream miners to scale indefinitely.

Ckproxy can be started in "userproxy" mode which monitors login names of miners attaching that don't match the master proxy username and recruits new upstream connections with each unique username, proxying all workers of the same username to the unique upstream proxy connections.

It can be configured to run with a database as per an actual pool entirely, thus acting like a child pool for a parent pool elsewhere, or simply for miners who wish full logging of every detail of their mining operation.

It can also act as a unique stratum-through-stratum passthrough mode which absolutely requires a ckpool as the parent pool with the -P switch. In this mode it does not decrease the bandwidth talking to the upstream pool but minimises the number of open connections instead, but requires extremely low resources to run. This mode is most useful for pools wishing to isolate their main pool instance from the outside world and set up multiple VPSs as a kind of front end proxy/firewall to the outside world. This also removes any realistic limit on the number of open connections since each passthrough instance could easily handle 10k connections, consolidating each into just 1 connection to the upstream pool.

In addition to the passthrough mode, there is a more advanced "node" mode which connects as a passthrough, but needs a local bitcoind connection of its own. It monitors all traffic and shares between the pool and miners, being able to display local hashrates and will submit any blocks found to the local bitcoind in addition to sending the shares to the upstream pool, circumventing the delay of block submission that would otherwise happen with remote nodes.

Finally ckproxy can be started in "redirector" mode which acts as a regular passthrough, but monitors share responses from the upstream pool, and once a valid share is recognised from the upstream pool it will redirect miners that support redirection (all cgminer based clients do) to the URL of your choice. Should the miners not support redirection, such as rental services, ckredirector will continue to act as an ordinary passthrough.

Primary developer/maintainer for cgminer and ckpool/ckproxy.
ZERO FEE Pooled mining at ckpool.org 1% Fee Solo mining at solo.ckpool.org
-ck
-ck
Moderator
Legendary
*
Offline Offline

Activity: 2590
Merit: 1111


Ruu \o/


View Profile WWW
September 21, 2014, 01:23:29 AM
 #5

About libckpool

While not strictly feature complete as a library that can be installed, dynamically linked etc. as per other Linux libraries (yet), libckpool is part of the ckpool suite that is designed to be easily included into other projects without requiring any of the other ckpool code. Any and all functions that can be put into the libckpool.c/h files without being dependent on ckpool are placed there for convenience for others to use in their project, thus benefiting from the many common functions a c/c++ application might need, along with many of the unique ck* functions created for the cgminer and ckpool projects that others might find useful.


About ckpmsg:

When ckpool is run, a series of unix sockets are created: listener, generator, stratifier, connector usually in /tmp/ckpool (though configurable) and ckdb creates its own listener socket in a ckdb directory.

Ckpmsg is a simple application designed to talk locally to the various ckpool/ckdb proceses using the message structure that ckpool expects, usually to the listener socket by default if called with no arguments, looking for ckpool by default but can be aimed at ckproxy (with -p), a named ckpool (with -n) or a user chosen socket directory (with -s). Currently ckpool only accepts a limited number of commands on its listener:

shutdown
restart
loglevel=$val (from 0-7)
ping

It looks for a response to any command sent, and it currently can't distinguish those that will and those that won't return a response so it will complain if none is returned.

Although the same ckpmsg can be used for any of the low level functions within any of the processes, it is expected that admins will mostly be using the simple functions. It can also be used for any number of ckdb queries.


About notifier:

This is an extremely simple binary that is designed to be run with the blocknotify feature of bitcoind. It simply tells ckpool to look for new block information and can be run with the -s option to tell it which socket directory to use to tell ckpool about block updates. Standard usage would be something like:

Create a notify script such as notify.sh:
Code:
#!/bin/bash
/usr/bin/notifier -s /opt

Start bitcoind with blocknotify telling it to call that script:
Code:
bitcoind -daemon -blocknotify=/usr/bin/notify.sh

Using a script as blocknotify allows you to change the script without having to restart bitcoind.

Primary developer/maintainer for cgminer and ckpool/ckproxy.
ZERO FEE Pooled mining at ckpool.org 1% Fee Solo mining at solo.ckpool.org
-ck
-ck
Moderator
Legendary
*
Offline Offline

Activity: 2590
Merit: 1111


Ruu \o/


View Profile WWW
September 21, 2014, 01:23:41 AM
 #6

Building ckpool

Apart from a basic development package installation, as ckpool is mostly hand written without using libraries, it has zero external dependencies. If ckpool is built with ckdb support, only the postgres development library needs to be installed to build it. Most proxy users and simple solo ckpool setups will not require ckdb.


(Note that this is only for a tarball release which does not yet exist):
sudo apt-get install build-essential
./configure --without-ckdb
make


Building with ckdb requires installation of the postgresql development library.

sudo apt-get install build-essential libpq-dev
./configure
make


Building from git also requires autoconf and automake

sudo apt-get install build-essential libpq-dev autoconf automake libtool
./autogen.sh
./configure
make


Binaries will be built in the src/ subdirectory.

Installation is NOT required and ckpool can be run directly from the directory
it's built in but it can be installed with:
sudo make install

Primary developer/maintainer for cgminer and ckpool/ckproxy.
ZERO FEE Pooled mining at ckpool.org 1% Fee Solo mining at solo.ckpool.org
-ck
-ck
Moderator
Legendary
*
Offline Offline

Activity: 2590
Merit: 1111


Ruu \o/


View Profile WWW
September 21, 2014, 01:23:53 AM
 #7

CKPOOL configuration

At least one bitcoind (aka btcd) is mandatory in ckpool mode with the minimum requirements of server, rpcuser and rpcpassword set. If no btcd is set up in the configuration, ckpool will look for a running bitcoind on the local machine on the default port 8332 and the username "user" and password "pass" set up.

At the very least you will need the following lines in your bitcoin.conf file:

Code:
server=1
rpcuser=user
rpcpassword=pass
rpcallowip=127.0.0.1

It is also recommended you start bitcoind with the -blocknotify feature calling the ckpool notifier as described here: https://bitcointalk.org/index.php?topic=790323.msg8907597#msg8907597


Ckpool takes a json encoded configuration file in ckpool.conf by default or ckproxy.conf in proxy or passthrough mode unless specified with -c. Sample configurations for ckpool and ckproxy are included with the source. Entries after the valid json are ignored and the space there can be used for comments.

Sample ckpool.conf file:
Code:
{
"btcd" :  [
        {
                "url" : "localhost:8332",
                "auth" : "user",
                "pass" : "pass",
                "notify" : true
        },
        {
                "url" : "backup:8332",
                "auth" : "user",
                "pass" : "pass",
                "notify" : false
        }
],
"btcaddress" : "14BMjogz69qe8hk9thyzbmR5pg34mVKB1e",
"btcsig" : "/mined by ck/",
"blockpoll" : 100,
"update_interval" : 30,
"serverurl" : "ckpool.org:3333",
"mindiff" : 1,
"startdiff" : 42,
"logdir" : "logs"
}
Comments from here on are ignored.

Sample ckproxy.conf file:
Code:
{
"proxy" :  [
        {
                "url" : "ckpool.org:3333",
                "auth" : "user",
                "pass" : "pass"
        },
        {
                "url" : "backup.ckpool.org:3333",
                "auth" : "user",
                "pass" : "pass"
        }
],
"update_interval" : 30,
"serverurl" : "192.168.1.100:3334",
"mindiff" : 1,
"startdiff" : 42,
"logdir" : "logs"
}
Comments from here on are ignored.
The options recognised are as follows:


"btcd" : This is an array of bitcoind(s) with the options url, auth  and pass
which match the configured bitcoind. This is mandatory in pool mode. The
optional boolean field notify tells ckpool this btcd is using the notifier
and does not need to be polled for block changes.

"proxy" : This is an array in the same format as btcd above but is used in
proxy and passthrough mode to set the upstream pool and is mandatory.

"btcaddress" : This is the bitcoin address to try to generate blocks to.

"btcsig" : This is an optional signature to put into the coinbase of mined
blocks.

"blockpoll" : This is the frequency in milliseconds for how often to check for
new network blocks and is 100 by default. It is intended to be a backup only
for when the notifier is not set up and only polls if the "notify" field is
not set on a btcd.

"update_interval" : This is the frequency that stratum updates are sent out to
miners and is set to 30 seconds by default to help perpetuate transactions for
the health of the bitcoin network.

"serverurl" : This is the IP to try to bind ckpool uniquely to, otherwise it
will attempt to bind to all interfaces in port 3333 by default in pool mode
and 3334 in proxy mode.

"mindiff" : Minimum diff that vardiff will allow miners to drop to. Default 1

"startdiff" : Starting diff that new clients are given. Default 42

"logdir" : Which directory to store pool and client logs. Default "logs"



It is anticipated that pool operators wishing to set up a full database based installation of ckpool+ckdb will be familiar with setting up postgresql and associated permissions to the directories where the various processes will communicate with each other and a web server so these will not be documented.

If you are not capable of setting up and running a database and/or webserver then you should be questioning whether you should be running a public pool or not.

Primary developer/maintainer for cgminer and ckpool/ckproxy.
ZERO FEE Pooled mining at ckpool.org 1% Fee Solo mining at solo.ckpool.org
-ck
-ck
Moderator
Legendary
*
Offline Offline

Activity: 2590
Merit: 1111


Ruu \o/


View Profile WWW
September 21, 2014, 01:24:13 AM
 #8

Stratum extensions:

In addition to support of all the common stratum features, ckpool supports extensions that are either not yet in use, along with its own interpretation of further stratum features as the need arises.

mining.passthrough

This is a unique stratum extension supported only by ckpools upstream and creates a stratum-through-stratum passthrough. It is not intended to be used by miners directly except through the use of the ckpool code itself in passthrough mode for connection combining.

mining.node

This is unique stratum extension supported only by ckpools upstream and creates a stratum-through-stratum passthrough and additionally receives workinfo information from the upstream pool to allow local block submission.

mining.get_transactions

This controversial bandwidth eating feature has been absorbed into ckpool but instead of it handing out the full transactions which are a complete waste of bandwidth, the number of transactions is returned. In addition to supporting the originally documented form with job_id embedded in the method, ckpool will accept the valid json job_id as a single array parameter eg: params: ["$jobid"] .The functionality of the original feature request has been supplanted by the following call instead:

mining.get_txnhashes

Instead of handing out the full transactions incorporated into a job, this version returns only the hashes of the transactions included in each job in a space separated string as the result. The returned hashes are less than 1/10th the bandwidth that returning the full transactions would have amounted to, but is ample information for auditing tools or external authorities to confirm what the running ckpool is working on. This feature is on and rate limited to return only one response per miner per job_id to avoid it becoming a source of DoS. eg:
Code:
{"id": 0, "method": "mining.get_txnhashes", "params":["545198de00000000"]}

mining.suggest_difficulty

Special handling is done for accepting a diff as requested by each mining connection. This is done separately from the per-worker connection so it allows overriding that. When a miner suggests a difficulty, ckpool will allow a slightly lower diff than it would have otherwise chosen, but still will not exceed 30 shares per minute to prevent miners from using this to flood the server with low diff shares.  In addition to supporting the originally documented form where the difficulty was embedded in the method name, ckpool will accept the valid json where the difficulty is a single arrray parameter in params. eg:
Code:
{"id": 2, "method": "mining.suggest_difficulty", "params": [42]}

mining.ping

This is as it says a simple ping sent to or from the miner without parameters. Ideally this would be used to ensure a miner is still alive or to inform the miner that the pool is still alive and ideally they should respond with a result of "pong" (or vice versa). Since most mining software does not currently support this it is not expected to be used for confirmation, although sending data is a good way to ensure a raw socket is still open.

Code:
{"id": 42, "method": "mining.ping", "params": []}

Code:
{"id": 42, "result": "pong", "error": null}

Primary developer/maintainer for cgminer and ckpool/ckproxy.
ZERO FEE Pooled mining at ckpool.org 1% Fee Solo mining at solo.ckpool.org
-ck
-ck
Moderator
Legendary
*
Offline Offline

Activity: 2590
Merit: 1111


Ruu \o/


View Profile WWW
September 21, 2014, 04:46:49 AM
 #9

FAQs

Q: I get permission errors on the sockets?
A: You cannot talk via unix sockets using sudo. Make sure your users have write permissions to the directory where your sockets go. In particular, apache/httpd cannot use /tmp so you will have to choose a different directory such as /opt and give write permission to the user/group that you run ckpool/ckdb as.

Q: System requirements?
A: This depends entirely on the mode of running ckpool and the number of clients you wish to connect to it.
In proxy passthrough mode even a single CPU 32MB ram VPS is enough and requires virtually no disk space.
Standalone proxy mode requires more ram and CPU.
Running a standalone pool without ckdb requires only a few hundred megabytes of ram and will run on about 256MB of ram and at least one virtual CPU if the bitcoind is run on a separate machine (not recommended but doable).
However bitcoind itself usually requires a minimum of 2GB of ram with the wallet disabled and almost 30GB of HD space.
So a recommended setup for a minimal pool with bitcoind would be a 4GB ram 4 virtual CPU without ckdb.
Ckdb however uses a lot of ram due to its nature of having all data memory resident for maximum speed so the ram requirements for a fully featured pool would be at least 16GB ram.

Q: Cross platform / other operating system support?
A: Linux is by far the most proven, tested, deployed server operating system of choice today, and by limiting ourselves to writing for it we are able to use many unique linux features and not have surprise differences in operating system behaviour. When working with low level socket code as ckpool does without a library, the actual operating system behaviour and APIs themselves matter, so it is not worth trying to port them across which is one of the major complaints about the protocol.

Q: What payscheme is it? Paying of orphans? Paying of transactions?
A: This is a choice at a pool operator level and has nothing to do with the core ckpool code. While intrinsically there is code for PPLNS in ckdb, the pay scheme and mechanism is up to the pool operator who sets up the pool with this code.

Q: Why not p2pool as a backend?
A: p2pool as a concept has failed as a scalable concept due to continually marginalising its smallest miners and increasing variance the more miners it has instead of decreasing variance the way a traditional pool does. I have not completely discounted this as a module for ckpool if we can come up with valid workarounds and we are always considering new options. We are instead proposing future development of sibling pools with ckpool to decrease variance by combining rewards from multiple pools into smaller pools. More on this to come.

Q: Other mining protocols?
A: While stratum may not be a perfect mining protocol, the adoption of it as the defacto standard for scalability and its robustness has been well proven. Instead of rewriting the protocol, we believe that a solid implementation is enough to offset any disadvantages to the protocol, and add extensions as the need arises. We support reporting of transaction hashes included in work templates as a security measure for validation by miners and auditors.

Q: GUI?
A: A GUI has no place in the core code of a server or database.

Q: Simple setup tutorial?
A: It is a cinch to set up a simple ckproxy or solo ckpool. If you need help setting up a fully featured pool then you shouldn't be doing it.

Q: Merged mining?
A: Any presumed profit increase from adding virtually worthless altcoins is not worth the disadvantage of introducing far more instability associated with running multiple lesser unstable coin daemons. The running overheads of ckpool should be so small as to allow low fees from pool operators and stability. Some purported free pools with multiple coin support have so much downtime that any extra profit from them is offset by their downtime and poor design.

Q: Altcoins?
A: The author has no interest in support for anything but bitcoin. You are free to modify the code yourself as you see fit, but no altcoin support will ever be merged into the master ckpool code.

Will be added to as the questions arise.

Primary developer/maintainer for cgminer and ckpool/ckproxy.
ZERO FEE Pooled mining at ckpool.org 1% Fee Solo mining at solo.ckpool.org
-ck
-ck
Moderator
Legendary
*
Offline Offline

Activity: 2590
Merit: 1111


Ruu \o/


View Profile WWW
September 21, 2014, 04:46:59 AM
 #10

Discussion/Future direction/Feature requests

At this time the development of the code pool code has been in an extensive testing, debugging and consolidation, having been completed months ago and has had a great deal of real world testing, minting many blocks along the way. The ckdb code is now at completion to the point where public pools can run the code, which is why we're finally able to announce this project. Future features are definitely planned once this consolidation phase is over, and bug reports/adoption/feature requests/code pushes are all to be expected.

The next major feature we wish to work on is to develop the node code to allow multiple trusted nodes in different locations share data, but this is primarily work to be done at the database level.

In the future I wish to develop the concept of sibling pools which will allow collaboration to minimise variance for miners while sharing rewards. The idea is to expand beyond the need for trusted nodes to be able to link up with other pools that can prove to each other the work they are performing towards a common reward. In essence it will involve proof-of-work much like miners do to the pool itself but with auditing of each other's work. The details of the protocol are not yet finalised and is still some way off.

Primary developer/maintainer for cgminer and ckpool/ckproxy.
ZERO FEE Pooled mining at ckpool.org 1% Fee Solo mining at solo.ckpool.org
-ck
will
Full Member
***
Offline Offline

Activity: 179
Merit: 100



View Profile
September 21, 2014, 06:10:59 AM
 #11

We are the owners of hashmine.io and commissioned the development of ckpool.

We've been working with Con & Kano on this for a few months now, and I must say it's a pleasure to see the masters at work. In a sense, the work was a natural progression of the solo-mining/gbt work on cgminer we commissioned earlier this year.

I started on basic visualization/GUI layer here: http://cpui.hashmine.io/ - changes to that sync with Kano's web implementation @ http://ice.kano.is/
Current focus is on browser compatibility, making it work and look serviceable on all devices. Priority is bugfixes and basic user management workflows, will look @ i18n and l10n after that.
This current UI is mainly a test for the REST API I'm building on Kano's ckdb work and testing the servicing of historical reporting. Will add more visualizations & reporting in the coming days.
Still very much in debug mode as daily changes are coming in, but will try to keep up with Kano & Con as time goes on.

hashmine.io takes a flat rate 1.5% fee, of which 0.5% goes directly to ckpool development (controlled by Con, and issued @ coinbase at time of blocksolve). Newly minted coins go directly into cold storage and I process them manually when the blocks mature. A payout history is available @ the above-mentioned UI. Will do this until I've worked through the security aspects of automation.

There's still much to do on this technical path (hardware, software, architecture, distribution, etc.) and this project will probably always be on-going. Once things calm down a bit we'll go into the unique-selling points of hashmine and the direction we'd like to take with it.

Will update this post with progress as I push changes.

QuiveringGibbage
Hero Member
*****
Offline Offline

Activity: 597
Merit: 515


http://idontALT.com


View Profile WWW
September 21, 2014, 07:42:09 AM
 #12

Discussion/Future direction/Feature requests
In the future I wish to develop the concept of sibling pools which will allow collaboration to minimise variance for miners while sharing rewards. The idea is to expand beyond the need for trusted nodes to be able to link up with other pools that can prove to each other the work they are performing towards a common reward. In essence it will involve proof-of-work much like miners do to the pool itself but with auditing of each other's work. The details of the protocol are not yet finalised and is still some way off.
very interesting concept for multi pools to trust each other... this will change the pooled mining landscape. Bitcoin mining is on the change again, fascinating future ahead for the mining scene.

@conman & kanoi; Congrats on the release Smiley and thank you for sharing your code with the community.

Cheers,
QG

Bitcoin is at the tippity top of the mountain...but it's really only half way up.. Wink
-ck
Moderator
Legendary
*
Offline Offline

Activity: 2590
Merit: 1111


Ruu \o/


View Profile WWW
September 22, 2014, 06:56:39 AM
 #13

Added support for using ckproxy to p2pool and large coinbase pools. Be aware that most non-ckpool based pools (p2pool included) have work limitations per connection when proxied as discussed in the ckproxy post.

Primary developer/maintainer for cgminer and ckpool/ckproxy.
ZERO FEE Pooled mining at ckpool.org 1% Fee Solo mining at solo.ckpool.org
-ck
-ck
Moderator
Legendary
*
Offline Offline

Activity: 2590
Merit: 1111


Ruu \o/


View Profile WWW
September 26, 2014, 02:33:34 AM
 #14

I've substantially updated the ckproxy code to work much better in concert with p2pool, and to increase the maximum speed of clients that are connected via the proxy when connected to a non-ckpool. On most pools, you will now be able to connect up to 256 clients to the proxy (down from what was 64k) but the maximum hashrate of each connected miner has been pushed up from 5TH to 1.2PH.

Primary developer/maintainer for cgminer and ckpool/ckproxy.
ZERO FEE Pooled mining at ckpool.org 1% Fee Solo mining at solo.ckpool.org
-ck
-ck
Moderator
Legendary
*
Offline Offline

Activity: 2590
Merit: 1111


Ruu \o/


View Profile WWW
September 30, 2014, 06:36:29 AM
 #15

I've added logging and statistics internally to ckpool on a combined per-worker basis, storing stats for each worker in the logs/workers directory.

I've also added the ability to set a user chosen minimum worker difficulty, though this will require some ckdb and front-end changes to allow this to be set.

In addition, I've implemented support for the stratum suggest_difficulty extension and updated the docs to reflect this. I've modified the cgminer git master to support this new extension with the --suggest-diff command.

Primary developer/maintainer for cgminer and ckpool/ckproxy.
ZERO FEE Pooled mining at ckpool.org 1% Fee Solo mining at solo.ckpool.org
-ck
mahrens917
Member
**
Offline Offline

Activity: 78
Merit: 10


View Profile WWW
October 05, 2014, 01:54:09 AM
 #16

First off, thanks for ckpool - it really sounds like a great product and I am trying to learn more.  I have a p2pool server and I am trying to get a ckpool proxy setup in front of it since it sounds like this will reduce load on my server (provided I have more users).  First, with ckpool -A -p running will all downstream users continue to maintain their individual presence on the p2pool (like it is described to work with -P)?  Within ckpool.conf there is a proxy url and a server url that need to be set.  Running this on my p2pool server the proxy url seems to want to be set to my p2pool server with port 9332.  That what is server URL?  The IP and port that outside clients would connect to, to use the proxy before hitting the p2pool server?  I have tried multiple configurations and cannot get it to work.  Perhaps, there is a sample .conf file out there already for p2pool?  Thanks for all of the help.

Find the pool with the best payout!
nodes.p2pool.co
-ck
Moderator
Legendary
*
Offline Offline

Activity: 2590
Merit: 1111


Ruu \o/


View Profile WWW
October 05, 2014, 02:05:20 AM
 #17

First off, thanks for ckpool - it really sounds like a great product and I am trying to learn more.  I have a p2pool server and I am trying to get a ckpool proxy setup in front of it since it sounds like this will reduce load on my server (provided I have more users).  First, with ckpool -A -p running will all downstream users continue to maintain their individual presence on the p2pool (like it is described to work with -P)?  Within ckpool.conf there is a proxy url and a server url that need to be set.  Running this on my p2pool server the proxy url seems to want to be set to my p2pool server with port 9332.  That what is server URL?  The IP and port that outside clients would connect to, to use the proxy before hitting the p2pool server?  I have tried multiple configurations and cannot get it to work.  Perhaps, there is a sample .conf file out there already for p2pool?  Thanks for all of the help.

Server URL is only when run in ckpool mode. The proxy entry is when you are running it in proxy mode. If you are connecting clients to the proxy, you can only have one upstream connection to the pool with one login only. If you allowed multiple logins it would end up just having multiple connections to the upstream pool so the proxy wouldn't actually be achieving anything. The -P option ONLY works when the upstream pool is a ckpool instance as the manual explicitly states and nothing else and does not decrease bandwidth, only the number of socket connections.

Simplest p2pool proxy entry would be just the proxy entry and nothing else. eg:

Code:
{
"proxy" :  [
        {
                "url" : "localhost:9332",
                "auth" : "user",
                "pass" : "pass"
        }
]
}

EDIT: I've been thinking of ways to allow multiple clients attach to the upstream pool with their username but it's a very invasive change to the code since it is designed around the concept of only one upstream server at any one time. Unless multiple clients are connected with the same username attach they're not going to benefit from the proxy being there, but this change will likely eventually make its way into the code, along with ways to open up extra connections once the proxy is "full" of clients.

Primary developer/maintainer for cgminer and ckpool/ckproxy.
ZERO FEE Pooled mining at ckpool.org 1% Fee Solo mining at solo.ckpool.org
-ck
mahrens917
Member
**
Offline Offline

Activity: 78
Merit: 10


View Profile WWW
October 05, 2014, 04:48:37 AM
 #18

Payout schemes are not discussed for ckpool.  Is it just solo or are others possible like PPLNS?  I have read everything i could find on ckpool and i do not belive this was ever explicitly stated.  Hopefully, this will be my last question for awhile.  Thanks!

Find the pool with the best payout!
nodes.p2pool.co
-ck
Moderator
Legendary
*
Offline Offline

Activity: 2590
Merit: 1111


Ruu \o/


View Profile WWW
October 05, 2014, 10:37:12 AM
 #19

Payout schemes are not discussed for ckpool.  Is it just solo or are others possible like PPLNS?  I have read everything i could find on ckpool and i do not belive this was ever explicitly stated.  Hopefully, this will be my last question for awhile.  Thanks!
Hi, read the FAQ linked in the top post. This is software, not a pool, so the payscheme is not fixed in the software design and entirely up to the pool. The ckdb code has a pplns calculation in it, but that doesn't mean the pool that adopts ckpool has to use pplns at all. Code to perform payments is not anywhere in the included code. Furthermore, if you are using ckproxy and not ckpool, the payment part is entirely dependent on your upstream pool and the proxy has zero effect on it. If you're asking specifically about the current pools that are running ckpool, hashmine.io and ckpool/kano.is are using pplns for payment, while solo.ckpool.org is using entire block reward payments.

Primary developer/maintainer for cgminer and ckpool/ckproxy.
ZERO FEE Pooled mining at ckpool.org 1% Fee Solo mining at solo.ckpool.org
-ck
Walter Rothbard
Sr. Member
****
Offline Offline

Activity: 476
Merit: 250


Bytecoin: 8VofSsbQvTd8YwAcxiCcxrqZ9MnGPjaAQm


View Profile WWW
October 12, 2014, 10:58:37 PM
 #20

Thanks for the awesome software - I was able to compile and configure a private pool in about five minutes!  Shocked

paradigmflux
Sr. Member
****
Offline Offline

Activity: 378
Merit: 250

small fry


View Profile WWW
October 13, 2014, 01:05:30 AM
 #21

Does this work for altcoins?

---
NXT Multipool! Mine Scrypt, SHA, Keccak or X11 for NXT! http://hashrate.org
http://hashrate.org/getting_started for port info!
Walter Rothbard
Sr. Member
****
Offline Offline

Activity: 476
Merit: 250


Bytecoin: 8VofSsbQvTd8YwAcxiCcxrqZ9MnGPjaAQm


View Profile WWW
October 13, 2014, 02:14:52 AM
 #22

Does this work for altcoins?

The author said this:

Q: Altcoins?
A: The author has no interest in support for anything but bitcoin. You are free to modify the code yourself as you see fit, but no altcoin support will ever be merged into the master ckpool code.

Personally, I had no trouble getting it to work.

-ck
Moderator
Legendary
*
Offline Offline

Activity: 2590
Merit: 1111


Ruu \o/


View Profile WWW
October 13, 2014, 11:38:33 PM
 #23

To be clear, merge mining coins which were just invented to monetise yet another coin that's stuffed into the bitcoin blockchain is a complete waste in my opinion. Something that uses the bitcoin blockchain but doesn't directly add value to the bitcoin economy is just free-riding. Extensions to bitcoin itself that depend on side chains are a valid potential use though (in my opinion), but none have matured at this stage. Please don't try and convince me otherwise, the noise is best left to other threads where I can more meaningfully ignore it.

Primary developer/maintainer for cgminer and ckpool/ckproxy.
ZERO FEE Pooled mining at ckpool.org 1% Fee Solo mining at solo.ckpool.org
-ck
mahrens917
Member
**
Offline Offline

Activity: 78
Merit: 10


View Profile WWW
October 14, 2014, 04:22:11 AM
 #24

I run ckpool -A and if the serverurl (in ckpool.conf) is set to anything other than 127.0.0.1:3333 than I get this error: [2014-10-14 00:13:58] Failed to bind socket for ckpool.org:3333 <- or any domain name or IP address
[2014-10-14 00:13:58] Connector failed to bind to socket, retrying in 5s

If I use 127.0.0.1:3333 then ckpool runs but I cannot connect any miner to it.  My miner connects to solo.ckpool.org:3333 just fine.  My firewall is open for port 3333.

I also have ensured that I can write to my socket directory as a user (not root) in /tmp.  I have also tried -s /run to change the socket directory to no avail.

Any thoughts?  Thanks again.

Find the pool with the best payout!
nodes.p2pool.co
-ck
Moderator
Legendary
*
Offline Offline

Activity: 2590
Merit: 1111


Ruu \o/


View Profile WWW
October 14, 2014, 04:23:32 AM
 #25

I run ckpool -A and if the serverurl (in ckpool.conf) is set to anything other than 127.0.0.1:3333 than I get this error: [2014-10-14 00:13:58] Failed to bind socket for ckpool.org:3333 <- or any domain name or IP address
[2014-10-14 00:13:58] Connector failed to bind to socket, retrying in 5s

If I use 127.0.0.1:3333 then ckpool runs but I cannot connect any miner to it.  My miner connects to solo.ckpool.org:3333 just fine.  My firewall is open for port 3333.

I also have ensured that I can write to my socket directory as a user (not root) in /tmp.  I have also tried -s /run to change the socket directory to no avail.

Any thoughts?  Thanks again.

What's your ifconfig look like? You need to bind it to whatever the interface is that looks out to the world (probably a 192.x address).

Primary developer/maintainer for cgminer and ckpool/ckproxy.
ZERO FEE Pooled mining at ckpool.org 1% Fee Solo mining at solo.ckpool.org
-ck
mahrens917
Member
**
Offline Offline

Activity: 78
Merit: 10


View Profile WWW
October 14, 2014, 02:21:05 PM
 #26

Perfect, thanks.  I am running in a datacenter and I have a public and a private IP address.  I placed in my private IP address in the config file and I was able to reach it and solo mine on it via my public IP address.

Find the pool with the best payout!
nodes.p2pool.co
warrensgun
Full Member
***
Offline Offline

Activity: 196
Merit: 100

Mining since bitcoin was $1


View Profile
October 15, 2014, 08:29:36 PM
 #27

any ideas for these errors:

Code:
[2014-10-15 16:27:07] Failed to get a json result in parse_subscribe, got: {"id": null, "method": "mining.set_difficulty", "params": [16384.0]}
[2014-10-15 16:27:07] Failed all subscription options in subscribe_stratum
[2014-10-15 16:27:22] Nonce2 length 3 too small to be able to proxy

ckpoool -A -p
proxy setup with 4 pools (ghash, p2p, eligius and something else i forgot)

-ck
Moderator
Legendary
*
Offline Offline

Activity: 2590
Merit: 1111


Ruu \o/


View Profile WWW
October 15, 2014, 09:15:08 PM
 #28

any ideas for these errors:

Code:
[2014-10-15 16:27:07] Failed to get a json result in parse_subscribe, got: {"id": null, "method": "mining.set_difficulty", "params": [16384.0]}
[2014-10-15 16:27:07] Failed all subscription options in subscribe_stratum
[2014-10-15 16:27:22] Nonce2 length 3 too small to be able to proxy

ckpoool -A -p
proxy setup with 4 pools (ghash, p2p, eligius and something else i forgot)
Looks like some pool responds with a command before it responds with the subscription, while another has a very small nonce2 (looks like f2pool or something).

The pool with a small nonce2 will likely only work with devices <5TH if I do this though.

I'll try and add workarounds for these in the code, thanks.

EDIT: Added nonce2 size 3 support with a warning.

Primary developer/maintainer for cgminer and ckpool/ckproxy.
ZERO FEE Pooled mining at ckpool.org 1% Fee Solo mining at solo.ckpool.org
-ck
Walter Rothbard
Sr. Member
****
Offline Offline

Activity: 476
Merit: 250


Bytecoin: 8VofSsbQvTd8YwAcxiCcxrqZ9MnGPjaAQm


View Profile WWW
October 21, 2014, 06:43:35 AM
 #29

Is there a way to tell ckpool to re-read its configuration file without a restart?

Apologies if this is answered somewhere; I looked through the FAQ and tried to search the whole thread.

Walter Rothbard
Sr. Member
****
Offline Offline

Activity: 476
Merit: 250


Bytecoin: 8VofSsbQvTd8YwAcxiCcxrqZ9MnGPjaAQm


View Profile WWW
October 22, 2014, 12:16:23 AM
 #30

I keep getting shut down with this message:

[2014-10-22 00:02:03] Failure in send_proc from stratifier.c ssend_process:2661 with errno 3: No such process
[2014-10-22 00:02:03] Child process received signal 15, forwarding signal to ckpool main process
[2014-10-22 00:02:03] Parent process ckpool received signal 15, shutting down

I've run without a hitch 24/7 until now.  What did I do?

-ck
Moderator
Legendary
*
Offline Offline

Activity: 2590
Merit: 1111


Ruu \o/


View Profile WWW
October 22, 2014, 12:29:15 AM
 #31

I keep getting shut down with this message:

[2014-10-22 00:02:03] Failure in send_proc from stratifier.c ssend_process:2661 with errno 3: No such process
[2014-10-22 00:02:03] Child process received signal 15, forwarding signal to ckpool main process
[2014-10-22 00:02:03] Parent process ckpool received signal 15, shutting down

I've run without a hitch 24/7 until now.  What did I do?
You probably had an upstream outage. The code was a little trigger happy at shutting itself down under those circumstances. Git pull the latest code.

Primary developer/maintainer for cgminer and ckpool/ckproxy.
ZERO FEE Pooled mining at ckpool.org 1% Fee Solo mining at solo.ckpool.org
-ck
Walter Rothbard
Sr. Member
****
Offline Offline

Activity: 476
Merit: 250


Bytecoin: 8VofSsbQvTd8YwAcxiCcxrqZ9MnGPjaAQm


View Profile WWW
October 22, 2014, 12:33:35 AM
 #32

Thanks, Con!

warrensgun
Full Member
***
Offline Offline

Activity: 196
Merit: 100

Mining since bitcoin was $1


View Profile
October 24, 2014, 05:51:26 PM
 #33

This just happened - but otherwise had been up and running for like 5 or 7 days without a problem.  I'll do a git pull to update - but in case this helps
Code:
[2014-10-24 13:22:36] Failed to recv in read_socket_line
[2014-10-24 13:22:36] Failed to read_socket_line in proxy_recv, attempting reconnect
[2014-10-24 13:22:36] Upstream socket invalidated, will attempt failover
[2014-10-24 13:22:36] Killing proxy
[2014-10-24 13:22:36] Nonce2 length 3 means proxied clients can't be >5TH each
[2014-10-24 13:22:41] Failed to receive line in auth_stratum
[2014-10-24 13:22:41] Failed initial authorise to pool:port with user !
[2014-10-24 13:22:42] Connected to upstream server pool2:port as proxy
[2014-10-24 13:22:42] Successfully reconnected to pool2:port as proxy
[2014-10-24 13:22:42] Killing proxy
[2014-10-24 13:22:42] Nonce2 length 3 means proxied clients can't be >5TH each
[2014-10-24 13:22:42] JSON-RPC decode failed: (unknown reason)
[2014-10-24 13:22:42] Failed to get a json result in parse_subscribe, got: {"id": null, "method": "mining.set_difficulty", "params": [8192.0]}
[2014-10-24 13:22:42] Failed all subscription options in subscribe_stratum
[2014-10-24 13:22:43] generator process dead! Relaunching
[2014-10-24 13:22:43] File /tmp/ckproxy/generator.pid exists
[2014-10-24 13:22:43] ckproxy generator starting
[2014-10-24 13:22:43] ckproxy generator ready
[2014-10-24 13:22:43] Nonce2 length 3 means proxied clients can't be >5TH each
[2014-10-24 13:22:48] Failed to receive line in auth_stratum
[2014-10-24 13:22:48] Failed initial authorise to pool:port with user !
[2014-10-24 13:22:55] Connected to upstream server pool2:port as proxy
[2014-10-24 13:22:55] Attempting to send message getnotify to dead process generator with errno 3: No such process
[2014-10-24 13:22:55] Failure in send_recv_proc from stratifier.c update_notify:852 with errno 3: No such process
[2014-10-24 13:22:55] Failed to get notify from generator in update_notify
[2014-10-24 13:22:55] Attempting to send message getsubscribe to dead process generator with errno 3: No such process
[2014-10-24 13:22:55] Failure in send_recv_proc from stratifier.c update_subscribe:809 with errno 3: No such process
[2014-10-24 13:22:55] Failed to get subscribe from generator in update_notify
[2014-10-24 13:22:55] ckproxy stratifier exiting with return code 1, shutting down!
[2014-10-24 13:22:55] Listener received shutdown message, terminating ckpool
[2014-10-24 13:22:55] Failed to write 4 byte length in send_unix_msg (32) with errno 32: Broken pipe
[2014-10-24 13:22:55] Failure in send_unix_msg from ckpool.c listener:255 with errno 32: Broken pipe
[2014-10-24 13:22:55] Parent process ckproxy received signal 15, shutting down

-ck
Moderator
Legendary
*
Offline Offline

Activity: 2590
Merit: 1111


Ruu \o/


View Profile WWW
October 24, 2014, 09:42:00 PM
 #34

This just happened - but otherwise had been up and running for like 5 or 7 days without a problem.  I'll do a git pull to update - but in case this helps
Thanks, likely the same as the previous report of a trigger happy shutdown of the proxy which a git pull should fix.

Primary developer/maintainer for cgminer and ckpool/ckproxy.
ZERO FEE Pooled mining at ckpool.org 1% Fee Solo mining at solo.ckpool.org
-ck
-ck
Moderator
Legendary
*
Offline Offline

Activity: 2590
Merit: 1111


Ruu \o/


View Profile WWW
October 27, 2014, 08:57:12 PM
 #35

Fixed a bug which would previously crash ckpool if you had 1024 clients or more connected concurrently due to an expected system call limitation with select(), along with worker count being incorrect. It's now being used live on kano's ckpool with more than 1500 active workers.

Primary developer/maintainer for cgminer and ckpool/ckproxy.
ZERO FEE Pooled mining at ckpool.org 1% Fee Solo mining at solo.ckpool.org
-ck
warrensgun
Full Member
***
Offline Offline

Activity: 196
Merit: 100

Mining since bitcoin was $1


View Profile
October 28, 2014, 12:08:18 AM
 #36

Code:
[2014-10-27 20:05:53] ckproxy stratifier ready
[2014-10-27 20:06:03] Failed to receive line in auth_stratum
[2014-10-27 20:06:14] Failed to receive line in auth_stratum
[2014-10-27 20:06:24] Failed to receive line in auth_stratum
[2014-10-27 20:06:34] Failed to receive line in auth_stratum
[2014-10-27 20:06:45] Failed to receive line in auth_stratum
[2014-10-27 20:07:00] Failed to receive line in auth_stratum
[2014-10-27 20:07:11] Failed to receive line in auth_stratum

This is after a fresh update.

-ck
Moderator
Legendary
*
Offline Offline

Activity: 2590
Merit: 1111


Ruu \o/


View Profile WWW
October 28, 2014, 02:40:39 AM
 #37

Code:
[2014-10-27 20:05:53] ckproxy stratifier ready
[2014-10-27 20:06:03] Failed to receive line in auth_stratum
[2014-10-27 20:06:14] Failed to receive line in auth_stratum
[2014-10-27 20:06:24] Failed to receive line in auth_stratum
[2014-10-27 20:06:34] Failed to receive line in auth_stratum
[2014-10-27 20:06:45] Failed to receive line in auth_stratum
[2014-10-27 20:07:00] Failed to receive line in auth_stratum
[2014-10-27 20:07:11] Failed to receive line in auth_stratum

This is after a fresh update.
What config and upstream pool? Seems to be working fine here. Maybe the pool you're trying to proxy is actually dead?

Primary developer/maintainer for cgminer and ckpool/ckproxy.
ZERO FEE Pooled mining at ckpool.org 1% Fee Solo mining at solo.ckpool.org
-ck
-ck
Moderator
Legendary
*
Offline Offline

Activity: 2590
Merit: 1111


Ruu \o/


View Profile WWW
October 30, 2014, 01:52:14 AM
 #38

I've updated the documentation to reflect the changes to the get_transactions, get_txnhashes and suggest_diff calls. The original documentation placed the parameter within the method which is not really meaningful use of json so ckpool supports the old form but expects the actual parameter within the params key.

Primary developer/maintainer for cgminer and ckpool/ckproxy.
ZERO FEE Pooled mining at ckpool.org 1% Fee Solo mining at solo.ckpool.org
-ck
kano
Legendary
*
Offline Offline

Activity: 2520
Merit: 1045


Linux since 1997 RedHat 4


View Profile
November 02, 2014, 11:28:30 PM
 #39

I thought I might explain a little of the CKDB share storage for anyone curious.
I was gonna post this in the pool thread, but of course realised, here is more appropriate.
(It relates to a change/fix I'm doing at the moment and thought I'd write out the current details at the same time)

CKDB has a 2 level structure for storing shares.
ShareSummary and MarkerSummary

ShareSummary is implemented.
MarkerSummary isn't yet - this simply means that I use a LOT more ram until I do implement it - and fast reporting at the 'Marker' level of course isn't possible until it's done.

CKPool creates work per WorkInfo which is effectively each block template we get from bitcoin.
We do this by default every 30s (faster than 'certain' other pools) since that is both good for Bitcoin and good for the pool.
For Bitcoin it means faster expected average transaction confirmation.
For the pool it means higher expected average transaction fees.
An obvious Win-Win for both.

CKDB groups shares, per WorkInfoID (the internal ID of the WorkInfo) and creates per worker ShareSummary records of these in RAM and in the DB.
You could compare this to what some other pools call "Shifts", with a ShareSummary record being a shift of work for a worker, of usually 30 seconds.
ShareSummary, per worker, per 30s, means a lot of ShareSummaries Smiley

The PPLNS code currently uses the ShareSummary information to calculate payouts, so the N value actually used for the payout will include the full 30s of work for the starting WorkInfoID calculated to be the start of the payout i.e. the N value used is expanded to the full first and last WorkInfoID - so, in concept, it is similar to a PPLNS "Shift" payout structure.

The MarkerSummary design allows any arbitrary range of WorkInfoIDs
The design is: to later to be able to determine the necessary WorkInfoID ranges to ensure all summary calculations required are possible, and then summarise the ShareSummaries into the MarkerSummaries and then be able to delete the ShareSummaries.
The original idea was that the Markers would be the block WorkInfoIDs and the PPLNS WorkInfoIDs and mean a much smaller amount of data required in RAM and in the database.
However, the timing of doing the summarisation to the Markers isn't possible until the end Marker is older than what is needed by other code.
For the current PPLNS used, that would mean: not until the end Marker is more than the N in PPLNS old.
i.e. all ShareSummaries would have to exist back to N share diff ago.

This actually runs pretty well on hashmine since most of the workers are high hash rate devices and have many high diff shares in each WorkInfo.
If the average number of shares per WorkInfo is low or the average difficulty of the shares is low, this of course leads to a much larger number of ShareSummaries - as is happening now on the kano.is pool.
Thus I've now decided to use the MarkerSummary to make larger "Shifts" that are both a subset of the original idea, i.e. more of them, but also at a size where it's OK to use for the PPLNS calculation - which I'll chose some value between 20 and 100 WorkInfoIDs (probably 50)
The MarkerSummary changes are pretty much next on the todo list.

Pool: https://kano.is Here on Bitcointalk: Forum BTC: 1KanoPb8cKYqNrswjaA8cRDk4FAS9eDMLU
FreeNode IRC: irc.freenode.net channel #kano.is Majority developer of the ckpool code
Help keep Bitcoin secure by mining on pools with full block verification on all blocks - and NO empty blocks!
-ck
Moderator
Legendary
*
Offline Offline

Activity: 2590
Merit: 1111


Ruu \o/


View Profile WWW
November 02, 2014, 11:51:08 PM
 #40

Milestone 7 was recently tagged as a nice stable point in the code to use, although we have continued to develop in the interim.

New features are the addition of the maxdiff and maxclients options.

Stratum redirect can now be sent via ckpmsg on the console to a URL of choice instead of just a blank redirect. Reconnect by itself will just issue a reconnect but url and port can be added:
reconnect:url,port

A substantial amount of performance tuning was performed on the code now that I've seen it working on kano's ckpool allowing me to find the largest CPU users and concentrate scalability improvements there. I've fixed a number of upper client limit issues and now it should only really be limited by available ram and open file limits on the system. The main connector was rewritten to use epoll and extra threads based on number of CPUs are now recruited for share processing and stratum message processing workqueues. CPU usage of any one component on ckpool is currently less than 5% for 2500 clients, but even if the pool was completely CPU bound at 100% it should still perform fine. If we get to 50 thousand clients I'll be able to see where the next bottleneck is and concentrate further improvements there. In the meantime, more work needs to be done to ckdb to address its memory usage to be suitable to support ckpool's growth and that's what Kano is currently working on.

Primary developer/maintainer for cgminer and ckpool/ckproxy.
ZERO FEE Pooled mining at ckpool.org 1% Fee Solo mining at solo.ckpool.org
-ck
norgan
Sr. Member
****
Offline Offline

Activity: 308
Merit: 250

Decentralize your hashing - p2pool - Norgz Pool


View Profile WWW
November 07, 2014, 03:47:45 AM
 #41

ok so firstly, my linux skills are not as good as my windows skills, i've compiled ckpool and bitcoind. i am trying to set up the web interface, i point apache to the http directory but get forbidden. apache works with default site so config is good. i have chmod 755 on both http and pool directories.

What am i missing?

Miner, tech geek, operator of NorgzPool - Sydney Australia P2Pool Node creator of p2pool fancy front end

Tips: 1NorganBbymShTN2MMpfGzRYJF8mcPeXjv Exchange BTC locally in Australia or Donate to p2pool miners
kano
Legendary
*
Offline Offline

Activity: 2520
Merit: 1045


Linux since 1997 RedHat 4


View Profile
November 07, 2014, 12:52:19 PM
 #42

There are 2 git folders html and pool
html is the web folder.
If you read index.php (which is only 1 line of code) it should be abundantly clear where pool goes Smiley

The web/db side of the pool is not designed for the non-technical, on purpose.

Pool: https://kano.is Here on Bitcointalk: Forum BTC: 1KanoPb8cKYqNrswjaA8cRDk4FAS9eDMLU
FreeNode IRC: irc.freenode.net channel #kano.is Majority developer of the ckpool code
Help keep Bitcoin secure by mining on pools with full block verification on all blocks - and NO empty blocks!
norgan
Sr. Member
****
Offline Offline

Activity: 308
Merit: 250

Decentralize your hashing - p2pool - Norgz Pool


View Profile WWW
November 08, 2014, 05:06:03 AM
 #43

There are 2 git folders html and pool
html is the web folder.
If you read index.php (which is only 1 line of code) it should be abundantly clear where pool goes Smiley

The web/db side of the pool is not designed for the non-technical, on purpose.

ok so i see that, looks to only work with db version. I wondered if it could be a way of seeing proxy stats. i'm guessing standalone proxy (-A -p) you wont get any stats other than the logs. i might have a go at getting the db set up.

Edit: ohhh of course i need to move pool to the web directory lol

Miner, tech geek, operator of NorgzPool - Sydney Australia P2Pool Node creator of p2pool fancy front end

Tips: 1NorganBbymShTN2MMpfGzRYJF8mcPeXjv Exchange BTC locally in Australia or Donate to p2pool miners
kingscrown
Hero Member
*****
Offline Offline

Activity: 672
Merit: 500


http://fuk.io - check it out!


View Profile WWW
November 08, 2014, 05:11:32 AM
 #44

u rock man, loving your work

kano
Legendary
*
Offline Offline

Activity: 2520
Merit: 1045


Linux since 1997 RedHat 4


View Profile
November 08, 2014, 11:44:13 AM
 #45

There are 2 git folders html and pool
html is the web folder.
If you read index.php (which is only 1 line of code) it should be abundantly clear where pool goes Smiley

The web/db side of the pool is not designed for the non-technical, on purpose.

ok so i see that, looks to only work with db version. I wondered if it could be a way of seeing proxy stats. i'm guessing standalone proxy (-A -p) you wont get any stats other than the logs. i might have a go at getting the db set up.

Edit: ohhh of course i need to move pool to the web directory lol
No, the web based interface is connected to ckdb.
i.e. you need to run ckpool is full mode with ckdb to be able to get full web stats out of it.

You could use the worker.php and address.php I wrote that uses Con's solo pool stats interface.
However, very much by design, ckpool itself isn't a store of mining information, just as ckdb itself isn't a work generator for a mining pool.

The separation makes for a much more powerful pool.
CKPool's job is to generate work, hand it out to miners and report the work and hash rate that the miners do.
This removes all the overhead of data storage of a pool and means ckpool concentrates on being the best that it is at handling work.

CKDB deals with all the data storage and web interface needed and thus you need ckdb also if you want all that.

Pool: https://kano.is Here on Bitcointalk: Forum BTC: 1KanoPb8cKYqNrswjaA8cRDk4FAS9eDMLU
FreeNode IRC: irc.freenode.net channel #kano.is Majority developer of the ckpool code
Help keep Bitcoin secure by mining on pools with full block verification on all blocks - and NO empty blocks!
norgan
Sr. Member
****
Offline Offline

Activity: 308
Merit: 250

Decentralize your hashing - p2pool - Norgz Pool


View Profile WWW
November 08, 2014, 11:47:18 AM
 #46

Thanks mate, will have a play through the week.

Miner, tech geek, operator of NorgzPool - Sydney Australia P2Pool Node creator of p2pool fancy front end

Tips: 1NorganBbymShTN2MMpfGzRYJF8mcPeXjv Exchange BTC locally in Australia or Donate to p2pool miners
bicer
Newbie
*
Offline Offline

Activity: 23
Merit: 0


View Profile
November 11, 2014, 12:29:01 AM
 #47

Running ckpool as proxy. After putting into production commit as of Nov 8 my local p2pool started reporting higher dead share rate, from around 0.5G-5G to 30-40G. After removing proxy stats returned to the expected numbers. Screen shot illustrates this. Since I'm code illiterate not sure if this is due to code change and now proxy provides true stats or p2pool node and pron't work well together.
http://s22.postimg.org/z6so4m4r5/dead_share.png

edit:corrected date, rate.
-ck
Moderator
Legendary
*
Offline Offline

Activity: 2590
Merit: 1111


Ruu \o/


View Profile WWW
November 12, 2014, 10:26:23 AM
 #48

Running ckpool as proxy. After putting into production commit as of Nov 8 my local p2pool started reporting higher dead share rate, from around 0.5G-5G to 30-40G. After removing proxy stats returned to the expected numbers. Screen shot illustrates this. Since I'm code illiterate not sure if this is due to code change and now proxy provides true stats or p2pool node and pron't work well together.


edit:corrected date, rate.
No I can't think of a mechanism for this, but you are adding another link into the chain. The purpose of adding the proxy would only be to add more miners to the one upstream p2pool connection. If you're just adding a proxy and have only one rig connected to it there really is zero advantage to adding the extra link in the chain. I would suggest setting the connection to the proxy to have a fixed diff though with a +diff extension to your username. I suggest your hashrate in GH / 1.7

Primary developer/maintainer for cgminer and ckpool/ckproxy.
ZERO FEE Pooled mining at ckpool.org 1% Fee Solo mining at solo.ckpool.org
-ck
Dimoza
Jr. Member
*
Offline Offline

Activity: 30
Merit: 0


View Profile
December 31, 2014, 06:32:57 PM
 #49

I'm trying to run solo via the http://solo.ckpool.org/ but however just a tiny fraction of shares are accepted. Is it possible to increase prevetively the minimum difficultiy form my (miner) side? I see the +diff option was named above. However I can't fid any relevant information regarding this option. How can  I use it with my USER(i.e. BTC address) parameter?

I'm using bfgminer, if it have a sense to mention.

Thank you!
-ck
Moderator
Legendary
*
Offline Offline

Activity: 2590
Merit: 1111


Ruu \o/


View Profile WWW
January 01, 2015, 04:30:00 AM
 #50

I'm trying to run solo via the http://solo.ckpool.org/ but however just a tiny fraction of shares are accepted. Is it possible to increase prevetively the minimum difficultiy form my (miner) side? I see the +diff option was named above. However I can't fid any relevant information regarding this option. How can  I use it with my USER(i.e. BTC address) parameter?

You're posting in the support thread for the ckpool software. The solo ckpool thread is here:
https://bitcointalk.org/index.php?topic=763510.620

However the quick answer is with solo mining it doesn't matter how many shares you get accepted since you don't get paid for shares at all and you only get a reward if you solve a block. Don't worry about what diff it's using since it's just an indirect marker of how hard you're mining.

Primary developer/maintainer for cgminer and ckpool/ckproxy.
ZERO FEE Pooled mining at ckpool.org 1% Fee Solo mining at solo.ckpool.org
-ck
-ck
Moderator
Legendary
*
Offline Offline

Activity: 2590
Merit: 1111


Ruu \o/


View Profile WWW
January 20, 2015, 01:15:49 AM
 #51

There has been some instability in the master git for a little while now and it's only just been resolved, apologies for the inconvenience. It took a long time to discover that the utlist macros FOREACH_SAFE are only safe for linked list deletion but not freeing of ram within the list. I've contacted the utlist author to inform him but have added a workaround in the code in the meantime and the crashes have since resolved. In addition, although no crashes were seen in the code prior to the changes, some theoretical crashes have been fixed as well, though the solo pool was running for 42 days solid before I restarted it with the new code.

Changes to the git tree:
- Added best share support/reporting per user/worker
- Pruning of old disconnected instances and dead clients' ram.
- Repaired and upgraded the stratum reconnect support to work with any valid extranonce1 sizes.

I'll be tagging this as a milestone in the near future once I confirm the stability over a longer period.

Kano has made massive changes to the ckdb code to support markers and for pplns to be more shift-like, dramatically reducing the ram usage of last instances. Once Kano commits yet more changes I will likely tag yet another milestone in short order.

As a suggestion to ckpool software users, unless you are actively watching development in the #ckpool IRC channel, you should stick to tagged milestones or you will be unaware if there is any instability in the master tree.

Primary developer/maintainer for cgminer and ckpool/ckproxy.
ZERO FEE Pooled mining at ckpool.org 1% Fee Solo mining at solo.ckpool.org
-ck
ZACHM
Hero Member
*****
Offline Offline

Activity: 776
Merit: 1002



View Profile
January 27, 2015, 09:08:35 PM
 #52

I want to be able to change what pool all of my miners are pointed to easily. I assume that if I setup ckpool as a proxy and point all of miners to it, then I can use the proxy to point everything (appearing as one miner) to whatever pool I set (and failovers) in the proxy settings for ckpool.

Assuming this is all correct I attempted to build ckpool on my Ubuntu 12.04 machine (desktop installation, but essentially used as a server).

I used:

Code:
git clone https://bitbucket.org/ckolivas/ckpool.git

Now I have a directory ckpool, when I am in the directory and try:

Code:
sudo apt-get install build-essential ./configure --without-ckdb make

I get this error:

Code:
E: Command line option --without-ckdb is not understood

Am I doing something wrong?
I saw the part that says "Building from git also requires autoconf and automake" so I also tried:

Code:
sudo apt-get install build-essential autoconf automake ./autogen.sh ./configure --without-ckdb make

with the same result.

-ck
Moderator
Legendary
*
Offline Offline

Activity: 2590
Merit: 1111


Ruu \o/


View Profile WWW
January 27, 2015, 09:40:55 PM
 #53

Read the readme directly instead of from the bitbucket page which doesn't handle the line breaks properly. Those are separate commands.

Primary developer/maintainer for cgminer and ckpool/ckproxy.
ZERO FEE Pooled mining at ckpool.org 1% Fee Solo mining at solo.ckpool.org
-ck
ZACHM
Hero Member
*****
Offline Offline

Activity: 776
Merit: 1002



View Profile
January 27, 2015, 10:15:45 PM
 #54

Thanks. I feel stupid now, I should have known that.  Smiley

-ck
Moderator
Legendary
*
Offline Offline

Activity: 2590
Merit: 1111


Ruu \o/


View Profile WWW
January 28, 2015, 08:45:24 AM
 #55

After yet more extensive debugging and fine tuning potential issues that were leading to hangs/lockups or crashes I finally found an issue that client instances could be in the process of being dropped and received messages from them would be processed ever so slightly after the drop, triggering... well, stuff. Anyway it's fixed and finally exhibiting stability in our real world pool usage and I've tagged a new milestone M10 to indicate its suitability for use.

Primary developer/maintainer for cgminer and ckpool/ckproxy.
ZERO FEE Pooled mining at ckpool.org 1% Fee Solo mining at solo.ckpool.org
-ck
FaSan
Hero Member
*****
Offline Offline

Activity: 658
Merit: 500



View Profile
January 29, 2015, 12:19:28 PM
 #56

I still try the CKProxy. I want to congratulate for this really great software.

But I found some problems, proxy going to crash many times :

Code:
[2015-01-29 10:57:31] ckproxy connector starting
[2015-01-29 10:57:31] ckproxy generator starting
[2015-01-29 10:57:31] ckproxy generator ready
[2015-01-29 10:57:31] ckproxy stratifier starting
[2015-01-29 10:57:31] Nonce2 length 3 means proxied clients can't be >5TH each
[2015-01-29 10:57:32] ckproxy connector ready
[2015-01-29 10:57:32] ckproxy stratifier ready
[2015-01-29 11:12:22] stratifier process dead, terminating!
[2015-01-29 11:12:23] Attempting to send message dropclient=46 to non existent process stratifier with errno 3: No such process
[2015-01-29 11:12:23] Failure in send_proc from connector.c stratifier_drop_client:241 with errno 3: No such process
[2015-01-29 11:12:23] Child process received signal 15, forwarding signal to ckproxy main process
[2015-01-29 11:12:23] Parent process ckproxy received signal 15, shutting down

and

Code:
root@devel:/opt/ckpool# src/ckpool -c /opt/ckpool/ckproxy.conf -A -p
[2015-01-29 12:05:39] ckproxy stratifier starting
[2015-01-29 12:05:39] ckproxy generator starting
[2015-01-29 12:05:39] ckproxy generator ready
[2015-01-29 12:05:39] ckproxy connector starting
[2015-01-29 12:05:39] Nonce2 length 3 means proxied clients can't be >5TH each
[2015-01-29 12:05:39] ckproxy connector ready
[2015-01-29 12:05:39] ckproxy stratifier ready
*** glibc detected *** src/ckpool: corrupted double-linked list: 0x00007f5dec004f80 ***



It's compiled without DB support in Ubuntu 12.04



Thank you in advance




FaSan
-ck
Moderator
Legendary
*
Offline Offline

Activity: 2590
Merit: 1111


Ruu \o/


View Profile WWW
January 30, 2015, 01:09:57 AM
 #57

I know it wasn't long ago I tagged M10 but I finally found a bug which would present the way the crashes have shown up to date and have fixed it and tagged M11.

Primary developer/maintainer for cgminer and ckpool/ckproxy.
ZERO FEE Pooled mining at ckpool.org 1% Fee Solo mining at solo.ckpool.org
-ck
-ck
Moderator
Legendary
*
Offline Offline

Activity: 2590
Merit: 1111


Ruu \o/


View Profile WWW
February 05, 2015, 10:15:11 AM
 #58

Last bit of instability seems to have been quashed with yet another race fix. M12 was tagged shortly after that fix to signify the latest stable point and now significant attention is being given to the proxy side of the code which has not been touched in quite a while and showed a lot of immaturity in the code.

Primary developer/maintainer for cgminer and ckpool/ckproxy.
ZERO FEE Pooled mining at ckpool.org 1% Fee Solo mining at solo.ckpool.org
-ck
ArchitektoR
Full Member
***
Offline Offline

Activity: 171
Merit: 100


View Profile
February 23, 2015, 09:10:58 PM
 #59

First of all - thanks for all your work!

Now trying to setup a test pool on testnet - and get:

Code:
[2015-02-24 00:07:45] HTTP response not ok: HTTP/1.0 401 Authorization Required
[2015-02-24 00:07:45] Reopening socket to localhost:18332
[2015-02-24 00:07:45] Failed to get valid json response to getblocktemplate
[2015-02-24 00:07:45] CRITICAL: No bitcoinds active!

Do I need extra command or config lines?
-ck
Moderator
Legendary
*
Offline Offline

Activity: 2590
Merit: 1111


Ruu \o/


View Profile WWW
February 23, 2015, 09:15:14 PM
 #60

First of all - thanks for all your work!

Now trying to setup a test pool on testnet - and get:

Code:
[2015-02-24 00:07:45] HTTP response not ok: HTTP/1.0 401 Authorization Required
[2015-02-24 00:07:45] Reopening socket to localhost:18332
[2015-02-24 00:07:45] Failed to get valid json response to getblocktemplate
[2015-02-24 00:07:45] CRITICAL: No bitcoinds active!

Do I need extra command or config lines?
You need to set up the rpc username and password on your bitcoind and set the same auth and password in your ckpool.conf file.

Primary developer/maintainer for cgminer and ckpool/ckproxy.
ZERO FEE Pooled mining at ckpool.org 1% Fee Solo mining at solo.ckpool.org
-ck
ArchitektoR
Full Member
***
Offline Offline

Activity: 171
Merit: 100


View Profile
February 23, 2015, 09:28:22 PM
 #61

You need to set up the rpc username and password on your bitcoind and set the same auth and password in your ckpool.conf file.

Looks like it was illegal characters in rpcpassword, sorry!
ArchitektoR
Full Member
***
Offline Offline

Activity: 171
Merit: 100


View Profile
February 23, 2015, 11:04:03 PM
 #62

Now it runs fine, no errors.

But pool.status shows no hashrate:

Code:
{"runtime": 241, "lastupdate": 1424732527, "Users": 2, "Workers": 2, "Idle": 2, "Disconnected": 0}
{"hashrate1m": "0", "hashrate5m": "0", "hashrate15m": "0", "hashrate1hr": "0", "hashrate6hr": "0", "hashrate1d": "0", "hashrate7d": "0"}
{"SPS1m": 0.0, "SPS5m": 0.0, "SPS15m": 0.0, "SPS1h": 0.0}

And the test AntMiner shows all shares as rejected, zero accepted. Running on testnet.
ArchitektoR
Full Member
***
Offline Offline

Activity: 171
Merit: 100


View Profile
February 24, 2015, 06:09:14 PM
 #63

And when doing ./configure --without-ckdb

it gives this:

Code:
checking linux/un.h usability... no
checking linux/un.h presence... yes
configure: WARNING: linux/un.h: present but cannot be compiled
configure: WARNING: linux/un.h:     check for missing prerequisite headers?
configure: WARNING: linux/un.h: see the Autoconf documentation
configure: WARNING: linux/un.h:     section "Present But Cannot Be Compiled"
configure: WARNING: linux/un.h: proceeding with the compiler's result
configure: WARNING:     ## --------------------------------- ##
configure: WARNING:     ## Report this to kernel@kolivas.org ##
configure: WARNING:     ## --------------------------------- ##
checking for linux/un.h... no

And when cat config.log | grep linux

Code:
configure:12878: checking linux/un.h usability
/usr/include/linux/un.h:7:2: error: unknown type name 'sa_family_t'
| #include <linux/un.h>
configure:12878: checking linux/un.h presence
configure:12878: WARNING: linux/un.h: present but cannot be compiled
configure:12878: WARNING: linux/un.h:     check for missing prerequisite headers?
configure:12878: WARNING: linux/un.h: see the Autoconf documentation
configure:12878: WARNING: linux/un.h:     section "Present But Cannot Be Compiled"
configure:12878: WARNING: linux/un.h: proceeding with the compiler's result
configure:12878: checking for linux/un.h
ac_cv_build=i686-pc-linux-gnu
ac_cv_header_linux_un_h=no
ac_cv_host=i686-pc-linux-gnu
ac_cv_target=i686-pc-linux-gnu
lt_cv_path_LD=/usr/i686-pc-linux-gnu/bin/ld

Looks like something is missing, but what?

But it compiles and runs without any errors thrown.
-ck
Moderator
Legendary
*
Offline Offline

Activity: 2590
Merit: 1111


Ruu \o/


View Profile WWW
February 24, 2015, 08:32:56 PM
 #64

Code:
configure:12878: checking linux/un.h usability
ac_cv_build=i686-pc-linux-gnu

Looks like something is missing, but what?

But it compiles and runs without any errors thrown.
Please, it's 2015. This is 64 bit code only, but if it's working ignore the error as it's just something to do with your distribution.

Primary developer/maintainer for cgminer and ckpool/ckproxy.
ZERO FEE Pooled mining at ckpool.org 1% Fee Solo mining at solo.ckpool.org
-ck
ArchitektoR
Full Member
***
Offline Offline

Activity: 171
Merit: 100


View Profile
February 24, 2015, 09:00:04 PM
 #65

Please, it's 2015. This is 64 bit code only, but if it's working ignore the error as it's just something to do with your distribution.

Compiled on another system (32-bit too - so the bitness doesn't meter) - now works like a charm :-)
ArchitektoR
Full Member
***
Offline Offline

Activity: 171
Merit: 100


View Profile
February 24, 2015, 11:53:16 PM
 #66

Everything is UP and working on testnet - thanks once again for great software.

But when the block was found - all the reward (except the 0.5% fee) was sent to btcaddress of the ckpool.conf, not the worker/miner address. Even there is no data in logs about what worker found a block. What should I do (config or some extra software) to make it send the reward to miner address as solo.ckpool.org does?
-ck
Moderator
Legendary
*
Offline Offline

Activity: 2590
Merit: 1111


Ruu \o/


View Profile WWW
February 25, 2015, 01:07:18 AM
 #67

Everything is UP and working on testnet - thanks once again for great software.

But when the block was found - all the reward (except the 0.5% fee) was sent to btcaddress of the ckpool.conf, not the worker/miner address. Even there is no data in logs about what worker found a block. What should I do (config or some extra software) to make it send the reward to miner address as solo.ckpool.org does?
You can only mine to the ckpool.conf address. Solo.ckpool.org is special.

Primary developer/maintainer for cgminer and ckpool/ckproxy.
ZERO FEE Pooled mining at ckpool.org 1% Fee Solo mining at solo.ckpool.org
-ck
ArchitektoR
Full Member
***
Offline Offline

Activity: 171
Merit: 100


View Profile
February 25, 2015, 09:53:23 AM
 #68

And what kind of modification or add-on must be done to achieve the solo.ckpool functionality? We want to setup one here in Russia to get better pings.
-ck
Moderator
Legendary
*
Offline Offline

Activity: 2590
Merit: 1111


Ruu \o/


View Profile WWW
February 25, 2015, 10:00:07 AM
 #69

And what kind of modification or add-on must be done to achieve the solo.ckpool functionality? We want to setup one here in Russia to get better pings.
Custom code which is not part of the ckpool code. Like I said solo.ckpool.org is special and I'm not really interested in helping others set up a competing pool with the same unique feature.

Primary developer/maintainer for cgminer and ckpool/ckproxy.
ZERO FEE Pooled mining at ckpool.org 1% Fee Solo mining at solo.ckpool.org
-ck
ArchitektoR
Full Member
***
Offline Offline

Activity: 171
Merit: 100


View Profile
February 25, 2015, 01:38:36 PM
 #70

Custom code which is not part of the ckpool code. Like I said solo.ckpool.org is special and I'm not really interested in helping others set up a competing pool with the same unique feature.

OK, I understand your reasons Smiley - will try "dreadful Russian hackers" our community help. Thanks again for your work!
kano
Legendary
*
Offline Offline

Activity: 2520
Merit: 1045


Linux since 1997 RedHat 4


View Profile
February 26, 2015, 12:04:40 AM
 #71

Custom code which is not part of the ckpool code. Like I said solo.ckpool.org is special and I'm not really interested in helping others set up a competing pool with the same unique feature.

OK, I understand your reasons Smiley - will try "dreadful Russian hackers" our community help. Thanks again for your work!
In my opinion, the main issue is that people who want to run pools should have software development experience and be able to modify the pool code.
Not be some point and click ipad user who has to call apple if Candy Crush stops working Tongue

Otherwise if something goes wrong, everyone on the pool is stuck until ... "Hey can someone fix my pool" gets solved by who-knows-who Tongue

With CKDB I am of course open to answer questions about anyone who's brave enough to use it, but I'm not a developer training school for noobs, there's plenty of places you can go to learn about computers ...
You need to know what you are doing and then I'll help with questions that show you do know what you are doing.

Of course if you aren't trying to run a pool, or are just solo mining, from a standard user point of view, the proxy/pool code is well documented and well usable.

Pool: https://kano.is Here on Bitcointalk: Forum BTC: 1KanoPb8cKYqNrswjaA8cRDk4FAS9eDMLU
FreeNode IRC: irc.freenode.net channel #kano.is Majority developer of the ckpool code
Help keep Bitcoin secure by mining on pools with full block verification on all blocks - and NO empty blocks!
ArchitektoR
Full Member
***
Offline Offline

Activity: 171
Merit: 100


View Profile
February 26, 2015, 12:31:05 AM
 #72

In my opinion, the main issue is that people who want to run pools should have software development experience and be able to modify the pool code.
Not be some point and click ipad user who has to call apple if Candy Crush stops working Tongue

Otherwise if something goes wrong, everyone on the pool is stuck until ... "Hey can someone fix my pool" gets solved by who-knows-who Tongue

It looks like the task to modify the code is not very difficult for a programmer/developer, but I am not a programmer myself Smiley Rig and farm building, server and router setup from scratch, vmware virtualization and web mastering - but not a tr00 c0der, impossible to do everything. Community is for that - one can setup and configure a server, another - write some code, the third - adopt software.

Quote
With CKDB I am of course open to answer questions about anyone who's brave enough to use it, but I'm not a developer training school for noobs, there's plenty of places you can go to learn about computers ...
You need to know what you are doing and then I'll help with questions that show you do know what you are doing.

As you can see, there were NO questions about "give me the working solo.ckpool alternative", just the info about the "public solo pool functionality" is not implemented (or was removed Smiley ) from github version. Why was such a question - just because there IS solo.ckpool alternatives on the net and they are too based on ckpool code.

Quote
Of course if you aren't trying to run a pool, or are just solo mining, from a standard user point of view, the proxy/pool code is well documented and well usable.

For single-user purposes everything is better, then OK Smiley
-ck
Moderator
Legendary
*
Offline Offline

Activity: 2590
Merit: 1111


Ruu \o/


View Profile WWW
March 21, 2015, 06:17:54 AM
 #73

Someone calling themselves HASHPOOL found a block using the existing code Smiley

https://blockchain.info/tx/4eb1d6e38d5953155c6b5ca7950405c578937a42fcc37080996931a0b864bb68

Primary developer/maintainer for cgminer and ckpool/ckproxy.
ZERO FEE Pooled mining at ckpool.org 1% Fee Solo mining at solo.ckpool.org
-ck
zefir
Donator
Hero Member
*
Offline Offline

Activity: 919
Merit: 1000



View Profile
March 23, 2015, 08:48:02 AM
 #74

With the latest builds of bitcoind and ckpool, I am stuck with the following problem:
Code:
[2015-03-23 09:34:58] ckpool generator starting
[2015-03-23 09:34:58] ckpool stratifier starting
[2015-03-23 09:34:58] ckpool connector starting
[2015-03-23 09:34:58] Failed to recv in read_socket_line
[2015-03-23 09:34:58] Failed to read socket line in json_rpc_call
[2015-03-23 09:34:58] Reopening socket to localhost:8332
[2015-03-23 09:34:58] Failed to get valid json response to validate_address with errno 115: Operation now in progress
[2015-03-23 09:34:58] Invalid btcaddress: 14BMjogz69qe8hk9thyzbmR5pg34mVKB1e !
[2015-03-23 09:34:58] CRITICAL: No bitcoinds active!

What puzzles me is that I had ckpool running some time ago, i.e. the configuration files used should be correct. Still, it seems it is not a common problem.

I double checked that configurations should match by doing the rpc commands manually:
Code:
zefir@PC:~/work/bitcoin/src$ ./bitcoin-cli -rpcconnect=localhost -rpcport=8332 -rpcuser=rpc -rpcpassword=pass validateaddress 14BMjogz69qe8hk9thyzbmR5pg34mVKB1e
{
    "isvalid" : true,
    "address" : "14BMjogz69qe8hk9thyzbmR5pg34mVKB1e",
    "scriptPubKey" : "76a91422ddd9233f44ac2e9f183ec755adf134c12cdbf188ac"
}

which should mimic what ckpool should be doing with the configuration of
Code:
{
"btcd" :  [
{
"url" : "localhost:8332",
"auth" : "rpc",
"pass" : "pass",
"notify" : false
}
],
"logdir" : "/home/zefir/tmp/ckpool-log"
}

Anything obviously wrong? I'll debug and report back if not, just to be sure it is not some silly mistake at my side.

-ck
Moderator
Legendary
*
Offline Offline

Activity: 2590
Merit: 1111


Ruu \o/


View Profile WWW
March 23, 2015, 08:51:26 AM
 #75

With the latest builds of bitcoind

Anything obviously wrong? I'll debug and report back if not, just to be sure it is not some silly mistake at my side.
bitcoind rpc allow command changed

Primary developer/maintainer for cgminer and ckpool/ckproxy.
ZERO FEE Pooled mining at ckpool.org 1% Fee Solo mining at solo.ckpool.org
-ck
zefir
Donator
Hero Member
*
Offline Offline

Activity: 919
Merit: 1000



View Profile
March 23, 2015, 09:26:46 AM
 #76

With the latest builds of bitcoind

Anything obviously wrong? I'll debug and report back if not, just to be sure it is not some silly mistake at my side.
bitcoind rpc allow command changed

Ouch, so a running bitcoin-cli on localhost does not necessarily mean bitcoind is configured properly for every client on localhost?

Thanks for the hint, will check later today.

-ck
Moderator
Legendary
*
Offline Offline

Activity: 2590
Merit: 1111


Ruu \o/


View Profile WWW
March 24, 2015, 12:22:44 AM
 #77

I updated the version number to 0.8.7 and tagged M14 after a number of substantial updates and fixing a long standing crash bug that has been eluding me till now.

Primary developer/maintainer for cgminer and ckpool/ckproxy.
ZERO FEE Pooled mining at ckpool.org 1% Fee Solo mining at solo.ckpool.org
-ck
zefir
Donator
Hero Member
*
Offline Offline

Activity: 919
Merit: 1000



View Profile
March 24, 2015, 10:48:58 PM
 #78

With the latest builds of bitcoind

Anything obviously wrong? I'll debug and report back if not, just to be sure it is not some silly mistake at my side.
bitcoind rpc allow command changed

Ok, did some tracing to narrow down the issue. First off, it is not a bitcoind misconfiguration problem, since localhost always works (double checked using RPC interface over curl).

I observe that in function read_socket_line() in line ckpool.c:455 the recv() function returns 0 when 'validateaddress' is called after 'getblocktemplate' returned a very large response over the socket.

Following manpage, a return value of 0 for recv() has to be interpreted as 'peer has performed an orderly shutdown' which is not handled in read_socket_line(). Question remains why bitcoind is closing the socket, but at least this has to be handled accordingly by ckpool.

This is my debug log:
Code:
[2015-03-24 23:40:56] Opening /tmp/ckpool/generator
[2015-03-24 23:40:56] Unlinked /tmp/ckpool/generator to recreate socket
[2015-03-24 23:40:56] Opened server path /tmp/ckpool/generator successfully on socket 5
[2015-03-24 23:40:56] File /tmp/ckpool/generator.pid exists
[2015-03-24 23:40:56] Opening /tmp/ckpool/stratifier
[2015-03-24 23:40:56] Unlinked /tmp/ckpool/stratifier to recreate socket
[2015-03-24 23:40:56] Opened server path /tmp/ckpool/stratifier successfully on socket 7
[2015-03-24 23:40:56] File /tmp/ckpool/stratifier.pid exists
[2015-03-24 23:40:56] Opening /tmp/ckpool/connector
[2015-03-24 23:40:56] Unlinked /tmp/ckpool/connector to recreate socket
[2015-03-24 23:40:56] Opened server path /tmp/ckpool/connector successfully on socket 8
[2015-03-24 23:40:56] File /tmp/ckpool/connector.pid exists
[2015-03-24 23:40:56] ckpool stratifier starting
[2015-03-24 23:40:56] Opened client path /tmp/ckpool/listener successfully on socket 6
[2015-03-24 23:40:56] Listener received ping request
[2015-03-24 23:40:56] ckpool generator starting
[2015-03-24 23:40:56] Closing file handle 6
[2015-03-24 23:40:56] Attempting to connect to bitcoind
[2015-03-24 23:40:56] Listener received ping request
[2015-03-24 23:40:56] Opened client path /tmp/ckpool/listener successfully on socket 6
[2015-03-24 23:40:56] Closing file handle 6
[2015-03-24 23:40:56] Closing file handle 6
[2015-03-24 23:40:56] Opened client path /tmp/ckpool/generator successfully on socket 6
[2015-03-24 23:40:56] Closing file handle 6
[2015-03-24 23:40:56] ckpool connector starting
[2015-03-24 23:40:56] Succeeded delayed connect
[2015-03-24 23:40:56] json_rpc_call: REQ: {"method": "getblocktemplate", "params": [{"capabilities": ["coinbasetxn", "workid", "coinbase/append"]}]}

[2015-03-24 23:40:57] json_rpc_call: RESP: OK
[2015-03-24 23:40:57] Discarding:
[2015-03-24 23:40:57] MH0 dba90ae1e4c98ae65e07baa18c5735015a3850ea2db3771a71f193647966e278
[2015-03-24 23:40:57] MH1 928e668d417d547bbfc3237e727abdb5f81ff5a1d9a587afa7500697720f5917
[2015-03-24 23:40:57] MH2 23f8815bcb4b8275b0242b6cca6d844daa2e2398cbfb8c2fa721ac23197846ec
[2015-03-24 23:40:57] MH3 357c2632b29c0a71845aa3aed3c74f907a797095b1229957dbce378753c8db5c
[2015-03-24 23:40:57] MH4 d962fe3ba85ef5b919c90ceb9c5fb898e78f1f5df025ed280666dedd6c03f94f
[2015-03-24 23:40:57] MH5 0f3b07341144ef4290d0bbe8170fa45cc975a091a2816fa9fdb30367dd25634f
[2015-03-24 23:40:57] MH6 116582e86cae9fbf0df80bf929bce816743f05a9984389d8908eb2ca71e6f7f5
[2015-03-24 23:40:57] MH7 1a25a3929cdab41e9be026884027dec5835bbe4780f61810073d7fdacf8a9cf2
[2015-03-24 23:40:57] MH8 3175f8961f699a1f160497568cb86960d6d3ea30c346b777da9506b48cbdc0d9
[2015-03-24 23:40:57] MH9 5ea864a0f2a6752e545e05388ebd63664a592a770455340b0264905dd35635c2
[2015-03-24 23:40:57] Stored 540 transactions
[2015-03-24 23:40:57] json_rpc_call: REQ: {"method": "validateaddress", "params": ["14BMjogz69qe8hk9thyzbmR5pg34mVKB1e"]}

[2015-03-24 23:40:57] Failed to recv in read_socket_line: 0/0/Success
[2015-03-24 23:40:57] Closing file handle 6
[2015-03-24 23:40:57] Failed to read socket line in json_rpc_call
[2015-03-24 23:40:57] Reopening socket to 192.168.0.14:8332
[2015-03-24 23:40:57] Succeeded delayed connect
[2015-03-24 23:40:57] Failed to get valid json response to validate_address with errno 115: Operation now in progress
[2015-03-24 23:40:57] Invalid btcaddress: 14BMjogz69qe8hk9thyzbmR5pg34mVKB1e !
[2015-03-24 23:40:57] Closing file handle 6
[2015-03-24 23:40:57] CRITICAL: No bitcoinds active!

The modified error message gives ret/errno/strerror(errno), added with
Code:
diff --git a/src/ckpool.c b/src/ckpool.c
index 1ffe45f..4df333a 100644
--- a/src/ckpool.c
+++ b/src/ckpool.c
@@ -457,7 +457,7 @@ int read_socket_line(connsock_t *cs, const int timeout)
                        /* Closed socket after valid message */
                        if (eom)
                                break;
-                       LOGERR("Failed to recv in read_socket_line");
+                       LOGERR("Failed to recv in read_socket_line: %d/%d/%s", ret, errno, strerror(errno));
                        ret = -1;
                        goto out;
                }
@@ -678,6 +678,7 @@ json_t *json_rpc_call(connsock_t *cs, const char *rpc_req)
        json_t *val = NULL;
        int len, ret;
 
+       LOGDEBUG("json_rpc_call: REQ: %s", rpc_req);
        if (unlikely(cs->fd < 0)) {
                LOGWARNING("FD %d invalid in json_rpc_call", cs->fd);
                goto out;
@@ -738,6 +739,9 @@ json_t *json_rpc_call(connsock_t *cs, const char *rpc_req)
        val = json_loads(cs->buf, 0, &err_val);
        if (!val)
                LOGWARNING("JSON decode failed(%d): %s", err_val.line, err_val.text);
+       else
+               LOGDEBUG("json_rpc_call: RESP: OK");
+
 out_empty:
        empty_socket(cs->fd);
        empty_buffer(cs);

Will dig deeper tomorrow, just to leave here as probable bug report.

-ck
Moderator
Legendary
*
Offline Offline

Activity: 2590
Merit: 1111


Ruu \o/


View Profile WWW
March 25, 2015, 12:10:10 AM
 #79

I observe that in function read_socket_line() in line ckpool.c:455 the recv() function returns 0 when 'validateaddress' is called after 'getblocktemplate' returned a very large response over the socket.

Following manpage, a return value of 0 for recv() has to be interpreted as 'peer has performed an orderly shutdown' which is not handled in read_socket_line(). Question remains why bitcoind is closing the socket, but at least this has to be handled accordingly by ckpool.

This was changed post M13. Grab the latest milestone.

Primary developer/maintainer for cgminer and ckpool/ckproxy.
ZERO FEE Pooled mining at ckpool.org 1% Fee Solo mining at solo.ckpool.org
-ck
bgibso01
Legendary
*
Offline Offline

Activity: 1218
Merit: 1001



View Profile
April 19, 2015, 04:23:50 AM
 #80

CK/Kano,

Obviously I love the software! I mine on Ck and solo as a backup.  I am going to finally have some time to try and set this up here at the house and wondered if the pool server has a front end or is that something that will need to be created?  It's just a tinkering thing on my part.  Last year I setup an Eliopool and MPOS but have since wiped them.

Nevermind, read through the thread again.  Definitely like  the concept of two parts.  I understand keeping the CK solo pool handling of payouts not part of this code, but it sure would be handy for those that have different miners using different wallet addresses.
-ck
Moderator
Legendary
*
Offline Offline

Activity: 2590
Merit: 1111


Ruu \o/


View Profile WWW
April 30, 2015, 10:23:41 PM
 #81

Tagged milestone M15. Numerous bugfixes and performance improvements to ckpool and significant feature upgrades to ckdb, too many to describe in detail.

Primary developer/maintainer for cgminer and ckpool/ckproxy.
ZERO FEE Pooled mining at ckpool.org 1% Fee Solo mining at solo.ckpool.org
-ck
iegservers
Member
**
Offline Offline

Activity: 92
Merit: 10


View Profile
May 12, 2015, 12:39:30 AM
 #82

Hello everyone.  I have read through this forum, and only have one question that I cannot seem to find the answer.  Does the ckpool code auto-pay the block finder from the address in the ckpool.conf, or is it a manual pay until "I" modify code to auto pay from that hard-coded address to the block finders address ?

Thank you!
-ck
Moderator
Legendary
*
Offline Offline

Activity: 2590
Merit: 1111


Ruu \o/


View Profile WWW
May 12, 2015, 12:58:45 AM
 #83

Hello everyone.  I have read through this forum, and only have one question that I cannot seem to find the answer.  Does the ckpool code auto-pay the block finder from the address in the ckpool.conf, or is it a manual pay until "I" modify code to auto pay from that hard-coded address to the block finders address ?
There is no payout management at all in the code. ckdb includes calculations for PPLNS payouts but does not perform the payouts or manage the wallet itself.

Primary developer/maintainer for cgminer and ckpool/ckproxy.
ZERO FEE Pooled mining at ckpool.org 1% Fee Solo mining at solo.ckpool.org
-ck
iegservers
Member
**
Offline Offline

Activity: 92
Merit: 10


View Profile
May 12, 2015, 04:28:39 PM
 #84

Hello everyone.  I have read through this forum, and only have one question that I cannot seem to find the answer.  Does the ckpool code auto-pay the block finder from the address in the ckpool.conf, or is it a manual pay until "I" modify code to auto pay from that hard-coded address to the block finders address ?
There is no payout management at all in the code. ckdb includes calculations for PPLNS payouts but does not perform the payouts or manage the wallet itself.

Ok, thanks!

I have access to the wallet, so I will just manual pay, until I create a script to handle it.

iegservers
Member
**
Offline Offline

Activity: 92
Merit: 10


View Profile
May 12, 2015, 04:30:07 PM
 #85

Hello everyone.  I have read through this forum, and only have one question that I cannot seem to find the answer.  Does the ckpool code auto-pay the block finder from the address in the ckpool.conf, or is it a manual pay until "I" modify code to auto pay from that hard-coded address to the block finders address ?
There is no payout management at all in the code. ckdb includes calculations for PPLNS payouts but does not perform the payouts or manage the wallet itself.

Ok, thanks!

I have access to the wallet, so I will just manual pay, until I create a script to handle it.

Also, I do have one other issue that I do not see everone else having.  When I built CKPool with the CKDB flag, I got an error from postgrql saying Incorrect version, and the database was not created, therefore, I have no database!  Any ideas ?

Thanks!

kano
Legendary
*
Offline Offline

Activity: 2520
Merit: 1045


Linux since 1997 RedHat 4


View Profile
May 13, 2015, 10:08:36 PM
 #86

Hello everyone.  I have read through this forum, and only have one question that I cannot seem to find the answer.  Does the ckpool code auto-pay the block finder from the address in the ckpool.conf, or is it a manual pay until "I" modify code to auto pay from that hard-coded address to the block finders address ?
There is no payout management at all in the code. ckdb includes calculations for PPLNS payouts but does not perform the payouts or manage the wallet itself.

Ok, thanks!

I have access to the wallet, so I will just manual pay, until I create a script to handle it.
Also, I do have one other issue that I do not see everone else having.  When I built CKPool with the CKDB flag, I got an error from postgrql saying Incorrect version, and the database was not created, therefore, I have no database!  Any ideas ?

Thanks!
... create the database ...

... and I'll add my usual comment about this:
If you need someone to tell you how to create a database and configure it and can't understand the sql/ directory then you shouldn't be running a pool.
I wont ever be supplying step by step hand holding instructions for setting up ckdb since what needs to be done there is mostly what someone who can run a pool should know how to do.

If you ask questions that show that you know what you are doing, you will get answers.
If you ask questions for hand holding, I'll ignore them.

If you are going to ask more than 1 or 2 questions, then visit IRC, since I'm also not going to spend pages posting answers here.

I'm not interested in helping someone setup a pool that is bad for the miners if the pool OP can't fully manage the pool.
We have enough scams in the community without me helping people screw over miners (intentionally or unintentionally) Tongue

Pool: https://kano.is Here on Bitcointalk: Forum BTC: 1KanoPb8cKYqNrswjaA8cRDk4FAS9eDMLU
FreeNode IRC: irc.freenode.net channel #kano.is Majority developer of the ckpool code
Help keep Bitcoin secure by mining on pools with full block verification on all blocks - and NO empty blocks!
PrivacyBTC
Jr. Member
*
Offline Offline

Activity: 54
Merit: 0


View Profile
May 15, 2015, 01:12:40 PM
 #87

Its up to you

You can answer simple questions or ignore, but setup a db is not easy and some users here like me can pay for setup db pool .

if you can do it with charge it will be a solution than ignoring us .
Mikestang
Legendary
*
Offline Offline

Activity: 1148
Merit: 1000



View Profile
May 15, 2015, 03:58:16 PM
 #88


I'm not interested in helping someone setup a pool that is bad for the miners if the pool OP can't fully manage the pool.
We have enough scams in the community without me helping people screw over miners (intentionally or unintentionally) Tongue

I like your style, kano.  Now if only we could do something about some of those pools that do have "bad code" (for lack of a better description) that lets miners do things that are bad for bitcoin...
PrivacyBTC
Jr. Member
*
Offline Offline

Activity: 54
Merit: 0


View Profile
May 15, 2015, 08:17:12 PM
 #89

Hi Con

I spent about 10 h last night to connect but its always Failed to connect socket

I tried
localhost:8332
localhost:3333
myserverip:3333
myserverip:8332
myserverip:80
url:3333

still Failed to connect socket
No bitcoinds Active !

Im running centos 6.6

Also I cant find
bitcoin.conf  file as you said in documet

CKPOOL configuration

At least one bitcoind (aka btcd) is mandatory in ckpool mode with the minimum requirements of server, rpcuser and rpcpassword set. If no btcd is set up in the configuration, ckpool will look for a running bitcoind on the local machine on the default port 8332 and the username "user" and password "pass" set up.

At the very least you will need the following lines in your bitcoin.conf file:

Code:

server=1
rpcuser=user
rpcpassword=pass
rpcallowip=127.0.0.1
Gws24
Hero Member
*****
Offline Offline

Activity: 488
Merit: 502


View Profile
May 15, 2015, 08:21:08 PM
 #90

Bitcoind doesn't automatically create bitcoin.conf when you install it so you have to create one yourself. Make a new text file (with any text editor) and put in those lines. Then save it as bitoin.conf and put it in the bitcoin data directory.

Watch the extension of the file; it needs to be exactly bitcoin.conf and not for example bitcoin.conf.txt


edit: if your bitcoind is running on another pc then ckpool you'll have to put in 'rpcallowip=ip of ckpool pc' as well

edit: and for the port you might want to add 'rpcport=8332'. You can look at https://en.bitcoin.it/wiki/Running_Bitcoin#Bitcoin.conf_Configuration_File for all the options
PrivacyBTC
Jr. Member
*
Offline Offline

Activity: 54
Merit: 0


View Profile
May 15, 2015, 08:52:46 PM
 #91

Thank you very much

I'm creating it now .

I really appreciate your reply.

Thanks
Mikestang
Legendary
*
Offline Offline

Activity: 1148
Merit: 1000



View Profile
May 15, 2015, 09:02:02 PM
 #92


server=1
rpcuser=user
rpcpassword=pass
rpcallowip=127.0.0.1

Be sure to use a secure rpc username and password, like the one Bitcoind generates.
PrivacyBTC
Jr. Member
*
Offline Offline

Activity: 54
Merit: 0


View Profile
May 15, 2015, 09:14:03 PM
 #93

Thanks Mikestang
iegservers
Member
**
Offline Offline

Activity: 92
Merit: 10


View Profile
May 16, 2015, 05:16:30 PM
 #94

Hello everyone.  I have read through this forum, and only have one question that I cannot seem to find the answer.  Does the ckpool code auto-pay the block finder from the address in the ckpool.conf, or is it a manual pay until "I" modify code to auto pay from that hard-coded address to the block finders address ?
There is no payout management at all in the code. ckdb includes calculations for PPLNS payouts but does not perform the payouts or manage the wallet itself.

Ok, thanks!

I have access to the wallet, so I will just manual pay, until I create a script to handle it.
Also, I do have one other issue that I do not see everone else having.  When I built CKPool with the CKDB flag, I got an error from postgrql saying Incorrect version, and the database was not created, therefore, I have no database!  Any ideas ?

Thanks!
... create the database ...

... and I'll add my usual comment about this:
If you need someone to tell you how to create a database and configure it and can't understand the sql/ directory then you shouldn't be running a pool.
I wont ever be supplying step by step hand holding instructions for setting up ckdb since what needs to be done there is mostly what someone who can run a pool should know how to do.

If you ask questions that show that you know what you are doing, you will get answers.
If you ask questions for hand holding, I'll ignore them.

If you are going to ask more than 1 or 2 questions, then visit IRC, since I'm also not going to spend pages posting answers here.

I'm not interested in helping someone setup a pool that is bad for the miners if the pool OP can't fully manage the pool.
We have enough scams in the community without me helping people screw over miners (intentionally or unintentionally) Tongue


Its already been taken care of.  It is now up and running.. btw.. love the Findshare&&EveroneDie! Smiley
kano
Legendary
*
Offline Offline

Activity: 2520
Merit: 1045


Linux since 1997 RedHat 4


View Profile
May 18, 2015, 12:08:30 AM
 #95

...
Its already been taken care of.  It is now up and running.. btw.. love the Findshare&&EveroneDie! Smiley
Yeah all the main loops in all the threads, and the db loading at the start, check 'everyone_die'
It's a simple trigger to shut down in a tidy manner - once they all say they've finished, it then completes the (unnecessary) code shutdown of freeing all the ram and disconnecting.

There's a main loop that checks if 'everyone is dead' and reports every few seconds who isn't finished yet so you can see on shutdown if a thread has locked up for some unexpected reason, and which thread it is - and a Ctrl-C will simply kill it all then and there.
i.e. you can decide if it doesn't matter to hit Ctrl-C now and kill it during an unexpected shutdown failure
- rather than the code killing everything when you send a terminate message, and threads not having a chance to finish their current action

I do lots of updates to ckdb quite regularly - so if you want to stay up to date with it, it's best to idle in the #ckpool IRC to know when I make changes and ask if you need to know if there's any steps required with a change
e.g. the recent change to no longer storing sharesummaries in the permanent DB means you can:
 delete * from sharesummary; vacuum sharesummary;
since the leftover data in there is no longer needed

Watch out for disk space, the hourly logs can get big fast if you have a lot of shares coming in.
- also note you can compress the ckpool logs/ckdb2*.log files and the ckdb reload will still reload them, use any of: lrzip, bzip2 or gzip
... but don't compress the current one while it's still being written to or the hour in it's UTC name is current Smiley
all other log files can of course be compressed as and when you like since ckdb doesn't need to read them

Pool: https://kano.is Here on Bitcointalk: Forum BTC: 1KanoPb8cKYqNrswjaA8cRDk4FAS9eDMLU
FreeNode IRC: irc.freenode.net channel #kano.is Majority developer of the ckpool code
Help keep Bitcoin secure by mining on pools with full block verification on all blocks - and NO empty blocks!
tl121
Sr. Member
****
Offline Offline

Activity: 279
Merit: 250


View Profile
May 20, 2015, 05:00:44 PM
 #96

I have been running a bunch of S3+ to BTC Guild and solo.ckpool.  The other day I installed ckproxy to combine all my miners into one connection. This is working well, with essentially the same hash rate at the pools as before.  However, my individual miners are showing 10 - 13 % rejected shares and around 1% stales.  I am curious as to why I am getting these errors or if anyone else sees similar errors.

I am using standard configuration of ckproxy.  The miners are using August, 2014 firmware, with cgminer updated to 4.6.0.

jowo88
Full Member
***
Offline Offline

Activity: 193
Merit: 100


View Profile
June 02, 2015, 12:59:42 PM
 #97

Runing ckpool without ckdb on my vps one week,but every 2-3 hour showing error ,,

Code:
[2015-06-02 08:20:54] Failed to read socket line in json_rpc_call
[2015-06-02 08:20:54] Reopening socket to 127.0.0.1:8332                                                           
[2015-06-02 08:20:54] Failed to get valid json response to getblocktemplate                                             
[2015-06-02 08:20:54] Failed to get block template from 127.0.0.1:8332                                                 
[2015-06-02 08:20:54] Killing server                                                                                   
[2015-06-02 08:20:54] Generator returned failure in update_base                                                       
[2015-06-02 08:20:57] Failed over to bitcoind:

My vps spec
Ram 4Gb swap 4 Gb
bitcoind version 0.10.1
kano
Legendary
*
Offline Offline

Activity: 2520
Merit: 1045


Linux since 1997 RedHat 4


View Profile
June 02, 2015, 03:09:37 PM
 #98

You need more resources for bitcoind or protect it from the bitcoin network
It's god awful resource hungry and on occasions when you are getting spammed with transactions, it wont reply for quite a while.
I've spent a lot of time over the past 4 days dealing with bitcoin problems and making sure (in advance) that the 2 blocks my pool found over that time weren't orphans ...

Pool: https://kano.is Here on Bitcointalk: Forum BTC: 1KanoPb8cKYqNrswjaA8cRDk4FAS9eDMLU
FreeNode IRC: irc.freenode.net channel #kano.is Majority developer of the ckpool code
Help keep Bitcoin secure by mining on pools with full block verification on all blocks - and NO empty blocks!
jowo88
Full Member
***
Offline Offline

Activity: 193
Merit: 100


View Profile
June 02, 2015, 03:56:23 PM
 #99

You need more resources for bitcoind or protect it from the bitcoin network
It's god awful resource hungry and on occasions when you are getting spammed with transactions, it wont reply for quite a while.
I've spent a lot of time over the past 4 days dealing with bitcoin problems and making sure (in advance) that the 2 blocks my pool found over that time weren't orphans ...

Thank you for answer sir,,but on my control panel show like this
Code:
Memory Usage
20% 836.71 MB of 4 GB Used / 3.18 GB Free
VSwap Usage
5% 193.13 MB of 4 GB Used / 3.81 GB Free

Peer connected above 40,so with my problems like that,it's safe for solo mining or not sir...last day i was sending 1200Th and seems no problem,,but when i check ckpool.log showing error  Grin
kano
Legendary
*
Offline Offline

Activity: 2520
Merit: 1045


Linux since 1997 RedHat 4


View Profile
June 02, 2015, 10:28:29 PM
 #100

You need to look at bitcoind not ckpool.

Pool: https://kano.is Here on Bitcointalk: Forum BTC: 1KanoPb8cKYqNrswjaA8cRDk4FAS9eDMLU
FreeNode IRC: irc.freenode.net channel #kano.is Majority developer of the ckpool code
Help keep Bitcoin secure by mining on pools with full block verification on all blocks - and NO empty blocks!
jowo88
Full Member
***
Offline Offline

Activity: 193
Merit: 100


View Profile
June 04, 2015, 03:41:19 PM
 #101

You need more resources for bitcoind or protect it from the bitcoin network
It's god awful resource hungry and on occasions when you are getting spammed with transactions, it wont reply for quite a while.
I've spent a lot of time over the past 4 days dealing with bitcoin problems and making sure (in advance) that the 2 blocks my pool found over that time weren't orphans ...

Look at this address sir,, make me confuse https://blockchain.info/address/1CD523oyvmb9QVyABc1uu9Zt9ovjPzXV7h

Maybe this attack the network?
PrivacyBTC
Jr. Member
*
Offline Offline

Activity: 54
Merit: 0


View Profile
June 07, 2015, 07:06:04 PM
 #102

My Pool Now is Online Smiley)))

Thank You CK for your effort , Your ckpool now connected to bitcoind.

It's take about 14 days , more than 30 issues fixed until i seen my miners online and worked to my pool .

Actually it takes this period due to low resources on internet to running this kind of programs , Also my linux knowledge not so good .

I run bitcoind on windows server 2012  5G Ram 4 Processor

Running ckpool on centos   3g Ram .

Now Trying to fix Internal Server Error in webserver to got stats but ckpool.log is working fine for me as privet pool .

Now I don't care to spent 6 btc renting hash to my pool expect for orphans race .

Finlay Thanks very much you CK and Kano .
I ll be happy to know donation address to support this develop .

Regards


I got this Error every 10 minutes and sometimes every 1 h But pool working good and accept works .

[2015-06-09 02:29:27] Failed to recv in read_socket_line with errno 11: Resource temporarily unavailable
[2015-06-09 02:29:27] Failed to read http socket lines in json_rpc_call
[2015-06-09 02:29:27] Reopening socket to 64.#####:8332
[2015-06-09 02:29:27] Failed to get valid json response to getblocktemplate
[2015-06-09 02:29:29] Failed to recv in read_socket_line with errno 11: Resource temporarily unavailable
[2015-06-09 02:29:29] Failed to read http socket lines in json_rpc_call
[2015-06-09 02:29:29] Reopening socket to 64.#####:8332
[2015-06-09 02:29:29] Failed to get valid json response to getblocktemplate
[2015-06-09 02:29:29] CRITICAL: No bitcoinds active!

Restarting Bitcoind is a pain killer then restarting ckpool it return to

root@ip-###### [/home/owner/public_html]# ckpool -A
[2015-06-09 02:40:15] Unable to parse serverurl entries as an array
[2015-06-09 02:40:15] ckpool generator starting
[2015-06-09 02:40:15] ckpool stratifier starting
[2015-06-09 02:40:15] ckpool connector starting
[2015-06-09 02:40:16] ckpool connector ready
[2015-06-09 02:40:16] ckpool stratifier ready

tf315
Member
**
Offline Offline

Activity: 71
Merit: 10


View Profile
June 15, 2015, 05:51:13 PM
 #103

I've been using ckproxy on a Centos machine for a while to connect to Kano.is and haven't had any problems. Thanks for writing this - its nice to have one connection out instead of one per machine.

I thought I would see if one of the small project boards would work as a proxy so I compiled it on an Odroid C1 (fedora). Compiled easily with only signed/unsigned warnings and connects just fine to kano.is but I get the following error when a miner finds a share and tries to submit it:

[2015-06-13 23:36:56] Invalid json line:1 col:4 pos:4 text: NULL string argument from stratifier.c submit_share:2953
[2015-06-13 23:36:56] Attempted to send null message to generator in send_proc
[2015-06-13 23:37:00] Invalid json line:1 col:4 pos:4 text: NULL string argument from stratifier.c submit_share:2953
[2015-06-13 23:37:00] Attempted to send null message to generator in send_proc
[2015-06-13 23:37:06] Invalid json line:1 col:4 pos:4 text: NULL string argument from stratifier.c submit_share:2953
[2015-06-13 23:37:06] Attempted to send null message to generator in send_proc
[2015-06-13 23:37:12] Invalid json line:1 col:4 pos:4 text: NULL string argument from stratifier.c submit_share:2953
[2015-06-13 23:37:12] Attempted to send null message to generator in send_proc
[2015-06-13 23:37:13] Invalid json line:1 col:4 pos:4 text: NULL string argument from stratifier.c submit_share:2953
[2015-06-13 23:37:13] Attempted to send null message to generator in send_proc
[2015-06-13 23:37:17] Invalid json line:1 col:4 pos:4 text: NULL string argument from stratifier.c submit_share:2953
[2015-06-13 23:37:17] Attempted to send null message to generator in send_proc

Any ideas on what could cause this?

I have it running right now without any miners attached and the log just has standard messages (0 hashrate and block hash change messages). When miners attach, they show share submitals, etc so it looks OK on that side. But proxy has the errors above and the pool doesn't show the shares since I'm sure they're not getting submitted.

Thanks
-ck
Moderator
Legendary
*
Offline Offline

Activity: 2590
Merit: 1111


Ruu \o/


View Profile WWW
June 15, 2015, 09:58:59 PM
 #104


I thought I would see if one of the small project boards would work as a proxy so I compiled it on an Odroid C1 (fedora). Compiled easily with only signed/unsigned warnings and connects just fine to kano.is but I get the following error when a miner finds a share and tries to submit it:
32bit processor? There's no 32 bit support in ckpool code.

Primary developer/maintainer for cgminer and ckpool/ckproxy.
ZERO FEE Pooled mining at ckpool.org 1% Fee Solo mining at solo.ckpool.org
-ck
tf315
Member
**
Offline Offline

Activity: 71
Merit: 10


View Profile
June 15, 2015, 10:58:38 PM
 #105


I thought I would see if one of the small project boards would work as a proxy so I compiled it on an Odroid C1 (fedora). Compiled easily with only signed/unsigned warnings and connects just fine to kano.is but I get the following error when a miner finds a share and tries to submit it:
32bit processor? There's no 32 bit support in ckpool code.

Understood - but I thought I saw a message earlier that someone had compiled it on a 32bit processor and it worked. I expected it wouldn't compile if that were the issue but it does and connects to kano.is with no problem. Just can't submit any shares.

I'll drop the experiment. Thought a simple, cheap, power efficient proxy would be good to run vs having it on one of my servers. It would be good to have a redundant, backup proxy.
bgibso01
Legendary
*
Offline Offline

Activity: 1218
Merit: 1001



View Profile
June 24, 2015, 09:29:27 PM
 #106

I was kind of curious before trying to install CKPool to play around with.  What kind of share logs does it produce or the format of them?
-ck
Moderator
Legendary
*
Offline Offline

Activity: 2590
Merit: 1111


Ruu \o/


View Profile WWW
June 24, 2015, 11:12:40 PM
 #107

I was kind of curious before trying to install CKPool to play around with.  What kind of share logs does it produce or the format of them?
By default it doesn't log shares unless you enable the -L | --log-shares option.

If you do enable share logging it creates subdirectories for each stratum work update and a sharelog entry, eg:
logs/00058798/558b38ff00000000.sharelog     

each share is logged and looks like this:

Code:
{"workinfoid": 6164083182854471680, "enonce1": "00398b55", "clientid": 1, "createinet": "localhost:3333", "workername": "a", "createdate": "1435187472,294148559", "nonce2": "030000", "ntime": "558b38ff", "diff": 1.0, "result": true, "nonce": "9ffc0151", "hash": "00000000b2768b34f5af2ddcb197fbb8e30e2f2cdf9052bc23884de4fe6e86b1", "sdiff": 1.4344486271514834, "errn": 0, "createby": "code", "createcode": "parse_submit", "username": "a"} 

Primary developer/maintainer for cgminer and ckpool/ckproxy.
ZERO FEE Pooled mining at ckpool.org 1% Fee Solo mining at solo.ckpool.org
-ck
bgibso01
Legendary
*
Offline Offline

Activity: 1218
Merit: 1001



View Profile
June 25, 2015, 12:54:19 AM
 #108

I was kind of curious before trying to install CKPool to play around with.  What kind of share logs does it produce or the format of them?
By default it doesn't log shares unless you enable the -L | --log-shares option.

If you do enable share logging it creates subdirectories for each stratum work update and a sharelog entry, eg:
logs/00058798/558b38ff00000000.sharelog     

each share is logged and looks like this:

Code:
{"workinfoid": 6164083182854471680, "enonce1": "00398b55", "clientid": 1, "createinet": "localhost:3333", "workername": "a", "createdate": "1435187472,294148559", "nonce2": "030000", "ntime": "558b38ff", "diff": 1.0, "result": true, "nonce": "9ffc0151", "hash": "00000000b2768b34f5af2ddcb197fbb8e30e2f2cdf9052bc23884de4fe6e86b1", "sdiff": 1.4344486271514834, "errn": 0, "createby": "code", "createcode": "parse_submit", "username": "a"} 

Thanks for the post.  That was exactly what I wanted to know.  For my own playing around, I didn't want to have to deal with a database.  The logs look like they would be fine for importing csv info to calc if I wanted.
kano
Legendary
*
Offline Offline

Activity: 2520
Merit: 1045


Linux since 1997 RedHat 4


View Profile
June 25, 2015, 03:42:31 AM
 #109

... or you can just read the hourly logs/ckdbYYYYMMDDHH.log files that ckpool can create.

Pool: https://kano.is Here on Bitcointalk: Forum BTC: 1KanoPb8cKYqNrswjaA8cRDk4FAS9eDMLU
FreeNode IRC: irc.freenode.net channel #kano.is Majority developer of the ckpool code
Help keep Bitcoin secure by mining on pools with full block verification on all blocks - and NO empty blocks!
bgibso01
Legendary
*
Offline Offline

Activity: 1218
Merit: 1001



View Profile
June 27, 2015, 01:21:58 AM
 #110

Ok, since there's no such thing as stupid questions... Smiley

Can a pool get it's block info from any node that's port 8333 is open?  I realize most run their own node, but just curious.

Heading over to page 1 again in case it states it there.

Edit:  Ok, guess not.  Pools look at 8332?

Maybe I'm missing something, but why wouldn't we want pools to be able to get info from any node?
kano
Legendary
*
Offline Offline

Activity: 2520
Merit: 1045


Linux since 1997 RedHat 4


View Profile
June 27, 2015, 01:52:58 AM
 #111

Well the answer is 2 fold ...

Indeed why would such a restriction exist? It doesn't. Look at the sample ckpool.conf
https://bitbucket.org/ckolivas/ckpool/src/580cf3a2b29a2a5e585cc3fb86fb6bf3ac86fef4/ckpool.conf?at=master
The first thing in there ... "btcd"

However, going remote to do getblocktemplate? Youch.

GBT is (lack of) designed for local access only.
https://github.com/bitcoin/bitcoin/issues/1985#issuecomment-10061729

If you start adding extra delays to work generation - that would be a bad idea.

A pool should have a local bitcoind.
If you are trying to run a pool on low performance hardware, then expect to lose out because of that.

Pool: https://kano.is Here on Bitcointalk: Forum BTC: 1KanoPb8cKYqNrswjaA8cRDk4FAS9eDMLU
FreeNode IRC: irc.freenode.net channel #kano.is Majority developer of the ckpool code
Help keep Bitcoin secure by mining on pools with full block verification on all blocks - and NO empty blocks!
bgibso01
Legendary
*
Offline Offline

Activity: 1218
Merit: 1001



View Profile
June 27, 2015, 02:14:44 AM
 #112

Thanks.  Agreed.  Was just wondering if it would make more sense for a high speed node network.  But the more I think about it, the less centralized it becomes and that doesn't seem like a good thing.  I really like the implementation of CKPool.  I was running a full node earlier, but my cap is 350gb and with the household, I come really close to that with one running.
TimSweat
Sr. Member
****
Offline Offline

Activity: 392
Merit: 250

TimSweat


View Profile
July 12, 2015, 07:30:30 AM
 #113

Think I might stick my s1 on it for a few months and see if I get very very lucky . lmao , probably not but we will see .

achow101_alt
Sr. Member
****
Offline Offline

Activity: 268
Merit: 250


View Profile
July 12, 2015, 10:02:16 PM
 #114

I'm trying to set up the whole thing as a test and learning experience, and when I try to start ckdb, I always get this error
Code:
check_db_version(): Select failed (7) 'ERROR:  relation "version" does not exist LINE 1: select version() as pgv,* from version;
Why? I can see that that table doesn't exist in the database. Won't ckdb set up all of its necessary tables by itself?

Tip Me!: 1AQx99s7q1wVinbgXbA48BaZQVWpHe5gYM | My PGP Key: Fingerprint 0x17565732E08E5E41
kano
Legendary
*
Offline Offline

Activity: 2520
Merit: 1045


Linux since 1997 RedHat 4


View Profile
July 12, 2015, 11:16:12 PM
 #115

I'm trying to set up the whole thing as a test and learning experience, and when I try to start ckdb, I always get this error
Code:
check_db_version(): Select failed (7) 'ERROR:  relation "version" does not exist LINE 1: select version() as pgv,* from version;
Why? I can see that that table doesn't exist in the database. Won't ckdb set up all of its necessary tables by itself?
There are scripts in the sql/ folder ... have a look at them.

Pool: https://kano.is Here on Bitcointalk: Forum BTC: 1KanoPb8cKYqNrswjaA8cRDk4FAS9eDMLU
FreeNode IRC: irc.freenode.net channel #kano.is Majority developer of the ckpool code
Help keep Bitcoin secure by mining on pools with full block verification on all blocks - and NO empty blocks!
achow101_alt
Sr. Member
****
Offline Offline

Activity: 268
Merit: 250


View Profile
July 12, 2015, 11:23:03 PM
 #116

I'm trying to set up the whole thing as a test and learning experience, and when I try to start ckdb, I always get this error
Code:
check_db_version(): Select failed (7) 'ERROR:  relation "version" does not exist LINE 1: select version() as pgv,* from version;
Why? I can see that that table doesn't exist in the database. Won't ckdb set up all of its necessary tables by itself?
There are scripts in the sql/ folder ... have a look at them.
Ah. I see. thanks.

Tip Me!: 1AQx99s7q1wVinbgXbA48BaZQVWpHe5gYM | My PGP Key: Fingerprint 0x17565732E08E5E41
netnegar
Newbie
*
Offline Offline

Activity: 11
Merit: 0


View Profile
July 13, 2015, 11:18:48 AM
 #117

Dear All

I configured the ckpool and it is work right .
But I have a problem with web interface .
I appreciate if someone provide me a web configuration manual
or how we can connect the interface to ckpool

Regards
dogedood
Newbie
*
Offline Offline

Activity: 5
Merit: 0


View Profile
July 17, 2015, 07:00:21 AM
 #118

While running some tests on the pool software, I see lots of clients being dropped.

What do you make of this:

[2015-07-17 02:33:05.328] Client id 753 fd 22 RDHUP in epoll
[2015-07-17 02:33:05.329] Connector dropped client 753 fd 22
[2015-07-17 02:33:05.329] Opened client path /tmp/ckpool/stratifier successfully on socket 14
[2015-07-17 02:33:05.329] Closing file handle 14
[2015-07-17 02:33:05.329] Closing file handle 9
[2015-07-17 02:33:05.329] Connector recycling client 750
[2015-07-17 02:33:05.329] Closing file handle 744
[2015-07-17 02:33:05.329] Stratifier received request: dropclient=753
[2015-07-17 02:33:05.329] Stratifier asked to drop client 753
[2015-07-17 02:33:05.329] Dropped client 753 XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX

Is this normal behavior or a problem?

-ck
Moderator
Legendary
*
Offline Offline

Activity: 2590
Merit: 1111


Ruu \o/


View Profile WWW
July 17, 2015, 11:43:28 AM
 #119

While running some tests on the pool software, I see lots of clients being dropped.

What do you make of this:

[2015-07-17 02:33:05.328] Client id 753 fd 22 RDHUP in epoll
[2015-07-17 02:33:05.329] Connector dropped client 753 fd 22
[2015-07-17 02:33:05.329] Opened client path /tmp/ckpool/stratifier successfully on socket 14
[2015-07-17 02:33:05.329] Closing file handle 14
[2015-07-17 02:33:05.329] Closing file handle 9
[2015-07-17 02:33:05.329] Connector recycling client 750
[2015-07-17 02:33:05.329] Closing file handle 744
[2015-07-17 02:33:05.329] Stratifier received request: dropclient=753
[2015-07-17 02:33:05.329] Stratifier asked to drop client 753
[2015-07-17 02:33:05.329] Dropped client 753 XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX

Is this normal behavior or a problem?


If your clients are disconnecting, they're disconnecting from their end... there's nothing a pool can do to force them to stay connected.

Primary developer/maintainer for cgminer and ckpool/ckproxy.
ZERO FEE Pooled mining at ckpool.org 1% Fee Solo mining at solo.ckpool.org
-ck
dogedood
Newbie
*
Offline Offline

Activity: 5
Merit: 0


View Profile
July 17, 2015, 04:22:45 PM
 #120

Ok, thank you.
nicklello
Member
**
Offline Offline

Activity: 181
Merit: 10

“Open and Transparent Science Powered By Blockchai


View Profile
August 07, 2015, 12:25:43 PM
 #121

Slightly off-topic; but is there a list of known public ckpool pools that can be used as upstream pools for private pools ?

ORVIUM        Open and Transparent Science Powered By Blockchain        ORVIUM
█    Whitepaper        Telegram        Twitter        Facebook        Reddit        Blog    █
▇▆▅▃▃▃▃▃▃   Token Generation Event: Coming Soon   ▃▃▃▃▃▃▅▆▇
-ck
Moderator
Legendary
*
Offline Offline

Activity: 2590
Merit: 1111


Ruu \o/


View Profile WWW
August 07, 2015, 12:41:17 PM
 #122

Slightly off-topic; but is there a list of known public ckpool pools that can be used as upstream pools for private pools ?
I think the only two public ckpools are kano's pooled mining and my solo pooled mine; kano.is and solo.ckpool.org . I'm aware of private farms using ckpool either in pool, proxy or passthrough mode, but I'm not aware of any other public ckpools.

Primary developer/maintainer for cgminer and ckpool/ckproxy.
ZERO FEE Pooled mining at ckpool.org 1% Fee Solo mining at solo.ckpool.org
-ck
loshia
Legendary
*
Offline Offline

Activity: 1610
Merit: 1000


View Profile
August 07, 2015, 03:26:30 PM
 #123

Slightly off-topic; but is there a list of known public ckpool pools that can be used as upstream pools for private pools ?
I think the only two public ckpools are kano's pooled mining and my solo pooled mine; kano.is and solo.ckpool.org . I'm aware of private farms using ckpool either in pool, proxy or passthrough mode, but I'm not aware of any other public ckpools.
And http://tbdice.org

Please help the Led Boy aka Bicknellski to make us a nice Christmas led tree and pay WASP membership fee here:
https://bitcointalk.org/index.php?topic=643999.msg7191563#msg7191563
And remember Bicknellski is not collecting money from community;D
-ck
Moderator
Legendary
*
Offline Offline

Activity: 2590
Merit: 1111


Ruu \o/


View Profile WWW
August 07, 2015, 03:32:47 PM
 #124

Slightly off-topic; but is there a list of known public ckpool pools that can be used as upstream pools for private pools ?
I think the only two public ckpools are kano's pooled mining and my solo pooled mine; kano.is and solo.ckpool.org . I'm aware of private farms using ckpool either in pool, proxy or passthrough mode, but I'm not aware of any other public ckpools.
And http://tbdice.org
Now that you mention it, I think westhash's solo pool also uses ckpool.

Primary developer/maintainer for cgminer and ckpool/ckproxy.
ZERO FEE Pooled mining at ckpool.org 1% Fee Solo mining at solo.ckpool.org
-ck
loshia
Legendary
*
Offline Offline

Activity: 1610
Merit: 1000


View Profile
August 07, 2015, 05:54:02 PM
 #125

Slightly off-topic; but is there a list of known public ckpool pools that can be used as upstream pools for private pools ?
I think the only two public ckpools are kano's pooled mining and my solo pooled mine; kano.is and solo.ckpool.org . I'm aware of private farms using ckpool either in pool, proxy or passthrough mode, but I'm not aware of any other public ckpools.
And http://tbdice.org
Now that you mention it, I think westhash's solo pool also uses ckpool.
I think so Yes they do. ...
 

Please help the Led Boy aka Bicknellski to make us a nice Christmas led tree and pay WASP membership fee here:
https://bitcointalk.org/index.php?topic=643999.msg7191563#msg7191563
And remember Bicknellski is not collecting money from community;D
nicklello
Member
**
Offline Offline

Activity: 181
Merit: 10

“Open and Transparent Science Powered By Blockchai


View Profile
August 10, 2015, 07:16:07 AM
 #126

Building a pool on Debian;

Found one issue with building on Debian 8 --- I needed to modify the configure script to get the PostGres support to configure/compile.

The VM running CKProxy crashed overnight; I'm investigating what caused this....

Would it be of use if I were to provide my notes on getting a fully functional node working for inclusion in the git repo ?

Lastly, should ckpool (in pool mode) support connecting to an upstream pool as backup if the local bitcoind fails --- I tried using kano.is as backup but this did not work...


ORVIUM        Open and Transparent Science Powered By Blockchain        ORVIUM
█    Whitepaper        Telegram        Twitter        Facebook        Reddit        Blog    █
▇▆▅▃▃▃▃▃▃   Token Generation Event: Coming Soon   ▃▃▃▃▃▃▅▆▇
kano
Legendary
*
Offline Offline

Activity: 2520
Merit: 1045


Linux since 1997 RedHat 4


View Profile
August 10, 2015, 07:49:26 AM
 #127

Building a pool on Debian;

Found one issue with building on Debian 8 --- I needed to modify the configure script to get the PostGres support to configure/compile.
Works as is (of course) on Ubuntu and Fedora - no idea what the difference would be on debian.

Quote
...
Would it be of use if I were to provide my notes on getting a fully functional node working for inclusion in the git repo ?
Not for ckdb/web as I've stated a few times in here:
e.g. https://bitcointalk.org/index.php?topic=790323.msg11369243#msg11369243

Quote
Lastly, should ckpool (in pool mode) support connecting to an upstream pool as backup if the local bitcoind fails --- I tried using kano.is as backup but this did not work...
The pool is a pool, not a proxy.
What you are describing is setting up a proxy that points to both your pool and my pool.
As for when it fails over, well that depends on what happens to the pool.

Pool: https://kano.is Here on Bitcointalk: Forum BTC: 1KanoPb8cKYqNrswjaA8cRDk4FAS9eDMLU
FreeNode IRC: irc.freenode.net channel #kano.is Majority developer of the ckpool code
Help keep Bitcoin secure by mining on pools with full block verification on all blocks - and NO empty blocks!
nicklello
Member
**
Offline Offline

Activity: 181
Merit: 10

“Open and Transparent Science Powered By Blockchai


View Profile
August 12, 2015, 04:07:00 PM
 #128

Hi Kano,

Building a pool on Debian;

Found one issue with building on Debian 8 --- I needed to modify the configure script to get the PostGres support to configure/compile.
Works as is (of course) on Ubuntu and Fedora - no idea what the difference would be on debian.
Seems the GSL library in the Debian 8 repository no longer has main() ; configure needed to be told to also link in gslcblas (which is tested afterward) in order to work.... bit of a kludge on my part to get things to configure.

Quote
Quote
...
Would it be of use if I were to provide my notes on getting a fully functional node working for inclusion in the git repo ?
Not for ckdb/web as I've stated a few times in here:
e.g. https://bitcointalk.org/index.php?topic=790323.msg11369243#msg11369243
Fair enough...

Quote
Quote
Lastly, should ckpool (in pool mode) support connecting to an upstream pool as backup if the local bitcoind fails --- I tried using kano.is as backup but this did not work...
The pool is a pool, not a proxy.
What you are describing is setting up a proxy that points to both your pool and my pool.
As for when it fails over, well that depends on what happens to the pool.
I didn't think this one through properly... of course it needs to be another bitcoin server for the failover.


I have everything built and working on a single machine now..

The Systems Architect in me wants to break it all up into separate (virtual) machines;

I'd would like to setup:-
  • a VM for (walletless) bitcoin
  • a second (walletless) bitcoin server VM (if/when I go 'live') for failover
  • ckdb + postgres server
  • warm standby ckdb + failover postgres server
  • a ckpool server
  • a web server
  • a data backup server (literally just software and storage to backup to)

*however* looking at the close bindings between ckpool, ckdb and the web code is it even possible to split these onto separate machines ?

The idea is to keep everything loosely coupled to allow any component to be grown/shrunk/replaced; makes for a quick way to tear down and replace any machine that gets compromised.

Also, is any work being undertaken on the web code ? -- there are some tweaks I'd like to make but I don't want to duplicate effort.

Lastly, are you open to any tweaks being submitted as new branches / pull requests on the Bitbucket respository...


Regards,
Nick

ORVIUM        Open and Transparent Science Powered By Blockchain        ORVIUM
█    Whitepaper        Telegram        Twitter        Facebook        Reddit        Blog    █
▇▆▅▃▃▃▃▃▃   Token Generation Event: Coming Soon   ▃▃▃▃▃▃▅▆▇
kano
Legendary
*
Offline Offline

Activity: 2520
Merit: 1045


Linux since 1997 RedHat 4


View Profile
August 12, 2015, 09:48:57 PM
 #129

Building a pool on Debian;

Found one issue with building on Debian 8 --- I needed to modify the configure script to get the PostGres support to configure/compile.
...
Seems the GSL library in the Debian 8 repository no longer has main() ; configure needed to be told to also link in gslcblas (which is tested afterward) in order to work.... bit of a kludge on my part to get things to configure.
Then see how -ck did it for postgresql and do something similar and submit a change for configure.ac

*however* looking at the close bindings between ckpool, ckdb and the web code is it even possible to split these onto separate machines ?

The idea is to keep everything loosely coupled to allow any component to be grown/shrunk/replaced; makes for a quick way to tear down and replace any machine that gets compromised.
They use linux sockets, so yeah not really possible with ckdb <-> ckpool with the current code.

The bitcoind needs to be REAL close since block changes need to be as fast as possible.
Block changes and sending out new work on a block change is so important on any pool, though it would seem that a lot of people can't understand that and mine on slow block change pools ... ... ... their loss.

Sooner or later (in the distant future? Smiley ) I'll write a separate (tiny) program as a standard socket that sits in front of ckdb, then it's only a matter of changing some of socket.php to talk to ckdb 'remotely' - i.e. web can be anywhere then.

Quote
Also, is any work being undertaken on the web code ? -- there are some tweaks I'd like to make but I don't want to duplicate effort.
? I don't commit often enough ??

Quote
Lastly, are you open to any tweaks being submitted as new branches / pull requests on the Bitbucket respository...

Regards,
Nick
Of course, but also you are best to have your own git fork (as I'm sure you do already) so that if you submit changes that aren't what I want, you still have your own version.

As I mentioned in the link before, asking in IRC is best regarding lots of questions.

There is a very long list of changes that I keep adding new ones to the list (that I write down any time I think of something) - for all sorts of reasons for each - some minor and some major Smiley

Pool: https://kano.is Here on Bitcointalk: Forum BTC: 1KanoPb8cKYqNrswjaA8cRDk4FAS9eDMLU
FreeNode IRC: irc.freenode.net channel #kano.is Majority developer of the ckpool code
Help keep Bitcoin secure by mining on pools with full block verification on all blocks - and NO empty blocks!
ldp
Newbie
*
Offline Offline

Activity: 11
Merit: 0


View Profile
September 09, 2015, 04:53:13 PM
 #130


I have the same problem building (with ckdb) on Debian :

Error: Required library gsl-dev not found. Install it or disable support with --without-ckdb

What changes are needed to enable the build ?

Thanks
kano
Legendary
*
Offline Offline

Activity: 2520
Merit: 1045


Linux since 1997 RedHat 4


View Profile
September 09, 2015, 09:48:29 PM
 #131


I have the same problem building (with ckdb) on Debian :

Error: Required library gsl-dev not found. Install it or disable support with --without-ckdb

What changes are needed to enable the build ?

Thanks
I updated the README a week ago and it shows the ubuntu requirements for gsl.
You'll have to work out how to translate that to debian if debian has different package names.

Pool: https://kano.is Here on Bitcointalk: Forum BTC: 1KanoPb8cKYqNrswjaA8cRDk4FAS9eDMLU
FreeNode IRC: irc.freenode.net channel #kano.is Majority developer of the ckpool code
Help keep Bitcoin secure by mining on pools with full block verification on all blocks - and NO empty blocks!
goodgryphon
Member
**
Offline Offline

Activity: 106
Merit: 10


View Profile
September 15, 2015, 03:08:59 AM
 #132

how do you know if u find a block solo mining solo.ckpool, my ant says it found a block but how do i confirm this?
tokona44
Member
**
Offline Offline

Activity: 111
Merit: 10


View Profile
September 22, 2015, 10:36:42 PM
 #133

Question, can i use CKPOOL files to set up my own private pool on a raspberry pi to mine Peercoin solo with rent and home hash?
kano
Legendary
*
Offline Offline

Activity: 2520
Merit: 1045


Linux since 1997 RedHat 4


View Profile
September 22, 2015, 11:38:09 PM
 #134

Question, can i use CKPOOL files to set up my own private pool on a raspberry pi to mine Peercoin solo with rent and home hash?
No idea - we don't support any sort of alt-coin mining at all and no point asking questions about it here.

However, any mining needs a full fledged, high performance, hacked bitcoind ... so yeah that, oddly enough, wont run on an rpi.

Pool: https://kano.is Here on Bitcointalk: Forum BTC: 1KanoPb8cKYqNrswjaA8cRDk4FAS9eDMLU
FreeNode IRC: irc.freenode.net channel #kano.is Majority developer of the ckpool code
Help keep Bitcoin secure by mining on pools with full block verification on all blocks - and NO empty blocks!
tokona44
Member
**
Offline Offline

Activity: 111
Merit: 10


View Profile
September 22, 2015, 11:57:38 PM
 #135

Question, can i use CKPOOL files to set up my own private pool on a raspberry pi to mine Peercoin solo with rent and home hash?
No idea - we don't support any sort of alt-coin mining at all and no point asking questions about it here.

However, any mining needs a full fledged, high performance, hacked bitcoind ... so yeah that, oddly enough, wont run on an rpi.
Yea ok np, was just thinking its a sha256 coin. But can i run a bitcoin-qt wallet on a rpi and mine solo on 127.0.0.1?? any way to set a stratum url for rent mining to home QT? 
kano
Legendary
*
Offline Offline

Activity: 2520
Merit: 1045


Linux since 1997 RedHat 4


View Profile
September 23, 2015, 12:44:55 AM
 #136

Question, can i use CKPOOL files to set up my own private pool on a raspberry pi to mine Peercoin solo with rent and home hash?
No idea - we don't support any sort of alt-coin mining at all and no point asking questions about it here.

However, any mining needs a full fledged, high performance, hacked bitcoind ... so yeah that, oddly enough, wont run on an rpi.
Yea ok np, was just thinking its a sha256 coin. But can i run a bitcoin-qt wallet on a rpi ...
I very much doubt it, but if you could, you'd be silly to mine to it coz you'd have a VERY high chance of losing blocks you mine.

Quote
However, any mining needs a full fledged, high performance, hacked bitcoind

Pool: https://kano.is Here on Bitcointalk: Forum BTC: 1KanoPb8cKYqNrswjaA8cRDk4FAS9eDMLU
FreeNode IRC: irc.freenode.net channel #kano.is Majority developer of the ckpool code
Help keep Bitcoin secure by mining on pools with full block verification on all blocks - and NO empty blocks!
tokona44
Member
**
Offline Offline

Activity: 111
Merit: 10


View Profile
September 23, 2015, 03:34:19 AM
 #137

Question, can i use CKPOOL files to set up my own private pool on a raspberry pi to mine Peercoin solo with rent and home hash?
No idea - we don't support any sort of alt-coin mining at all and no point asking questions about it here.

However, any mining needs a full fledged, high performance, hacked bitcoind ... so yeah that, oddly enough, wont run on an rpi.
Yea ok np, was just thinking its a sha256 coin. But can i run a bitcoin-qt wallet on a rpi ...
I very much doubt it, but if you could, you'd be silly to mine to it coz you'd have a VERY high chance of losing blocks you mine.

Quote
However, any mining needs a full fledged, high performance, hacked bitcoind
Okie dokie i trust you kano. Thanks
Lyddite
Member
**
Offline Offline

Activity: 97
Merit: 10



View Profile
October 22, 2015, 08:32:37 AM
 #138

Please, it's 2015. This is 64 bit code only, but if it's working ignore the error as it's just something to do with your distribution.

Compiled on another system (32-bit too - so the bitness doesn't meter) - now works like a charm :-)

Ok... this explains the problems I have had... Whether it works on a 32 bit system depends on how you use it.


I thought I would see if one of the small project boards would work as a proxy so I compiled it on an Odroid C1 (fedora). Compiled easily with only signed/unsigned warnings and connects just fine to kano.is but I get the following error when a miner finds a share and tries to submit it:
32bit processor? There's no 32 bit support in ckpool code.

Understood - but I thought I saw a message earlier that someone had compiled it on a 32bit processor and it worked. I expected it wouldn't compile if that were the issue but it does and connects to kano.is with no problem. Just can't submit any shares.

I'll drop the experiment. Thought a simple, cheap, power efficient proxy would be good to run vs having it on one of my servers. It would be good to have a redundant, backup proxy.

I managed to compile and run using debian jessie  and
Code:
./configure --without-ckdb
with the intention of running it on an old laptop as a proxy and hoping to get some nice logs.

Did not succeed in getting the "-p" proxy to run

It would almost work but the following would appear in the logs and eventually the hashrate on the pool ( kano.is ) would drop off and it would fail to submit shares.

Code:
Invalid json line:1 col:4 pos:4 text: NULL string argument from stratifier.c submit_share:2965
Attempted to send null message to generator in send_proc

The passthrough proxy "-P" does work well in 32 bit. The hashrates add up and each worker shows up on the pool. I have used it for several weeks to combine the connections from miners on different machines.

Code:
Failed to set json object from connector.c connector_stats:782
 Invalid json line:1 col:5 pos:5 text: NULL string argument from connector.c connector_stats:784
 Failed to set json object from connector.c connector_stats:787
 Passthrough:{"runtime": 593}

My advice to anyone ckpool/ckproxy with a 32 bit system is to experiment, test, check the logs and verify that the hashrates  correspond at all ends. Difficulty adjustments can complicate the testing.

It would be nice if everything worked without problems on 32 bit systems. Then again, I should probably ditch the old laptops. For the record, I'm running my small ckproxy on an old Compaq Evo N410, Pentium III, 1200MHz ca. 2003.  Grin

- Lyddite -
-ck
Moderator
Legendary
*
Offline Offline

Activity: 2590
Merit: 1111


Ruu \o/


View Profile WWW
November 22, 2015, 08:01:10 PM
 #139

I just set up the proxy to migrate away from p2pool without having to update each miner to a new URL. There seems to be an issue if the username on the miners contains p2pool difficulty settings such as "/256+256" tacked on to the end of the username. The miners using this technique see the ckproxy as dead.
The slash is illegal in the username and pointless to use with p2pool anyway. The + should work though.

Primary developer/maintainer for cgminer and ckpool/ckproxy.
ZERO FEE Pooled mining at ckpool.org 1% Fee Solo mining at solo.ckpool.org
-ck
.anto.
Full Member
***
Offline Offline

Activity: 162
Merit: 100


View Profile
November 29, 2015, 11:11:44 PM
 #140


I thought I would see if one of the small project boards would work as a proxy so I compiled it on an Odroid C1 (fedora). Compiled easily with only signed/unsigned warnings and connects just fine to kano.is but I get the following error when a miner finds a share and tries to submit it:
32bit processor? There's no 32 bit support in ckpool code.

Hi Con,

I don't believe that you clearly explained the requirement to use Linux amd64 for your CKPool. The only error I saw from the previous posts is the "unknown type name sa_family_t" from /usr/include/linux/un.h.

Could you please explain in detail which parts on your CKPool require Linux amd64?

The main reason I asked is that, for small VPS it is more efficient - in term of the RAM usage - to use Linux i386 instead of amd64.  So it would be helpful to know the impact of compiling and running your CKPool on Linux i386.

Cheers,

Anto
-ck
Moderator
Legendary
*
Offline Offline

Activity: 2590
Merit: 1111


Ruu \o/


View Profile WWW
November 29, 2015, 11:16:33 PM
 #141

Hi Con,

I don't believe that you clearly explained the requirement to use Linux amd64 for your CKPool. The only error I saw from the previous posts is the "unknown type name sa_family_t" from /usr/include/linux/un.h.

Could you please explain in detail which parts on your CKPool require Linux amd64?

The main reason I asked is that, for small VPS it is more efficient - in term of the RAM usage - to use Linux i386 instead of amd64.  So it would be helpful to know the impact of compiling and running your CKPool on Linux i386.

Cheers,

Anto
The answer is I don't care so I've not bothered to make sure the code is fine on 32bit architectures and I don't want to care. You have your priorities wrong if you are worried about that on a pool.

Primary developer/maintainer for cgminer and ckpool/ckproxy.
ZERO FEE Pooled mining at ckpool.org 1% Fee Solo mining at solo.ckpool.org
-ck
kano
Legendary
*
Offline Offline

Activity: 2520
Merit: 1045


Linux since 1997 RedHat 4


View Profile
November 29, 2015, 11:17:50 PM
 #142

I'm really not sure how a 32bit OS can be more efficient on 64bit hardware ...

Edit: ... and I'll add that mining requires 64bit math quite a bit ... since 4billion really isn't a big enough number Smiley
So all that code would be slower.

Pool: https://kano.is Here on Bitcointalk: Forum BTC: 1KanoPb8cKYqNrswjaA8cRDk4FAS9eDMLU
FreeNode IRC: irc.freenode.net channel #kano.is Majority developer of the ckpool code
Help keep Bitcoin secure by mining on pools with full block verification on all blocks - and NO empty blocks!
.anto.
Full Member
***
Offline Offline

Activity: 162
Merit: 100


View Profile
November 29, 2015, 11:35:24 PM
 #143

Hi Con,

I don't believe that you clearly explained the requirement to use Linux amd64 for your CKPool. The only error I saw from the previous posts is the "unknown type name sa_family_t" from /usr/include/linux/un.h.

Could you please explain in detail which parts on your CKPool require Linux amd64?

The main reason I asked is that, for small VPS it is more efficient - in term of the RAM usage - to use Linux i386 instead of amd64.  So it would be helpful to know the impact of compiling and running your CKPool on Linux i386.

Cheers,

Anto
The answer is I don't care so I've not bothered to make sure the code is fine on 32bit architectures and I don't want to care. You have your priorities wrong if you are worried about that on a pool.
I clearly didn't ask or demanded that you should make sure your code run on i386. I just asked which parts rely on amd64. So never mind then.
.anto.
Full Member
***
Offline Offline

Activity: 162
Merit: 100


View Profile
November 30, 2015, 08:35:14 AM
 #144

I'm really not sure how a 32bit OS can be more efficient on 64bit hardware ...

Edit: ... and I'll add that mining requires 64bit math quite a bit ... since 4billion really isn't a big enough number Smiley
So all that code would be slower.

I am not a programmer and I know very little about 32bit vs 64bit programs. However, some years ago when I started to rent VPS for my private web site, I did some readings and testing myself. I have made the conclusion that Linux i386 is more efficient in using the RAM than Linux amd64. Somebody did more thorough tests than me and posted the results on this web page, if you wanted to know that.
kano
Legendary
*
Offline Offline

Activity: 2520
Merit: 1045


Linux since 1997 RedHat 4


View Profile
November 30, 2015, 03:38:14 PM
 #145

As I already implied, the software is full of 64bit maths and that will produce a noticeable difference, as will having double the registers in general code.

... and you will find that 5 year old link quite outdated now ... comments about not everyone having 64bit processors and "fewer issues" with 32bit are now wrong.
It's the other way around, fewer issues with 64bit and I'm not sure you can even find 32bit processors online any more.
If you can, you've been given old dodgy hardware.

Now the most relevant point ... if you want to run a pool, and you are trying to skimp on hardware, be well aware that you may lose blocks.
You need a bitcoind, and running one on a small vps is a problem waiting to happen.

Pool: https://kano.is Here on Bitcointalk: Forum BTC: 1KanoPb8cKYqNrswjaA8cRDk4FAS9eDMLU
FreeNode IRC: irc.freenode.net channel #kano.is Majority developer of the ckpool code
Help keep Bitcoin secure by mining on pools with full block verification on all blocks - and NO empty blocks!
.anto.
Full Member
***
Offline Offline

Activity: 162
Merit: 100


View Profile
November 30, 2015, 04:53:25 PM
 #146

As I already implied, the software is full of 64bit maths and that will produce a noticeable difference, as will having double the registers in general code.

... and you will find that 5 year old link quite outdated now ... comments about not everyone having 64bit processors and "fewer issues" with 32bit are now wrong.
It's the other way around, fewer issues with 64bit and I'm not sure you can even find 32bit processors online any more.
If you can, you've been given old dodgy hardware.
I am quite sure that I didn't mention anything related to 32bit processors. My questions are clearly related to the use CKPool software on VPS with Linux i386, which are still very easy to get from all Linux distros or compile it ourselves. All VPS' definitely use 64bit capable processors.

Now the most relevant point ... if you want to run a pool, and you are trying to skimp on hardware, be well aware that you may lose blocks.
You need a bitcoind, and running one on a small vps is a problem waiting to happen.
Again, I am not asking anything outside running CKPool software on VPS with Linux i386. I know the impact of running bitcoind on VPS with RAM less than 2GB as I experience the issues myself, e.g. bitcoind regularly crashes. So I have the full node running on a real hardware with a Quad Core 2 GHz each and 8 GB RAM. However, the bandwidth of the link of the full node is asymmetric. So I want to have the pool software on the VPS with symmetric bandwidth to be able to better manage the user connections.

Anyway, this discussion does not seem to lead anywhere. But thanks for responding to my questions.
kano
Legendary
*
Offline Offline

Activity: 2520
Merit: 1045


Linux since 1997 RedHat 4


View Profile
November 30, 2015, 10:24:57 PM
 #147

As I already implied, the software is full of 64bit maths and that will produce a noticeable difference, as will having double the registers in general code.

... and you will find that 5 year old link quite outdated now ... comments about not everyone having 64bit processors and "fewer issues" with 32bit are now wrong.
It's the other way around, fewer issues with 64bit and I'm not sure you can even find 32bit processors online any more.
If you can, you've been given old dodgy hardware.
I am quite sure that I didn't mention anything related to 32bit processors. My questions are clearly related to the use CKPool software on VPS with Linux i386, which are still very easy to get from all Linux distros or compile it ourselves. All VPS' definitely use 64bit capable processors.
Right so running i386 code on them pretends it's a 32bit processor missing all the vast gains in current 64bit processors,
the most obvious one (even mentioned at your very old link) being double the number of registers.

Quote
Now the most relevant point ... if you want to run a pool, and you are trying to skimp on hardware, be well aware that you may lose blocks.
You need a bitcoind, and running one on a small vps is a problem waiting to happen.
Again, I am not asking anything outside running CKPool software on VPS with Linux i386. I know the impact of running bitcoind on VPS with RAM less than 2GB as I experience the issues myself, e.g. bitcoind regularly crashes. So I have the full node running on a real hardware with a Quad Core 2 GHz each and 8 GB RAM. However, the bandwidth of the link of the full node is asymmetric. So I want to have the pool software on the VPS with symmetric bandwidth to be able to better manage the user connections.

Anyway, this discussion does not seem to lead anywhere. But thanks for responding to my questions.
So your design is to have a pool's main connection talking to a remote bitcoind ... sounds like a bad idea to me.
As for bandwidth, bitcoind will be higher than the pool unless you have a big pool ...

Pool: https://kano.is Here on Bitcointalk: Forum BTC: 1KanoPb8cKYqNrswjaA8cRDk4FAS9eDMLU
FreeNode IRC: irc.freenode.net channel #kano.is Majority developer of the ckpool code
Help keep Bitcoin secure by mining on pools with full block verification on all blocks - and NO empty blocks!
e46btc
Full Member
***
Offline Offline

Activity: 136
Merit: 100


View Profile
December 12, 2015, 01:16:46 PM
 #148

Can someone give advice why ckdb (latest ver from git) can't connect via RPC to local bitcoind (v0.11.2) ?  

At least I am trying to setup BTC payout address in User settings (web) but got error ERR: Invalid BTC address

First time ckdb was not able to connect to standard bitcoind RPC port 8332 as it was hardcoded to 8330  in ckdb.c
Code:
char *btc_server = "http://127.0.0.1:8330";
char *btc_auth;

I've changed to 8332 and recompiled, it is connected but still no luck

Code:
[2015-12-12 13:04:28.923+00] _btc_io() btc server response not ok: HTTP/1.0 401 Authorization Required0x0d0x0aDate: Sat, 12 Dec 2015 13:04:28 +00000x0d0x0aServer: bitcoin-json-rpc/v0.11.2.0-g7e278920x0d0x0a
WWW-Authenticate: Basic realm="jsonrpc"0x0d0x0aContent-Type: text/html0x0d0x0aContent-Length: 2960x0d0x0a0x0d0x0a<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
0x0d0x0a"http://www.w3.org/TR/1999/REC-html401-19991224/loose.dtd">0x0d0x0a<HTML>0x0d0x0a<HEAD>0x0d0x0a<TITLE>Error</TITLE>0x0d0x0a<META HTTP-EQUIV='Content-Type'
CONTENT='text/html; charset=ISO-8859-1'>0x0d0x0a</HEAD>0x0d0x0a<BODY><H1>401 Unauthorized.</H1></BODY>0x0d0x0a</HTML>0x0d0x0a0x00
[2015-12-12 13:04:28.923+00] usersettings.userset5111.ERR.Invalid BTC address

I've tried to recompile this again w/ hardcoded username/password  in ckdb.c
Code:
char *btc_server = "http://127.0.0.1:8332";
char *btc_auth = "USER:PASS";

according to
Code:
snprintf(buf, sizeof(buf), "%s:%s", btc_user, btc_pass);
btc_auth = http_base64(buf);

but the same result, this can't authenticate against bitcoind RPC.  

Any hints will be highly appreciated. Thanks!

ps: ckpool works fine via RPC using user/pass from ckpool.conf  , so there is no mistake in user/pass

https://double-spending.com/ - Automatic double-spending tool
https://dgb256.online - Digibyte DGB pool for SHA256 algorithm
kano
Legendary
*
Offline Offline

Activity: 2520
Merit: 1045


Linux since 1997 RedHat 4


View Profile
December 12, 2015, 01:50:40 PM
 #149

command line:
./ckdb -p pgsqlpass -U btcuser -P btcpass -S http://127.0.0.1:8332 -m -g

https://bitbucket.org/ckolivas/ckpool/src/96d6707511de3cfcee37261a5e0516791789e1ff/src/ckdb.c?at=master&fileviewer=file-view-default#ckdb.c-5631

Edit: and of course below that:

https://bitbucket.org/ckolivas/ckpool/src/96d6707511de3cfcee37261a5e0516791789e1ff/src/ckdb.c?at=master&fileviewer=file-view-default#ckdb.c-5686

Edit2: firstly yeah you don't need to edit the code, just use the command line options
secondly, you didn't
Code:
btc_auth = http_base64(buf);

Pool: https://kano.is Here on Bitcointalk: Forum BTC: 1KanoPb8cKYqNrswjaA8cRDk4FAS9eDMLU
FreeNode IRC: irc.freenode.net channel #kano.is Majority developer of the ckpool code
Help keep Bitcoin secure by mining on pools with full block verification on all blocks - and NO empty blocks!
e46btc
Full Member
***
Offline Offline

Activity: 136
Merit: 100


View Profile
December 12, 2015, 02:05:19 PM
 #150

Thank you Kano!  So easy, it works. 
I've missed command line params related to BTC  and instead of this "http://127.0.0.1:8330" string in ckdb log confused me.

https://double-spending.com/ - Automatic double-spending tool
https://dgb256.online - Digibyte DGB pool for SHA256 algorithm
o_solo_miner
Legendary
*
Offline Offline

Activity: 969
Merit: 1001


-> morgen, ist heute, schon gestern <-


View Profile
December 15, 2015, 06:54:07 PM
 #151

 Wink got it working!

Thank you both, Con & Kano.

I compiled all under Debian AMD64, no problem.
Configured first the proxy, than the rest, no problem.

That looks like your README is all I needet to come to sucsess.

All my miners goes now as 1 to cksolo.pool  Grin


You make me verry happy!

---

Next step is to get the relaynetwork working.

http://ckpool.org "THE Pool" from the creator of CGMiner & CKPool / Payout System:SPLNS / ZERO FEE!
------------------------------------------- join now -----------------------------------------------
http://solo.ckpool.org for Solominers with the best block notify system
hodedowe
Sr. Member
****
Offline Offline

Activity: 350
Merit: 251


View Profile
December 24, 2015, 05:38:52 AM
 #152

Hope this helps someone else. If you get this response from the pool:

HTTP response to ( "getblock...) 0.001s not ok: HTTP/1.1 500 Internal Server Error


Then something has gone haywire with your Bitcoin core installation. It's not the pool. On one of my test machines was throwing this error with a remote core installation. I spent 2 days troubleshooting the pool and ports/etc. A simple shutdown>reinstall of bitcoin core fixed the problem.



Solo mining is alive and profitable!
Helped? Thanks! 1CXRFh4bDVFBsUzoHMMDbTMPcBP14RUTus
hodedowe
Sr. Member
****
Offline Offline

Activity: 350
Merit: 251


View Profile
December 24, 2015, 03:03:37 PM
 #153

You could also just download the VMware version and run it on any machine. Smiley

Solo mining is alive and profitable!
Helped? Thanks! 1CXRFh4bDVFBsUzoHMMDbTMPcBP14RUTus
-ck
Moderator
Legendary
*
Offline Offline

Activity: 2590
Merit: 1111


Ruu \o/


View Profile WWW
January 04, 2016, 03:15:00 AM
 #154

Massive code drop into git master long overdue with many new features and improvements, mostly on the proxy and passthrough side. I've tagged milestone M18 to just before the code drop and M19 to after it, along with incrementing the version to 0.9.0. The new features are documented in the README and with sample configurations, and at some stage I'll add descriptions to this thread.

Primary developer/maintainer for cgminer and ckpool/ckproxy.
ZERO FEE Pooled mining at ckpool.org 1% Fee Solo mining at solo.ckpool.org
-ck
-ck
Moderator
Legendary
*
Offline Offline

Activity: 2590
Merit: 1111


Ruu \o/


View Profile WWW
January 04, 2016, 03:37:06 AM
 #155

I've quoted the opening post on ckproxy and highlighted the changes below in bold.

Ckproxy uses the same core code as ckpool and acts as a proxy with a simple switch (-p). It acts as a stratum-to-stratum proxy, or stratum-through-stratum proxy in passthrough mode (see below).

It is most useful to regular miners who wish to consolidate their mining hardware into one connection for minimal upstream/downstream bandwidth in standalone mode (with the additional -A switch). Ckproxy uses multiple modes to maintain as many miners as possible communicating with the upstream pool. It works by splitting up nonce2 sizes if the upstream pool's nonce2 is large enough and then it recruits extra upstream connections as needed to allow the number of downstream miners to scale indefinitely.

Ckproxy can be started in "userproxy" mode which monitors login names of miners attaching that don't match the master proxy username and recruits new upstream connections with each unique username, proxying all workers of the same username to the unique upstream proxy connections.

It can be configured to run with a database as per an actual pool entirely, thus acting like a child pool for a parent pool elsewhere, or simply for miners who wish full logging of every detail of their mining operation.

It can also act as a unique stratum-through-stratum passthrough mode which absolutely requires a ckpool as the parent pool with the -P switch. In this mode it does not decrease the bandwidth talking to the upstream pool but minimises the number of open connections instead, but requires extremely low resources to run. This mode is most useful for pools wishing to isolate their main pool instance from the outside world and set up multiple VPSs as a kind of front end proxy/firewall to the outside world. This also removes any realistic limit on the number of open connections since each passthrough instance could easily handle 10k connections, consolidating each into just 1 connection to the upstream pool.

In addition to the passthrough mode, there is a more advanced "node" mode which connects as a passthrough, but needs a local bitcoind connection of its own. It monitors all traffic and shares between the pool and miners, being able to display local hashrates and will submit any blocks found to the local bitcoind in addition to sending the shares to the upstream pool, circumventing the delay of block submission that would otherwise happen with remote nodes.

Finally ckproxy can be started in "redirector" mode which acts as a regular passthrough, but monitors share responses from the upstream pool, and once a valid share is recognised from the upstream pool it will redirect miners that support redirection (all cgminer based clients do) to the URL of your choice. Should the miners not support redirection, such as rental services, ckredirector will continue to act as an ordinary passthrough.

Primary developer/maintainer for cgminer and ckpool/ckproxy.
ZERO FEE Pooled mining at ckpool.org 1% Fee Solo mining at solo.ckpool.org
-ck
analpaper
Jr. Member
*
Offline Offline

Activity: 36
Merit: 0


View Profile WWW
January 13, 2016, 01:05:10 PM
 #156

sorry lil question if possible: can we know what is the meaning of the variables tw=1 and fa=0 used in myqr.sh ?

this script doesnt exists in the repo so i rewrote it, and seems to me that this variables are just a check to see if the qr was parsed ok, but im not sure at all..

Thanks!
kano
Legendary
*
Offline Offline

Activity: 2520
Merit: 1045


Linux since 1997 RedHat 4


View Profile
January 13, 2016, 11:55:25 PM
 #157

Basically you gotta write your own "$sfaurl" -> "qrcode"
Site works without it since it also displays a 'link' that is the "$sfaurl", just without a pretty qrcode by default.

Someone actually paid me to write the 2FA code but they think my web site sux so they have their own Tongue
So they didn't need my php for it, so I didn't provide the program I wrote to convert the input for the html5 in my php.
It's a completely separate program so wont be in git.

Pool: https://kano.is Here on Bitcointalk: Forum BTC: 1KanoPb8cKYqNrswjaA8cRDk4FAS9eDMLU
FreeNode IRC: irc.freenode.net channel #kano.is Majority developer of the ckpool code
Help keep Bitcoin secure by mining on pools with full block verification on all blocks - and NO empty blocks!
mmpool
Sr. Member
****
Offline Offline

Activity: 375
Merit: 250


View Profile WWW
January 26, 2016, 05:42:23 AM
 #158

mmpool switched to using ckpool recently, from SockThing, mainly to get the benefit of variable difficulty settings for users but also to get a supported efficient codebase. We're a small pool and found the first block using the ckpool backend today.

We're not using the ckdb backend, - just ckpool. It connects to our merge mining server and the already existing pool reward system, database, etc. I wanted to minimize the integration work to try ckpool at the time. It was quite painless to integrate.

Thanks for the great software. I've sent a manual donation to the AUTHORS to help support the work.

mmpool.org - BTC Pool - DGM - pays tx fees/vardiff/merge mining/tor
-ck
Moderator
Legendary
*
Offline Offline

Activity: 2590
Merit: 1111


Ruu \o/


View Profile WWW
January 26, 2016, 05:53:23 AM
 #159

mmpool switched to using ckpool recently, from SockThing, mainly to get the benefit of variable difficulty settings for users but also to get a supported efficient codebase. We're a small pool and found the first block using the ckpool backend today.

We're not using the ckdb backend, - just ckpool. It connects to our merge mining server and the already existing pool reward system, database, etc. I wanted to minimize the integration work to try ckpool at the time. It was quite painless to integrate.

Thanks for the great software. I've sent a manual donation to the AUTHORS to help support the work.
You're most welcome. Thanks for the donation and good luck.

Primary developer/maintainer for cgminer and ckpool/ckproxy.
ZERO FEE Pooled mining at ckpool.org 1% Fee Solo mining at solo.ckpool.org
-ck
kano
Legendary
*
Offline Offline

Activity: 2520
Merit: 1045


Linux since 1997 RedHat 4


View Profile
January 26, 2016, 08:22:18 PM
 #160

mmpool switched to using ckpool recently, from SockThing, mainly to get the benefit of variable difficulty settings for users but also to get a supported efficient codebase. We're a small pool and found the first block using the ckpool backend today.

We're not using the ckdb backend, - just ckpool. It connects to our merge mining server and the already existing pool reward system, database, etc. I wanted to minimize the integration work to try ckpool at the time. It was quite painless to integrate.

Thanks for the great software. I've sent a manual donation to the AUTHORS to help support the work.
Thanks - very nice donation!
Now you need to start using ckdb Cheesy
It uses truck loads of ram, but less CPU than ckpool on the same machine Smiley
Every so often I change something to reduce the ram requirements.

Pool: https://kano.is Here on Bitcointalk: Forum BTC: 1KanoPb8cKYqNrswjaA8cRDk4FAS9eDMLU
FreeNode IRC: irc.freenode.net channel #kano.is Majority developer of the ckpool code
Help keep Bitcoin secure by mining on pools with full block verification on all blocks - and NO empty blocks!
chiguireitor
Legendary
*
Offline Offline

Activity: 899
Merit: 1000


Coins, Games & Miners


View Profile WWW
February 09, 2016, 04:23:56 AM
 #161

Was going to ask questions about constant disconnection of the clients on the proxy, but it seems it was just uplink unstability.

On another note, is there any documentation on ckpmsg? I would love to see what nifty things i can do with it/add to it...

Btw, loving your perpetual while conditions Smiley some Douglas Adams loving there.

-ck
Moderator
Legendary
*
Offline Offline

Activity: 2590
Merit: 1111


Ruu \o/


View Profile WWW
February 09, 2016, 04:30:28 AM
 #162

Was going to ask questions about constant disconnection of the clients on the proxy, but it seems it was just uplink unstability.

On another note, is there any documentation on ckpmsg? I would love to see what nifty things i can do with it/add to it...

Btw, loving your perpetual while conditions Smiley some Douglas Adams loving there.
Heh 42 indeed. There's no real documentation for anything ckpmsg has over and above what's in the main readme. If you can read the code you can issue direct commands to each of the main process loops provided you know the syntax but generally it's only expected people will use ckpmsg to speak to the main ckpool process which will forward on the relevant message. The other processes aren't obliged to provide a response whereas the main pool process always does as a rule.

Primary developer/maintainer for cgminer and ckpool/ckproxy.
ZERO FEE Pooled mining at ckpool.org 1% Fee Solo mining at solo.ckpool.org
-ck
chiguireitor
Legendary
*
Offline Offline

Activity: 899
Merit: 1000


Coins, Games & Miners


View Profile WWW
February 09, 2016, 04:42:54 AM
 #163

...

Heh 42 indeed. There's no real documentation for anything ckpmsg has over and above what's in the main readme. If you can read the code you can issue direct commands to each of the main process loops provided you know the syntax but generally it's only expected people will use ckpmsg to speak to the main ckpool process which will forward on the relevant message. The other processes aren't obliged to provide a response whereas the main pool process always does as a rule.

Ok, will keep searching if there's some functionality already implemented for what i want to do. If i happen to add something useful, you wouldn't mind a PR?

-ck
Moderator
Legendary
*
Offline Offline

Activity: 2590
Merit: 1111


Ruu \o/


View Profile WWW
February 09, 2016, 04:59:31 AM
 #164

...

Heh 42 indeed. There's no real documentation for anything ckpmsg has over and above what's in the main readme. If you can read the code you can issue direct commands to each of the main process loops provided you know the syntax but generally it's only expected people will use ckpmsg to speak to the main ckpool process which will forward on the relevant message. The other processes aren't obliged to provide a response whereas the main pool process always does as a rule.

Ok, will keep searching if there's some functionality already implemented for what i want to do. If i happen to add something useful, you wouldn't mind a PR?
I always welcome outside code, but I'm very fussy...

Primary developer/maintainer for cgminer and ckpool/ckproxy.
ZERO FEE Pooled mining at ckpool.org 1% Fee Solo mining at solo.ckpool.org
-ck
chiguireitor
Legendary
*
Offline Offline

Activity: 899
Merit: 1000


Coins, Games & Miners


View Profile WWW
February 09, 2016, 05:18:04 AM
 #165

...

I always welcome outside code, but I'm very fussy...

Sure thing, i will use ckproxy for a product i'm developing, and as per the GPL i must release the source, so i'll be sure to let you know when/if i do changes.

vh
Hero Member
*****
Offline Offline

Activity: 603
Merit: 552


View Profile
February 10, 2016, 02:11:45 PM
 #166

quick question: do i need to wire the notifier to a bitcoind node to pick up block solve messages from upstream in proxy mode?   trying to read through the stratum protocol docs to understand it a bit more, but thought i'd just ask.

chiguireitor
Legendary
*
Offline Offline

Activity: 899
Merit: 1000


Coins, Games & Miners


View Profile WWW
February 10, 2016, 02:37:32 PM
 #167

quick question: do i need to wire the notifier to a bitcoind node to pick up block solve messages from upstream in proxy mode?   trying to read through the stratum protocol docs to understand it a bit more, but thought i'd just ask.

From ckpool's readme:

Code:
notifier - An application designed to be run with bitcoind's -blocknotify to notify ckpool of block changes.

So you must set your blocknotify option on either bitcoind's command line or bitcoin.conf's

vh
Hero Member
*****
Offline Offline

Activity: 603
Merit: 552


View Profile
February 10, 2016, 02:44:35 PM
 #168

From ckpool's readme:

Code:
notifier - An application designed to be run with bitcoind's -blocknotify to notify ckpool of block changes.

So you must set your blocknotify option on either bitcoind's command line or bitcoin.conf's

trying it out was my next step.   initially sounded like it applied only in solo mining mode, was unsure if proxy mode get broadcasts from upstream pools.

chiguireitor
Legendary
*
Offline Offline

Activity: 899
Merit: 1000


Coins, Games & Miners


View Profile WWW
February 10, 2016, 02:49:46 PM
 #169

...
trying it out was my next step.   initially sounded like it applied only in solo mining mode, was unsure if proxy mode get broadcasts from upstream pools.

There's a stratum message that just does that, but i doubt ckproxy has a way to handle it from the command line, you could watch the log for the block hash change messages though.

-ck
Moderator
Legendary
*
Offline Offline

Activity: 2590
Merit: 1111


Ruu \o/


View Profile WWW
February 10, 2016, 08:29:21 PM
 #170

quick question: do i need to wire the notifier to a bitcoind node to pick up block solve messages from upstream in proxy mode?   trying to read through the stratum protocol docs to understand it a bit more, but thought i'd just ask.
Bitcoind is not used at all in proxy modes except for node mode.

Primary developer/maintainer for cgminer and ckpool/ckproxy.
ZERO FEE Pooled mining at ckpool.org 1% Fee Solo mining at solo.ckpool.org
-ck
Subw
Hero Member
*****
Offline Offline

Activity: 677
Merit: 500


View Profile
February 13, 2016, 11:34:30 PM
 #171

Code:
[2016-02-13 20:44:15.742] Proxy 1:stratum+tcp://stratum.f2pool.com:3333 failed, attempting reconnect
[2016-02-13 20:44:20.742] Proxy 1:stratum+tcp://stratum.f2pool.com:3333 recovered
[2016-02-13 20:57:25.442] Proxy 0:stratum+tcp://sha256.eu.nicehash.com:3334 recovered
[2016-02-13 20:57:25.442] Successfully connected to pool 0 stratum+tcp://sha256.eu.nicehash.com:3334 as proxy
[2016-02-13 20:59:30.354] Proxy 1:stratum+tcp://stratum.f2pool.com:3333 reconnect issue to zombies.f2pool.com:3333, dropping existing connection
[2016-02-13 20:59:30.354] Proxy 1:zombies.f2pool.com:3333 failed, attempting reconnect
[2016-02-13 20:59:35.354] Proxy 1:zombies.f2pool.com:3333 recovered
[2016-02-13 21:01:55.891] Proxy 0:stratum+tcp://sha256.eu.nicehash.com:3334 reconnect issue to stratum+tcp://sha256.eu.nicehash.com:3334, dropping existing connection
[2016-02-13 21:01:55.891] Proxy 0:stratum+tcp://sha256.eu.nicehash.com:3334 failed, attempting reconnect
[2016-02-13 21:01:55.892] Successfully connected to pool 1 zombies.f2pool.com:3333 as proxy
[2016-02-13 21:02:00.892] Proxy 0:stratum+tcp://sha256.eu.nicehash.com:3334 recovered
[2016-02-13 21:02:00.892] Successfully connected to pool 0 stratum+tcp://sha256.eu.nicehash.com:3334 as proxy
[2016-02-13 21:08:56.245] Proxy 0:stratum+tcp://sha256.eu.nicehash.com:3334 failed, attempting reconnect
[2016-02-13 21:08:56.245] Successfully connected to pool 1 zombies.f2pool.com:3333 as proxy
[2016-02-13 21:20:20.762] Proxy 1:zombies.f2pool.com:3333 failed, attempting reconnect
[2016-02-13 21:20:25.763] Proxy 1:zombies.f2pool.com:3333 recovered
[2016-02-13 21:40:31.450] Proxy 1:zombies.f2pool.com:3333 failed, attempting reconnect
[2016-02-13 21:40:36.450] Proxy 1:zombies.f2pool.com:3333 recovered
[2016-02-13 22:01:31.443] Proxy 1:zombies.f2pool.com:3333 failed, attempting reconnect
[2016-02-13 22:01:36.443] Proxy 1:zombies.f2pool.com:3333 recovered
[2016-02-13 22:22:30.755] Proxy 1:zombies.f2pool.com:3333 failed, attempting reconnect
[2016-02-13 22:22:35.755] Proxy 1:zombies.f2pool.com:3333 recovered
[2016-02-13 22:42:48.924] Proxy 1:zombies.f2pool.com:3333 failed, attempting reconnect
[2016-02-13 22:42:53.924] Proxy 1:zombies.f2pool.com:3333 recovered
[2016-02-13 23:03:09.367] Proxy 1:zombies.f2pool.com:3333 failed, attempting reconnect
[2016-02-13 23:03:14.368] Proxy 1:zombies.f2pool.com:3333 recovered
[2016-02-13 23:25:08.741] Proxy 1:zombies.f2pool.com:3333 failed, attempting reconnect
[2016-02-13 23:25:13.741] Proxy 1:zombies.f2pool.com:3333 recovered
[2016-02-13 23:45:31.433] Proxy 1:zombies.f2pool.com:3333 failed, attempting reconnect
[2016-02-13 23:45:36.433] Proxy 1:zombies.f2pool.com:3333 recovered
[2016-02-14 00:06:11.522] Proxy 1:zombies.f2pool.com:3333 failed, attempting reconnect
[2016-02-14 00:06:16.522] Proxy 1:zombies.f2pool.com:3333 recovered
[2016-02-14 00:26:31.409] Proxy 1:zombies.f2pool.com:3333 failed, attempting reconnect
[2016-02-14 00:26:36.409] Proxy 1:zombies.f2pool.com:3333 recovered
[2016-02-14 00:46:48.799] Proxy 1:zombies.f2pool.com:3333 failed, attempting reconnect
[2016-02-14 00:46:53.799] Proxy 1:zombies.f2pool.com:3333 recovered
[2016-02-14 00:57:21.523] Proxy 0:stratum+tcp://sha256.eu.nicehash.com:3334 recovered
[2016-02-14 00:57:21.524] Successfully connected to pool 0 stratum+tcp://sha256.eu.nicehash.com:3334 as proxy
[2016-02-14 01:04:16.722] Proxy 0:stratum+tcp://sha256.eu.nicehash.com:3334 failed, attempting reconnect
[2016-02-14 01:04:16.723] Successfully connected to pool 1 zombies.f2pool.com:3333 as proxy
[2016-02-14 01:08:28.734] Proxy 1:zombies.f2pool.com:3333 failed, attempting reconnect
[2016-02-14 01:08:33.734] Proxy 1:zombies.f2pool.com:3333 recovered
[2016-02-14 01:28:48.041] Proxy 1:zombies.f2pool.com:3333 failed, attempting reconnect
[2016-02-14 01:28:53.041] Proxy 1:zombies.f2pool.com:3333 recovered
[2016-02-14 01:49:08.817] Proxy 1:zombies.f2pool.com:3333 failed, attempting reconnect
[2016-02-14 01:49:13.817] Proxy 1:zombies.f2pool.com:3333 recovered
[2016-02-14 02:09:28.039] Proxy 1:zombies.f2pool.com:3333 failed, attempting reconnect
[2016-02-14 02:09:33.039] Proxy 1:zombies.f2pool.com:3333 recovered

Code:
[2016-02-14 02:36:43.014] ckproxy generator starting
[2016-02-14 02:36:43.015] ckproxy connector starting
[2016-02-14 02:36:43.015] ckproxy connector ready
[2016-02-14 02:36:43.015] ckproxy stratifier starting
[2016-02-14 02:36:43.015] ckproxy stratifier ready
[2016-02-14 02:36:43.517] Proxy 0:stratum+tcp://eu-01.miningrigrentals.com:3333 connection established
[2016-02-14 02:36:43.572] Proxy 0:stratum+tcp://eu-01.miningrigrentals.com:3333 failed, attempting reconnect
[2016-02-14 02:36:44.025] Successfully connected to pool 0 stratum+tcp://eu-01.miningrigrentals.com:3333 as proxy
[2016-02-14 02:36:44.025] ckproxy generator ready
[2016-02-14 02:36:48.572] Proxy 0:stratum+tcp://eu-01.miningrigrentals.com:3333 recovered
[2016-02-14 02:36:48.572] Proxy 0:stratum+tcp://eu-01.miningrigrentals.com:3333 failed, attempting reconnect
[2016-02-14 02:36:53.573] Proxy 0:stratum+tcp://eu-01.miningrigrentals.com:3333 recovered
[2016-02-14 02:36:53.573] Proxy 0:stratum+tcp://eu-01.miningrigrentals.com:3333 failed, attempting reconnect
[2016-02-14 02:36:58.573] Proxy 0:stratum+tcp://eu-01.miningrigrentals.com:3333 recovered
[2016-02-14 02:36:58.573] Proxy 0:stratum+tcp://eu-01.miningrigrentals.com:3333 failed, attempting reconnect
[2016-02-14 02:37:03.573] Proxy 0:stratum+tcp://eu-01.miningrigrentals.com:3333 recovered
[2016-02-14 02:37:03.573] Proxy 0:stratum+tcp://eu-01.miningrigrentals.com:3333 failed, attempting reconnect
[2016-02-14 02:37:08.574] Proxy 0:stratum+tcp://eu-01.miningrigrentals.com:3333 recovered
[2016-02-14 02:37:08.574] Proxy 0:stratum+tcp://eu-01.miningrigrentals.com:3333 failed, attempting reconnect
[2016-02-14 02:37:13.574] Proxy 0:stratum+tcp://eu-01.miningrigrentals.com:3333 recovered
[2016-02-14 02:37:13.574] Proxy 0:stratum+tcp://eu-01.miningrigrentals.com:3333 failed, attempting reconnect
[2016-02-14 02:37:18.574] Proxy 0:stratum+tcp://eu-01.miningrigrentals.com:3333 recovered
[2016-02-14 02:37:18.574] Proxy 0:stratum+tcp://eu-01.miningrigrentals.com:3333 failed, attempting reconnect
[2016-02-14 02:37:23.574] Proxy 0:stratum+tcp://eu-01.miningrigrentals.com:3333 recovered
[2016-02-14 02:37:23.574] Proxy 0:stratum+tcp://eu-01.miningrigrentals.com:3333 failed, attempting reconnect
[2016-02-14 02:37:28.574] Proxy 0:stratum+tcp://eu-01.miningrigrentals.com:3333 recovered
[2016-02-14 02:37:28.575] Proxy 0:stratum+tcp://eu-01.miningrigrentals.com:3333 failed, attempting reconnect


why do i have so many reconnects? i belive my connection is not a problem here
-ck
Moderator
Legendary
*
Offline Offline

Activity: 2590
Merit: 1111


Ruu \o/


View Profile WWW
February 14, 2016, 12:23:33 AM
 #172

Code:
[2016-02-13 20:44:15.742] Proxy 1:stratum+tcp://stratum.f2pool.com:3333 failed, attempting reconnect
[2016-02-13 20:44:20.742] Proxy 1:stratum+tcp://stratum.f2pool.com:3333 recovered
[2016-02-13 20:57:25.442] Proxy 0:stratum+tcp://sha256.eu.nicehash.com:3334 recovered
[2016-02-13 20:57:25.442] Successfully connected to pool 0 stratum+tcp://sha256.eu.nicehash.com:3334 as proxy
[2016-02-13 20:59:30.354] Proxy 1:stratum+tcp://stratum.f2pool.com:3333 reconnect issue to zombies.f2pool.com:3333, dropping existing connection
[2016-02-13 20:59:30.354] Proxy 1:zombies.f2pool.com:3333 failed, attempting reconnect
[2016-02-13 20:59:35.354] Proxy 1:zombies.f2pool.com:3333 recovered
[2016-02-13 21:01:55.891] Proxy 0:stratum+tcp://sha256.eu.nicehash.com:3334 reconnect issue to stratum+tcp://sha256.eu.nicehash.com:3334, dropping existing connection
[2016-02-13 21:01:55.891] Proxy 0:stratum+tcp://sha256.eu.nicehash.com:3334 failed, attempting reconnect
[2016-02-13 21:01:55.892] Successfully connected to pool 1 zombies.f2pool.com:3333 as proxy
[2016-02-13 21:02:00.892] Proxy 0:stratum+tcp://sha256.eu.nicehash.com:3334 recovered
[2016-02-13 21:02:00.892] Successfully connected to pool 0 stratum+tcp://sha256.eu.nicehash.com:3334 as proxy
[2016-02-13 21:08:56.245] Proxy 0:stratum+tcp://sha256.eu.nicehash.com:3334 failed, attempting reconnect
[2016-02-13 21:08:56.245] Successfully connected to pool 1 zombies.f2pool.com:3333 as proxy
[2016-02-13 21:20:20.762] Proxy 1:zombies.f2pool.com:3333 failed, attempting reconnect
[2016-02-13 21:20:25.763] Proxy 1:zombies.f2pool.com:3333 recovered
[2016-02-13 21:40:31.450] Proxy 1:zombies.f2pool.com:3333 failed, attempting reconnect
[2016-02-13 21:40:36.450] Proxy 1:zombies.f2pool.com:3333 recovered
[2016-02-13 22:01:31.443] Proxy 1:zombies.f2pool.com:3333 failed, attempting reconnect
[2016-02-13 22:01:36.443] Proxy 1:zombies.f2pool.com:3333 recovered
[2016-02-13 22:22:30.755] Proxy 1:zombies.f2pool.com:3333 failed, attempting reconnect
[2016-02-13 22:22:35.755] Proxy 1:zombies.f2pool.com:3333 recovered
[2016-02-13 22:42:48.924] Proxy 1:zombies.f2pool.com:3333 failed, attempting reconnect
[2016-02-13 22:42:53.924] Proxy 1:zombies.f2pool.com:3333 recovered
[2016-02-13 23:03:09.367] Proxy 1:zombies.f2pool.com:3333 failed, attempting reconnect
[2016-02-13 23:03:14.368] Proxy 1:zombies.f2pool.com:3333 recovered
[2016-02-13 23:25:08.741] Proxy 1:zombies.f2pool.com:3333 failed, attempting reconnect
[2016-02-13 23:25:13.741] Proxy 1:zombies.f2pool.com:3333 recovered
[2016-02-13 23:45:31.433] Proxy 1:zombies.f2pool.com:3333 failed, attempting reconnect
[2016-02-13 23:45:36.433] Proxy 1:zombies.f2pool.com:3333 recovered
[2016-02-14 00:06:11.522] Proxy 1:zombies.f2pool.com:3333 failed, attempting reconnect
[2016-02-14 00:06:16.522] Proxy 1:zombies.f2pool.com:3333 recovered
[2016-02-14 00:26:31.409] Proxy 1:zombies.f2pool.com:3333 failed, attempting reconnect
[2016-02-14 00:26:36.409] Proxy 1:zombies.f2pool.com:3333 recovered
[2016-02-14 00:46:48.799] Proxy 1:zombies.f2pool.com:3333 failed, attempting reconnect
[2016-02-14 00:46:53.799] Proxy 1:zombies.f2pool.com:3333 recovered
[2016-02-14 00:57:21.523] Proxy 0:stratum+tcp://sha256.eu.nicehash.com:3334 recovered
[2016-02-14 00:57:21.524] Successfully connected to pool 0 stratum+tcp://sha256.eu.nicehash.com:3334 as proxy
[2016-02-14 01:04:16.722] Proxy 0:stratum+tcp://sha256.eu.nicehash.com:3334 failed, attempting reconnect
[2016-02-14 01:04:16.723] Successfully connected to pool 1 zombies.f2pool.com:3333 as proxy
[2016-02-14 01:08:28.734] Proxy 1:zombies.f2pool.com:3333 failed, attempting reconnect
[2016-02-14 01:08:33.734] Proxy 1:zombies.f2pool.com:3333 recovered
[2016-02-14 01:28:48.041] Proxy 1:zombies.f2pool.com:3333 failed, attempting reconnect
[2016-02-14 01:28:53.041] Proxy 1:zombies.f2pool.com:3333 recovered
[2016-02-14 01:49:08.817] Proxy 1:zombies.f2pool.com:3333 failed, attempting reconnect
[2016-02-14 01:49:13.817] Proxy 1:zombies.f2pool.com:3333 recovered
[2016-02-14 02:09:28.039] Proxy 1:zombies.f2pool.com:3333 failed, attempting reconnect
[2016-02-14 02:09:33.039] Proxy 1:zombies.f2pool.com:3333 recovered

Code:
[2016-02-14 02:36:43.014] ckproxy generator starting
[2016-02-14 02:36:43.015] ckproxy connector starting
[2016-02-14 02:36:43.015] ckproxy connector ready
[2016-02-14 02:36:43.015] ckproxy stratifier starting
[2016-02-14 02:36:43.015] ckproxy stratifier ready
[2016-02-14 02:36:43.517] Proxy 0:stratum+tcp://eu-01.miningrigrentals.com:3333 connection established
[2016-02-14 02:36:43.572] Proxy 0:stratum+tcp://eu-01.miningrigrentals.com:3333 failed, attempting reconnect
[2016-02-14 02:36:44.025] Successfully connected to pool 0 stratum+tcp://eu-01.miningrigrentals.com:3333 as proxy
[2016-02-14 02:36:44.025] ckproxy generator ready
[2016-02-14 02:36:48.572] Proxy 0:stratum+tcp://eu-01.miningrigrentals.com:3333 recovered
[2016-02-14 02:36:48.572] Proxy 0:stratum+tcp://eu-01.miningrigrentals.com:3333 failed, attempting reconnect
[2016-02-14 02:36:53.573] Proxy 0:stratum+tcp://eu-01.miningrigrentals.com:3333 recovered
[2016-02-14 02:36:53.573] Proxy 0:stratum+tcp://eu-01.miningrigrentals.com:3333 failed, attempting reconnect
[2016-02-14 02:36:58.573] Proxy 0:stratum+tcp://eu-01.miningrigrentals.com:3333 recovered
[2016-02-14 02:36:58.573] Proxy 0:stratum+tcp://eu-01.miningrigrentals.com:3333 failed, attempting reconnect
[2016-02-14 02:37:03.573] Proxy 0:stratum+tcp://eu-01.miningrigrentals.com:3333 recovered
[2016-02-14 02:37:03.573] Proxy 0:stratum+tcp://eu-01.miningrigrentals.com:3333 failed, attempting reconnect
[2016-02-14 02:37:08.574] Proxy 0:stratum+tcp://eu-01.miningrigrentals.com:3333 recovered
[2016-02-14 02:37:08.574] Proxy 0:stratum+tcp://eu-01.miningrigrentals.com:3333 failed, attempting reconnect
[2016-02-14 02:37:13.574] Proxy 0:stratum+tcp://eu-01.miningrigrentals.com:3333 recovered
[2016-02-14 02:37:13.574] Proxy 0:stratum+tcp://eu-01.miningrigrentals.com:3333 failed, attempting reconnect
[2016-02-14 02:37:18.574] Proxy 0:stratum+tcp://eu-01.miningrigrentals.com:3333 recovered
[2016-02-14 02:37:18.574] Proxy 0:stratum+tcp://eu-01.miningrigrentals.com:3333 failed, attempting reconnect
[2016-02-14 02:37:23.574] Proxy 0:stratum+tcp://eu-01.miningrigrentals.com:3333 recovered
[2016-02-14 02:37:23.574] Proxy 0:stratum+tcp://eu-01.miningrigrentals.com:3333 failed, attempting reconnect
[2016-02-14 02:37:28.574] Proxy 0:stratum+tcp://eu-01.miningrigrentals.com:3333 recovered
[2016-02-14 02:37:28.575] Proxy 0:stratum+tcp://eu-01.miningrigrentals.com:3333 failed, attempting reconnect


why do i have so many reconnects? i belive my connection is not a problem here
Why blame the code? Your "pools" are disconnecting you, probably because you're idle. They look like they have 5 minute idle timeouts.

Primary developer/maintainer for cgminer and ckpool/ckproxy.
ZERO FEE Pooled mining at ckpool.org 1% Fee Solo mining at solo.ckpool.org
-ck
Subw
Hero Member
*****
Offline Offline

Activity: 677
Merit: 500


View Profile
February 14, 2016, 12:27:31 AM
 #173

true, no miners connected through proxy, but look at a second log it is constant reconnects, no 5 min delays there, it reconnects every 5 seconds
-ck
Moderator
Legendary
*
Offline Offline

Activity: 2590
Merit: 1111


Ruu \o/


View Profile WWW
February 14, 2016, 12:34:39 AM
 #174

true, no miners connected through proxy, but look at a second log it is constant reconnects, no 5 min delays there, it reconnects every 5 seconds
I can't speak for what your upstream pools do with your chosen credentials. Try logging in debug mode and you might get more info.

Primary developer/maintainer for cgminer and ckpool/ckproxy.
ZERO FEE Pooled mining at ckpool.org 1% Fee Solo mining at solo.ckpool.org
-ck
Subw
Hero Member
*****
Offline Offline

Activity: 677
Merit: 500


View Profile
February 14, 2016, 12:39:20 AM
 #175

credential are valid i copied them from miner's config.


here is level 7 log:
Code:
sudo ./ckpool --proxy -c ckproxy.conf --loglevel 7
[2016-02-14 03:37:57.104] ckproxy connector starting
[2016-02-14 03:37:57.104] ckproxy connector ready
[2016-02-14 03:37:57.105] ckproxy stratifier starting
[2016-02-14 03:37:57.105] ckproxy generator starting
[2016-02-14 03:37:57.105] ckproxy stratifier ready
[2016-02-14 03:37:57.480] Proxy 0:stratum+tcp://eu-01.miningrigrentals.com:3333 connection established
[2016-02-14 03:37:57.536] Proxy 0:stratum+tcp://eu-01.miningrigrentals.com:3333 failed, attempting reconnect
[2016-02-14 03:37:58.117] Successfully connected to pool 0 stratum+tcp://eu-01.miningrigrentals.com:3333 as proxy
[2016-02-14 03:37:58.117] ckproxy generator ready
[2016-02-14 03:38:02.536] Proxy 0:stratum+tcp://eu-01.miningrigrentals.com:3333 recovered
[2016-02-14 03:38:02.537] Proxy 0:stratum+tcp://eu-01.miningrigrentals.com:3333 failed, attempting reconnect
[2016-02-14 03:38:07.537] Proxy 0:stratum+tcp://eu-01.miningrigrentals.com:3333 recovered
[2016-02-14 03:38:07.537] Proxy 0:stratum+tcp://eu-01.miningrigrentals.com:3333 failed, attempting reconnect
[2016-02-14 03:38:12.537] Proxy 0:stratum+tcp://eu-01.miningrigrentals.com:3333 recovered
[2016-02-14 03:38:12.537] Proxy 0:stratum+tcp://eu-01.miningrigrentals.com:3333 failed, attempting reconnect
[2016-02-14 03:38:17.537] Proxy 0:stratum+tcp://eu-01.miningrigrentals.com:3333 recovered
[2016-02-14 03:38:17.537] Proxy 0:stratum+tcp://eu-01.miningrigrentals.com:3333 failed, attempting reconnect
[2016-02-14 03:38:22.538] Proxy 0:stratum+tcp://eu-01.miningrigrentals.com:3333 recovered
[2016-02-14 03:38:22.538] Proxy 0:stratum+tcp://eu-01.miningrigrentals.com:3333 failed, attempting reconnect
[2016-02-14 03:38:27.538] Proxy 0:stratum+tcp://eu-01.miningrigrentals.com:3333 recovered
[2016-02-14 03:38:27.539] Proxy 0:stratum+tcp://eu-01.miningrigrentals.com:3333 failed, attempting reconnect
[2016-02-14 03:38:32.539] Proxy 0:stratum+tcp://eu-01.miningrigrentals.com:3333 recovered
[2016-02-14 03:38:32.539] Proxy 0:stratum+tcp://eu-01.miningrigrentals.com:3333 failed, attempting reconnect
-ck
Moderator
Legendary
*
Offline Offline

Activity: 2590
Merit: 1111


Ruu \o/


View Profile WWW
February 14, 2016, 12:42:07 AM
 #176

credential are valid i copied them from miner's config.


here is level 7 log:
Code:
sudo ./ckpool --proxy -c ckproxy.conf --loglevel 7
[2016-02-14 03:37:57.104] ckproxy connector starting
[2016-02-14 03:37:57.104] ckproxy connector ready
[2016-02-14 03:37:57.105] ckproxy stratifier starting
[2016-02-14 03:37:57.105] ckproxy generator starting
[2016-02-14 03:37:57.105] ckproxy stratifier ready
[2016-02-14 03:37:57.480] Proxy 0:stratum+tcp://eu-01.miningrigrentals.com:3333 connection established
[2016-02-14 03:37:57.536] Proxy 0:stratum+tcp://eu-01.miningrigrentals.com:3333 failed, attempting reconnect
[2016-02-14 03:37:58.117] Successfully connected to pool 0 stratum+tcp://eu-01.miningrigrentals.com:3333 as proxy
[2016-02-14 03:37:58.117] ckproxy generator ready
[2016-02-14 03:38:02.536] Proxy 0:stratum+tcp://eu-01.miningrigrentals.com:3333 recovered
[2016-02-14 03:38:02.537] Proxy 0:stratum+tcp://eu-01.miningrigrentals.com:3333 failed, attempting reconnect
[2016-02-14 03:38:07.537] Proxy 0:stratum+tcp://eu-01.miningrigrentals.com:3333 recovered
[2016-02-14 03:38:07.537] Proxy 0:stratum+tcp://eu-01.miningrigrentals.com:3333 failed, attempting reconnect
[2016-02-14 03:38:12.537] Proxy 0:stratum+tcp://eu-01.miningrigrentals.com:3333 recovered
[2016-02-14 03:38:12.537] Proxy 0:stratum+tcp://eu-01.miningrigrentals.com:3333 failed, attempting reconnect
[2016-02-14 03:38:17.537] Proxy 0:stratum+tcp://eu-01.miningrigrentals.com:3333 recovered
[2016-02-14 03:38:17.537] Proxy 0:stratum+tcp://eu-01.miningrigrentals.com:3333 failed, attempting reconnect
[2016-02-14 03:38:22.538] Proxy 0:stratum+tcp://eu-01.miningrigrentals.com:3333 recovered
[2016-02-14 03:38:22.538] Proxy 0:stratum+tcp://eu-01.miningrigrentals.com:3333 failed, attempting reconnect
[2016-02-14 03:38:27.538] Proxy 0:stratum+tcp://eu-01.miningrigrentals.com:3333 recovered
[2016-02-14 03:38:27.539] Proxy 0:stratum+tcp://eu-01.miningrigrentals.com:3333 failed, attempting reconnect
[2016-02-14 03:38:32.539] Proxy 0:stratum+tcp://eu-01.miningrigrentals.com:3333 recovered
[2016-02-14 03:38:32.539] Proxy 0:stratum+tcp://eu-01.miningrigrentals.com:3333 failed, attempting reconnect

That's the console output, not the log...

Primary developer/maintainer for cgminer and ckpool/ckproxy.
ZERO FEE Pooled mining at ckpool.org 1% Fee Solo mining at solo.ckpool.org
-ck
Subw
Hero Member
*****
Offline Offline

Activity: 677
Merit: 500


View Profile
February 14, 2016, 12:48:06 AM
 #177

Code:
[2016-02-14 03:46:32.283] Setting maxclients to 921 due to max open file limit of 1024
[2016-02-14 03:46:32.284] ckproxy stratifier starting
[2016-02-14 03:46:32.283] ckproxy connector starting
[2016-02-14 03:46:32.283] ckproxy connector ready
[2016-02-14 03:46:32.284] ckproxy generator starting
[2016-02-14 03:46:32.284] ckproxy stratifier ready
[2016-02-14 03:46:32.283] File /tmp/ckproxy/generator.pid exists
[2016-02-14 03:46:32.283] File /tmp/ckproxy/stratifier.pid exists
[2016-02-14 03:46:32.283] File /tmp/ckproxy/connector.pid exists
[2016-02-14 03:46:32.507] Found notify for new proxy 0:0 with enonce f800002e nonce2len 4
[2016-02-14 03:46:32.507] Got updated subscribe for proxy 0
[2016-02-14 03:46:32.507] Stratifier added new proxy 0
[2016-02-14 03:46:32.507] Upstream pool stratum+tcp://eu-01.miningrigrentals.com:3333 0 extranonce2 length 4, max proxy clients 256
[2016-02-14 03:46:32.657] Proxy 0:stratum+tcp://eu-01.miningrigrentals.com:3333 connection established
[2016-02-14 03:46:32.712] Proxy 0:0 stratum+tcp://eu-01.miningrigrentals.com:3333 failed to epoll/read_socket_line in proxy_recv
[2016-02-14 03:46:32.712] Proxy 0:stratum+tcp://eu-01.miningrigrentals.com:3333 failed, attempting reconnect
[2016-02-14 03:46:32.923] Found notify for new proxy 0:0 with enonce f800002e nonce2len 4
[2016-02-14 03:46:32.923] Got updated subscribe for proxy 0
[2016-02-14 03:46:32.923] Upstream pool stratum+tcp://eu-01.miningrigrentals.com:3333 0 extranonce2 length 4, max proxy clients 256
[2016-02-14 03:46:33.285] Pool:{"runtime": 1, "lastupdate": 1455410793, "Users": 0, "Workers": 0, "Idle": 0, "Disconnected": 0}
[2016-02-14 03:46:33.285] Pool:{"hashrate1m": "0", "hashrate5m": "0", "hashrate15m": "0", "hashrate1hr": "0", "hashrate6hr": "0", "hashrate1d": "0", "hashrate7d": "0"}
[2016-02-14 03:46:33.285] Pool:{"SPS1m": 0.0, "SPS5m": 0.0, "SPS15m": 0.0, "SPS1h": 0.0}
[2016-02-14 03:46:33.294] Successfully connected to pool 0 stratum+tcp://eu-01.miningrigrentals.com:3333 as proxy
[2016-02-14 03:46:33.295] ckproxy generator ready
[2016-02-14 03:46:37.712] Proxy 0:stratum+tcp://eu-01.miningrigrentals.com:3333 recovered
[2016-02-14 03:46:37.713] Proxy 0:0 stratum+tcp://eu-01.miningrigrentals.com:3333 failed to epoll/read_socket_line in proxy_recv
[2016-02-14 03:46:37.713] Proxy 0:stratum+tcp://eu-01.miningrigrentals.com:3333 failed, attempting reconnect
[2016-02-14 03:46:37.927] Found notify for new proxy 0:0 with enonce f800002e nonce2len 4
[2016-02-14 03:46:37.927] Got updated subscribe for proxy 0
[2016-02-14 03:46:37.927] Upstream pool stratum+tcp://eu-01.miningrigrentals.com:3333 0 extranonce2 length 4, max proxy clients 256
[2016-02-14 03:46:42.713] Proxy 0:stratum+tcp://eu-01.miningrigrentals.com:3333 recovered
[2016-02-14 03:46:42.713] Proxy 0:0 stratum+tcp://eu-01.miningrigrentals.com:3333 failed to epoll/read_socket_line in proxy_recv
[2016-02-14 03:46:42.713] Proxy 0:stratum+tcp://eu-01.miningrigrentals.com:3333 failed, attempting reconnect
[2016-02-14 03:46:42.928] Found notify for new proxy 0:0 with enonce f800002e nonce2len 4
[2016-02-14 03:46:42.928] Got updated subscribe for proxy 0
[2016-02-14 03:46:42.928] Upstream pool stratum+tcp://eu-01.miningrigrentals.com:3333 0 extranonce2 length 4, max proxy clients 256
[2016-02-14 03:46:47.713] Proxy 0:stratum+tcp://eu-01.miningrigrentals.com:3333 recovered
[2016-02-14 03:46:47.713] Proxy 0:0 stratum+tcp://eu-01.miningrigrentals.com:3333 failed to epoll/read_socket_line in proxy_recv
[2016-02-14 03:46:47.713] Proxy 0:stratum+tcp://eu-01.miningrigrentals.com:3333 failed, attempting reconnect
[2016-02-14 03:46:47.922] Found notify for new proxy 0:0 with enonce f800002e nonce2len 4
[2016-02-14 03:46:47.922] Got updated subscribe for proxy 0
[2016-02-14 03:46:47.922] Upstream pool stratum+tcp://eu-01.miningrigrentals.com:3333 0 extranonce2 length 4, max proxy clients 256
[2016-02-14 03:46:52.713] Proxy 0:stratum+tcp://eu-01.miningrigrentals.com:3333 recovered
[2016-02-14 03:46:52.713] Proxy 0:0 stratum+tcp://eu-01.miningrigrentals.com:3333 failed to epoll/read_socket_line in proxy_recv
[2016-02-14 03:46:52.713] Proxy 0:stratum+tcp://eu-01.miningrigrentals.com:3333 failed, attempting reconnect
[2016-02-14 03:46:52.927] Found notify for new proxy 0:0 with enonce f800002e nonce2len 4
[2016-02-14 03:46:52.928] Got updated subscribe for proxy 0
[2016-02-14 03:46:52.928] Upstream pool stratum+tcp://eu-01.miningrigrentals.com:3333 0 extranonce2 length 4, max proxy clients 256
[2016-02-14 03:46:53.645] Parent process ckproxy received signal 2, shutting down
-ck
Moderator
Legendary
*
Offline Offline

Activity: 2590
Merit: 1111


Ruu \o/


View Profile WWW
February 14, 2016, 12:54:07 AM
 #178

Code:
[2016-02-14 03:46:32.283] Setting maxclients to 921 due to max open file limit of 1024
[2016-02-14 03:46:32.284] ckproxy stratifier starting
[2016-02-14 03:46:32.283] ckproxy connector starting
[2016-02-14 03:46:32.283] ckproxy connector ready
[2016-02-14 03:46:32.284] ckproxy generator starting
[2016-02-14 03:46:32.284] ckproxy stratifier ready
[2016-02-14 03:46:32.283] File /tmp/ckproxy/generator.pid exists
[2016-02-14 03:46:32.283] File /tmp/ckproxy/stratifier.pid exists
[2016-02-14 03:46:32.283] File /tmp/ckproxy/connector.pid exists
[2016-02-14 03:46:32.507] Found notify for new proxy 0:0 with enonce f800002e nonce2len 4
[2016-02-14 03:46:32.507] Got updated subscribe for proxy 0
[2016-02-14 03:46:32.507] Stratifier added new proxy 0
[2016-02-14 03:46:32.507] Upstream pool stratum+tcp://eu-01.miningrigrentals.com:3333 0 extranonce2 length 4, max proxy clients 256
[2016-02-14 03:46:32.657] Proxy 0:stratum+tcp://eu-01.miningrigrentals.com:3333 connection established
[2016-02-14 03:46:32.712] Proxy 0:0 stratum+tcp://eu-01.miningrigrentals.com:3333 failed to epoll/read_socket_line in proxy_recv
[2016-02-14 03:46:32.712] Proxy 0:stratum+tcp://eu-01.miningrigrentals.com:3333 failed, attempting reconnect
[2016-02-14 03:46:32.923] Found notify for new proxy 0:0 with enonce f800002e nonce2len 4
[2016-02-14 03:46:32.923] Got updated subscribe for proxy 0
[2016-02-14 03:46:32.923] Upstream pool stratum+tcp://eu-01.miningrigrentals.com:3333 0 extranonce2 length 4, max proxy clients 256
[2016-02-14 03:46:33.285] Pool:{"runtime": 1, "lastupdate": 1455410793, "Users": 0, "Workers": 0, "Idle": 0, "Disconnected": 0}
[2016-02-14 03:46:33.285] Pool:{"hashrate1m": "0", "hashrate5m": "0", "hashrate15m": "0", "hashrate1hr": "0", "hashrate6hr": "0", "hashrate1d": "0", "hashrate7d": "0"}
[2016-02-14 03:46:33.285] Pool:{"SPS1m": 0.0, "SPS5m": 0.0, "SPS15m": 0.0, "SPS1h": 0.0}
[2016-02-14 03:46:33.294] Successfully connected to pool 0 stratum+tcp://eu-01.miningrigrentals.com:3333 as proxy
[2016-02-14 03:46:33.295] ckproxy generator ready
[2016-02-14 03:46:37.712] Proxy 0:stratum+tcp://eu-01.miningrigrentals.com:3333 recovered
[2016-02-14 03:46:37.713] Proxy 0:0 stratum+tcp://eu-01.miningrigrentals.com:3333 failed to epoll/read_socket_line in proxy_recv
[2016-02-14 03:46:37.713] Proxy 0:stratum+tcp://eu-01.miningrigrentals.com:3333 failed, attempting reconnect
[2016-02-14 03:46:37.927] Found notify for new proxy 0:0 with enonce f800002e nonce2len 4
[2016-02-14 03:46:37.927] Got updated subscribe for proxy 0
[2016-02-14 03:46:37.927] Upstream pool stratum+tcp://eu-01.miningrigrentals.com:3333 0 extranonce2 length 4, max proxy clients 256
[2016-02-14 03:46:42.713] Proxy 0:stratum+tcp://eu-01.miningrigrentals.com:3333 recovered
[2016-02-14 03:46:42.713] Proxy 0:0 stratum+tcp://eu-01.miningrigrentals.com:3333 failed to epoll/read_socket_line in proxy_recv
[2016-02-14 03:46:42.713] Proxy 0:stratum+tcp://eu-01.miningrigrentals.com:3333 failed, attempting reconnect
[2016-02-14 03:46:42.928] Found notify for new proxy 0:0 with enonce f800002e nonce2len 4
[2016-02-14 03:46:42.928] Got updated subscribe for proxy 0
[2016-02-14 03:46:42.928] Upstream pool stratum+tcp://eu-01.miningrigrentals.com:3333 0 extranonce2 length 4, max proxy clients 256
[2016-02-14 03:46:47.713] Proxy 0:stratum+tcp://eu-01.miningrigrentals.com:3333 recovered
[2016-02-14 03:46:47.713] Proxy 0:0 stratum+tcp://eu-01.miningrigrentals.com:3333 failed to epoll/read_socket_line in proxy_recv
[2016-02-14 03:46:47.713] Proxy 0:stratum+tcp://eu-01.miningrigrentals.com:3333 failed, attempting reconnect
[2016-02-14 03:46:47.922] Found notify for new proxy 0:0 with enonce f800002e nonce2len 4
[2016-02-14 03:46:47.922] Got updated subscribe for proxy 0
[2016-02-14 03:46:47.922] Upstream pool stratum+tcp://eu-01.miningrigrentals.com:3333 0 extranonce2 length 4, max proxy clients 256
[2016-02-14 03:46:52.713] Proxy 0:stratum+tcp://eu-01.miningrigrentals.com:3333 recovered
[2016-02-14 03:46:52.713] Proxy 0:0 stratum+tcp://eu-01.miningrigrentals.com:3333 failed to epoll/read_socket_line in proxy_recv
[2016-02-14 03:46:52.713] Proxy 0:stratum+tcp://eu-01.miningrigrentals.com:3333 failed, attempting reconnect
[2016-02-14 03:46:52.927] Found notify for new proxy 0:0 with enonce f800002e nonce2len 4
[2016-02-14 03:46:52.928] Got updated subscribe for proxy 0
[2016-02-14 03:46:52.928] Upstream pool stratum+tcp://eu-01.miningrigrentals.com:3333 0 extranonce2 length 4, max proxy clients 256
[2016-02-14 03:46:53.645] Parent process ckproxy received signal 2, shutting down
All I see is lots of disconnects from the upstream pool. Are you using the latest git code? The code is a continual work in progress and it's easy to find a spot where things are broken if you're not careful. Current git is stable though.

Primary developer/maintainer for cgminer and ckpool/ckproxy.
ZERO FEE Pooled mining at ckpool.org 1% Fee Solo mining at solo.ckpool.org
-ck
Subw
Hero Member
*****
Offline Offline

Activity: 677
Merit: 500


View Profile
February 14, 2016, 12:58:47 AM
 #179

yes, latest git version.
i point proxy to sha256.eu.nicehash.com and there is no such disconnects.
but my miners are pointed to eu-01.miningrigrentals.com directly and they are doing fine.

btw is it possible to switch pools in the proxy list on the fly while miners are connected and working?
-ck
Moderator
Legendary
*
Offline Offline

Activity: 2590
Merit: 1111


Ruu \o/


View Profile WWW
February 14, 2016, 01:14:49 AM
 #180

yes, latest git version.
i point proxy to sha256.eu.nicehash.com and there is no such disconnects.
but my miners are pointed to eu-01.miningrigrentals.com directly and they are doing fine.

btw is it possible to switch pools in the proxy list on the fly while miners are connected and working?
Not at the moment, no. I suspect it's just some incompatibility with MRR but I can't guess what it might be sorry. Earlier on I had tested with MRR and saw they *always* disconnect idle miners, and additionally they use redirects with reconnects for changes in where the rentals are pointed.

Primary developer/maintainer for cgminer and ckpool/ckproxy.
ZERO FEE Pooled mining at ckpool.org 1% Fee Solo mining at solo.ckpool.org
-ck
Subw
Hero Member
*****
Offline Offline

Activity: 677
Merit: 500


View Profile
February 14, 2016, 01:21:16 AM
 #181

yes looks like only MRR doing this, tried stratum.f2pool.com and it is fine too
WBF1
Sr. Member
****
Offline Offline

Activity: 418
Merit: 250


View Profile
February 14, 2016, 12:53:47 PM
 #182

Hi ck

I'm getting the same errors over and over. I cloned and built from commit db42a13. Built with all dependencies satisfied. No build problems that I can remember. Running from build directory, not installed. Environment is 32-bit Arch Linux Arm running on a Raspberry Pi2. I haven't yet taken a dive into the lines of code specified here. Was hoping maybe this is something you've encountered before with an easy fix. Any help/pointers would be much appreciated.

Looks to me like stratifier and generator are not starting. I checked and all the sockets and such are getting successfully created in /tmp/ckpool. bitcoind is slow in responding sometimes on this box. Not sure if that could cause this issue.

command line:

Code:
./ckpool -k -A -c ../ckproxy2.conf

ckproxy2.conf:

Code:
{
"btcd" :  [
        {
                "url" : "localhost:8332",
                "auth" : "[user]",
                "pass" : "[pass]"
        }
],
"update_interval" : 30,
"serverurl" : [
        "127.0.0.1:3334"
        ],
"mindiff" : 1,
"startdiff" : 1000,
"maxdiff" : 0,
"logdir" : "logs",
"btcaddress" : "[address]",
"btcsig" : "[sig]"
}

console output:

Code:
[2016-02-14 07:35:22.481] ckpool stratifier starting
[2016-02-14 07:35:22.481] ckpool generator starting
[2016-02-14 07:35:22.482] ckpool connector starting
[2016-02-14 07:35:22.483] ckpool connector ready
[2016-02-14 07:35:27.484] Select1 failed in recv_unix_msg (2) with errno 2: No such file or directory
[2016-02-14 07:35:27.485] Failure in recv_unix_msg from stratifier.c stratifier:7546 with errno 2: No such file or directory
[2016-02-14 07:35:27.485] Failure in send_recv_proc from stratifier.c stratifier:7546 with errno 2: No such file or directory
[2016-02-14 07:35:32.487] Select1 failed in recv_unix_msg (2) with errno 2: No such file or directory
[2016-02-14 07:35:32.488] Failure in recv_unix_msg from stratifier.c stratifier:7546 with errno 2: No such file or directory
[2016-02-14 07:35:32.488] Failure in send_recv_proc from stratifier.c stratifier:7546 with errno 2: No such file or directory
[2016-02-14 07:35:37.490] Select1 failed in recv_unix_msg (2) with errno 2: No such file or directory

log output:

Code:
[2016-02-14 07:35:22.475] Setting maxclients to 921 due to max open file limit of 1024
[2016-02-14 07:35:22.481] ckpool stratifier starting
[2016-02-14 07:35:22.475] Setting maxclients to 921 due to max open file limit of 1024
[2016-02-14 07:35:22.481] ckpool generator starting
[2016-02-14 07:35:22.482] ckpool connector starting
[2016-02-14 07:35:22.483] ckpool connector ready
[2016-02-14 07:35:27.484] Select1 failed in recv_unix_msg (2) with errno 2: No such file or directory
[2016-02-14 07:35:27.485] Failure in recv_unix_msg from stratifier.c stratifier:7546 with errno 2: No such file or directory
[2016-02-14 07:35:27.485] Failure in send_recv_proc from stratifier.c stratifier:7546 with errno 2: No such file or directory
[2016-02-14 07:35:32.487] Select1 failed in recv_unix_msg (2) with errno 2: No such file or directory
[2016-02-14 07:35:32.488] Failure in recv_unix_msg from stratifier.c stratifier:7546 with errno 2: No such file or directory
[2016-02-14 07:35:32.488] Failure in send_recv_proc from stratifier.c stratifier:7546 with errno 2: No such file or directory

Anonymous, no-registration, no-frills BCH Mining - http://luckypool.co - Get Lucky Today!
-ck
Moderator
Legendary
*
Offline Offline

Activity: 2590
Merit: 1111


Ruu \o/


View Profile WWW
February 14, 2016, 01:01:25 PM
 #183

Environment is 32-bit ...
Ckpool demands a 64 bit environment and I have no interest in creating support for 32 bits sorry.

Primary developer/maintainer for cgminer and ckpool/ckproxy.
ZERO FEE Pooled mining at ckpool.org 1% Fee Solo mining at solo.ckpool.org
-ck
WBF1
Sr. Member
****
Offline Offline

Activity: 418
Merit: 250


View Profile
February 14, 2016, 05:17:22 PM
 #184

Environment is 32-bit ...
Ckpool demands a 64 bit environment and I have no interest in creating support for 32 bits sorry.

Interesting. Thanks for clearing that up.

Anonymous, no-registration, no-frills BCH Mining - http://luckypool.co - Get Lucky Today!
WBF1
Sr. Member
****
Offline Offline

Activity: 418
Merit: 250


View Profile
February 17, 2016, 03:19:50 AM
 #185

Interestingly, it may actually have been working fine. I got similar errors on 64-bit as well. Issue seemed to be hangups with bitcoind. Adding more RAM and setting bitcoind to properly use the notifier seems to made it all work a lot smoother. Still running it on 64-bit.

Anonymous, no-registration, no-frills BCH Mining - http://luckypool.co - Get Lucky Today!
WBF1
Sr. Member
****
Offline Offline

Activity: 418
Merit: 250


View Profile
February 18, 2016, 03:00:29 AM
 #186

@ -ck

Can you elaborate from a high level what exactly happens when ckpool is notified by the notifier? I can see that it seems like miners start in on a new block immediately. How does ckpool decide which transactions to put in that new block? (I ask because it seems like miners start on the new block before the last one is fully downloaded and verified... But I could be mistaken on that).  I'm guessing since all we really need is the hash of the previous block we can start with that before its fully verified? Or am I really wrong in thinking that we are working on the next block before the last one is fully verified?

I see this on the first post:

"New work generation on block changes incorporate full bitcoind transaction
set without delay"

But from experience, I don't see the delay surrounding block changes that seemed to be present when mining directly to a node via GBT, so just a little curious how this works.

And yeah I know I can probably figure this all out by diving into the code, but I don't read code very well and was hoping a high level explanation wouldn't be too much of an ask.

Anonymous, no-registration, no-frills BCH Mining - http://luckypool.co - Get Lucky Today!
-ck
Moderator
Legendary
*
Offline Offline

Activity: 2590
Merit: 1111


Ruu \o/


View Profile WWW
February 18, 2016, 03:04:33 AM
 #187

@ -ck

Can you elaborate from a high level what exactly happens when ckpool is notified by the notifier? I can see that it seems like miners start in on a new block immediately. How does ckpool decide which transactions to put in that new block? (I ask because it seems like miners start on the new block before the last one is fully downloaded and verified... But I could be mistaken on that).  I'm guessing since all we really need is the hash of the previous block we can start with that before its fully verified? Or am I really wrong in thinking that we are working on the next block before the last one is fully verified?

I see this on the first post:

"New work generation on block changes incorporate full bitcoind transaction
set without delay"

But from experience, I don't see the delay surrounding block changes that seemed to be present when mining directly to a node via GBT, so just a little curious how this works.

And yeah I know I can probably figure this all out by diving into the code, but I don't read code very well and was hoping a high level explanation wouldn't be too much of an ask.
The notify comes from bitcoind only once it has verified the previous block, the notifier then tells ckpool that bitcoind is ready to generate a new template so ckpool immediately requests a new template and works from that. It is always a fully verified block that ckpool works with and the getblocktemplate that bitcoind generates after the verified block.

Primary developer/maintainer for cgminer and ckpool/ckproxy.
ZERO FEE Pooled mining at ckpool.org 1% Fee Solo mining at solo.ckpool.org
-ck
WBF1
Sr. Member
****
Offline Offline

Activity: 418
Merit: 250


View Profile
February 18, 2016, 03:08:35 AM
 #188

Ah okay I wasn't sure when the block notify was triggered by bitcoind. Thanks for that info.

I have a follow up, seemingly basic question that I couldn't find an answer to elsewhere... Do all miners everywhere concurrently work on the same block with the same transactions in it, or are the contents of a block at the discretion of each miner (assuming there are more than enough transactions on the mempool to cover more than one block worth)?

Sorry for getting a bit off topic...

Anonymous, no-registration, no-frills BCH Mining - http://luckypool.co - Get Lucky Today!
-ck
Moderator
Legendary
*
Offline Offline

Activity: 2590
Merit: 1111


Ruu \o/


View Profile WWW
February 18, 2016, 03:10:04 AM
 #189

Ah okay I wasn't sure when the block notify was triggered by bitcoind. Thanks for that info.

I have a follow up, seemingly basic question that I couldn't find an answer to elsewhere... Do all miners everywhere concurrently work on the same block with the same transactions in it, or are the contents of a block at the discretion of each miner (assuming there are more than enough transactions on the mempool to cover more than one block worth)?

Sorry for getting a bit off topic...
Same workinfo, same transactions for everyone.

Primary developer/maintainer for cgminer and ckpool/ckproxy.
ZERO FEE Pooled mining at ckpool.org 1% Fee Solo mining at solo.ckpool.org
-ck
WBF1
Sr. Member
****
Offline Offline

Activity: 418
Merit: 250


View Profile
February 18, 2016, 03:19:11 AM
 #190

Ah okay I wasn't sure when the block notify was triggered by bitcoind. Thanks for that info.

I have a follow up, seemingly basic question that I couldn't find an answer to elsewhere... Do all miners everywhere concurrently work on the same block with the same transactions in it, or are the contents of a block at the discretion of each miner (assuming there are more than enough transactions on the mempool to cover more than one block worth)?

Sorry for getting a bit off topic...
Same workinfo, same transactions for everyone.

So I think I phrased that wrong or confusingly. By miners I didn't mean miners on the same pool. I meant I guess pools as mining entities, or maybe more accurately mining nodes. Wouldn't each node or pool potentially include a different transaction set per the block they are working on? Sorry these are probably really basic questions I can answer by re-reading the white paper or some other source.

I do have a more ckpool-specific question... Before I had the notifier and blocknotify setup on my bitcoind, there were times my miners were working on work that appears to be from previous blocks. It also seemed that ckpool would timeout when trying to get work from bitcoind. None of this happens anymore.

Is that because the "blockpoll" method is taxing on bitcoind? Or is it because requesting a new blocktemplate during verification causes slowdowns? Or both?

Anonymous, no-registration, no-frills BCH Mining - http://luckypool.co - Get Lucky Today!
-ck
Moderator
Legendary
*
Offline Offline

Activity: 2590
Merit: 1111


Ruu \o/


View Profile WWW
February 18, 2016, 03:21:38 AM
 #191

I do have a more ckpool-specific question... Before I had the notifier and blocknotify setup on my bitcoind, there were times my miners were working on work that appears to be from previous blocks. It also seemed that ckpool would timeout when trying to get work from bitcoind. None of this happens anymore.

Is that because the "blockpoll" method is taxing on bitcoind? Or is it because requesting a new blocktemplate during verification causes slowdowns? Or both?
Both

Primary developer/maintainer for cgminer and ckpool/ckproxy.
ZERO FEE Pooled mining at ckpool.org 1% Fee Solo mining at solo.ckpool.org
-ck
WBF1
Sr. Member
****
Offline Offline

Activity: 418
Merit: 250


View Profile
February 18, 2016, 03:24:49 AM
 #192

Thanks for the quick replies.

Anonymous, no-registration, no-frills BCH Mining - http://luckypool.co - Get Lucky Today!
ksoze75
Newbie
*
Offline Offline

Activity: 5
Merit: 0


View Profile
February 24, 2016, 06:12:53 AM
 #193

I am trying to get this compiled and running on my RPi2B with Jessie lite. I git cloned the source and attempted to run autogen.sh and got the following output:

autom4te: cannot create autom4te.cache: No such file or directory
aclocal: error: echo failed with exit status: 1
autoreconf: aclocal failed with exit status: 1

I am guessing I am doing something wrong here. I am fairly new to Linux and am learning as fast as I can but I have no idea where to go with this other than check out the script and see what it is looking for and it is indeed missing.

Any help for this noob would be great.

K
irritant
Sr. Member
****
Offline Offline

Activity: 451
Merit: 250


Sodium hypochlorite, acetone, ethanol


View Profile
February 24, 2016, 06:29:11 AM
 #194

I am trying to get this compiled and running on my RPi2B with Jessie lite. I git cloned the source and attempted to run autogen.sh and got the following output:

autom4te: cannot create autom4te.cache: No such file or directory
aclocal: error: echo failed with exit status: 1
autoreconf: aclocal failed with exit status: 1

I am guessing I am doing something wrong here. I am fairly new to Linux and am learning as fast as I can but I have no idea where to go with this other than check out the script and see what it is looking for and it is indeed missing.

Any help for this noob would be great.

K


have you installed autoconf and automake?

Building from git also requires autoconf and automake

sudo apt-get install build-essential libpq-dev autoconf automake libtool
./autogen.sh
./configure
make
dont know if it works on 32 bit but i read there is no support for it (rpi2b)
ksoze75
Newbie
*
Offline Offline

Activity: 5
Merit: 0


View Profile
February 24, 2016, 06:43:25 AM
 #195

Unsupported Sad. I thought RPi2B was 64 bit. Maybe not, oh well.

I am pretty sure I installed those pkgs, I'll double check.
WBF1
Sr. Member
****
Offline Offline

Activity: 418
Merit: 250


View Profile
February 24, 2016, 10:50:37 AM
 #196

Environment is 32-bit ...
Ckpool demands a 64 bit environment and I have no interest in creating support for 32 bits sorry.

But I was able to build and run on RPi2. I got errors while it was running but they may not have been related to running in a 32 bit environment.

Note that you'll definitely not be able to run with ckdb, as I believe it's recommended to have 16 GB ram or so for a full ckdb implementation running behind ckpool.

Anonymous, no-registration, no-frills BCH Mining - http://luckypool.co - Get Lucky Today!
-ck
Moderator
Legendary
*
Offline Offline

Activity: 2590
Merit: 1111


Ruu \o/


View Profile WWW
February 24, 2016, 08:45:36 PM
 #197

Environment is 32-bit ...
Ckpool demands a 64 bit environment and I have no interest in creating support for 32 bits sorry.

But I was able to build and run on RPi2. I got errors while it was running but they may not have been related to running in a 32 bit environment.

Note that you'll definitely not be able to run with ckdb, as I believe it's recommended to have 16 GB ram or so for a full ckdb implementation running behind ckpool.
Warnings at startup are not actually unusual or fatal as the multiprocess nature of ckpool means that sometimes one process waits excessively for another process - usually because they're waiting on bitcoind responses for example. The latest git version has moved away from the multiprocess model so those warnings shouldn't occur any more. While the code was made to be general and should work on 32 bit and big endian, the fact remains that it was never tested on either of those so they should be considered unsupported. Of course if someone wants to audit the code and test it on those platforms and contribute patches to fix any issues they find, they're welcome to. Unlike cgminer, though, for speed of development the code for ckpool was intentionally designed with one platform in mind - making code suit multiple architectures and operating systems means dealing with the quirks of low level behaviour of each platform which slows development down and often limits what can even be done with the code. Since ckpool uses low level socket code and system functions all over the place, cross-platform support, for example, is never going to happen.

Primary developer/maintainer for cgminer and ckpool/ckproxy.
ZERO FEE Pooled mining at ckpool.org 1% Fee Solo mining at solo.ckpool.org
-ck
WBF1
Sr. Member
****
Offline Offline

Activity: 418
Merit: 250


View Profile
February 24, 2016, 09:08:53 PM
 #198

Environment is 32-bit ...
Ckpool demands a 64 bit environment and I have no interest in creating support for 32 bits sorry.

But I was able to build and run on RPi2. I got errors while it was running but they may not have been related to running in a 32 bit environment.

Note that you'll definitely not be able to run with ckdb, as I believe it's recommended to have 16 GB ram or so for a full ckdb implementation running behind ckpool.
Warnings at startup are not actually unusual or fatal as the multiprocess nature of ckpool means that sometimes one process waits excessively for another process - usually because they're waiting on bitcoind responses for example. The latest git version has moved away from the multiprocess model so those warnings shouldn't occur any more. While the code was made to be general and should work on 32 bit and big endian, the fact remains that it was never tested on either of those so they should be considered unsupported. Of course if someone wants to audit the code and test it on those platforms and contribute patches to fix any issues they find, they're welcome to. Unlike cgminer, though, for speed of development the code for ckpool was intentionally designed with one platform in mind - making code suit multiple architectures and operating systems means dealing with the quirks of low level behaviour of each platform which slows development down and often limits what can even be done with the code. Since ckpool uses low level socket code and system functions all over the place, cross-platform support, for example, is never going to happen.

Yup. I'll be testing on 64 bit ARM as soo as my Odroid C2 comes in.

Anonymous, no-registration, no-frills BCH Mining - http://luckypool.co - Get Lucky Today!
WBF1
Sr. Member
****
Offline Offline

Activity: 418
Merit: 250


View Profile
February 24, 2016, 10:02:58 PM
 #199

@ck are the M* tags considered more stable than master? or S* tags? are there still version numbers for stable releases?

Anonymous, no-registration, no-frills BCH Mining - http://luckypool.co - Get Lucky Today!
-ck
Moderator
Legendary
*
Offline Offline

Activity: 2590
Merit: 1111


Ruu \o/


View Profile WWW
February 24, 2016, 10:48:48 PM
 #200

@ck are the M* tags considered more stable than master? or S* tags? are there still version numbers for stable releases?
Tagged versions are considered stable for use indeed. The S tags were a mistake, the M tags stand for "milestone" releases. Having said that, the current git master is currently stable but that can change at any time. The version numbers are almost an afterthought.

Primary developer/maintainer for cgminer and ckpool/ckproxy.
ZERO FEE Pooled mining at ckpool.org 1% Fee Solo mining at solo.ckpool.org
-ck
WBF1
Sr. Member
****
Offline Offline

Activity: 418
Merit: 250


View Profile
February 24, 2016, 11:21:00 PM
 #201

@ck are the M* tags considered more stable than master? or S* tags? are there still version numbers for stable releases?
Tagged versions are considered stable for use indeed. The S tags were a mistake, the M tags stand for "milestone" releases. Having said that, the current git master is currently stable but that can change at any time. The version numbers are almost an afterthought.

great so use M tags for stability when in doubt

Anonymous, no-registration, no-frills BCH Mining - http://luckypool.co - Get Lucky Today!
chiguireitor
Legendary
*
Offline Offline

Activity: 899
Merit: 1000


Coins, Games & Miners


View Profile WWW
February 25, 2016, 12:19:23 AM
 #202

Can confirm master is stable as a rock.

WBF1
Sr. Member
****
Offline Offline

Activity: 418
Merit: 250


View Profile
February 25, 2016, 12:29:28 AM
 #203

Cool yeah I built master just now and no problems so far

Anonymous, no-registration, no-frills BCH Mining - http://luckypool.co - Get Lucky Today!
igorwhite
Member
**
Offline Offline

Activity: 113
Merit: 10


View Profile WWW
February 25, 2016, 01:40:35 PM
 #204

Hello!
I get this error when doing blocknotify.
Quote
~$ Failed to bind to socket in open_unix_client
Closing file handle 5
Failure in open_unix_client from notifier.c main:50
Failed to open socket: /tmp/ckpool/stratifier

What could be the problem?

CTO, R&D Director Esonics
WBF1
Sr. Member
****
Offline Offline

Activity: 418
Merit: 250


View Profile
February 25, 2016, 02:31:53 PM
 #205

Hello!
I get this error when doing blocknotify.
Quote
~$ Failed to bind to socket in open_unix_client
Closing file handle 5
Failure in open_unix_client from notifier.c main:50
Failed to open socket: /tmp/ckpool/stratifier

What could be the problem?

Make sure /tmp/ckpool/stratifier exists. It's a socket opened by ckpool. Probably also need to make sure the user running bitcoind has access to that socket. This may not be the case especially if bitcoind is running as a service but you're running ckpool from command line.

Anonymous, no-registration, no-frills BCH Mining - http://luckypool.co - Get Lucky Today!