7

I created a VM instance on Microsoft Azure using its Go Ethereum template. The node is running and syncing. However it does not allow me to access remotely. I ran geth attach on my local computer and got the following error:

Fatal: Failed to start the JavaScript console: api modules: Post http://104.201.38.85:8545: dial tcp 104.201.38.85:8545: connectex: A connection attempt failed because the connected party did not properly respond after a period of time, or established connection failed because connected host has failed to respond.

My parameters are geth --rpc --rpcaddr 0.0.0.0 --rpcport 8545. This should allow external access. I also checked security group and the inbound port 8545 is open. What is the reason that I cannot connect?

2
  • we are having the same problem. Were you able to fix it ever?
    – kahmed
    Commented May 22, 2017 at 17:35
  • try ethereum microsoft's templates, so far that setup was working fine
    – tatigo
    Commented Oct 16, 2017 at 13:24

3 Answers 3

3

make sure you have attached the network interface rules for port 8545 under inbound port rules

check your ubuntu how did you run your geth console- mine is some thing like this as shown below

geth --identity "node1" --rpc --rpcport "8545" --rpccorsdomain "*" --fast --rpc --rpcaddr "10.0.0.4" --datadir "node1" --port "30303" --rpcapi "db,eth,net,web3,personal,miner,admin" --mine --minerthreads "1" --ws --wsaddr "10.0.0.4" --wsorigins "*" --networkid 1900 --nat "any"

check the terminal output: it should show like this' INFO [05-19|08:40:11] HTTP endpoint opened url=http://10.0.0.4:8545

then open another ssh to your vm and connect: geth attach http://10.0.0.4:8545 if it works. then go back to your pc terminal geth attach http://Azurevmip.add.re.ss:8545. it will work as i just tried this out

1

check the azure load balancer inbound nat rules. You have to map nat rules port to the internal network/vm port

1

Did you create your environment from a consortium leader template?

Instead of running the console on your local terminal, run it on the remote machine. You'll find the details of how to connect in the azure portal:

Go to the resources group you created the template in,and click on deployments. You'll see under Outputs the field SSH-TO-FIRST-TX-NODE which will give you something like this ssh -p 3000 [email protected]

If you cannot find this, just ssh to the IP address of your vm. The port will be displayed in the Overview section of the VM under Port to connect. It will be different from 8545 which is what I think the problem is as noted above.

Another way to do this is to use PuTTy by configuring a session and adding and entry under the SSH > tunnels node

connect via ssh with that string (which will obviously be different depending on your deployment and what you named the admin account) and from there use geth attach to interact with the running node.

Your Answer

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

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