On the test network, there is the friendly bot that gives out XLM to fund an account. How does one fund an account on a private network (think, something similar to a Bitcoin node in regtest mode) in return for say, some EUR?

By looking up the secret key of root account in the private network, one has access to native asset and therefore the mechanism to issue native assets against say, EUR. https://github.com/stellar/horizon/issues/337

So, exactly how do I look for "secret key of the root account"? And, how are the assets issued - are there relevant Horizon API?

7 days later

Quick follow-up.

On a private network, the root account would still deal with XLM, right? How many XLM does (can) the root account hold? I guess, I am asking, what is the equivalent of a coinbase transaction here.

Is the transfer from this root account and then to other accounts done same as the way described here for transferring money? https://www.stellar.org/developers/guides/get-started/transactions.html

    chainhead

    I think the that the root account starts with 100 billion XLM. You can transfer this XLM to other accounts as described in the link you posted. There is no coinbase transaction, because there is no mining.

      8 months later

      chainhead
      Hi, did you ever manage to get the secret key of the root account from the logs?
      I cannot seem to get it right, I set the log level to TRACE and still nothing..
      Any help will really be appreciated
      :-)

      Yes, Did you run "stellar-core --newdb"?

      15 days later

      chainhead Did you manage to send lumens from root account to new account?

      I am following the exact code as given in "https://www.stellar.org/developers/guides/get-started/transactions.html"

      It is giving be bad sequence error!!

      CreateAccountOperation op = new CreateAccountOperation.Builder(destination, "100").build();
      Transaction transaction = new Transaction.Builder(sourceAccount).addOperation(op).addMemo(Memo.text("Test Transaction")).build();
      transaction.sign(source);
      SubmitTransactionResponse response = server.submitTransaction(transaction);

      • zcc replied to this.

        zcc Thanks zcc but I am not using docker - I have built the core manually.

        18 days later

        bkolobara How do we load root account if more lumen (>100 billion) is required?

          a month later

          bkolobara I'm looking at https://github.com/stellar/stellar-core/blob/048971af22b417e4216eb0c740f19643b1377f5d/src/ledger/LedgerManagerImpl.cpp#L72

          It seems the values hardcoded in LedgerManager::GENESIS_LEDGER_TOTAL_COINS is quite more than 100 billion.

          Is there a calculation somewhere else which gives 100 billion or I am looking at the wrong place for the total initial number of coins in the stellar network?

            How to create a friendbot account for private network?