Sie verwenden einen veralteten Browser und können nicht alle Funktionen dieser Webseite nutzen. Hier erfahren Sie, wie Sie Ihren Browser aktualisieren können.

Starten Sie jetzt mit der Konfiguration Ihres Vision Systems Webshop

What to do if you got the error message "SocketBufferSize not valid!" in pylon4linux on Linux?

If you are trying to run a GigE camera on a Linux system and get the following error message while trying to grab images, you may want to try the solution described below:

"Failed to allocate resources

Failed to set stream grabber property. SocketBufferSize not valid!

../../../../pylonsrc/Pylon/PylonTL_GigE/PylonGigE/GxStream.cpp : 1178"

At the start of image acquisition pylon sets the SocketBufferSize to the maximum supported by the given OS value.

This value can be also changed in the StreamGrabber Nodemap every time, of course.

In the initialization stage pylon checks the maximum supported value for SocketBufferSize, which is reported by the system.

This value can be also retrieved with the command:

sysctl net.core.rmem_max

This value will then be used as the maximum value for the SocketBufferSize in the Feature Properties in pylon viewer (see attached screenshot).

Pay attention though, "sysctl" returns values in [Bytes], but the Nodemap works with [KBytes].

Hence, the reported maximum value in pylon viewer should have the following value:

"sysctl net.core.rmem_max" / 1024.

If pylon should fail at reading out the value for the SocketBufferSize for any reason, it will always use a default value of 2048 [KBytes].

However, under circumstances this value may be too big and hence not supported by the given system. This will in turn result in the mentioned error message!

Hence, if you run in this error message, you should check the current and maximum value for SocketBufferSize reported in the Feature Properties in pylon viewer first (see the attached screenshot).

Then open a console and execute "sysctl net.core.rmem_max". Now divide the reported value by 1024 and compare it with the maximum value reported in pylon viewer.

If these two values should be different, this means that pylon has failed in reading out the maximum system value, i.e. "net.core.rmem_max".

In this case you should manually set the SocketBufferSize to a smaller, secure value, e.g. 64, and try to grab images then.

Pay attention though, the value for the SocketBufferSize should be as big as possible in order not to degrade the performance.

Wir helfen Ihnen gerne

Basler Support