Is it possible to attach with geth to ganache-cli?

I start ganache-cli like this:

ganache-cli --db ~/ganache -i 15

Then I try to attach to the chain like this:

geth --datadir ~/ganache/ --networkid 15 attach

This is the error I get:

Fatal: Unable to attach to remote geth: dial unix /root/ganache/geth.ipc: connect: no such file or directory

If I start a private chain using geth directly, I can attach to it without any problems.

geth --datadir ~/mychain --rpc --rpcapi eth,net,web3 --nodiscover --networkid 15 --bootnodes {URI}
geth --datadir ~/mychain --networkid 15 attach

1 Answer 1


If you are running ganache at 8545:

geth attach

Your Answer

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