Edge Pi Image Duplication

Looking for advice on the best way to duplicate a PI image for a mass production machine (small numbers)

On the PI (Raspberry Pi CM5) I run ignition and codesys. I want to create a master image for quick duplication. I tried setting one up, naming the gateway master image, re-imaged a new pi, changed the gateway name But when I connect it to the main ignition server for MQTT and EAM they over write each other. I assume as the serial or ID is the same for each image.

So now I’m thinking I just unzip necessary edge files but not actually run the gateway. Create a image then on each new instance run the files. That way each one will have a unique serial / ID.

Or am I over thinking this and there is a easier way ?

Are you changing the MAC address to the correct values for each PI? Most images overwrite the MAC with their own values, this is used for a lot of machine identification.

Do you mean "Pi" (π, small 'i') as in "Raspberry Pi" or something else?

Do you mean CODESYS (previously called CoDeSys)?

CM5 is a Raspberry Pi Compute Module 5.

Codesys has a fully compiled soft PLC with realtime kernel built for Raspberry Pi.
This is a very common pairing, especially on the likes of RevolutionPi hardware which provides UL listed hardware with real IO.

This is correct, I have edited the original post.

I will look into it, as far as I was aware the MAC was baked into the hardware and not transferred with the image but I will look into it thankyou.

For MQTT, assuming sparkplugB, you have to change the Node & Group to a unique combo. If not SparkplugB, you need to change the topic path to a unique path. Otherwise, yes, they are going to overwrite each other.

Not positive, but I think your issue is the uuid. Look for the file .uuid in the Ignition/data folder. If you are duplicating that file then you’ll have issues adding both to the gateway network.

I think you can delete this file on the duplicated gateway and it will generate a new one on startup based on this thread: GAN - How to reset gateway Id/UUID? - Ignition - Inductive Automation Forum