9

Using Windows, when I started Geth with:

geth --rpc --rpcaddr 192.168.1.9 --rpcport 8545 --rpcapi "eth,net,web3,personal" --datadir C:\Users\BulldogBud\AppData\Roaming\Ethereum\testnet\chaindata --networkid 3 console

Receiving:

I1206 11:55:12.857903 node/node.go:410] HTTP endpoint opened: http://192.168.1.9:8545

I opened another Console typing:

curl -X POST --data '{"jsonrpc":"2.0","method":"web3_clientVersion","params":[],"id":1}' http://192.168.1.9:8545

Receiving :

{"jsonrpc":"2.0","error":{"code":-32600,"message":"invalid character '\'' looking for beginning of value"}}

How can I fix this issue? Thank you in advance!

EDIT after several attempts, giving:

curl -X POST --data '{"jsonrpc":"2.0","method":"eth_coinbase","params":[],"id":1}' http://localhost:8545

the new error message is:

curl: (7) Failed to connect to localhost port 8545: Connection refused

Any suggestion?

7

2 Answers 2

1

Let use POST MAN

With:

{
  "jsonrpc": "2.0",
  "method": "eth_coinbase",
  "params": ["0x68656c6c6f20776f726c64"],
  "id": 1
}

worked perfectly for me.

-2

Try to set

--rpccorsdomain="http://yourip/"

Or

--rpccorsdomain="*"

Tell me if that work!

Also sometime I use NGROK this way I can create a domain, point to 8545 port and use that domain instead that IP

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

Not the answer you're looking for? Browse other questions tagged or ask your own question.