Not able to start testrpc for Ethereum truffle

0 votes

I am learning about truffle metamask and there is a step to start testrpc. The command is testrpc. But when I run it, I am getting the following error. 

Error: listen EADDRINUSE :::8545

    at Object._errnoException (util.js:1022:11)

    at _exceptionWithHostPort (util.js:1044:20)

    at Server.setupListenHandle [as _listen2] (net.js:1367:14)

    at listenInCluster (net.js:1408:12)

    at Server.listen (net.js:1492:7)

    at Server.server.listen (/usr/local/lib/node_modules/ethereumjs-testrpc/build/cli.node.js:106030:17)

    at Object.<anonymous> (/usr/local/lib/node_modules/ethereumjs-testrpc/build/cli.node.js:50244:8)

    at __webpack_require__ (/usr/local/lib/node_modules/ethereumjs-testrpc/build/cli.node.js:21:30)

    at /usr/local/lib/node_modules/ethereumjs-testrpc/build/cli.node.js:64:18

    at Object.<anonymous> (/usr/local/lib/node_modules/ethereumjs-testrpc/build/cli.node.js:67:10)

Any ideas?

Nov 28, 2018 in Blockchain by digger
• 26,550 points

edited Nov 28, 2018 by digger 113 views

1 answer to this question.

0 votes

Hey. It seems like you already have testrpc running. Check it using the ps command:

$ps

PID TTY          TIME CMD

  4195 pts/0    00:00:00 bash

  5551 pts/0    00:00:01 node

  5627 pts/0    00:00:00 ps

Here, the process node (5551) is the testrpc. Kill it using this command and you will be able to start testrpc just fine:

kill -9 <pid>

In my case, it is

kill -9 5551
answered Nov 28, 2018 by Omkar
• 67,480 points

Related Questions In Blockchain

–1 vote
1 answer

Not able to create new account in geth for private ethereum blockchain

personal.newAccount() is not a default geth method. This ...READ MORE

answered Jan 17 in Blockchain by Omkar
• 67,480 points
206 views
0 votes
1 answer
0 votes
1 answer

Ethereum wallet not able to make transaction

I can see that the nonce you ...READ MORE

answered Aug 9, 2018 in Blockchain by slayer
• 29,050 points
35 views
0 votes
1 answer

Not able to send Ethereum transaction

Hey, Change this line: await crowdsale.sendTransaction({value, from: buyer, gas: ...READ MORE

answered Sep 24, 2018 in Blockchain by slayer
• 29,050 points
24 views
0 votes
1 answer

Truffle tests not running after truffle init

This was a bug. They've fixed it. ...READ MORE

answered Sep 11, 2018 in Blockchain by Christine
• 15,790 points
140 views
0 votes
1 answer
0 votes
1 answer

Protocols used in a distributed/dlt system for the nodes to establish communication

yes all are over TCP/IP connections secured by TLS encryption in hashgraph architecture-hashgraph, ...READ MORE

answered Aug 6, 2018 in Blockchain by ariaholic
• 7,340 points
75 views
0 votes
1 answer

Not able to create new account in geth for private ethereum network

Looks like the account you are trying ...READ MORE

answered Dec 6, 2018 in Blockchain by Omkar
• 67,480 points
110 views
0 votes
1 answer

Not able to migrate truffle project even after running testrpc

Maybe you forgot to compile the project ...READ MORE

answered Dec 11, 2018 in Blockchain by Omkar
• 67,480 points
66 views