Search code examples
blockchainsubstratepolkadot

Error about connecting Substrate blockchains to Polkadot with Cumulus


I'm trying to connect my custom Substrate blockchains to Polkadot with Cumulus, by following the reference https://substrate.dev/cumulus-workshop/#/, I have successfully install Substrate, Relay Chain Node, and Collator Template.

Then, followed the reference, use the built-in rococo-loca to create my own chain spec file. When I move to the next part Launch Relay Chain, I have met some problems, by following the reference https://substrate.dev/cumulus-workshop/#/2-relay-chain/2-launch, I'm going to start Alice's Node, after the node starts I suppose to see several log messages, but it didn't.

How can I solve this problem, or do I miss something to do? Thanks~

It supposes to look like this:

polkadot \
  --chain spec.json \
  --tmp \
  --ws-port 9944 \
  --port 30333 \
  --alice

Output:

Local node identity is: 12D3KooWLRPJAA6CrXP14FRJztzCh4JmgtRzKWpiBjL3BtseEfyv

But I get this error:

user1215@ubuntu:~/substrate-node-template/polkadot/target/release$ polkadot \
> chain spec.json \
> tmp \
> ws-port 9944 \
> port 30333 \
> alice

polkadot: command not found


Solution

  • Seems you're not familiar with Linux. I recommend you learn some Linux first.

    In this case, you should run ./polakadot instead polkadot.

    ./polkadot \
      --chain spec.json \
      --tmp \
      --ws-port 9944 \
      --port 30333 \
      --alice
    
    # or this will work for you
    
    ~/substrate-node-template/polkadot/target/release/polkadot \
      --chain spec.json \
      --tmp \
      --ws-port 9944 \
      --port 30333 \
      --alice