Yes, I know it is a permission problem, but I have tried a lot of methods, but there is no way to solve it, as follows:
chmod g+w /opt/librenms/cache
chmod 777 /opt/librenms/cache
touch /opt/librenms/cache/devices_relationships.cache
chown librenms:librenms /opt/librenms/cache/devices_relationships.cache
chmod 664 /opt/librenms/cache/*
setfacl -R -m g::rwx /opt/librenms/cache