Alright, that was a long day.
My C-Notes wallet was very ill. But I solved the problem, by
scripted sending of many transactions - whew. Yiehah!
1) I had won the
auction of GRID shares and wanted to send C-Notes for that - but my wallet was suddenly very ill.
2) So I
documented the problem in that altcoin thread about C-notes, and asked for help.
3) The
existing block explorer does not help to find out what's going on -
we will get a better one.
4) I was almost sure that I had understood the problem, now I was searching for a solution.
5) I searched in many places, then
asked for script here, and
in pywallet.
6) I could have made a simple Windows Batch script, but
the Dev had only compiled the qt-wallet for us, not the
really useful headless CLI wallet daemon.
7) What about
accessing the wallet through its built-in JSON RPC-Server? (Until today I hadn't used my www browser to look at my wallet, coooool.)
8) But hey - I suddenly thought: For linux I have a CLI client, because I had
compiled it myself. So I transferred the wallet.dat with PSCP.exe up into the cloud.
9) But then the
wallet.dat seemed incompatible. Aaaarrghhh. Learnt a bit
about the qt-sourcecode - but I could only get so far without
the dev who compiled the windows-qt wallet.
10) In the end the only thing it needed was
redownloading the blockchain. Wallet transfer = new blockchain download!
11) Then I could finally start to write that simple script. I am still new to linux-scripting, so I ran into many stupid problems...
12) Wow, I can catch exit code AND programm output:
A=$(command parameter); if [ "$?" != "0" ]; then ...13) I did not expect that subtracting non-integer values could problematic. Didn't get it. Solved it with
$(echo $a-$b | bc) 14) But I could not code my strategy: I wanted to send transaction until the final balance was just under the target balance. But I just could not get the while-condition to work for me, probably because of the float values? My workaround was ... giving up, and instead using a
for (( i = 1 ; i <= $3 ; i++ )) loop, and catching the error if the balance would run out.
15) It works. YIIIIEHAAAH! Yeah! Yippieh.
16) With my script I have sent all 2000 tiny funds in a few dozen many small packages to wallet2, and from there in one big transaction back to wallet1.
So here we are. Ready. My wallet is healthy again.
All asking today did not really result in much help. Have I asked in the wrong way, or in the wrong places?
It was as if bitcointalk was empty, and everyone knowledgable on holidays :-)
I solved it alone. And a few other things on the way. What a learning experience!
Thanks bitcoin, you are some nerdy playground :-)
You like that detective story? My donation address is BTC 1JLKNFxKjkU3YsLs38y4e672iWiXBeFYP3
or C-Notes CTVHuvvdJj61fC1mzFAQ4V1TrYBb8QTpiA or many other at www.tiny.cc/drakointip