I cannot add p2pool through API:
echo "addpool|http://p2pool.org:9327,Lc8TWMiKM7gRUrG8VB8pPNP1Yvt1SGZnoH,x" | nc localhost 4028
STATUS=S,When=1371456527,Code=55,Msg=Added pool 'http://p2pool.org:9327',Description=cgminer 3.2.2|
I don't understand why but newline is a troublemaker for stratum configurations. This command works, pool is added and it is alive (-n was added to echo):
echo -n "addpool|http://p2pool.org:9327,Lc8TWMiKM7gRUrG8VB8pPNP1Yvt1SGZnoH,x" | nc localhost 4028
STATUS=S,When=1371456527,Code=55,Msg=Added pool 'http://p2pool.org:9327',Description=cgminer 3.2.2|
I think I miss an API command, to FREEZE cgminer; something like that need it to remove active pools and to load new configuration. With current API, I can do it but I have to use tricks to remove active pools and the result is not perfect. There is always one pool that is active and active pool cannot be removed even it is disabled. And when pool 0 is removed, it is replaced with the last pool, so order is changed, etc. Well, it is tricky to replace pools through API...
Nice workaround! This stratum behavior is strange tho.
About active zero pool, atm i am trying: add new pools, switch new pools to highest priority, disable and remove old ones (with delays). It is working.
I was thinking of adding all of the pools to default cgminer config and disable them at startup. Bring em up when necessary (enable/increase priority). This should circumvent any add/remove glitches.