<p>Ok. For some reason, I got this working when I tried it for the second time. This time, I set the Last PoW block number to 350. I mined first 5 blocks using the server. Then, I setup 4 different wallets in 4 different systems. I sent enough coins to all those 4 different wallets and make it available for staking. All these I did by the first 20 blocks. Then, I started to mine again using the server. Once the block number reached 350, I stopped mining on the server and suddenly, PoS took over and started producing blocks one by one using those 4 wallets. From this experience, I feel that just having 1 server and 2 clients are not enough to simulate PoS. We may need many more wallets connected to the network to get this working. Hope this helps some one.</p>

CC BY-SA 4.0
2018-10-11T06:18:26.593Z
2018-10-11T06:18:26.593Z
Harish Kumar B P
<p>After the end of PoW blocks, I am unable to mine using PoS. Here is my setup.</p>

<p>1) Server with the following config file.</p>

<pre><code>server=1
daemon=1
listen=1
rpcuser=user
rpcpassword=password
</code></pre>

<p>2) Two clients running from 2 different VPS with individual unique IPs pointed to the server using the following in config file.</p>

<pre><code>staking=1
addnode=&lt;ip of the server&gt;
</code></pre>

<p>3) A Mansternode installed on a separate VPS configured to one of the client VPS above.</p>

<p>4) I set the last block for PoW as 200. After that it must use PoS.</p>

<p>5) I start the mining using the server.</p>

<p>6) I send 100,000 coins each both to the client wallets. In one of them I lock 10,000 coins for Masternode, which works fine.</p>

<p>7) The mining continues and all are updating the blocks properly without any issues.</p>

<p>8) However, I see that none of the wallets report that their coins are enabled for staking. when I check the status using "getstakingstatus", this is what I see.</p>

<pre><code>"validtime" : true,
"haveconnections" : true,
"walletunlocked" : true,
"mintablecoins" : true,
"enoughcoins" : true,
"mnsync" : true,
"staking status" : false
</code></pre>

<p>Everything is true, but, "staking status" alone is false.</p>

<p>9) PoW stops at 200 blocks. After that, no blocks are produced and none of the clients are active for staking (PoS).</p>

<p>What am I doing wrong? How do I solve this so that I can test PoS and understand it better? Is there any code that I need to look at and chance some setting in the code? Please let me know.</p>

<altcoin><altcoin-development><proof-of-stake>
How can I simulate ProofOfStake (PoS) for a testnet (clone of Pivx)?
Harish Kumar B P
# How can I simulate ProofOfStake (PoS) for a testnet (clone of Pivx)?

(Asked by: username_0 on 2018-10-10)

After the end of PoW blocks, I am unable to mine using PoS. Here is my setup.

1) Server with the following config file.

```
server=1
daemon=1
listen=1
rpcuser=user
rpcpassword=password

```

2) Two clients running from 2 different VPS with individual unique IPs pointed to the server using the following in config file.

```
staking=1
addnode=<ip of the server>

```

3) A Mansternode installed on a separate VPS configured to one of the client VPS above.

4) I set the last block for PoW as 200. After that it must use PoS.

5) I start the mining using the server.

6) I send 100,000 coins each both to the client wallets. In one of them I lock 10,000 coins for Masternode, which works fine.

7) The mining continues and all are updating the blocks properly without any issues.

8) However, I see that none of the wallets report that their coins are enabled for staking. when I check the status using "getstakingstatus", this is what I see.

```
"validtime" : true,
"haveconnections" : true,
"walletunlocked" : true,
"mintablecoins" : true,
"enoughcoins" : true,
"mnsync" : true,
"staking status" : false

```

Everything is true, but, "staking status" alone is false.

9) PoW stops at 200 blocks. After that, no blocks are produced and none of the clients are active for staking (PoS).

What am I doing wrong? How do I solve this so that I can test PoS and understand it better? Is there any code that I need to look at and chance some setting in the code? Please let me know.

**Tags:** altcoin, altcoin-development, proof-of-stake


---

## 1 answers

### Answer by username_0 on 2018-10-11. Score: 0

Ok. For some reason, I got this working when I tried it for the second time. This time, I set the Last PoW block number to 350. I mined first 5 blocks using the server. Then, I setup 4 different wallets in 4 different systems. I sent enough coins to all those 4 different wallets and make it available for staking. All these I did by the first 20 blocks. Then, I started to mine again using the server. Once the block number reached 350, I stopped mining on the server and suddenly, PoS took over and started producing blocks one by one using those 4 wallets. From this experience, I feel that just having 1 server and 2 clients are not enough to simulate PoS. We may need many more wallets connected to the network to get this working. Hope this helps some one.


---

