<p>It is absolutely possible, running parallel networks will be even added as a GUI option in the next RaspiBlitz release (FOSS bitcoin - lightning node package) which will also make C-lightning available.</p>
<p>See the issue about the parallel networks:
<a href="https://github.com/rootzoll/raspiblitz/issues/2290" rel="nofollow noreferrer">https://github.com/rootzoll/raspiblitz/issues/2290</a></p>
<p>Here is a screenshot demonstrating running 5 LN nodes (3 C-lightning, 2 LND) on the three Bitcoin networks (mainnet, testnet and signet) on the same machine:
<a href="https://twitter.com/openoms/status/1397187128136802326" rel="nofollow noreferrer">https://twitter.com/openoms/status/1397187128136802326</a></p>
<p>For LND need to carefully specify the ZMQ ports to not mix the block hashes of the networks via:</p>
<pre><code>main.zmqpubrawblock=tcp://127.0.0.1:28332
main.zmqpubrawtx=tcp://127.0.0.1:28333
</code></pre>
<p>and for example:</p>
<pre><code>test.zmqpubrawblock=tcp://127.0.0.1:21332
test.zmqpubrawtx=tcp://127.0.0.1:21333
</code></pre>
<p>in the bitcoin.conf.</p>
<p>The Bitcoin Core, Lightningd and LND binaries can be the same, but - if using systemd - different services are the best to be used for the specific network instances.
I found using one bitcoin.conf file is sufficient (as ports can be set with the network prefixes), but the LN implementations should have their dedicated config files per instance.
As it was mentioned C-lightning makes this easy by having different directories for each network by default.</p>

CC BY-SA 4.0
2021-09-01T15:10:16.310Z
2021-09-01T15:10:16.310Z
openoms
<p>This was answered by individuals on IRC.</p>
<p>It is perfectly fine to run any number of c-lightning nodes for any combination of networks as long as you keep home directories (<code>--lightning-dir</code>) and (<code>--bind-addr</code>, <code>--addr</code>) bindings distinct. For different networks (i.e. mainnet, testnet, signet etc) c-lightning already has subdirectories so there is no need to specify those manually. But multiple nodes for the same network would conflict on the pid file and back out safely.</p>
<p>I think the alternative implementation question is dependent on which alternative implementation we are talking about and how they have been designed. There hasn't been much cross implementation testing and use of multiple implementations concurrently at the time of writing.</p>
<p>Openoms has been running Bitcoin Core mainnet, testnet, signet nodes with 5 Lightning instances (LND and c-lightning implementations). See his <a href="https://twitter.com/openoms/status/1397187128136802326?s=20" rel="nofollow noreferrer">tweet</a> or this GitHub <a href="https://github.com/rootzoll/raspiblitz/issues/2295" rel="nofollow noreferrer">issue</a> for further details. For LND he states you need to be careful to specify the ZMQ ports so as not to mix the blockhashes of the networks (see his answer for more details).</p>
<p><a href="https://i.sstatic.net/TNwTJ.jpg" rel="nofollow noreferrer"><img src="https://i.sstatic.net/TNwTJ.jpg" alt="openoms" /></a></p>

CC BY-SA 4.0
2021-09-01T14:01:05.427Z
2021-09-01T15:11:40.333Z
2021-09-01T15:11:40.333Z
Michael Folkson
<p>This is a WIP answer investigating various Bitcoin Core and Core Lightning nodes running in parallel. Revisiting this after a couple more years.</p>
<p>By default (without making changes to the lightning config files) you can't run a mainnet Core Lightning node and a signet Core Lightning node in parallel connecting to the same Bitcoin Core instance running the mainnet and signet (bitcoind) daemons. When I attempt to do this I get the error message</p>
<pre><code>**BROKEN** connectd: STATUS_FAIL_INTERNAL_ERROR: Failed to bind on 2 socket: Address already in use
</code></pre>
<p>This is despite mainnet and signet having different default ports for both Bitcoin Core (8333, 38333 respectively) and Core Lightning (9735, 39735 respectively).</p>

CC BY-SA 4.0
2023-08-07T10:52:20.663Z
2023-08-07T10:59:39.927Z
2023-08-07T10:59:39.927Z
Michael Folkson
<p>Running mainnet, testnet and signet Bitcoin Core full nodes on the same machine/same VM works fine.</p>
<p>Is running say a c-lightning mainnet node in parallel with a c-lightning signet node on the same machine/same VM something that should work?</p>
<p>What about a c-lightning mainnet node in parallel with say a lnd/eclair/rust-lightning mainnet node? Or a c-lightning mainnet node with say a lnd/eclair/rust-lightning signet node? I'm guessing not as the two Lightning implementations will be in competition for Bitcoin Core resources and would end up crashing it.</p>

CC BY-SA 4.0
2021-08-31T14:58:11.527Z
Have you tried?
Pieter Wuille
CC BY-SA 4.0
2021-08-31T15:10:53.610Z
@PieterWuille: No not yet. Just trying to understand what should happen/if this is dumb to try before I do it.
Michael Folkson
<bitcoin-core><lightning-network><testnet><core-lightning><signet>
Should you be able to run a mainnet c-lightning node in parallel with a signet c-lightning node? What about an alternative Lightning implementation?
Michael Folkson
# Should you be able to run a mainnet c-lightning node in parallel with a signet c-lightning node? What about an alternative Lightning implementation?

(Asked by: username_0 on 2021-08-31)

Running mainnet, testnet and signet Bitcoin Core full nodes on the same machine/same VM works fine.

Is running say a c-lightning mainnet node in parallel with a c-lightning signet node on the same machine/same VM something that should work?

What about a c-lightning mainnet node in parallel with say a lnd/eclair/rust-lightning mainnet node? Or a c-lightning mainnet node with say a lnd/eclair/rust-lightning signet node? I'm guessing not as the two Lightning implementations will be in competition for Bitcoin Core resources and would end up crashing it.

**Tags:** bitcoin-core, lightning-network, testnet, core-lightning, signet

> **Comments:**
> **username_1**: Have you tried?  
> **username_0**: @username_1: No not yet. Just trying to understand what should happen/if this is dumb to try before I do it.  

---

## 3 answers

### Answer by username_2 on 2021-09-01. Score: 3 | Accepted answer

It is absolutely possible, running parallel networks will be even added as a GUI option in the next RaspiBlitz release (FOSS bitcoin - lightning node package) which will also make C-lightning available.

See the issue about the parallel networks:
<https://github.com/rootzoll/raspiblitz/issues/2290>

Here is a screenshot demonstrating running 5 LN nodes (3 C-lightning, 2 LND) on the three Bitcoin networks (mainnet, testnet and signet) on the same machine:
<https://twitter.com/username_2/status/1397187128136802326>

For LND need to carefully specify the ZMQ ports to not mix the block hashes of the networks via:

```
main.zmqpubrawblock=tcp://127.0.0.1:28332
main.zmqpubrawtx=tcp://127.0.0.1:28333

```

and for example:

```
test.zmqpubrawblock=tcp://127.0.0.1:21332
test.zmqpubrawtx=tcp://127.0.0.1:21333

```

in the bitcoin.conf.

The Bitcoin Core, Lightningd and LND binaries can be the same, but - if using systemd - different services are the best to be used for the specific network instances.
I found using one bitcoin.conf file is sufficient (as ports can be set with the network prefixes), but the LN implementations should have their dedicated config files per instance.
As it was mentioned C-lightning makes this easy by having different directories for each network by default.


---

### Answer by username_0 on 2021-09-01. Score: 4

This was answered by individuals on IRC.

It is perfectly fine to run any number of c-lightning nodes for any combination of networks as long as you keep home directories (`--lightning-dir`) and (`--bind-addr`, `--addr`) bindings distinct. For different networks (i.e. mainnet, testnet, signet etc) c-lightning already has subdirectories so there is no need to specify those manually. But multiple nodes for the same network would conflict on the pid file and back out safely.

I think the alternative implementation question is dependent on which alternative implementation we are talking about and how they have been designed. There hasn't been much cross implementation testing and use of multiple implementations concurrently at the time of writing.

username_2 has been running Bitcoin Core mainnet, testnet, signet nodes with 5 Lightning instances (LND and c-lightning implementations). See his [tweet](https://twitter.com/username_2/status/1397187128136802326?s=20) or this GitHub [issue](https://github.com/rootzoll/raspiblitz/issues/2295) for further details. For LND he states you need to be careful to specify the ZMQ ports so as not to mix the blockhashes of the networks (see his answer for more details).

[![username_2](https://i.sstatic.net/TNwTJ.jpg)](https://i.sstatic.net/TNwTJ.jpg)


---

### Answer by username_0 on 2023-08-07. Score: 0

This is a WIP answer investigating various Bitcoin Core and Core Lightning nodes running in parallel. Revisiting this after a couple more years.

By default (without making changes to the lightning config files) you can't run a mainnet Core Lightning node and a signet Core Lightning node in parallel connecting to the same Bitcoin Core instance running the mainnet and signet (bitcoind) daemons. When I attempt to do this I get the error message

```
**BROKEN** connectd: STATUS_FAIL_INTERNAL_ERROR: Failed to bind on 2 socket: Address already in use

```

This is despite mainnet and signet having different default ports for both Bitcoin Core (8333, 38333 respectively) and Core Lightning (9735, 39735 respectively).


---

