Pages:
Author

Topic: More Genesis Block Discussion (Read 33875 times)

hero member
Activity: 666
Merit: 516
Fuck BlackRock
March 03, 2022, 05:58:08 PM
lightenup gave me this advice for generating a genesis block:

Awww, that is cheating!

You really have no business creating your own block chain if you don't understand the code well enough to figure out how to mine a new genesis block without somebody else's help.


Shots fired @BillyMarkus!!! That's part of the devtome guide. BOOO GAVIN BOOO!

https://www.devtome.com/doku.php?id=scrypt_altcoin_cloning_guide&rev=1391981820#genesis_blocks
member
Activity: 910
Merit: 14
Everyone join Blurt.blog & Steemit.com
August 25, 2018, 03:35:55 AM
Ethereum Smart Contract pre-compiled
https://github.com/satansdeer/ethereum-token-tutorial
full member
Activity: 132
Merit: 100
Walking alone in the darkness
December 27, 2017, 10:21:25 PM
Guys really need your help, i've downloaded linked above script, added blake-256 hashing algo there, but how to tell that script to use extranonce and nversion as options while it generates merkle and hash?


Will be really appriciated for help and give bounty on coin start!
full member
Activity: 132
Merit: 100
Walking alone in the darkness
December 27, 2017, 02:32:13 PM
Is there any options or script or maybe somebody know how to midify Genesis H0 to get Genesis block for blake256 algo?
newbie
Activity: 3
Merit: 0
November 05, 2017, 09:03:59 PM
I need to help. I have created a coin for myself, but when sent, can not receive. Why wallet contacted the system it has multiple ports connected to it
http://fs5.directupload.net/images/171105/uncttku6.png
http://fs5.directupload.net/images/171105/i8qqsing.png
http://fs1.directupload.net/images/171105/el82all8.png
legendary
Activity: 1498
Merit: 1113
July 27, 2017, 11:23:31 AM
What I did so far:

Change pszTimestamp to a sentence from newspaper
change block.nTime to current time

compile

run compiled source with -testnet -noirc

now u see some lines and a crash
Code:
b115383690ee67ebeef9a7e754342638cd7bbf488561998e6d1bc1ed367484f6 // Block derived from pszTimestamp
b8fa883689f099d3942ff73439d9f55d60a5e257b0d69a8f0f6ab4572ecff415 // Genesisblock (invalid cuz its already coded wrong)
bd58bf217abb76059de07dc519f6c3dcdf5b1a7bb9219a66d24205e08f3716f9 // MerkleRoot (Valid because its newly calculated

corresponding to code:
Code:
       //// debug print
        printf("%s\n", block.GetHash().ToString().c_str());
        printf("%s\n", hashGenesisBlock.ToString().c_str());
        printf("%s\n", block.hashMerkleRoot.ToString().c_str());
        assert(block.hashMerkleRoot == uint256("0xbd58bf217abb76059de07dc519f6c3dcdf5b1a7bb9219a66d24205e08f3716f9"));

update main.cpp with the mentioned merkleroot (it crashed because of the last assert) and run again

you should have already changed the false to true in
Code:
       // If genesis block hash does not match, then generate new genesis hash.
        if (true && block.GetHash() != hashGenesisBlock)

so it will find a genesis block for your string

after a long time you get:
Code:
nonce 003C1000: hash = e8525d8ae8a74a33dbc4b06a64c97ced84dfd29628b3e9e4197c7030cc4a09d3 (target = 00000ffff0000000000000000000000000000000000000000000000000000000)
block.nTime = 1367704866
block.nNonce = 3939341
block.GetHash = fafdbfc957ea6867a0743ff80c4ae126c7dd9fa82057255228a4d58f6ccfdf33
CBlock(hash=fafdbfc957ea6867a074, PoW=000000b1398554a520b5, ver=1, hashPrevBlock=00000000000000000000, hashMerkleRoot=bd58bf217a, nTime=1367704866, nBits=1e0ffff0, nNonce=3939341, vtx=1)
  CTransaction(hash=bd58bf217a, ver=1, vin.size=1, vout.size=1, nLockTime=0)
    CTxIn(COutPoint(0000000000, -1), coinbase 04ffff001d01043741442e6e6c20342f352042657672696a64696e6773646167207a6f6e6e69672c20646161726e61206f6f6b207a6f6d657273207761726d)
    CTxOut(error)
  vMerkleTree: bd58bf217a
xx: main.cpp:2070: bool LoadBlockIndex(bool): Assertion `block.GetHash() == hashGenesisBlock' failed.
Aborted (core dumped)

Now you have the valid Genesisblock and nNonce:
block.nNonce = 3939341
block.GetHash = fafdbfc957ea6867a0743ff80c4ae126c7dd9fa82057255228a4d58f6ccfdf33

Update your code with these values and your ready to go!



i have to reactivate this topic. i am playing with coin-cloning an now i am stuck at the MerkleRoot-part.

The app crashes and in terminal i got this:

Code:
Assertion failed: (block.hashMerkleRoot == uint256("0x")), function LoadBlockIndex, file main.cpp, line 2031.
Abort trap: 6

and according to this how-to (https://gist.github.com/mhsjlw/8130158de01071aa8c87) i should find the hash in a log file. but in the only corresponding log file i found i only have this.

Quote
c6e32eac75316aa6be562726b219fac84560439fea1c819550fb95abbeb23582
5813d4cfab0eeda94a15d11c5e7d6895e667fbbe67c59ef9a1b3bc232c9a0b7f
c12f442c067f5c64e58e294d423c36b42201801a55ed551fa0d4da57b1810651

the how-to says i should have something like this:

Quote
Thanks to tyrion's amazingly helpful post, we can decipher this debug out put as so:

b1753ec3845a48ddc4618bc595af6dc89dac328cd48f9f8db178df5dd3b302fc Block hashed using the non-existent Merkel, based on the pzTimestamp from main.cpp
0000000000000000000000000000000000000000000000000000000000000000 Genesis block, no good because all the nNonces are set to 0 in main.cpp
2fc1b7ef46270c053711fbae934cf7f83378efd4b3e158079451d9c6c90e4700 Valid Merkel Hash, generated using the epoch time in main.cpp


or is one off the three lines above the hash i need?

thank you.

EDIT: i got it, reformatting the text from the how-to solves the problem.... the third line is the hash i need.
sr. member
Activity: 378
Merit: 250
June 16, 2017, 01:01:19 PM
i was able to compile and make some modifications, but when i execute litecoind, it obviously give me the error genesisblock does not match, everything fine until there,
what i am not being able to find the debug.log file, it supposes it is created a .litecoin folder where the log file should it be, but the .litecoin folder in home it is not being created...
so i would like some enlightment in this part, anyone could help me? thanks
full member
Activity: 235
Merit: 100
May 04, 2017, 02:37:59 PM
Updated 2017 Genesis Block information http://practicecoin.com/index.php/2017/04/19/genesis-block/
legendary
Activity: 996
Merit: 1013
July 30, 2015, 02:28:54 AM
#99
Hello all, I'm attempting to compile a cloned version of fastcoin (NOT FOR REALEASE, JUST LEARNING). Ive managed to get as far as obtaining my merkle hash. However, now that im at the part of generating a genesis block by changing if (false && block.GetHash() != hashGenesisBlock) to if (true && block.GetHash() != hashGenesisBlock) Ive run into a roadblock. It seems the dev team who created fastcoin has heavily modified their source, and i am missing that particular line of code in main.cpp lol. Any chance someone knows what they may have changed it too? (or is willing to take a look?) Or is it more likely that it was just removed as a method of stopping people from cloning their source to a new chain?

Take a look at some other coins source to
familiarize yourself what the genesis block producing code looks
like. It is indeed in the fastcoin source, but the condition under
which it runs is different.

legendary
Activity: 1007
Merit: 1000
July 29, 2015, 11:08:38 PM
#98
Hello all, I'm attempting to compile a cloned version of fastcoin (NOT FOR REALEASE, JUST LEARNING). Ive managed to get as far as obtaining my merkle hash. However, now that im at the part of generating a genesis block by changing if (false && block.GetHash() != hashGenesisBlock) to if (true && block.GetHash() != hashGenesisBlock) Ive run into a roadblock. It seems the dev team who created fastcoin has heavily modified their source, and i am missing that particular line of code in main.cpp lol. Any chance someone knows what they may have changed it too? (or is willing to take a look?) Or is it more likely that it was just removed as a method of stopping people from cloning their source to a new chain?
legendary
Activity: 910
Merit: 1000
June 23, 2015, 08:14:26 AM
#97
im trying to create peercoin genesis block and got it done quite easily
im using the 0.8.6 based source
but sometimes cant find it beacuse nonce reseting back to zero, why this is happening?
where is the part of source doing this:

2015-06-22 08:06:15 n=4095M hash=fbf2af49cbd6dfdb2bc61e5ac2a0f2f7847b14d122345b1d7afccfab9ef2d7a5
2015-06-22 08:06:17 n=0M hash=be71678a2a5a4c073f71e87f22816de6e567135cc23c3079118f089dd6c622c5

after 4095M nonces drop back to 0

where is the part of the sourcecode doing this?
i tried to find answer related to value 0xffff, but did not get it yet why this is happening
legendary
Activity: 996
Merit: 1013
August 22, 2014, 08:02:11 PM
#96
Working on a new coin (I know, too many already). I have had success mining a genesis block for a scrypt coin, but running into trouble now with X11. Is the process very different? I have changed the merklehash and now my wallet daemon runs without any errors on my local machine, but I am getting an assertion error after compiling on my VPS. Assertion 'hash == hashGenesisBlock' failed. I have been trying to get this working for days but can't seem to figure out what I am doing wrong.

If the code compiles on one machine, it
should work on another.
Check and compare that you have the same
merkleroot,
nonce,
timestamp,
hashGenesisBlock

and of course the same algo
member
Activity: 102
Merit: 10
August 22, 2014, 05:25:58 AM
#95
Working on a new coin (I know, too many already). I have had success mining a genesis block for a scrypt coin, but running into trouble now with X11. Is the process very different? I have changed the merklehash and now my wallet daemon runs without any errors on my local machine, but I am getting an assertion error after compiling on my VPS. Assertion 'hash == hashGenesisBlock' failed. I have been trying to get this working for days but can't seem to figure out what I am doing wrong.
legendary
Activity: 1551
Merit: 1002
♠ ♥ ♣ ♦ < ♛♚&#
July 19, 2014, 08:08:58 PM
#94
Thanks for sharing with us.
Its very useful information
newbie
Activity: 18
Merit: 0
June 25, 2014, 01:27:25 PM
#93
my daemon work now, i needed to forward ports  in my router and check vm is in bridge mode

thank you guys for help in debugging
 
newbie
Activity: 18
Merit: 0
June 24, 2014, 05:09:39 PM
#92
I can get connection in daemon if I try to use local IPs of 2 pc ?
newbie
Activity: 18
Merit: 0
June 24, 2014, 05:00:59 PM
#91
Perhaps an obvious question, but you can ping google.com from both virtual machines yes?

Yes of course I can browse internet and ping google on VM. I also used a daemon of a working coin and synchronisation working well on VM

sr. member
Activity: 294
Merit: 250
Bitmark Developer
June 24, 2014, 04:54:15 PM
#90
Perhaps an obvious question, but you can ping google.com from both virtual machines yes?
newbie
Activity: 18
Merit: 0
June 24, 2014, 04:44:34 PM
#89

Try connecting to 192.168.1.56 either from
your pc or the other vm. Just get the other ip from
ifconfig or ipconfig (windows) also. Typically they
are of the form 192.168.1.x

I can ping between host (PC1) local ip (192.168.1.84) and vm (VM1) local ip (192.168.1.54) that is running on host. This is Ok for both PC1/VM1 and PC2/VM2

But of course I can't cross ping local IPs between those 2 pcs because they are on different LAN.


 Undecided
legendary
Activity: 996
Merit: 1013
June 24, 2014, 04:31:19 PM
#88

Try connecting to 192.168.1.56 either from
your pc or the other vm. Just get the other ip from
ifconfig or ipconfig (windows) also. Typically they
are of the form 192.168.1.x
Pages:
Jump to: