Page 1 of 1

Raspberry pi 4 cluster

Posted: Tue Jan 14, 2020 5:52 pm
by raym3d
I am seeing that when you make a cluster of Raspberry (join several) the power is increased.

My question is:

1. Is this true? Can I have a powerful computer with 2 raspberry pi 4 attached?
2. Do you know any good method to join only 2 raspberry?
3. Internally, how does it work, how is it possible to join two different computers?

Greetings.

Re: Raspberry pi 4 cluster

Posted: Tue Jan 14, 2020 5:58 pm
by davidcoton
  1. No. You can cluster computers, but you need particular sorts of tasks that can be shared to be able to use the two together.
  2. You can network them. Minimally, just a cable between the two.
  3. See first answer. It doesn't work like you expect/want.

Re: Raspberry pi 4 cluster

Posted: Tue Jan 14, 2020 6:17 pm
by fruitoftheloom
raym3d wrote:
Tue Jan 14, 2020 5:52 pm
I am seeing that when you make a cluster of Raspberry (join several) the power is increased.

My question is:

1. Is this true? Can I have a powerful computer with 2 raspberry pi 4 attached?
2. Do you know any good method to join only 2 raspberry?
3. Internally, how does it work, how is it possible to join two different computers?

Greetings.

Look at the PiDramble, it is likely the most relevant project regarding a Cluster:

https://www.pidramble.com/


Though it will not make an 8 core super computer like you expect, that is just a ludicrous notion.

Re: Raspberry pi 4 cluster

Posted: Tue Jan 14, 2020 6:22 pm
by B.Goode
Have a look at the Raspberry Pi website and blog.

There are a series of related blog posts searchable with the tag octapi, such as this one: https://www.raspberrypi.org/blog/octapi/

That should lead you to a project/tutorial - https://projects.raspberrypi.org/en/pro ... -an-octapi

You don't have to build this with eight nodes...

Reading that, or trying it for yourself, will allow you to find the answers to your own questions.

Re: Raspberry pi 4 cluster

Posted: Tue Jan 14, 2020 7:05 pm
by Heater
raym3d,
Internally, how does it work, how is it possible to join two different computers?
The same way we 'join' humans.

We are discrete, independently operating beings, but we communicate. By whatever means possible. Like this discussion we are having now.

So computers can be made to work together by exchanging messages over whatever media. Typically a regular TCP/IP network.

But, none of that get's you any increased performance unless you have software than can be divided up to run different parts of the problem on different computers, and communicate between each other.

In short, no. You cannot make a faster computer simply by bolting lesser computers together.

Re: Raspberry pi 4 cluster

Posted: Tue Jan 14, 2020 7:09 pm
by drgeoff
@raym3d

If one woman can make one baby in 9 months how many women are needed to make one baby in one month?

Re: Raspberry pi 4 cluster

Posted: Tue Jan 14, 2020 7:37 pm
by Heater
drgeoff,
If one woman can make one baby in 9 months how many women are needed to make one baby in one month?
Do what the computer architecture guys do.

Make a pipeline of 9 women. Then on, average, you get a new baby every month. Never mind the latency at start up.

Of course the 9 women might have something to say about this idea.

Re: Raspberry pi 4 cluster

Posted: Tue Jan 14, 2020 7:58 pm
by Daniel Gessel
I was just thinking about using two Pies to do alternate frame rendering with an external dongle to merge the HDMI streams, like an old school crossfire system...

Re: Raspberry pi 4 cluster

Posted: Tue Jan 14, 2020 8:14 pm
by Heater
Given the speed of HDMI signalling I'm very sure that idea is never going to work.

Re: Raspberry pi 4 cluster

Posted: Tue Jan 14, 2020 8:25 pm
by dustnbone
Daniel Gessel wrote:
Tue Jan 14, 2020 7:58 pm
I was just thinking about using two Pies to do alternate frame rendering with an external dongle to merge the HDMI streams, like an old school crossfire system...
SLI/Crossfire depend on very fast interconnects between the GPUs and their respective memory, no such way to connect 2 Pis together exists.

Traditional clustering works at the application level, not at the hardware level. Pis are perfectly capable of this type of clustering, with software designed for this purpose. Running arbitrary software like that won't work, it needs to be specifically designed to "farm out" tasks to other computers in the cluster over the network, and combine the results into a coherent output. It's not a peer to peer arrangement, but very much a client(s)/server one.

Re: Raspberry pi 4 cluster

Posted: Tue Jan 14, 2020 8:33 pm
by Daniel Gessel
The dongles that used to ship with crossfire boards had an fpga in them that could merge two digital video signals in a few different ways: checkerboard, interlaced, and AFR. I don’t see why it wouldn’t work on the output of a pair of Pies, other than getting the two streams to sync (which might be the problem).

This has been replaced with successively faster interconnects (I believe today it’s called XGMA, but I don’t work on that part of the drivers).

But, yes, there was a time when crossfire just merged video streams...

Re: Raspberry pi 4 cluster

Posted: Wed Jan 15, 2020 7:12 am
by wolf.z
raym3d wrote:
Tue Jan 14, 2020 5:52 pm
...
My question is:
...
2. Do you know any good method to join only 2 raspberry?
...
From a minimalist's point of view, I like the idea of networking via USB. Since I had no application to run for, I can't report on what preformance you might expect, but you may spare the ethernet hub when networking just 2 Raspberrys together....
https://github.com/alexellis/docker-arm ... ter/OTG.md

Re: Raspberry pi 4 cluster

Posted: Wed Jan 15, 2020 10:14 am
by davidcoton
wolf.z wrote:
Wed Jan 15, 2020 7:12 am
raym3d wrote:
Tue Jan 14, 2020 5:52 pm
...
My question is:
...
2. Do you know any good method to join only 2 raspberry?
...
From a minimalist's point of view, I like the idea of networking via USB. Since I had no application to run for, I can't report on what preformance you might expect, but you may spare the ethernet hub when networking just 2 Raspberrys together....
https://github.com/alexellis/docker-arm ... ter/OTG.md
Certainly USB networking is potentially faster than Ethernet, as long as you use USB3 on the Pi4B. However, you need some hardware in between to allow to USB hosts to talk to each other (AFAIK).

Using an Ethernet cable for two Pis needs just that -- one cable. You have to give both of them static IPs (yuck), or set one as an AP (not trivial, but doable).

Re: Raspberry pi 4 cluster

Posted: Wed Jan 15, 2020 10:29 am
by wolf.z
davidcoton wrote:
Wed Jan 15, 2020 10:14 am
...
Certainly USB networking is potentially faster than Ethernet, as long as you use USB3 on the Pi4B. However, you need some hardware in between to allow to USB hosts to talk to each other (AFAIK).

Using an Ethernet cable for two Pis needs just that -- one cable. You have to give both of them static IPs (yuck), or set one as an AP (not trivial, but doable).
Well, it's quite the same with USB networking. No, you won't need a Hub since the OTG trick does the job with one Raspberry and up to 4 USB (networking) ports acting as a USB Master and all other Pis as USB Slaves. The up to 4 port thus slaves thing makes the difference.

Re: Raspberry pi 4 cluster

Posted: Wed Jan 15, 2020 10:57 am
by davidcoton
wolf.z wrote:
Wed Jan 15, 2020 10:29 am
davidcoton wrote:
Wed Jan 15, 2020 10:14 am
...
Certainly USB networking is potentially faster than Ethernet, as long as you use USB3 on the Pi4B. However, you need some hardware in between to allow to USB hosts to talk to each other (AFAIK).

Using an Ethernet cable for two Pis needs just that -- one cable. You have to give both of them static IPs (yuck), or set one as an AP (not trivial, but doable).
Well, it's quite the same with USB networking. No, you won't need a Hub since the OTG trick does the job with one Raspberry and up to 4 USB (networking) ports acting as a USB Master and all other Pis as USB Slaves. The up to 4 port thus slaves thing makes the difference.
Except the Slave port is USB2, and so much slower than Ethernet at 1Gbs. And uses the USB-C connector, so alternative power arrangements are required.