System monitoring can help to detect anomalies, but crafting monitors for robot systems is difficult due to the inherent complexity, changing, and uncertain operating environment. We address this challenge by automatically inferring system invariants and synthesizing those invariants into monitors to detect faults with an approach inspired by state of the art software engineering methods. Our approach is novel in that: (1) It automatically derives invariants from messages; (2) The invariants types are tailored to match the spatial, temporal, and architectural attributes of robotic systems; and (3) It automatically classifies and synthesizes invariants into an online invariants monitor node. We have assessed the approach in the context of two unmanned aerial vehicle systems running robot operating system. We found that monitoring the inferred invariants can reduce system failure rates when facing unexpected contexts from 76 to 11 %, and can detect differences between the lab environment and the field deployments.