0

When I launch ganache-cli for Port 7545, it will create 10 accounts by default.

ganache-cli -p 7545

However, when I then open the Ganache-Desktop-App, it will show different accounts and the accounts from the CLI can't be found.

This appears in the terminal from ganache-cli:

enter image description here

This is shown in Ganache Desktop-App:

enter image description here

Why aren't both in sync?

  • How do you run ganache-cli from the command line and ganache-ui on the same port at the same time? For me, they behave like separate instances and thus I can not run them at the same time at the same port. – Mike A. Clearance Apr 29 '18 at 11:28
  • I ran "ganache-cli -p 7545" as shown in the screenshot in terminal and launched then the Ganache Desktop-App. It is listening at the same port as you can see in the screenshot – delete Apr 29 '18 at 11:45
  • 1
    Yes, I can see, but when I try to do the same my ganache-ui won't start, because port is blocked. I have slightly older version of ganache, maybe there were some changes. One thing you can try is to start ganache-cli with the same mnemonic key as ganache-ui is using as argument. The command is: ganache-cli -p 7545 -m "candy maple cake sugar pudding cream honey rich smooth crumble sweet treat" Maybe it will help you somehow – Mike A. Clearance Apr 29 '18 at 12:03
  • @MikeA.Clearance this is the solution! works perfectly! – delete Apr 29 '18 at 14:30
  • 1
    Glad I could help ;) I added previous comment as the answer. – Mike A. Clearance Apr 29 '18 at 15:15
3

One thing you can try is to start ganache-cli with the same mnemonic seed as ganache-ui is using as argument. The command is:

ganache-cli -p 7545 -m "candy maple cake sugar pudding cream honey rich smooth crumble sweet treat"

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

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