Automotive, aerospace, industrial control, and railway systems are examples of application domains which are particularly characterized by the need for developing and managing critical systems. Model-driven engineering is recognized as an effective solution to leverage abstraction and automation while developing complex systems. One of the major and key challenges in the model-driven engineering of critical software systems is the integration of design and runtime aspects. Even though several methods and tools are available for performing measurements of runtime properties, the ability to trace them with design models is still limited. In the context of a real railway system, this paper presents a model-based approach that has been conceived to analyze runtime data (coming from different sensors), to produce corresponding traceability models and to automatically infer from them potential design issues that might need to be fixed in order to solve detected system malfunctionings.