Hello i'm currently I have my chain running inside my virtual machine (with Ubuntu 16.04) and my PC (running Windows 10). NodeJS is running a server which i can access from http://192.168.0.108:3000/.
Metamask running on firefox inside the VM can actually connect to the network.
Have tried what this post suggests( MetaMask and Access Ethereum Private Chain from other PC in the same network (for test) ) but had no luck so far.
This is my starting node commandgeth --datadir ~/eth-dev/ --identity 'nodo maquina local' --verbosity 4 --ipcdisable --rpc --port 30304 --rpccorsdomain "*" --nodiscover --syncmode "full" --networkid 7051872 --targetgaslimit 16233158 console
Asked
Active
Viewed 5,520 times
1
Roberto C.
- 330
- 3
- 13
-
check if the 8545 is open in your vm or map it – Badr Bellaj May 09 '18 at 18:28
-
i have opened it using 'sudo ufw allow 22', but still not working – Roberto C. May 10 '18 at 05:11
-
i mean, 'sudo ufw allow 8545' – Roberto C. May 10 '18 at 16:25
-
try to explecite the port using -rpcport or use another port than 8545 – Badr Bellaj May 10 '18 at 16:29
-
i have tried setting it to port 7373 and the issue persists, metamask inside VM can connect but my PC cannot – Roberto C. May 10 '18 at 16:58
-
if anyone cares, i connected metamask on my pc directly to one of my nodes on AWS and it is now working. – Roberto C. May 10 '18 at 17:36
-
@RobertoC. If your VM is NAT and you cannot change to bridged you have to enable port forwarding and map host port 9999 to 8545 in the VM. Then when you connect to host_ip:9999 it will redirect to vm_ip:8545. – Ismael Apr 08 '19 at 19:30
2 Answers
1
Force the port 8545 to rpc, e.g.
geth --datadir ~/eth-dev/ --identity 'nodo maquina local' --verbosity 4 --ipcdisable --rpc --rpcport "8545" --rpccorsdomain "*" --nodiscover --syncmode "full" --networkid 7051872 --targetgaslimit 16233158 console
sfl0r3nz05
- 111
- 1
0
Open virtualbox -> right click on your machine -> settings -> Network -> Enable network adapter -> select bridge adapter and you can now set a port forwarder from your virtualmachine to your localhost.
Then, try to connect to http://localhost:8545 and that should work like a charm.
oktapodia
- 467
- 2
- 15
-
The only way i can configure port forwarding is with NAT adapter and that is no the conf i want to use. – Roberto C. May 10 '18 at 05:12
-
-
-