Skip to content

Possible Issue When Starting a pylon-Based Application in Multiple Instances on Linux#

In rare use cases, you might need to run an application in multiple instances to manage multiple cameras.

In case that all cameras are of the same model, use the same firmware version, and all instances of the application are starting at the same time, GenICam will throw an exception due to file access violation.

The reason is that when using the same camera model and the same firmware, the same name for the GenICam cache file will be used.

The GenICam version used in pylon for Windows is protected against this, but not the Linux version.

Workaround 1#

Start the application in a single instance first to write the camera's XML cache file to disk. Once a GenICam cache file exists on the hard disk for a given camera, only reading access will be granted, and the exception should no longer be raised.

Workaround 2#

In case the operating system is installed on a ROM, the above workaround will not help, because the system loses the XML cache file after system reboot.

Assigning an individual GenICam cache directory for each application instance will solve this issue in this case, e.g.:

  • GENICAM_CACHE_V2_3=/home/$username/Genicam_cache1 ./Grab
  • GENICAM_CACHE_V2_3=/home/$username/Genicam_cache2 ./Grab

Info

Use GENICAM_CACHE_V2_3 for pylon 4 and GENICAM_CACHE_V3_0 for pylon 5 or higher. Make sure that the target directory exists, and the user has write privileges.

Back to Knowledge Articles