ZTE ZXR10 5900-series switches Platform/OS not found from sysDescr

Tags: #<Tag:0x00007fd8941fcee8>

Hi! I am new to LibreNMS (and PHP…) but have solved this issue by editing includes/polling/os/zxr10.inc.php. But my config is not valid anymore of course. Perhaps you can include my code (or a better version of it):

preg_match(’/Version…V(.+),.+,/’, $device[‘sysDescr’], $matches);

$version = $matches[‘1’];

preg_match(’/(.+) Software,/’, $device[‘sysDescr’], $matches);

$hardware = $matches[‘1’];

sysDescr: ZTE 5128E-FI Software, 5900 Version: V3.01.10.B31, RELEASE SOFTWARE, Product Version : V1.4

Now gives:

Hardware: ZTE ZXR10 5960-32DL
OS: 3.01.10.B31