Is a node A to node B connection necessary to pin on cluster A-B?

Heeey community,

At this moment I have two ipfs nodes A and B where B is stationary i.e a server and A is a portable device aka a laptop. Together they form the cluster A-B. Now, I experienced that if my two nodes being on different networks are not connected with their ipfs ID’s that it is not possible to pin files from the portable device A on the server static device B. Hence,

1: Is a node to node connection on ipfs necessary for a cluster pin to happen ? or is solely ipfs-cluster-service daemon running on both ipfs nodes enough to pin on the cluster A-B.

2: Secondly, I would like to continue staying connected to node B once I connected to it with ipfs swarm connect . My GCPeriod: 1h. However, the TCP connection is dropped after 60 seconds and from that moment on I again need to run the command ipfs swarm connect to connect again. Is there a solution for this or the only way is to create a systemctl that periodically asks ipfs swarm connect to B ?

Thanks in advance!!! :slight_smile:

both ipfs-cluster-service and ipfs daemons need to be connected to their respective counterparts on the other node.

ipfs has a config section to add peers that it should always stay connected to: kubo/docs/config.md at master · ipfs/kubo · GitHub

ipfs-cluster, I believe, retries periodically to reconnect to known peers if the connection is lost.

Thank you Hector, by using the section add peers my portable device indeed stays connected to my server node! thanks a lot.