Hi Everyone, I would like to mechanize a PLC program, that is to say to duplicate the PLC program to every new PLC a receive. Is it possible to clone the SD car with all programs (PLC and Linux) to an other SD card? I want to start the new PLC with the new SD card and the program will start automatically. Thank you for your help!
Hello Loic Vossier, you can copy the contents of the SD.
You have to be carefull not to override the “license” Folder thou.
All the adaptions you made Linux and Programs will be stored on the SDCard in the “upperdir” folder.
PLCnext uses a overlay file system. We have a Read Only area for default configurations on the Internal Memory. Whenever you modify a file or add a new file a copy will be added to the RW area of the SD.(/dev/mmcblk1p1 = SD Card = Mounted at /media/rfs/rw)
The Overlay system then maps
/media/rfs/ro and /media/rfs/rw to /df -h
`Filesystem Size Used Avail Use% Mounted on
/dev/root 294M 219M 56M 80% /media/rfs/ro
/dev/mmcblk1p1 1.9G 1.4G 396M 78% /media/rfs/rw
overlay 1.9G 1.4G 396M 78% /admin@axcf2152:~$ ls -la /media/rfs/rw/
total 21
drwxrwxrwx 6 root root 4096 May 7 14:47 .
drwxr-xr-x 4 root root 1024 Mar 22 13:09 ..
drwxr-xr-x 2 root root 4096 May 8 2018 licence
drwxr-xr-x 7 tss tss 4096 Jul 2 2018 lost+found
drwxr-xr-x 10 root root 4096 May 21 17:03 upperdir
drwxr-xr-x 3 root root 4096 May 17 07:09 work` When there is a file it will be used from RW first if there is no file at RW it will fallback to the RO area… So:
The Upperdir holds a collection of the PLCnext Engineer programs , network settings ect. and all other modifications you made.kind regards, Oliver
Hi forum, I have tried “clone” a sd card by copy the upperdir directory to a brand new SD card but the mission failed.The project does’nt start up. Has anyone got it work?
Hi Acke, it might be that in your case were not all symlinks copied or that the user permissions were corrupted of the upper directory. After playing a bit around I’ve found a procedure which worked for me quite well a few times and created an FAQ accordingly. Please try it and if it does not work just let me know… Take care!