Store PLCnext CommunityPLCnext on LinkedInPLCnext on Instagram  PLCnext on YouTube Github PLCnext CommunityStore PLCnext Community

  1. peterbolier
  2. Container @ PLCnext (Docker, Moby, balena)
  3. Wednesday, 26 May 2021
We're working on a Greengrass V2 solution. Though there is a blog for Greengrass V1 at https://www.plcnext-community.net/en/hn-makers-blog/465-how-to-turn-an-axc-f-2152-into-an-aws-greengrass-device.html we have a few questions.
- is it smart to use containers in which Greengrass is running ? Or is it better to run the lambdas run in a container?
- is it a good idea to use a container on such a constraint system or is it better to not use containers at all?
- what is the best approach on the PLC for logging, we don't want to wear out the persistent storage.
Martin PLCnext Team Accepted Answer Pending Moderation
0
Votes
Undo
there is a blog for Greengrass V1
It seems that the Getting Started procedure for V2 is quite different to V1, so perhaps we will update that Makers Blog post at some stage for V2.

is it smart to use containers in which Greengrass is running ?
I don't see why not.

is it a good idea to use a container on such a constraint system or is it better to not use containers at all?
The AXC F 1152 isn't too constrained to run containers. It all depends on what container you want to run.

- what is the best approach on the PLC for logging, we don't want to wear out the persistent storage.
It depends. What type of logging do you want to do? Message logging, like in syslog? Or data logging, like the built-in DataLogger? Is remote storage an option, e.g. by sending MQTT messages? What logging approach would you use if you didn't have to worry about wearing out the persistent storage?
Phoenix Contact Electronics Headquarters - PLCnext Runtime Product Management and Support
peterbolier Accepted Answer Pending Moderation
0
Votes
Undo
Hi Martin thanks for your answers.
After a few runs using first the Amazon Linux container and then one build with ubuntu i will try using alpine.
One concern when using containers is that it may add a (small) penalty in diskspace, RAM and CPU usage.
I can see (at least) one advantage of using containers, we create the image once and distribute it later to all devices.
Another advantage would be that the Linux system on the PLC will be kept clean(er).
For the logging (and other persistent buffering) we need to see what will be the best strategy.

When wearing out is not on issue normally we would use a rolling logging so we limit the size and number of log files and keep rotating them.

Suggestions are welcome.
Martin PLCnext Team Accepted Answer Pending Moderation
0
Votes
Undo
normally we would use a rolling logging so we limit the size and number of log files and keep rotating them.
That's exactly the method that all the built-in loggers on the PLC use (Output.log file, DataLogger service, etc). So that's probably a good method to go with for your application.
Phoenix Contact Electronics Headquarters - PLCnext Runtime Product Management and Support
  • Page :
  • 1


There are no replies made for this post yet.
However, you are not allowed to reply to this post.